diff --git a/.gitignore b/.gitignore index d066dbaba1..507f258b15 100644 --- a/.gitignore +++ b/.gitignore @@ -6,6 +6,7 @@ var/ composer.lock .php-cs-fixer.cache .phpunit.result.cache +.phpunit.cache/ /.deptrac.cache phpstan.neon .rules/ diff --git a/composer.json b/composer.json index 529f143c68..427c221bf3 100644 --- a/composer.json +++ b/composer.json @@ -71,11 +71,11 @@ "ibexa/rector": "~6.0.x-dev", "ibexa/test-core": "~6.0.x-dev", "jenner/simple_fork": "^1.2", - "matthiasnoback/symfony-dependency-injection-test": "^5.0", + "matthiasnoback/symfony-dependency-injection-test": "^6.0", "phpstan/phpstan": "^2.0", "phpstan/phpstan-phpunit": "^2.0", "phpstan/phpstan-symfony": "^2.0", - "phpunit/phpunit": "^9.6", + "phpunit/phpunit": "^11.5", "symfony/phpunit-bridge": "^7.4", "symfony/runtime": "^7.4", "webmozart/assert": "^2.3" diff --git a/phpstan-baseline.neon b/phpstan-baseline.neon index bdaf82dc4f..e85dc848c9 100644 --- a/phpstan-baseline.neon +++ b/phpstan-baseline.neon @@ -18679,62 +18679,8 @@ parameters: path: tests/bundle/Core/ChainConfigResolverTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\ChainConfigResolverTest\:\:getParameterProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/ChainConfigResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\ChainConfigResolverTest\:\:testGetDefaultNamespace\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/ChainConfigResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\ChainConfigResolverTest\:\:testGetParameter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/ChainConfigResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\ChainConfigResolverTest\:\:testGetParameterInvalid\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/ChainConfigResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\ChainConfigResolverTest\:\:testHasParameterFalse\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/ChainConfigResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\ChainConfigResolverTest\:\:testHasParameterTrue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/ChainConfigResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\ChainConfigResolverTest\:\:testPriority\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/ChainConfigResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\ChainConfigResolverTest\:\:testReSortResolvers\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/ChainConfigResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\ChainConfigResolverTest\:\:testSetDefaultNamespace\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/ChainConfigResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\ChainConfigResolverTest\:\:testSortResolvers\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\ChainConfigResolverTest\:\:createResolverMocks\(\) should return array\ but returns array\\.$#' + identifier: return.type count: 1 path: tests/bundle/Core/ChainConfigResolverTest.php @@ -18750,90 +18696,18 @@ parameters: count: 1 path: tests/bundle/Core/ChainConfigResolverTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\ChainConfigResolverPassTest\:\:addResolverProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/ChainConfigResolverPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\ChainConfigResolverPassTest\:\:testAddResolver\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/ChainConfigResolverPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\ChainRoutingPassTest\:\:addRouterProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/ChainRoutingPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\ChainRoutingPassTest\:\:testAddRouter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/ChainRoutingPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\ChainRoutingPassTest\:\:testAddRouterWithDefaultRouter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/ChainRoutingPassTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\FieldTypeParameterProviderRegistryPassTest\:\:tagsProvider\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 path: tests/bundle/Core/DependencyInjection/Compiler/FieldTypeParameterProviderRegistryPassTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\FieldTypeParameterProviderRegistryPassTest\:\:testRegisterFieldType\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/FieldTypeParameterProviderRegistryPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\FieldTypeParameterProviderRegistryPassTest\:\:testRegisterFieldTypeNoAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/FieldTypeParameterProviderRegistryPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\FragmentPassTest\:\:testProcess\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/FragmentPassTest.php - - message: '#^Offset 0 might not exist on array\|string\|null\.$#' identifier: offsetAccess.notFound count: 1 path: tests/bundle/Core/DependencyInjection/Compiler/FragmentPassTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\NotificationRendererPassTest\:\:testAddRenderer\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/NotificationRendererPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\NotificationRendererPassTest\:\:testAddRendererWithoutAliasThrowsLogicException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/NotificationRendererPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\PlaceholderProviderPassTest\:\:testAddProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/PlaceholderProviderPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\PlaceholderProviderPassTest\:\:testAddProviderWithoutType\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/PlaceholderProviderPassTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\QueryTypePassTest\:\:tagsProvider\(\) return type has no value type specified in iterable type iterable\.$#' identifier: missingType.iterableValue @@ -18852,36 +18726,6 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/Compiler/RegisterSearchEnginePassTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\RegisterStorageEnginePassTest\:\:testRegisterDefaultStorageEngine\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/RegisterStorageEnginePassTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\RegisterStorageEnginePassTest\:\:testRegisterStorageEngine\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/RegisterStorageEnginePassTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\RegisterStorageEnginePassTest\:\:testRegisterStorageEngineNoAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/RegisterStorageEnginePassTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\SlugConverterConfigurationPassTest\:\:configurationProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/SlugConverterConfigurationPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\SlugConverterConfigurationPassTest\:\:testMergeConfigurations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/SlugConverterConfigurationPassTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\SlugConverterConfigurationPassTest\:\:testMergeConfigurations\(\) has parameter \$commandsToAdd with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue @@ -18912,30 +18756,6 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/Compiler/TranslationCollectorPassTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\URLHandlerPassTest\:\:testRegisterURLHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/URLHandlerPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\URLHandlerPassTest\:\:testRegisterURLHandlerNoScheme\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/URLHandlerPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\ViewProvidersPassTest\:\:addViewProviderProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/ViewProvidersPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\ViewProvidersPassTest\:\:testAddViewProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Compiler/ViewProvidersPassTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Compiler\\ViewProvidersPassTest\:\:testAddViewProvider\(\) has parameter \$declaredPriority with no type specified\.$#' identifier: missingType.parameter @@ -18948,18 +18768,6 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/Compiler/ViewProvidersPassTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\ComplexSettings\\ComplexSettingParserTest\:\:provideSettings\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/ComplexSettings/ComplexSettingParserTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\ComplexSettings\\ComplexSettingParserTest\:\:testContainsDynamicSettings\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/ComplexSettings/ComplexSettingParserTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\ComplexSettings\\ComplexSettingParserTest\:\:testContainsDynamicSettings\(\) has parameter \$expected with no type specified\.$#' identifier: missingType.parameter @@ -18972,12 +18780,6 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/Configuration/ComplexSettings/ComplexSettingParserTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\ComplexSettings\\ComplexSettingParserTest\:\:testParseComplexSetting\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/ComplexSettings/ComplexSettingParserTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\ComplexSettings\\ComplexSettingParserTest\:\:testParseComplexSetting\(\) has parameter \$expected with no type specified\.$#' identifier: missingType.parameter @@ -18990,12 +18792,6 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/Configuration/ComplexSettings/ComplexSettingParserTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\ComplexSettings\\ComplexSettingValueResolverTest\:\:testGetArgumentValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/ComplexSettings/ComplexSettingValueResolverTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\ConfigResolver\\ChainConfigResolverTest\:\:hasParameterProvider\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue @@ -19080,54 +18876,6 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/Configuration/Parser/CommonTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\CommonTest\:\:sessionSettingsProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/CommonTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\CommonTest\:\:testApiKeysSettings\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/CommonTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\CommonTest\:\:testDefaultPage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/CommonTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\CommonTest\:\:testIndexPage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/CommonTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\CommonTest\:\:testMiscSettings\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/CommonTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\CommonTest\:\:testNoUserSettings\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/CommonTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\CommonTest\:\:testNonExistentSettings\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/CommonTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\CommonTest\:\:testSessionSettings\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/CommonTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\CommonTest\:\:testSessionSettings\(\) has parameter \$expected with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue @@ -19140,12 +18888,6 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/Configuration/Parser/CommonTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\CommonTest\:\:testUserSettings\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/CommonTest.php - - message: '#^Parameter \#1 \$input of static method Symfony\\Component\\Yaml\\Yaml\:\:parse\(\) expects string, string\|false given\.$#' identifier: argument.type @@ -19164,24 +18906,12 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/Configuration/Parser/CommonTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\ContentTest\:\:contentSettingsProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\ContentTest\:\:getMinimalConfiguration\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 path: tests/bundle/Core/DependencyInjection/Configuration/Parser/ContentTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\ContentTest\:\:testContentSettings\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\ContentTest\:\:testContentSettings\(\) has parameter \$config with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue @@ -19194,12 +18924,6 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/Configuration/Parser/ContentTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\ContentTest\:\:testDefaultContentSettings\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/ContentTest.php - - message: '#^Parameter \#1 \$input of static method Symfony\\Component\\Yaml\\Yaml\:\:parse\(\) expects string, string\|false given\.$#' identifier: argument.type @@ -19212,18 +18936,6 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/Configuration/Parser/FieldType/ImageAssetTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\FieldType\\ImageAssetTest\:\:testDefaultImageAssetSettings\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/FieldType/ImageAssetTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\FieldType\\ImageAssetTest\:\:testImageAssetSettings\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/FieldType/ImageAssetTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\FieldType\\ImageAssetTest\:\:testImageAssetSettings\(\) has parameter \$config with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue @@ -19242,12 +18954,6 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/Configuration/Parser/IOTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\IOTest\:\:testHandlersConfig\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/IOTest.php - - message: '#^Parameter \#1 \$input of static method Symfony\\Component\\Yaml\\Yaml\:\:parse\(\) expects string, string\|false given\.$#' identifier: argument.type @@ -19272,18 +18978,6 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/Configuration/Parser/ImageTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\ImageTest\:\:testPrePostParameters\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/ImageTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\ImageTest\:\:testVariations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/ImageTest.php - - message: '#^Parameter \#1 \$input of static method Symfony\\Component\\Yaml\\Yaml\:\:parse\(\) expects string, string\|false given\.$#' identifier: argument.type @@ -19303,46 +18997,22 @@ parameters: path: tests/bundle/Core/DependencyInjection/Configuration/Parser/LanguagesTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\LanguagesTest\:\:testLanguagesSingleSiteaccess\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$input of static method Symfony\\Component\\Yaml\\Yaml\:\:parse\(\) expects string, string\|false given\.$#' + identifier: argument.type count: 1 path: tests/bundle/Core/DependencyInjection/Configuration/Parser/LanguagesTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\LanguagesTest\:\:testLanguagesSiteaccessGroup\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\TemplatesTest\:\:getExpectedConfigFieldDefinitionSettingsTemplates\(\) has parameter \$config with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/LanguagesTest.php + path: tests/bundle/Core/DependencyInjection/Configuration/Parser/TemplatesTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\LanguagesTest\:\:testTranslationSiteAccesses\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\TemplatesTest\:\:getExpectedConfigFieldDefinitionSettingsTemplates\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/LanguagesTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\LanguagesTest\:\:testTranslationSiteAccessesWithGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/LanguagesTest.php - - - - message: '#^Parameter \#1 \$input of static method Symfony\\Component\\Yaml\\Yaml\:\:parse\(\) expects string, string\|false given\.$#' - identifier: argument.type - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/LanguagesTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\TemplatesTest\:\:getExpectedConfigFieldDefinitionSettingsTemplates\(\) has parameter \$config with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/TemplatesTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\TemplatesTest\:\:getExpectedConfigFieldDefinitionSettingsTemplates\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/TemplatesTest.php + path: tests/bundle/Core/DependencyInjection/Configuration/Parser/TemplatesTest.php - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\TemplatesTest\:\:getExpectedConfigFieldTemplates\(\) has parameter \$config with no value type specified in iterable type array\.$#' @@ -19362,18 +19032,6 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/Configuration/Parser/TemplatesTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\TemplatesTest\:\:testFieldDefinitionSettingsTemplates\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/TemplatesTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\TemplatesTest\:\:testFieldTemplates\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/TemplatesTest.php - - message: '#^Parameter \#1 \$input of static method Symfony\\Component\\Yaml\\Yaml\:\:parse\(\) expects string, string\|false given\.$#' identifier: argument.type @@ -19392,18 +19050,6 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/Configuration/Parser/ViewTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\ViewTest\:\:testContentView\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/ViewTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Parser\\ViewTest\:\:testLocationView\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Parser/ViewTest.php - - message: '#^Parameter \#1 \$input of static method Symfony\\Component\\Yaml\\Yaml\:\:parse\(\) expects string, string\|false given\.$#' identifier: argument.type @@ -19428,66 +19074,6 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ConfigurationProcessorTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ConfigurationProcessorTest\:\:testConstruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ConfigurationProcessorTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ConfigurationProcessorTest\:\:testGetSetContextualizer\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ConfigurationProcessorTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ConfigurationProcessorTest\:\:testMapConfigArray\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ConfigurationProcessorTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ConfigurationProcessorTest\:\:testMapConfigClosure\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ConfigurationProcessorTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ConfigurationProcessorTest\:\:testMapConfigHookableMapperObject\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ConfigurationProcessorTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ConfigurationProcessorTest\:\:testMapConfigMapperObject\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ConfigurationProcessorTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ConfigurationProcessorTest\:\:testMapSetting\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ConfigurationProcessorTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ContextualizerTest\:\:fullMapConfigArrayProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ContextualizerTest\:\:setContextualParameterProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ContextualizerTest\:\:testFullMapConfigArray\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ContextualizerTest\:\:testFullMapConfigArray\(\) has parameter \$config with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue @@ -19542,66 +19128,6 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ContextualizerTest\:\:testGetSetAvailableSiteAccesses\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ContextualizerTest\:\:testGetSetContainer\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ContextualizerTest\:\:testGetSetGroupsBySA\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ContextualizerTest\:\:testGetSetNamespace\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ContextualizerTest\:\:testGetSetSANodeName\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ContextualizerTest\:\:testMapConfigArray\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ContextualizerTest\:\:testMapConfigArraySecondLevel\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ContextualizerTest\:\:testMapConfigArrayUnique\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ContextualizerTest\:\:testMapSetting\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ContextualizerTest\:\:testSetContextualParameter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ContextualizerTest\:\:testSetContextualParameter\(\) has parameter \$parameterName with no type specified\.$#' identifier: missingType.parameter @@ -19620,6 +19146,12 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php + - + message: '#^Offset ''heyho'' on array\{siteaccess\: array\{list\: array\{''krondor''\}, groups\: array\{midkemia\: array\{''krondor''\}, triagia\: array\{''krondor''\}\}\}, heyho\: array\{\}\|array\{krondor\: array\{location_view\: array\{full\: array\{Wizard\: array\{template\: ''wizard\.html\.twig''\}, Sorcerer\: array\{template\: ''sorcerer\.html\.twig''\}\}\}\}\}\|array\{krondor\: array\{wizards\: array\{''Kulgan'', ''Macros the Black'', ''Pug'', ''Rogen'', ''William''\}\}\}\|array\{midkemia\: array\{location_view\: array\{full\: array\{Dwarve\: array\{template\: ''dwarve\.html\.twig''\}, Sorcerer\: array\{template\: ''sorcerer2\.html\.twig''\}\}\}\}, krondor\: array\{location_view\: array\{full\: array\{Moredhel\: array\{template\: ''moredhel\.html\.twig''\}, Sorcerer\: array\{template\: ''sorcerer3\.html\.twig''\}\}\}\}\}\|array\{midkemia\: array\{location_view\: array\{full\: array\{Dwarve\: array\{template\: ''dwarve\.html\.twig''\}, Sorcerer\: array\{template\: ''sorcerer2\.html\.twig''\}\}\}\}, triagia\?\: array\{location_view\: array\{full\: array\{Moredhel\: array\{template\: ''moredhel\.html\.twig''\}, Sorcerer\: array\{template\: ''sorcerer3\.html\.twig''\}\}\}\}, krondor\?\: array\{location_view\: array\{full\: array\{Moredhel\: array\{template\: ''moredhel2\.html\.twig''\}, Warrior\: array\{template\: ''warrior\.html\.twig''\}\}\}\}\}\|array\{midkemia\: array\{wizards\: array\{''Kulgan'', ''Macros the Black''\}\}\}\|array\{midkemia\: array\{wizards\: array\{''Macros the Black''\}\}, triagia\: array\{wizards\: array\{''Pug'', ''William'', ''Kulgan''\}\|array\{''Pug''\}\}, krondor\: array\{wizards\: array\{''Rogen'', ''Pug'', ''Rogen'', ''Macros the Black''\}\|array\{0\: ''Rogen'', 1\?\: ''Pug''\}\}\}\|array\{midkemia\: array\{wizards\: array\{''Pug'', ''Rogen'', ''William''\}\}\}\|array\{midkemia\: array\{wizards\: array\{0\: ''Pug'', 1\?\: ''Rogen''\}\}, triagia\: array\{wizards\: array\{''Rogen''\}\}\|array\{wizards\: array\{''William''\}\}, krondor\?\: array\{wizards\: array\{''William''\}\}\}\|array\{midkemia\?\: array\{location_view\: array\{full\: array\{Wizard\: array\{template\: ''wizard\.html\.twig''\}, Sorcerer\: array\{template\: ''sorcerer\.html\.twig''\}\}\}\}, triagia\?\: array\{location_view\: array\{full\: array\{Dwarve\: array\{template\: ''dwarve\.html\.twig''\}, Sorcerer\: array\{template\: ''sorcerer2\.html\.twig''\}\}\}\}, krondor\?\: array\{location_view\: array\{full\: array\{Moredhel\: array\{template\: ''moredhel\.html\.twig''\}, Sorcerer\: array\{template\: ''sorcerer3\.html\.twig''\}\}\}\}\}\|array\{triagia\: array\{location_view\: array\{full\: array\{Wizard\: array\{template\: ''wizard\.html\.twig''\}, Sorcerer\: array\{template\: ''sorcerer\.html\.twig''\}\}\}\}, krondor\: array\{location_view\: array\{full\: array\{Dwarve\: array\{template\: ''dwarve\.html\.twig''\}, Sorcerer\: array\{template\: ''sorcerer2\.html\.twig''\}\}\}\}\}\|array\{triagia\: array\{wizards\: array\{''Kulgan'', ''Macros the Black'', ''Pug'', ''Rogen'', ''William''\}\}\}\} in isset\(\) always exists and is not nullable\.$#' + identifier: isset.offset + count: 1 + path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php + - message: '#^Property Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\ContextualizerTest\:\:\$availableSAs type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue @@ -19638,24 +19170,6 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\DynamicSettingParserTest\:\:isDynamicSettingProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/DynamicSettingParserTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\DynamicSettingParserTest\:\:parseDynamicSettingProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/DynamicSettingParserTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\DynamicSettingParserTest\:\:testIsDynamicSetting\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/DynamicSettingParserTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\DynamicSettingParserTest\:\:testIsDynamicSetting\(\) has parameter \$expected with no type specified\.$#' identifier: missingType.parameter @@ -19668,12 +19182,6 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/DynamicSettingParserTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\DynamicSettingParserTest\:\:testParseDynamicSetting\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/DynamicSettingParserTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\DynamicSettingParserTest\:\:testParseDynamicSetting\(\) has parameter \$expected with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue @@ -19686,42 +19194,6 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/DynamicSettingParserTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\SiteAccessAware\\DynamicSettingParserTest\:\:testParseDynamicSettingFail\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/DynamicSettingParserTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Suggestion\\Collector\\SuggestionCollectorTest\:\:testAddHasGetSuggestions\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Suggestion/Collector/SuggestionCollectorTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Suggestion\\ConfigSuggestionTest\:\:testConfigSuggestion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Suggestion/ConfigSuggestionTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Suggestion\\ConfigSuggestionTest\:\:testEmptyConstructor\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Suggestion/ConfigSuggestionTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Suggestion\\Formatter\\YamlSuggestionFormatterTest\:\:testFormat\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Suggestion/Formatter/YamlSuggestionFormatterTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Configuration\\Suggestion\\Formatter\\YamlSuggestionFormatterTest\:\:testFormatNoSuggestion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Configuration/Suggestion/Formatter/YamlSuggestionFormatterTest.php - - message: '#^Argument of an invalid type array\|bool\|float\|int\|string\|null supplied for foreach, only iterables are supported\.$#' identifier: foreach.nonIterable @@ -19746,12 +19218,6 @@ parameters: count: 1 path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:cacheConfigurationProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:getFilteringQueryBuilderData\(\) return type has no value type specified in iterable type iterable\.$#' identifier: missingType.iterableValue @@ -19765,230 +19231,98 @@ parameters: path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:repositoriesConfigurationFieldGroupsProvider\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testCacheConfiguration\(\) has parameter \$customCacheConfig with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testCacheConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testRepositoriesConfigurationFieldGroups\(\) has parameter \$expectedRepositories with no type specified\.$#' + identifier: missingType.parameter count: 1 path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testCacheConfiguration\(\) has parameter \$customCacheConfig with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testRepositoriesConfigurationFieldGroups\(\) has parameter \$repositories with no type specified\.$#' + identifier: missingType.parameter count: 1 path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testCacheConfigurationCustomPurgeService\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$input of static method Symfony\\Component\\Yaml\\Yaml\:\:parse\(\) expects string, string\|false given\.$#' + identifier: argument.type count: 1 path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testImageMagickConfigurationBasic\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$value of function count expects array\|Countable, array\|bool\|float\|int\|string\|null given\.$#' + identifier: argument.type count: 1 path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testImageMagickConfigurationFilters\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 + message: '#^Parameter \#2 \$array of static method PHPUnit\\Framework\\Assert\:\:assertArrayHasKey\(\) expects array\\|ArrayAccess\<\(int\|string\), mixed\>, array\|bool\|float\|int\|string\|null given\.$#' + identifier: argument.type + count: 2 path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testImagePlaceholderConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#2 \$haystack of static method PHPUnit\\Framework\\Assert\:\:assertContains\(\) expects iterable, array\|bool\|float\|int\|string\|null given\.$#' + identifier: argument.type count: 1 path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testLocaleConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#2 \.\.\.\$arrays of function array_merge_recursive expects array, array\|bool\|float\|int\|string\|null given\.$#' + identifier: argument.type count: 1 path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testRegisteredPolicies\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:\$minimalConfig has no type specified\.$#' + identifier: missingType.property count: 1 path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testRepositoriesConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:\$minimalConfig is never read, only written\.$#' + identifier: property.onlyWritten count: 1 path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testRepositoriesConfigurationCompatibility\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:\$siteaccessConfig has no type specified\.$#' + identifier: missingType.property count: 1 path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testRepositoriesConfigurationCompatibility2\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Security\\PolicyProvider\\PoliciesConfigBuilderTest\:\:policiesConfigProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php + path: tests/bundle/Core/DependencyInjection/Security/PolicyProvider/PoliciesConfigBuilderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testRepositoriesConfigurationEmpty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Security\\PolicyProvider\\PoliciesConfigBuilderTest\:\:testAddConfig\(\) has parameter \$configOne with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php + path: tests/bundle/Core/DependencyInjection/Security/PolicyProvider/PoliciesConfigBuilderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testRepositoriesConfigurationFieldGroups\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Security\\PolicyProvider\\PoliciesConfigBuilderTest\:\:testAddConfig\(\) has parameter \$configTwo with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php + path: tests/bundle/Core/DependencyInjection/Security/PolicyProvider/PoliciesConfigBuilderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testRepositoriesConfigurationFieldGroups\(\) has parameter \$expectedRepositories with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Security\\PolicyProvider\\PoliciesConfigBuilderTest\:\:testAddConfig\(\) has parameter \$expectedConfig with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php + path: tests/bundle/Core/DependencyInjection/Security/PolicyProvider/PoliciesConfigBuilderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testRepositoriesConfigurationFieldGroups\(\) has parameter \$repositories with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testRepositoriesConfigurationSearchEmpty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testRepositoriesConfigurationStorageEmpty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testRoutingConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testSiteAccessConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testSiteAccessNoConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:testUrlAliasConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - - - message: '#^Parameter \#1 \$input of static method Symfony\\Component\\Yaml\\Yaml\:\:parse\(\) expects string, string\|false given\.$#' - identifier: argument.type - count: 1 - path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - - - message: '#^Parameter \#1 \$value of function count expects array\|Countable, array\|bool\|float\|int\|string\|null given\.$#' - identifier: argument.type - count: 1 - path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - - - message: '#^Parameter \#2 \$array of static method PHPUnit\\Framework\\Assert\:\:assertArrayHasKey\(\) expects array\|ArrayAccess, array\|bool\|float\|int\|string\|null given\.$#' - identifier: argument.type - count: 2 - path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - - - message: '#^Parameter \#2 \$haystack of static method PHPUnit\\Framework\\Assert\:\:assertContains\(\) expects iterable, array\|bool\|float\|int\|string\|null given\.$#' - identifier: argument.type - count: 1 - path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - - - message: '#^Parameter \#2 \.\.\.\$arrays of function array_merge_recursive expects array, array\|bool\|float\|int\|string\|null given\.$#' - identifier: argument.type - count: 1 - path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - - - message: '#^Property Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:\$minimalConfig has no type specified\.$#' - identifier: missingType.property - count: 1 - path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - - - message: '#^Property Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:\$minimalConfig is never read, only written\.$#' - identifier: property.onlyWritten - count: 1 - path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - - - message: '#^Property Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\IbexaCoreExtensionTest\:\:\$siteaccessConfig has no type specified\.$#' - identifier: missingType.property - count: 1 - path: tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Security\\PolicyProvider\\PoliciesConfigBuilderTest\:\:policiesConfigProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/bundle/Core/DependencyInjection/Security/PolicyProvider/PoliciesConfigBuilderTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Security\\PolicyProvider\\PoliciesConfigBuilderTest\:\:testAddConfig\(\) has parameter \$configOne with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/bundle/Core/DependencyInjection/Security/PolicyProvider/PoliciesConfigBuilderTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Security\\PolicyProvider\\PoliciesConfigBuilderTest\:\:testAddConfig\(\) has parameter \$configTwo with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/bundle/Core/DependencyInjection/Security/PolicyProvider/PoliciesConfigBuilderTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Security\\PolicyProvider\\PoliciesConfigBuilderTest\:\:testAddConfig\(\) has parameter \$expectedConfig with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/bundle/Core/DependencyInjection/Security/PolicyProvider/PoliciesConfigBuilderTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Security\\PolicyProvider\\PoliciesConfigBuilderTest\:\:testAddResource\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Security/PolicyProvider/PoliciesConfigBuilderTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Security\\PolicyProvider\\YamlPolicyProviderTest\:\:testMultipleYaml\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Security/PolicyProvider/YamlPolicyProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Security\\PolicyProvider\\YamlPolicyProviderTest\:\:testSingleYaml\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/DependencyInjection/Security/PolicyProvider/YamlPolicyProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Stub\\QueryTypeBundle\\QueryType\\TestQueryType\:\:getQuery\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\DependencyInjection\\Stub\\QueryTypeBundle\\QueryType\\TestQueryType\:\:getQuery\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 path: tests/bundle/Core/DependencyInjection/Stub/QueryTypeBundle/QueryType/TestQueryType.php @@ -20052,36 +19386,6 @@ parameters: count: 2 path: tests/bundle/Core/EventListener/BackgroundIndexingTerminateListenerTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\BackgroundIndexingTerminateListenerTest\:\:indexDeleteProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/BackgroundIndexingTerminateListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\BackgroundIndexingTerminateListenerTest\:\:indexingProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/BackgroundIndexingTerminateListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\BackgroundIndexingTerminateListenerTest\:\:testGetSubscribedEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/BackgroundIndexingTerminateListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\BackgroundIndexingTerminateListenerTest\:\:testIndexDelete\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/BackgroundIndexingTerminateListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\BackgroundIndexingTerminateListenerTest\:\:testIndexing\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/BackgroundIndexingTerminateListenerTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\BackgroundIndexingTerminateListenerTest\:\:testIndexing\(\) has parameter \$values with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue @@ -20100,12 +19404,6 @@ parameters: count: 1 path: tests/bundle/Core/EventListener/BackgroundIndexingTerminateListenerTest.php - - - message: '#^Parameter \#1 \$stub of method PHPUnit\\Framework\\MockObject\\Builder\\InvocationMocker\:\:will\(\) expects PHPUnit\\Framework\\MockObject\\Stub\\Stub, PHPUnit\\Framework\\MockObject\\Stub given\.$#' - identifier: argument.type - count: 2 - path: tests/bundle/Core/EventListener/BackgroundIndexingTerminateListenerTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\BackwardCompatibleCommandListenerTest\:\:createBackwardCompatibleCommand\(\) has parameter \$aliases with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue @@ -20136,18 +19434,6 @@ parameters: count: 1 path: tests/bundle/Core/EventListener/ConfigScopeListenerTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\ConfigScopeListenerTest\:\:testGetSubscribedEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/ConfigScopeListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\ConfigScopeListenerTest\:\:testOnConfigScopeChange\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/ConfigScopeListenerTest.php - - message: '#^Parameter \#1 \$viewProviders of method Ibexa\\Bundle\\Core\\EventListener\\ConfigScopeListener\:\:setViewProviders\(\) expects array, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' identifier: argument.type @@ -20161,95 +19447,17 @@ parameters: path: tests/bundle/Core/EventListener/ConfigScopeListenerTest.php - - message: '#^Property Ibexa\\Tests\\Bundle\\Core\\EventListener\\ConfigScopeListenerTest\:\:\$viewProviders \(PHPUnit\\Framework\\MockObject\\MockObject\) does not accept array\\.$#' + message: '#^Property Ibexa\\Tests\\Bundle\\Core\\EventListener\\ConfigScopeListenerTest\:\:\$viewProviders \(PHPUnit\\Framework\\MockObject\\MockObject\) does not accept array\\.$#' identifier: assign.propertyType count: 1 path: tests/bundle/Core/EventListener/ConfigScopeListenerTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\ConsoleCommandListenerTest\:\:testDefaultSiteAccess\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/ConsoleCommandListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\ConsoleCommandListenerTest\:\:testGetSubscribedEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/ConsoleCommandListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\ConsoleCommandListenerTest\:\:testInvalidSiteAccessDev\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/ConsoleCommandListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\ConsoleCommandListenerTest\:\:testInvalidSiteAccessProd\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/ConsoleCommandListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\ConsoleCommandListenerTest\:\:testValidSiteAccess\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/ConsoleCommandListenerTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\ContentDownloadRouteReferenceListenerTest\:\:getListener\(\) has no return type specified\.$#' identifier: missingType.return count: 1 path: tests/bundle/Core/EventListener/ContentDownloadRouteReferenceListenerTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\ContentDownloadRouteReferenceListenerTest\:\:testDownloadNameOverrideWorks\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/ContentDownloadRouteReferenceListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\ContentDownloadRouteReferenceListenerTest\:\:testGeneratesCorrectRouteReference\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/ContentDownloadRouteReferenceListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\ContentDownloadRouteReferenceListenerTest\:\:testIgnoresOtherRoutes\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/ContentDownloadRouteReferenceListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\ContentDownloadRouteReferenceListenerTest\:\:testThrowsExceptionOnBadContentParameter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/ContentDownloadRouteReferenceListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\ContentDownloadRouteReferenceListenerTest\:\:testThrowsExceptionOnBadFieldIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/ContentDownloadRouteReferenceListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\IndexRequestListenerTest\:\:indexPageProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/IndexRequestListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\IndexRequestListenerTest\:\:testOnKernelRequestIndexNotOnIndexPage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/IndexRequestListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\IndexRequestListenerTest\:\:testOnKernelRequestIndexOnIndexPage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/IndexRequestListenerTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\IndexRequestListenerTest\:\:testOnKernelRequestIndexOnIndexPage\(\) has parameter \$configuredIndexPath with no type specified\.$#' identifier: missingType.parameter @@ -20268,12 +19476,6 @@ parameters: count: 1 path: tests/bundle/Core/EventListener/IndexRequestListenerTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\IndexRequestListenerTest\:\:testSubscribedEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/IndexRequestListenerTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\LocaleListenerTest\:\:onKernelRequestProvider\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue @@ -20310,30 +19512,6 @@ parameters: count: 1 path: tests/bundle/Core/EventListener/LocaleListenerTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\OriginalRequestListenerTest\:\:testGetSubscribedEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/OriginalRequestListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\OriginalRequestListenerTest\:\:testOnKernelRequestNoOriginalRequest\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/OriginalRequestListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\OriginalRequestListenerTest\:\:testOnKernelRequestNotMaster\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/OriginalRequestListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\OriginalRequestListenerTest\:\:testOnKernelRequestWithOriginalRequest\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/OriginalRequestListenerTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\RejectExplicitFrontControllerRequestsListenerTest\:\:prohibitedRequestDataProvider\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue @@ -20347,70 +19525,16 @@ parameters: path: tests/bundle/Core/EventListener/RejectExplicitFrontControllerRequestsListenerTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\RequestEventListenerTest\:\:testOnKernelRequestForward\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/RequestEventListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\RequestEventListenerTest\:\:testOnKernelRequestForwardSubRequest\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Bundle\\Core\\EventListener\\RequestEventListenerTest\:\:\$event is never read, only written\.$#' + identifier: property.onlyWritten count: 1 path: tests/bundle/Core/EventListener/RequestEventListenerTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\RequestEventListenerTest\:\:testOnKernelRequestRedirect\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/RequestEventListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\RequestEventListenerTest\:\:testOnKernelRequestRedirectPrependSiteaccess\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/RequestEventListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\RequestEventListenerTest\:\:testOnKernelRequestRedirectSubRequest\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/RequestEventListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\RequestEventListenerTest\:\:testOnKernelRequestRedirectWithLocationId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/RequestEventListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\RequestEventListenerTest\:\:testSubscribedEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/RequestEventListenerTest.php - - - - message: '#^Property Ibexa\\Tests\\Bundle\\Core\\EventListener\\RequestEventListenerTest\:\:\$event is never read, only written\.$#' - identifier: property.onlyWritten - count: 1 - path: tests/bundle/Core/EventListener/RequestEventListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\RoutingListenerTest\:\:testGetSubscribedEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/RoutingListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\RoutingListenerTest\:\:testOnSiteAccessMatch\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/RoutingListenerTest.php - - - - message: '#^Parameter \#1 \$configResolver of class Ibexa\\Bundle\\Core\\EventListener\\RoutingListener constructor expects Ibexa\\Contracts\\Core\\SiteAccess\\ConfigResolverInterface, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type - count: 2 - path: tests/bundle/Core/EventListener/RoutingListenerTest.php + message: '#^Parameter \#1 \$configResolver of class Ibexa\\Bundle\\Core\\EventListener\\RoutingListener constructor expects Ibexa\\Contracts\\Core\\SiteAccess\\ConfigResolverInterface, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type + count: 2 + path: tests/bundle/Core/EventListener/RoutingListenerTest.php - message: '#^Parameter \#2 \$urlAliasRouter of class Ibexa\\Bundle\\Core\\EventListener\\RoutingListener constructor expects Symfony\\Component\\Routing\\RouterInterface, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' @@ -20436,24 +19560,6 @@ parameters: count: 1 path: tests/bundle/Core/EventListener/SessionSetDynamicNameListenerTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\SiteAccessListenerTest\:\:siteAccessMatchProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/SiteAccessListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\SiteAccessListenerTest\:\:testGetSubscribedEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/SiteAccessListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\SiteAccessListenerTest\:\:testOnSiteAccessMatchMasterRequest\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/SiteAccessListenerTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\SiteAccessListenerTest\:\:testOnSiteAccessMatchMasterRequest\(\) has parameter \$expectedSemanticPathinfo with no type specified\.$#' identifier: missingType.parameter @@ -20478,12 +19584,6 @@ parameters: count: 1 path: tests/bundle/Core/EventListener/SiteAccessListenerTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\SiteAccessListenerTest\:\:testOnSiteAccessMatchSubRequest\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/SiteAccessListenerTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\SiteAccessListenerTest\:\:testOnSiteAccessMatchSubRequest\(\) has parameter \$expectedViewParameters with no type specified\.$#' identifier: missingType.parameter @@ -20604,30 +19704,6 @@ parameters: count: 1 path: tests/bundle/Core/EventListener/Stubs/ViewProvider.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\ViewControllerListenerTest\:\:testGetControllerMatchedView\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/ViewControllerListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\ViewControllerListenerTest\:\:testGetControllerNoBuilder\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/ViewControllerListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\ViewControllerListenerTest\:\:testGetControllerWithClosure\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/ViewControllerListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventListener\\ViewControllerListenerTest\:\:testGetSubscribedEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventListener/ViewControllerListenerTest.php - - message: '#^Property Ibexa\\Tests\\Bundle\\Core\\EventListener\\ViewControllerListenerTest\:\:\$controllerResolver \(PHPUnit\\Framework\\MockObject\\MockObject&Symfony\\Component\\HttpKernel\\Controller\\ControllerResolver\) does not accept PHPUnit\\Framework\\MockObject\\MockObject&Symfony\\Component\\HttpKernel\\Controller\\ControllerResolverInterface\.$#' identifier: assign.propertyType @@ -20640,24 +19716,12 @@ parameters: count: 1 path: tests/bundle/Core/EventListener/ViewControllerListenerTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventSubscriber\\CrowdinRequestLocaleSubscriberTest\:\:testSetLocale\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventSubscriber/CrowdinRequestLocaleSubscriberTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventSubscriber\\CrowdinRequestLocaleSubscriberTest\:\:testSetLocale\(\) has parameter \$shouldHaveCustomLocale with no type specified\.$#' identifier: missingType.parameter count: 1 path: tests/bundle/Core/EventSubscriber/CrowdinRequestLocaleSubscriberTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventSubscriber\\CrowdinRequestLocaleSubscriberTest\:\:testSetRequestsProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/EventSubscriber/CrowdinRequestLocaleSubscriberTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\EventSubscriber\\TrustedHeaderClientIpEventSubscriberTest\:\:getTrustedHeaderEventSubscriberTestData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue @@ -20688,18 +19752,6 @@ parameters: count: 1 path: tests/bundle/Core/Fragment/DirectFragmentRendererTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Fragment\\FragmentListenerFactoryTest\:\:buildFragmentListenerProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/Fragment/FragmentListenerFactoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Fragment\\FragmentListenerFactoryTest\:\:testBuildFragmentListener\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/Fragment/FragmentListenerFactoryTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Fragment\\FragmentListenerFactoryTest\:\:testBuildFragmentListener\(\) has parameter \$isFragmentCandidate with no type specified\.$#' identifier: missingType.parameter @@ -20712,102 +19764,18 @@ parameters: count: 1 path: tests/bundle/Core/Fragment/FragmentListenerFactoryTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Fragment\\FragmentListenerFactoryTest\:\:testBuildFragmentListenerNoRequest\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/Fragment/FragmentListenerFactoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\AliasCleanerTest\:\:testRemoveAliases\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/Imagine/AliasCleanerTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\AliasGeneratorTest\:\:supportsValueProvider\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 path: tests/bundle/Core/Imagine/AliasGeneratorTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\BinaryLoaderTest\:\:testFindBadPathRoot\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/Imagine/BinaryLoaderTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\BinaryLoaderTest\:\:testFindMissing\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/Imagine/BinaryLoaderTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\BinaryLoaderTest\:\:testFindNotFound\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/Imagine/BinaryLoaderTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Cache\\Resolver\\ProxyResolverTest\:\:testResolveAndRemovePortUsingProxyHost\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/Imagine/Cache/Resolver/ProxyResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Cache\\Resolver\\ProxyResolverTest\:\:testResolveAndRemovePortUsingProxyHostWithTrailingSlash\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/Imagine/Cache/Resolver/ProxyResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Cache\\Resolver\\ProxyResolverTest\:\:testResolveUsingProxyHostWithTrailingSlash\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/Imagine/Cache/Resolver/ProxyResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Cache\\Resolver\\RelativeResolverTest\:\:testResolve\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/Imagine/Cache/Resolver/RelativeResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Cache\\ResolverFactoryTest\:\:testCreateProxyCacheResolver\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/Imagine/Cache/ResolverFactoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Cache\\ResolverFactoryTest\:\:testCreateRelativeCacheResolver\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/Imagine/Cache/ResolverFactoryTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\AbstractFilterTest\:\:getFilter\(\) has no return type specified\.$#' identifier: missingType.return count: 1 path: tests/bundle/Core/Imagine/Filter/AbstractFilterTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\AbstractFilterTest\:\:getSetOptionNoDefaulValueProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/Imagine/Filter/AbstractFilterTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\AbstractFilterTest\:\:getSetOptionWithDefaulValueProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/Imagine/Filter/AbstractFilterTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\AbstractFilterTest\:\:testGetSetOptionNoDefaultValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/Imagine/Filter/AbstractFilterTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\AbstractFilterTest\:\:testGetSetOptionNoDefaultValue\(\) has parameter \$optionName with no type specified\.$#' identifier: missingType.parameter @@ -20820,12 +19788,6 @@ parameters: count: 1 path: tests/bundle/Core/Imagine/Filter/AbstractFilterTest.php - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\AbstractFilterTest\:\:testGetSetOptionWithDefaultValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/Imagine/Filter/AbstractFilterTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\AbstractFilterTest\:\:testGetSetOptionWithDefaultValue\(\) has parameter \$defaultValue with no type specified\.$#' identifier: missingType.parameter @@ -20845,38498 +19807,18692 @@ parameters: path: tests/bundle/Core/Imagine/Filter/AbstractFilterTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\AbstractFilterTest\:\:testGetSetOptions\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\BorderFilterLoaderTest\:\:testLoad\(\) has parameter \$color with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/bundle/Core/Imagine/Filter/AbstractFilterTest.php + path: tests/bundle/Core/Imagine/Filter/Loader/BorderFilterLoaderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\FilterConfigurationTest\:\:testAll\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\BorderFilterLoaderTest\:\:testLoad\(\) has parameter \$thickX with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/bundle/Core/Imagine/Filter/FilterConfigurationTest.php + path: tests/bundle/Core/Imagine/Filter/Loader/BorderFilterLoaderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\FilterConfigurationTest\:\:testGetEzVariationImagineFilters\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\BorderFilterLoaderTest\:\:testLoad\(\) has parameter \$thickY with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/bundle/Core/Imagine/Filter/FilterConfigurationTest.php + path: tests/bundle/Core/Imagine/Filter/Loader/BorderFilterLoaderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\FilterConfigurationTest\:\:testGetEzVariationImagineOptions\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\BorderFilterLoaderTest\:\:testLoadInvalidOptions\(\) has parameter \$options with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/FilterConfigurationTest.php + path: tests/bundle/Core/Imagine/Filter/Loader/BorderFilterLoaderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\FilterConfigurationTest\:\:testGetEzVariationNoReference\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\CropFilterLoaderTest\:\:testLoadInvalidOptions\(\) has parameter \$options with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/FilterConfigurationTest.php + path: tests/bundle/Core/Imagine/Filter/Loader/CropFilterLoaderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\FilterConfigurationTest\:\:testGetEzVariationWithReference\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleDownOnlyFilterLoaderTest\:\:testLoadInvalidOptions\(\) has parameter \$options with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/FilterConfigurationTest.php + path: tests/bundle/Core/Imagine/Filter/Loader/ScaleDownOnlyFilterLoaderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\FilterConfigurationTest\:\:testGetNoEzVariationInvalidImagineFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleExactFilterLoaderTest\:\:testLoadInvalidOptions\(\) has parameter \$options with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/FilterConfigurationTest.php + path: tests/bundle/Core/Imagine/Filter/Loader/ScaleExactFilterLoaderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\FilterConfigurationTest\:\:testGetOnlyImagineFilters\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleFilterLoaderTest\:\:testLoadInvalidOptions\(\) has parameter \$options with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/FilterConfigurationTest.php + path: tests/bundle/Core/Imagine/Filter/Loader/ScaleFilterLoaderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\BorderFilterLoaderTest\:\:loadInvalidProvider\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Static method PHPUnit\\Framework\\TestCase\:\:createStub\(\) invoked with 2 parameters, 1 required\.$#' + identifier: arguments.count count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/BorderFilterLoaderTest.php + path: tests/bundle/Core/Imagine/Filter/Loader/ScaleHeightFilterLoaderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\BorderFilterLoaderTest\:\:loadProvider\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScalePercentFilterLoaderTest\:\:testLoadInvalidOptions\(\) has parameter \$options with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/BorderFilterLoaderTest.php + path: tests/bundle/Core/Imagine/Filter/Loader/ScalePercentFilterLoaderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\BorderFilterLoaderTest\:\:testLoad\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Static method PHPUnit\\Framework\\TestCase\:\:createStub\(\) invoked with 2 parameters, 1 required\.$#' + identifier: arguments.count count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/BorderFilterLoaderTest.php + path: tests/bundle/Core/Imagine/Filter/Loader/ScaleWidthFilterLoaderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\BorderFilterLoaderTest\:\:testLoad\(\) has parameter \$color with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\SwirlFilterLoaderTest\:\:testLoadWithOption\(\) has parameter \$degrees with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/BorderFilterLoaderTest.php + path: tests/bundle/Core/Imagine/Filter/Loader/SwirlFilterLoaderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\BorderFilterLoaderTest\:\:testLoad\(\) has parameter \$thickX with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderAliasGeneratorTest\:\:getVariationProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/BorderFilterLoaderTest.php + path: tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\BorderFilterLoaderTest\:\:testLoad\(\) has parameter \$thickY with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderAliasGeneratorTest\:\:supportsValueProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/BorderFilterLoaderTest.php + path: tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\BorderFilterLoaderTest\:\:testLoadDefaultColor\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderAliasGeneratorTest\:\:testGetVariationOriginalFound\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/BorderFilterLoaderTest.php + path: tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\BorderFilterLoaderTest\:\:testLoadInvalidOptions\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderAliasGeneratorTest\:\:testGetVariationOriginalNotFound\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/BorderFilterLoaderTest.php + path: tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\BorderFilterLoaderTest\:\:testLoadInvalidOptions\(\) has parameter \$options with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderAliasGeneratorTest\:\:testGetVariationReturnsPlaceholderIfBinaryDataIsNotAvailable\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/BorderFilterLoaderTest.php + path: tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\CropFilterLoaderTest\:\:loadInvalidProvider\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderAliasGeneratorTest\:\:testGetVariationSkipsPlaceholderGeneration\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/CropFilterLoaderTest.php + path: tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\CropFilterLoaderTest\:\:testLoad\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderAliasGeneratorTest\:\:\$placeholderOptions type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/CropFilterLoaderTest.php + path: tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\CropFilterLoaderTest\:\:testLoadInvalidOptions\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderProvider\\GenericProviderTest\:\:assertColorEquals\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/CropFilterLoaderTest.php + path: tests/bundle/Core/Imagine/PlaceholderProvider/GenericProviderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\CropFilterLoaderTest\:\:testLoadInvalidOptions\(\) has parameter \$options with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderProvider\\GenericProviderTest\:\:assertColorEquals\(\) has parameter \$expected with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/CropFilterLoaderTest.php + path: tests/bundle/Core/Imagine/PlaceholderProvider/GenericProviderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\GrayscaleFilterLoaderTest\:\:testLoad\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderProvider\\GenericProviderTest\:\:assertSizeEquals\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/GrayscaleFilterLoaderTest.php + path: tests/bundle/Core/Imagine/PlaceholderProvider/GenericProviderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ReduceNoiseFilterLoaderTest\:\:testLoadInvalidDriver\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderProvider\\GenericProviderTest\:\:assertSizeEquals\(\) has parameter \$expected with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ReduceNoiseFilterLoaderTest.php + path: tests/bundle/Core/Imagine/PlaceholderProvider/GenericProviderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleDownOnlyFilterLoaderTest\:\:loadInvalidProvider\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderProvider\\GenericProviderTest\:\:testGetPlaceholder\(\) has parameter \$expectedText with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleDownOnlyFilterLoaderTest.php + path: tests/bundle/Core/Imagine/PlaceholderProvider/GenericProviderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleDownOnlyFilterLoaderTest\:\:testLoad\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderProvider\\GenericProviderTest\:\:testGetPlaceholder\(\) has parameter \$options with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleDownOnlyFilterLoaderTest.php + path: tests/bundle/Core/Imagine/PlaceholderProvider/GenericProviderTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleDownOnlyFilterLoaderTest\:\:testLoadInvalidOptions\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleDownOnlyFilterLoaderTest.php + message: '#^Cannot access offset ''path'' on array\{scheme\?\: string, host\?\: string, port\?\: int\<0, 65535\>, user\?\: string, pass\?\: string, path\?\: string, query\?\: string, fragment\?\: string\}\|false\.$#' + identifier: offsetAccess.nonOffsetAccessible + count: 2 + path: tests/bundle/Core/Routing/DefaultRouterTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleDownOnlyFilterLoaderTest\:\:testLoadInvalidOptions\(\) has parameter \$options with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Offset ''scheme'' might not exist on array\{scheme\?\: string, host\: string, port\: int\<0, 65535\>, user\?\: string, pass\?\: string, path\?\: string, query\?\: string, fragment\?\: string\}\.$#' + identifier: offsetAccess.notFound count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleDownOnlyFilterLoaderTest.php + path: tests/bundle/Core/Routing/DefaultRouterTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleExactFilterLoaderTest\:\:loadInvalidProvider\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Offset ''scheme'' might not exist on array\{scheme\?\: string, host\: string, port\?\: int\<0, 65535\>, user\?\: string, pass\?\: string, path\?\: string, query\?\: string, fragment\?\: string\}\.$#' + identifier: offsetAccess.notFound count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleExactFilterLoaderTest.php + path: tests/bundle/Core/Routing/DefaultRouterTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleExactFilterLoaderTest\:\:testLoad\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#3 \$length of function substr expects int\|null, int\<0, max\>\|false given\.$#' + identifier: argument.type count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleExactFilterLoaderTest.php + path: tests/bundle/Core/Routing/DefaultRouterTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleExactFilterLoaderTest\:\:testLoadInvalidOptions\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Routing\\JsRouting\\ExposedRoutesExtractorTest\:\:getDataForTestGetBaseUrl\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleExactFilterLoaderTest.php + path: tests/bundle/Core/Routing/JsRouting/ExposedRoutesExtractorTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleExactFilterLoaderTest\:\:testLoadInvalidOptions\(\) has parameter \$options with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Call to an undefined method Ibexa\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouter\:\:setConfigResolver\(\)\.$#' + identifier: method.notFound count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleExactFilterLoaderTest.php + path: tests/bundle/Core/Routing/UrlAliasRouterTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleFilterLoaderTest\:\:loadInvalidProvider\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Routing\\UrlAliasRouterTest\:\:resetConfigResolver\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleFilterLoaderTest.php + path: tests/bundle/Core/Routing/UrlAliasRouterTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleFilterLoaderTest\:\:testLoadHeighten\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$configResolver of method Ibexa\\Bundle\\Core\\Routing\\UrlAliasRouter\:\:setConfigResolver\(\) expects Ibexa\\Contracts\\Core\\SiteAccess\\ConfigResolverInterface, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleFilterLoaderTest.php + path: tests/bundle/Core/Routing/UrlAliasRouterTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleFilterLoaderTest\:\:testLoadInvalidOptions\(\) has no return type specified\.$#' + message: '#^Parameter \#1 \$siteAccessMatcherRegistry of class Ibexa\\Bundle\\Core\\SiteAccess\\MatcherBuilder constructor expects Ibexa\\Bundle\\Core\\SiteAccess\\SiteAccessMatcherRegistryInterface, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type + count: 3 + path: tests/bundle/Core/SiteAccess/MatcherBuilderTest.php + + - + message: '#^Parameter \#1 \$matchers of class Ibexa\\Bundle\\Core\\SiteAccess\\SiteAccessMatcherRegistry constructor expects array\, array\ given\.$#' + identifier: argument.type + count: 1 + path: tests/bundle/Core/SiteAccess/SiteAccessMatcherRegistryTest.php + + - + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\URLChecker\\URLCheckerTest\:\:configureUrlHandlerRegistry\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleFilterLoaderTest.php + path: tests/bundle/Core/URLChecker/URLCheckerTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleFilterLoaderTest\:\:testLoadInvalidOptions\(\) has parameter \$options with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\URLChecker\\URLCheckerTest\:\:configureUrlHandlerRegistry\(\) has parameter \$schemes with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleFilterLoaderTest.php + path: tests/bundle/Core/URLChecker/URLCheckerTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleFilterLoaderTest\:\:testLoadWiden\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\URLChecker\\URLCheckerTest\:\:createGroupedUrls\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleFilterLoaderTest.php + path: tests/bundle/Core/URLChecker/URLCheckerTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleHeightDownOnlyFilterLoaderTest\:\:testLoad\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\URLChecker\\URLCheckerTest\:\:createGroupedUrls\(\) has parameter \$n with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleHeightDownOnlyFilterLoaderTest.php + path: tests/bundle/Core/URLChecker/URLCheckerTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleHeightDownOnlyFilterLoaderTest\:\:testLoadInvalid\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\URLChecker\\URLCheckerTest\:\:createGroupedUrls\(\) has parameter \$schemes with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleHeightDownOnlyFilterLoaderTest.php + path: tests/bundle/Core/URLChecker/URLCheckerTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleHeightFilterLoaderTest\:\:testLoad\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\URLChecker\\URLCheckerTest\:\:createSearchResults\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleHeightFilterLoaderTest.php + path: tests/bundle/Core/URLChecker/URLCheckerTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleHeightFilterLoaderTest\:\:testLoadFail\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Bundle\\Core\\URLChecker\\URLCheckerTest\:\:createSearchResults\(\) has parameter \$urls with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleHeightFilterLoaderTest.php + path: tests/bundle/Core/URLChecker/URLCheckerTest.php - - message: '#^Method PHPUnit\\Framework\\TestCase\:\:createMock\(\) invoked with 2 parameters, 1 required\.$#' - identifier: arguments.count + message: '#^Argument of an invalid type PHPUnit\\Framework\\MockObject\\MockObject supplied for foreach, only iterables are supported\.$#' + identifier: foreach.nonIterable count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleHeightFilterLoaderTest.php + path: tests/bundle/Debug/Collector/IbexaCoreCollectorTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScalePercentFilterLoaderTest\:\:loadInvalidProvider\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Bundle\\Debug\\Collector\\IbexaCoreCollectorTest\:\:getDataCollectorMock\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScalePercentFilterLoaderTest.php + path: tests/bundle/Debug/Collector/IbexaCoreCollectorTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScalePercentFilterLoaderTest\:\:testLoad\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^PHPDoc tag @var above foreach loop does not specify variable name\.$#' + identifier: varTag.noVariable count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScalePercentFilterLoaderTest.php + path: tests/bundle/Debug/Collector/IbexaCoreCollectorTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScalePercentFilterLoaderTest\:\:testLoadInvalidOptions\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Bundle\\IO\\DependencyInjection\\ConfigurationFactoryTestCase\:\:provideExpectedParentServiceId\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScalePercentFilterLoaderTest.php + path: tests/bundle/IO/DependencyInjection/ConfigurationFactoryTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScalePercentFilterLoaderTest\:\:testLoadInvalidOptions\(\) has parameter \$options with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Call to an undefined method object\:\:decorate\(\)\.$#' + identifier: method.notFound count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScalePercentFilterLoaderTest.php + path: tests/bundle/IO/DependencyInjection/IbexaIOExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleWidthDownOnlyFilterLoaderTest\:\:testLoad\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Using nullsafe method call on non\-nullable type Symfony\\Component\\HttpFoundation\\Response\. Use \-\> instead\.$#' + identifier: nullsafe.neverNull count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleWidthDownOnlyFilterLoaderTest.php + path: tests/bundle/IO/EventListener/StreamFileListenerTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleWidthDownOnlyFilterLoaderTest\:\:testLoadInvalid\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\BaseCoreFieldTypeIntegrationTestCase\:\:getDatabaseConnection\(\) should return Doctrine\\DBAL\\Connection but returns object\.$#' + identifier: return.type count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleWidthDownOnlyFilterLoaderTest.php + path: tests/integration/Core/BaseCoreFieldTypeIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleWidthFilterLoaderTest\:\:testLoad\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^PHPDoc tag @return with type object is not subtype of native type Doctrine\\DBAL\\Connection\.$#' + identifier: return.phpDocType count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleWidthFilterLoaderTest.php + path: tests/integration/Core/BaseCoreFieldTypeIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\ScaleWidthFilterLoaderTest\:\:testLoadFail\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to an undefined method object\:\:match\(\)\.$#' + identifier: method.notFound count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleWidthFilterLoaderTest.php + path: tests/integration/Core/BasicKernelTest.php - - message: '#^Method PHPUnit\\Framework\\TestCase\:\:createMock\(\) invoked with 2 parameters, 1 required\.$#' - identifier: arguments.count + message: '#^Method Ibexa\\Tests\\Integration\\Core\\BinaryBase\\BinaryBaseStorage\\BinaryBaseStorageTest\:\:getContext\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/ScaleWidthFilterLoaderTest.php + path: tests/integration/Core/BinaryBase/BinaryBaseStorage/BinaryBaseStorageTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\SwirlFilterLoaderTest\:\:loadWithOptionProvider\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\BinaryBase\\BinaryBaseStorage\\BinaryBaseStorageTest\:\:providerOfFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/SwirlFilterLoaderTest.php + path: tests/integration/Core/BinaryBase/BinaryBaseStorage/BinaryBaseStorageTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\SwirlFilterLoaderTest\:\:testLoadNoOption\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Integration\\Core\\BinaryBase\\BinaryBaseStorage\\BinaryBaseStorageTest\:\:\$gateway \(Ibexa\\Core\\FieldType\\BinaryBase\\BinaryBaseStorage\\Gateway&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept Ibexa\\Core\\FieldType\\BinaryBase\\BinaryBaseStorage\\Gateway\.$#' + identifier: assign.propertyType count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/SwirlFilterLoaderTest.php + path: tests/integration/Core/BinaryBase/BinaryBaseStorage/BinaryBaseStorageTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\SwirlFilterLoaderTest\:\:testLoadWithOption\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Cannot access property \$id on Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null\.$#' + identifier: property.nonObject + count: 4 + path: tests/integration/Core/FieldType/FieldConstraintsStorage/FieldConstraintsStorageTest.php + + - + message: '#^Parameter \#2 \$fieldDefinition of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:updateFieldDefinition\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition, Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null given\.$#' + identifier: argument.type count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/SwirlFilterLoaderTest.php + path: tests/integration/Core/FieldType/FieldConstraintsStorage/FieldConstraintsStorageTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\Loader\\SwirlFilterLoaderTest\:\:testLoadWithOption\(\) has parameter \$degrees with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\FieldType\\FieldConstraintsStorage\\Stub\\ExampleFieldConstraintsStorage\:\:__construct\(\) has parameter \$fieldConstraints with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/Filter/Loader/SwirlFilterLoaderTest.php + path: tests/integration/Core/FieldType/FieldConstraintsStorage/Stub/ExampleFieldConstraintsStorage.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\Filter\\UnsupportedFilterTest\:\:testLoad\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^PHPDoc tag @param has invalid value \(\\Ibexa\\Contracts\\Core\\Persistence\\Content\\FieldTypeConstraints\[\]\)\: Unexpected token "\\n ", expected variable at offset 82 on line 2$#' + identifier: phpDoc.parseError count: 1 - path: tests/bundle/Core/Imagine/Filter/UnsupportedFilterTest.php + path: tests/integration/Core/FieldType/FieldConstraintsStorage/Stub/ExampleFieldConstraintsStorage.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\ImageAsset\\AliasGeneratorTest\:\:testGetVariationOfImageAsset\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\IO\\BinarydataHandler\\FlysystemTest\:\:getBinaryDataHandler\(\) should return Ibexa\\Core\\IO\\IOBinarydataHandler but returns object\.$#' + identifier: return.type count: 1 - path: tests/bundle/Core/Imagine/ImageAsset/AliasGeneratorTest.php + path: tests/integration/Core/IO/BinarydataHandler/FlysystemTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\ImageAsset\\AliasGeneratorTest\:\:testGetVariationOfNonImageAsset\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\IO\\BinarydataHandler\\FlysystemTest\:\:getFlysystemFilesystem\(\) should return League\\Flysystem\\FilesystemOperator but returns object\.$#' + identifier: return.type count: 1 - path: tests/bundle/Core/Imagine/ImageAsset/AliasGeneratorTest.php + path: tests/integration/Core/IO/BinarydataHandler/FlysystemTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\ImageAsset\\AliasGeneratorTest\:\:testSupport\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$inputStream of method Ibexa\\Contracts\\Core\\IO\\BinaryFileCreateStruct\:\:setInputStream\(\) expects resource, resource\|false given\.$#' + identifier: argument.type count: 1 - path: tests/bundle/Core/Imagine/ImageAsset/AliasGeneratorTest.php + path: tests/integration/Core/IO/BinarydataHandler/FlysystemTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderAliasGeneratorConfiguratorTest\:\:testConfigure\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$stream of function fclose expects resource, resource\|false given\.$#' + identifier: argument.type count: 1 - path: tests/bundle/Core/Imagine/PlaceholderAliasGeneratorConfiguratorTest.php + path: tests/integration/Core/IO/BinarydataHandler/FlysystemTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderAliasGeneratorTest\:\:getVariationProvider\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\MemberOfLimitationTest\:\:testCanUserAssignRoleToUser\(\) has parameter \$limitations with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php + path: tests/integration/Core/Limitation/MemberOfLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderAliasGeneratorTest\:\:supportsValueProvider\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\MemberOfLimitationTest\:\:userPermissionLimitationProvider\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php + path: tests/integration/Core/Limitation/MemberOfLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderAliasGeneratorTest\:\:testGetVariationOriginalFound\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\PermissionResolver\\LanguageLimitationIntegrationTest\:\:providerForCanUserCreateContent\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php + path: tests/integration/Core/Limitation/PermissionResolver/LanguageLimitationIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderAliasGeneratorTest\:\:testGetVariationOriginalFound\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\PermissionResolver\\LanguageLimitationIntegrationTest\:\:providerForCanUserDeleteContent\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php + path: tests/integration/Core/Limitation/PermissionResolver/LanguageLimitationIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderAliasGeneratorTest\:\:testGetVariationOriginalNotFound\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\PermissionResolver\\LanguageLimitationIntegrationTest\:\:providerForCanUserDeleteContentTranslation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php + path: tests/integration/Core/Limitation/PermissionResolver/LanguageLimitationIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderAliasGeneratorTest\:\:testGetVariationOriginalNotFound\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\PermissionResolver\\LanguageLimitationIntegrationTest\:\:providerForCanUserEditOrPublishContent\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php + path: tests/integration/Core/Limitation/PermissionResolver/LanguageLimitationIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderAliasGeneratorTest\:\:testGetVariationReturnsPlaceholderIfBinaryDataIsNotAvailable\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\PermissionResolver\\LanguageLimitationIntegrationTest\:\:testCanUserCreateContent\(\) has parameter \$limitations with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php + path: tests/integration/Core/Limitation/PermissionResolver/LanguageLimitationIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderAliasGeneratorTest\:\:testGetVariationSkipsPlaceholderGeneration\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\PermissionResolver\\LanguageLimitationIntegrationTest\:\:testCanUserEditContent\(\) has parameter \$limitations with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php + path: tests/integration/Core/Limitation/PermissionResolver/LanguageLimitationIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderAliasGeneratorTest\:\:testGetVariationSkipsPlaceholderGeneration\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\PermissionResolver\\LanguageLimitationIntegrationTest\:\:testCanUserPublishContent\(\) has parameter \$limitations with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php + path: tests/integration/Core/Limitation/PermissionResolver/LanguageLimitationIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderAliasGeneratorTest\:\:testGetVariationWrongValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' + identifier: argument.type count: 1 - path: tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php + path: tests/integration/Core/Limitation/PermissionResolver/LanguageLimitationIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderAliasGeneratorTest\:\:testSupportsValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\RoleLimitationTest\:\:testCanUserAssignRole\(\) has parameter \$limitations with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php + path: tests/integration/Core/Limitation/RoleLimitationTest.php - - message: '#^Property Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderAliasGeneratorTest\:\:\$placeholderOptions type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\RoleLimitationTest\:\:userPermissionLimitationProvider\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php + path: tests/integration/Core/Limitation/RoleLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderProvider\\GenericProviderTest\:\:assertColorEquals\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Persistence\\Search\\Content\\IndexerGatewayTest\:\:getDataForContentInSubtree\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/PlaceholderProvider/GenericProviderTest.php + path: tests/integration/Core/Persistence/Search/Content/IndexerGatewayTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderProvider\\GenericProviderTest\:\:assertColorEquals\(\) has parameter \$expected with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/bundle/Core/Imagine/PlaceholderProvider/GenericProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderProvider\\GenericProviderTest\:\:assertSizeEquals\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Persistence\\Search\\Content\\IndexerGatewayTest\:\:getDataForContentSince\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/PlaceholderProvider/GenericProviderTest.php + path: tests/integration/Core/Persistence/Search/Content/IndexerGatewayTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderProvider\\GenericProviderTest\:\:assertSizeEquals\(\) has parameter \$expected with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseContentServiceTestCase\:\:createContentDraft\(\) has parameter \$fieldValues with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/PlaceholderProvider/GenericProviderTest.php + path: tests/integration/Core/Repository/BaseContentServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderProvider\\GenericProviderTest\:\:getPlaceholderDataProvider\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseContentServiceTestCase\:\:createContentDraftVersion1\(\) has parameter \$contentFieldNameIdentifier with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/bundle/Core/Imagine/PlaceholderProvider/GenericProviderTest.php + path: tests/integration/Core/Repository/BaseContentServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderProvider\\GenericProviderTest\:\:testGetPlaceholder\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseContentServiceTestCase\:\:createContentDraftVersion1\(\) has parameter \$contentTypeIdentifier with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/bundle/Core/Imagine/PlaceholderProvider/GenericProviderTest.php + path: tests/integration/Core/Repository/BaseContentServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderProvider\\GenericProviderTest\:\:testGetPlaceholder\(\) has parameter \$expectedText with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseContentServiceTestCase\:\:createContentDraftVersion1\(\) has parameter \$locationId with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/bundle/Core/Imagine/PlaceholderProvider/GenericProviderTest.php + path: tests/integration/Core/Repository/BaseContentServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderProvider\\GenericProviderTest\:\:testGetPlaceholder\(\) has parameter \$options with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseContentServiceTestCase\:\:createMultilingualContentDraft\(\) has parameter \$multilingualFieldValues with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/PlaceholderProvider/GenericProviderTest.php + path: tests/integration/Core/Repository/BaseContentServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderProviderRegistryTest\:\:testConstructor\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseContentServiceTestCase\:\:createUpdatedDraftVersion2NotAdmin\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/PlaceholderProviderRegistryTest.php + path: tests/integration/Core/Repository/BaseContentServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderProviderRegistryTest\:\:testGetProviderKnown\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$id of method Ibexa\\Contracts\\Core\\Repository\\UserService\:\:loadUserGroup\(\) expects int, string given\.$#' + identifier: argument.type count: 1 - path: tests/bundle/Core/Imagine/PlaceholderProviderRegistryTest.php + path: tests/integration/Core/Repository/BaseContentServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderProviderRegistryTest\:\:testGetProviderUnknown\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseNonRedundantFieldSetTestCase\:\:createMultilingualTestContent\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Core/Imagine/PlaceholderProviderRegistryTest.php + path: tests/integration/Core/Repository/BaseNonRedundantFieldSetTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\PlaceholderProviderRegistryTest\:\:testSupports\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseNonRedundantFieldSetTestCase\:\:createTestContent\(\) has parameter \$fieldValues with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Imagine/PlaceholderProviderRegistryTest.php + path: tests/integration/Core/Repository/BaseNonRedundantFieldSetTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\VariationPathGenerator\\AliasDirectoryVariationPathGeneratorTest\:\:testGetVariationPath\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseNonRedundantFieldSetTestCase\:\:createTestContentForUpdate\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Core/Imagine/VariationPathGenerator/AliasDirectoryVariationPathGeneratorTest.php + path: tests/integration/Core/Repository/BaseNonRedundantFieldSetTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Imagine\\VariationPathGenerator\\OriginalDirectoryVariationPathGeneratorTest\:\:testGetVariationPath\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseNonRedundantFieldSetTestCase\:\:updateTestContent\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Core/Imagine/VariationPathGenerator/OriginalDirectoryVariationPathGeneratorTest.php - - - - message: '#^Cannot access offset ''path'' on array\{scheme\?\: string, host\?\: string, port\?\: int\<0, 65535\>, user\?\: string, pass\?\: string, path\?\: string, query\?\: string, fragment\?\: string\}\|false\.$#' - identifier: offsetAccess.nonOffsetAccessible - count: 2 - path: tests/bundle/Core/Routing/DefaultRouterTest.php - - - - message: '#^Offset ''scheme'' might not exist on array\{scheme\?\: string, host\: string, port\: int\<0, 65535\>, user\?\: string, pass\?\: string, path\?\: string, query\?\: string, fragment\?\: string\}\.$#' - identifier: offsetAccess.notFound - count: 1 - path: tests/bundle/Core/Routing/DefaultRouterTest.php + path: tests/integration/Core/Repository/BaseNonRedundantFieldSetTestCase.php - - message: '#^Offset ''scheme'' might not exist on array\{scheme\?\: string, host\: string, port\?\: int\<0, 65535\>, user\?\: string, pass\?\: string, path\?\: string, query\?\: string, fragment\?\: string\}\.$#' - identifier: offsetAccess.notFound + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseNonRedundantFieldSetTestCase\:\:updateTestContent\(\) has parameter \$fieldValues with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Routing/DefaultRouterTest.php + path: tests/integration/Core/Repository/BaseNonRedundantFieldSetTestCase.php - - message: '#^Parameter \#3 \$length of function substr expects int\|null, int\<0, max\>\|false given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseNonRedundantFieldSetTestCase\:\:updateTestContent\(\) has parameter \$initialLanguageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/bundle/Core/Routing/DefaultRouterTest.php + path: tests/integration/Core/Repository/BaseNonRedundantFieldSetTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Routing\\JsRouting\\ExposedRoutesExtractorTest\:\:getDataForTestGetBaseUrl\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Argument of an invalid type Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject supplied for foreach, only iterables are supported\.$#' + identifier: foreach.nonIterable count: 1 - path: tests/bundle/Core/Routing/JsRouting/ExposedRoutesExtractorTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Call to an undefined method Ibexa\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouter\:\:setConfigResolver\(\)\.$#' - identifier: method.notFound + message: '#^Call to method commit\(\) on an unknown class Ibexa\\Solr\\Handler\.$#' + identifier: class.notFound count: 1 - path: tests/bundle/Core/Routing/UrlAliasRouterTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Routing\\UrlAliasRouterTest\:\:resetConfigResolver\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Core/Routing/UrlAliasRouterTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Routing\\UrlAliasRouterTest\:\:testMatchRequestDeactivatedUrlAlias\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertPropertiesCorrectUnsorted\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Core/Routing/UrlAliasRouterTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Routing\\UrlAliasRouterTest\:\:testMatchRequestLocationCaseRedirectWithRootLocation\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertPropertiesEqual\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Core/Routing/UrlAliasRouterTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Routing\\UrlAliasRouterTest\:\:testMatchRequestLocationCaseRedirectWithRootRootLocation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertPropertiesEqual\(\) has parameter \$actualValue with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/bundle/Core/Routing/UrlAliasRouterTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Routing\\UrlAliasRouterTest\:\:testMatchRequestResourceCaseRedirectWithRootLocation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertPropertiesEqual\(\) has parameter \$expectedValue with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/bundle/Core/Routing/UrlAliasRouterTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Routing\\UrlAliasRouterTest\:\:testMatchRequestVirtualCaseRedirectWithRootLocation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertPropertiesEqual\(\) has parameter \$propertyName with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/bundle/Core/Routing/UrlAliasRouterTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Routing\\UrlAliasRouterTest\:\:testMatchRequestWithRootLocation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertPropertiesEqual\(\) has parameter \$sortArray with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/bundle/Core/Routing/UrlAliasRouterTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\Routing\\UrlAliasRouterTest\:\:testMatchRequestWithRootLocationAndExclusion\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertStructPropertiesCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Core/Routing/UrlAliasRouterTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Parameter \#1 \$configResolver of method Ibexa\\Bundle\\Core\\Routing\\UrlAliasRouter\:\:setConfigResolver\(\) expects Ibexa\\Contracts\\Core\\SiteAccess\\ConfigResolverInterface, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertStructPropertiesCorrect\(\) has parameter \$additionalProperties with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/Routing/UrlAliasRouterTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\SiteAccess\\MatcherBuilderTest\:\:testBuildMatcherNoService\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:createFolder\(\) has parameter \$names with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/SiteAccess/MatcherBuilderTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\SiteAccess\\MatcherBuilderTest\:\:testBuildMatcherService\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:createRoleWithPolicies\(\) has parameter \$policiesData with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/SiteAccess/MatcherBuilderTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\SiteAccess\\MatcherBuilderTest\:\:testBuildMatcherServiceWrongInterface\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:createRoleWithPolicies\(\) has parameter \$roleName with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/bundle/Core/SiteAccess/MatcherBuilderTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Parameter \#1 \$siteAccessMatcherRegistry of class Ibexa\\Bundle\\Core\\SiteAccess\\MatcherBuilder constructor expects Ibexa\\Bundle\\Core\\SiteAccess\\SiteAccessMatcherRegistryInterface, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type - count: 3 - path: tests/bundle/Core/SiteAccess/MatcherBuilderTest.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:createSimpleContentType\(\) has parameter \$fieldsToDefine with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Parameter \#1 \$matchers of class Ibexa\\Bundle\\Core\\SiteAccess\\SiteAccessMatcherRegistry constructor expects array\, array\ given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:createUserWithPolicies\(\) has parameter \$policiesData with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/SiteAccess/SiteAccessMatcherRegistryTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\URLChecker\\URLCheckerTest\:\:configureUrlHandlerRegistry\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:refreshSearch\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Core/URLChecker/URLCheckerTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\URLChecker\\URLCheckerTest\:\:configureUrlHandlerRegistry\(\) has parameter \$schemes with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:resolveSetupFactory\(\) should return Ibexa\\Contracts\\Core\\Test\\Repository\\SetupFactory but returns object\.$#' + identifier: return.type count: 1 - path: tests/bundle/Core/URLChecker/URLCheckerTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\URLChecker\\URLCheckerTest\:\:createGroupedUrls\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:sortItems\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Core/URLChecker/URLCheckerTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\URLChecker\\URLCheckerTest\:\:createGroupedUrls\(\) has parameter \$n with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:sortItems\(\) has parameter \$items with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/URLChecker/URLCheckerTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\URLChecker\\URLCheckerTest\:\:createGroupedUrls\(\) has parameter \$schemes with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:updateFolder\(\) has parameter \$names with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/bundle/Core/URLChecker/URLCheckerTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\URLChecker\\URLCheckerTest\:\:createSearchResults\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^PHPDoc tag @param references unknown parameter\: \$propertyNames$#' + identifier: parameter.notFound count: 1 - path: tests/bundle/Core/URLChecker/URLCheckerTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\URLChecker\\URLCheckerTest\:\:createSearchResults\(\) has parameter \$urls with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^PHPDoc tag @var for variable \$searchHandler contains unknown class Ibexa\\Solr\\Handler\.$#' + identifier: class.notFound count: 1 - path: tests/bundle/Core/URLChecker/URLCheckerTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\URLChecker\\URLCheckerTest\:\:testCheck\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$string1 of function strcmp expects string, bool\|float\|int\|string given\.$#' + identifier: argument.type count: 1 - path: tests/bundle/Core/URLChecker/URLCheckerTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Core\\URLChecker\\URLCheckerTest\:\:testCheckUnsupported\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#2 \$string2 of function strcmp expects string, bool\|float\|int\|string given\.$#' + identifier: argument.type count: 1 - path: tests/bundle/Core/URLChecker/URLCheckerTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Argument of an invalid type PHPUnit\\Framework\\MockObject\\MockObject supplied for foreach, only iterables are supported\.$#' - identifier: foreach.nonIterable + message: '#^Property Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:\$repository \(Ibexa\\Contracts\\Core\\Repository\\Repository\) does not accept null\.$#' + identifier: assign.propertyType count: 1 - path: tests/bundle/Debug/Collector/IbexaCoreCollectorTest.php + path: tests/integration/Core/Repository/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Debug\\Collector\\IbexaCoreCollectorTest\:\:getDataCollectorMock\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTrashServiceTestCase\:\:createTrashItem\(\) should return Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\TrashItem but returns Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\TrashItem\|null\.$#' + identifier: return.type count: 1 - path: tests/bundle/Debug/Collector/IbexaCoreCollectorTest.php + path: tests/integration/Core/Repository/BaseTrashServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Debug\\Collector\\IbexaCoreCollectorTest\:\:testAddGetCollector\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/Debug/Collector/IbexaCoreCollectorTest.php + message: '#^Access to protected property Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\URL\:\:\$url\.$#' + identifier: property.protected + count: 5 + path: tests/integration/Core/Repository/BaseURLServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Debug\\Collector\\IbexaCoreCollectorTest\:\:testCollect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\URL\\\\SearchResult'' and Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\SearchResult will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/bundle/Debug/Collector/IbexaCoreCollectorTest.php + path: tests/integration/Core/Repository/BaseURLServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Debug\\Collector\\IbexaCoreCollectorTest\:\:testGetAllCollectors\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseURLServiceTestCase\:\:assertSearchResultItems\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Debug/Collector/IbexaCoreCollectorTest.php + path: tests/integration/Core/Repository/BaseURLServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Debug\\Collector\\IbexaCoreCollectorTest\:\:testGetInvalidCollector\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseURLServiceTestCase\:\:assertSearchResultItems\(\) has parameter \$expectedUrls with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Debug/Collector/IbexaCoreCollectorTest.php + path: tests/integration/Core/Repository/BaseURLServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Debug\\Collector\\IbexaCoreCollectorTest\:\:testGetPanelTemplate\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseURLServiceTestCase\:\:assertSearchResultItems\(\) has parameter \$ignoreOrder with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/bundle/Debug/Collector/IbexaCoreCollectorTest.php + path: tests/integration/Core/Repository/BaseURLServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Debug\\Collector\\IbexaCoreCollectorTest\:\:testGetPanelTemplateNothing\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseURLServiceTestCase\:\:assertUsagesSearchResultItems\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Debug/Collector/IbexaCoreCollectorTest.php + path: tests/integration/Core/Repository/BaseURLServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Debug\\Collector\\IbexaCoreCollectorTest\:\:testGetToolbarTemplate\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseURLServiceTestCase\:\:assertUsagesSearchResultItems\(\) has parameter \$expectedContentInfoIds with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Debug/Collector/IbexaCoreCollectorTest.php + path: tests/integration/Core/Repository/BaseURLServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Debug\\Collector\\IbexaCoreCollectorTest\:\:testGetToolbarTemplateNothing\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseURLServiceTestCase\:\:doTestFindUrls\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Debug/Collector/IbexaCoreCollectorTest.php + path: tests/integration/Core/Repository/BaseURLServiceTestCase.php - - message: '#^PHPDoc tag @var above foreach loop does not specify variable name\.$#' - identifier: varTag.noVariable + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseURLServiceTestCase\:\:doTestFindUrls\(\) has parameter \$expectedUrls with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/bundle/Debug/Collector/IbexaCoreCollectorTest.php + path: tests/integration/Core/Repository/BaseURLServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Bundle\\Debug\\DependencyInjection\\Compiler\\DataCollectorPassTest\:\:testAddCollector\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Common\\SlugConverter\:\:setConfigurationValue\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/bundle/Debug/DependencyInjection/Compiler/DataCollectorPassTest.php + path: tests/integration/Core/Repository/Common/SlugConverter.php - - message: '#^Method Ibexa\\Tests\\Bundle\\IO\\DependencyInjection\\ConfigurationFactoryTestCase\:\:provideExpectedParentServiceId\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Cannot call method getValue\(\) on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Field\|null\.$#' + identifier: method.nonObject count: 1 - path: tests/bundle/IO/DependencyInjection/ConfigurationFactoryTestCase.php + path: tests/integration/Core/Repository/ContentService/CopyNonTranslatableFieldsFromPublishedVersionTest.php - - message: '#^Call to an undefined method object\:\:decorate\(\)\.$#' - identifier: method.notFound + message: '#^Parameter \#2 \$fieldDefinition of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:updateFieldDefinition\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition, Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null given\.$#' + identifier: argument.type count: 1 - path: tests/bundle/IO/DependencyInjection/IbexaIOExtensionTest.php + path: tests/integration/Core/Repository/ContentService/VersionValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\IO\\DependencyInjection\\IbexaIOExtensionTest\:\:testParametersWithBinarydataHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/IO/DependencyInjection/IbexaIOExtensionTest.php + message: '#^Parameter \#1 \$parentLocationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:newLocationCreateStruct\(\) expects int, int\|null given\.$#' + identifier: argument.type + count: 2 + path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\IO\\DependencyInjection\\IbexaIOExtensionTest\:\:testParametersWithMetadataHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/IO/DependencyInjection/IbexaIOExtensionTest.php + message: '#^Access to an undefined property object\:\:\$content\.$#' + identifier: property.notFound + count: 6 + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Bundle\\IO\\DependencyInjection\\IbexaIOExtensionTest\:\:testParametersWithoutConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/bundle/IO/DependencyInjection/IbexaIOExtensionTest.php + message: '#^Access to an undefined property object\:\:\$reverseRelations\.$#' + identifier: property.notFound + count: 9 + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Using nullsafe method call on non\-nullable type Symfony\\Component\\HttpFoundation\\Response\. Use \-\> instead\.$#' - identifier: nullsafe.neverNull + message: '#^Argument of an invalid type Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentMetadataUpdateStruct supplied for foreach, only iterables are supported\.$#' + identifier: foreach.nonIterable count: 1 - path: tests/bundle/IO/EventListener/StreamFileListenerTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\BaseCoreFieldTypeIntegrationTestCase\:\:getDatabaseConnection\(\) should return Doctrine\\DBAL\\Connection but returns object\.$#' - identifier: return.type + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\ContentType'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentType will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/BaseCoreFieldTypeIntegrationTestCase.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^PHPDoc tag @return with type object is not subtype of native type Doctrine\\DBAL\\Connection\.$#' - identifier: return.phpDocType - count: 1 - path: tests/integration/Core/BaseCoreFieldTypeIntegrationTestCase.php + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Language'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Language will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 2 + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Call to an undefined method object\:\:match\(\)\.$#' - identifier: method.notFound + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Section'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Section will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/BasicKernelTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\BinaryBase\\BinaryBaseStorage\\BinaryBaseStorageTest\:\:getContext\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/BinaryBase/BinaryBaseStorage/BinaryBaseStorageTest.php + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\User'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\User will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 2 + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\BinaryBase\\BinaryBaseStorage\\BinaryBaseStorageTest\:\:providerOfFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Cannot access property \$sortField on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null\.$#' + identifier: property.nonObject count: 1 - path: tests/integration/Core/BinaryBase/BinaryBaseStorage/BinaryBaseStorageTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Property Ibexa\\Tests\\Integration\\Core\\BinaryBase\\BinaryBaseStorage\\BinaryBaseStorageTest\:\:\$gateway \(Ibexa\\Core\\FieldType\\BinaryBase\\BinaryBaseStorage\\Gateway&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept Ibexa\\Core\\FieldType\\BinaryBase\\BinaryBaseStorage\\Gateway\.$#' - identifier: assign.propertyType + message: '#^Cannot access property \$sortOrder on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null\.$#' + identifier: property.nonObject count: 1 - path: tests/integration/Core/BinaryBase/BinaryBaseStorage/BinaryBaseStorageTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Cannot access property \$id on Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null\.$#' + message: '#^Cannot access property \$sourceContentInfo on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Relation\|null\.$#' identifier: property.nonObject - count: 4 - path: tests/integration/Core/FieldType/FieldConstraintsStorage/FieldConstraintsStorageTest.php + count: 9 + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Parameter \#2 \$fieldDefinition of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:updateFieldDefinition\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition, Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertAliasesCorrect\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/FieldType/FieldConstraintsStorage/FieldConstraintsStorageTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\FieldType\\FieldConstraintsStorage\\Stub\\ExampleFieldConstraintsStorage\:\:__construct\(\) has parameter \$fieldConstraints with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertAliasesCorrect\(\) has parameter \$actualAliases with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/FieldType/FieldConstraintsStorage/Stub/ExampleFieldConstraintsStorage.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^PHPDoc tag @param has invalid value \(\\Ibexa\\Contracts\\Core\\Persistence\\Content\\FieldTypeConstraints\[\]\)\: Unexpected token "\\n ", expected variable at offset 82 on line 2$#' - identifier: phpDoc.parseError + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertAliasesCorrect\(\) has parameter \$expectedAliasProperties with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/FieldType/FieldConstraintsStorage/Stub/ExampleFieldConstraintsStorage.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\IO\\BinarydataHandler\\FlysystemTest\:\:getBinaryDataHandler\(\) should return Ibexa\\Core\\IO\\IOBinarydataHandler but returns object\.$#' - identifier: return.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertAllFieldsEquals\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/IO/BinarydataHandler/FlysystemTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\IO\\BinarydataHandler\\FlysystemTest\:\:getFlysystemFilesystem\(\) should return League\\Flysystem\\FilesystemOperator but returns object\.$#' - identifier: return.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertDefaultContentStates\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/IO/BinarydataHandler/FlysystemTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Parameter \#1 \$inputStream of method Ibexa\\Contracts\\Core\\IO\\BinaryFileCreateStruct\:\:setInputStream\(\) expects resource, resource\|false given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertExpectedRelations\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/IO/BinarydataHandler/FlysystemTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Parameter \#1 \$stream of function fclose expects resource, resource\|false given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertLocaleFieldsEquals\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/IO/BinarydataHandler/FlysystemTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\MemberOfLimitationTest\:\:testCanUserAssignRoleToUser\(\) has parameter \$limitations with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertTranslationDoesNotExist\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Limitation/MemberOfLimitationTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\MemberOfLimitationTest\:\:userPermissionLimitationProvider\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:contentRemoteIdVersionLanguageProvider\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Limitation/MemberOfLimitationTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\PermissionResolver\\LanguageLimitationIntegrationTest\:\:providerForCanUserCreateContent\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:createUserWithVersionReadLimitations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Limitation/PermissionResolver/LanguageLimitationIntegrationTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\PermissionResolver\\LanguageLimitationIntegrationTest\:\:providerForCanUserDeleteContent\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:filterHiddenLocations\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Limitation/PermissionResolver/LanguageLimitationIntegrationTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\PermissionResolver\\LanguageLimitationIntegrationTest\:\:providerForCanUserDeleteContentTranslation\(\) return type has no value type specified in iterable type iterable\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:getExpectedMediaContentInfoProperties\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Limitation/PermissionResolver/LanguageLimitationIntegrationTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\PermissionResolver\\LanguageLimitationIntegrationTest\:\:providerForCanUserEditOrPublishContent\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:getPrioritizedLanguageList\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Limitation/PermissionResolver/LanguageLimitationIntegrationTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\PermissionResolver\\LanguageLimitationIntegrationTest\:\:testCanUserCreateContent\(\) has parameter \$limitations with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:providerForDeleteTranslationFromDraftRemovesUrlAliasOnPublishing\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Limitation/PermissionResolver/LanguageLimitationIntegrationTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\PermissionResolver\\LanguageLimitationIntegrationTest\:\:testCanUserEditContent\(\) has parameter \$limitations with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentWithLocationCreateParameterCreatesExpectedLocation\(\) has parameter \$testData with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Limitation/PermissionResolver/LanguageLimitationIntegrationTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\PermissionResolver\\LanguageLimitationIntegrationTest\:\:testCanUserPublishContent\(\) has parameter \$limitations with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentByRemoteId\(\) has parameter \$languages with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Limitation/PermissionResolver/LanguageLimitationIntegrationTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentInfo\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Limitation/PermissionResolver/LanguageLimitationIntegrationTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\RoleLimitationTest\:\:testCanUserAssignRole\(\) has parameter \$limitations with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentInfoByRemoteId\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Limitation/RoleLimitationTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Limitation\\RoleLimitationTest\:\:userPermissionLimitationProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentWithPrioritizedLanguages\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Limitation/RoleLimitationTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Persistence\\Search\\Content\\IndexerGatewayTest\:\:getDataForContentInSubtree\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadVersionInfoById\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Persistence/Search/Content/IndexerGatewayTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Persistence\\Search\\Content\\IndexerGatewayTest\:\:getDataForContentSince\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadVersionInfoByIdWithSecondParameter\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Persistence/Search/Content/IndexerGatewayTest.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseContentServiceTestCase\:\:createContentDraft\(\) has parameter \$fieldValues with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadVersionInfoByIdWithSecondParameterSetsExpectedVersionInfo\(\) has parameter \$data with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/BaseContentServiceTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseContentServiceTestCase\:\:createContentDraftVersion1\(\) has parameter \$contentFieldNameIdentifier with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/BaseContentServiceTestCase.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseContentServiceTestCase\:\:createContentDraftVersion1\(\) has parameter \$contentTypeIdentifier with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testPublishVersionCreatesLocationsDefinedOnCreate\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/BaseContentServiceTestCase.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseContentServiceTestCase\:\:createContentDraftVersion1\(\) has parameter \$locationId with no type specified\.$#' - identifier: missingType.parameter + message: '#^PHPDoc tag @var for variable \$field has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/BaseContentServiceTestCase.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseContentServiceTestCase\:\:createMultilingualContentDraft\(\) has parameter \$multilingualFieldValues with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$fields of method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertAllFieldsEquals\(\) expects array\, iterable\ given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/BaseContentServiceTestCase.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseContentServiceTestCase\:\:createUpdatedDraftVersion2NotAdmin\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/BaseContentServiceTestCase.php + message: '#^Parameter \#1 \$fields of method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertLocaleFieldsEquals\(\) expects array\, iterable\ given\.$#' + identifier: argument.type + count: 2 + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Parameter \#1 \$id of method Ibexa\\Contracts\\Core\\Repository\\UserService\:\:loadUserGroup\(\) expects int, string given\.$#' + message: '#^Parameter \#1 \$fields of method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:normalizeFields\(\) expects array\, iterable\ given\.$#' identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/BaseContentServiceTestCase.php + count: 4 + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseNonRedundantFieldSetTestCase\:\:createMultilingualTestContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/BaseNonRedundantFieldSetTestCase.php + message: '#^Parameter \#1 \$locations of method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:filterHiddenLocations\(\) expects array\, iterable\ given\.$#' + identifier: argument.type + count: 5 + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseNonRedundantFieldSetTestCase\:\:createTestContent\(\) has parameter \$fieldValues with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/BaseNonRedundantFieldSetTestCase.php + message: '#^Parameter \#1 \$string of function md5 expects string, float given\.$#' + identifier: argument.type + count: 3 + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseNonRedundantFieldSetTestCase\:\:createTestContentForUpdate\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$value of function count expects array\|Countable, iterable\ given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/BaseNonRedundantFieldSetTestCase.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseNonRedundantFieldSetTestCase\:\:updateTestContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/BaseNonRedundantFieldSetTestCase.php + message: '#^Parameter \#2 \$actualAliases of method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertAliasesCorrect\(\) expects array, iterable\ given\.$#' + identifier: argument.type + count: 4 + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseNonRedundantFieldSetTestCase\:\:updateTestContent\(\) has parameter \$fieldValues with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#2 \$code of class InvalidArgumentException constructor expects int, string given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/BaseNonRedundantFieldSetTestCase.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseNonRedundantFieldSetTestCase\:\:updateTestContent\(\) has parameter \$initialLanguageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#2 \$fieldDefinition of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:updateFieldDefinition\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition, Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/BaseNonRedundantFieldSetTestCase.php + path: tests/integration/Core/Repository/ContentServiceTest.php - - message: '#^Argument of an invalid type Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject supplied for foreach, only iterables are supported\.$#' - identifier: foreach.nonIterable + message: '#^Parameter \#2 \$fieldDefinition of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:removeFieldDefinition\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition, Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php - - message: '#^Call to method commit\(\) on an unknown class Ibexa\\Solr\\Handler\.$#' - identifier: class.notFound + message: '#^Parameter \#2 \$fieldDefinition of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:updateFieldDefinition\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition, Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Argument of an invalid type Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinitionCreateStruct supplied for foreach, only iterables are supported\.$#' + identifier: foreach.nonIterable count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertPropertiesCorrectUnsorted\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Argument of an invalid type Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinitionUpdateStruct supplied for foreach, only iterables are supported\.$#' + identifier: foreach.nonIterable count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertPropertiesEqual\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\ContentType'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentType will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 5 + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertPropertiesEqual\(\) has parameter \$actualValue with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\ContentType'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentTypeDraft will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertPropertiesEqual\(\) has parameter \$expectedValue with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\ContentTypeCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentTypeCreateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertPropertiesEqual\(\) has parameter \$propertyName with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\ContentTypeDraft'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentTypeDraft will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 4 + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertPropertiesEqual\(\) has parameter \$sortArray with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\ContentTypeGroup'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentTypeGroup will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 3 + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertStructPropertiesCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\ContentTypeGroupCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentTypeGroupCreateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertStructPropertiesCorrect\(\) has parameter \$additionalProperties with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\ContentTypeGroupUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentTypeGroupUpdateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 2 + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:createFolder\(\) has parameter \$names with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\ContentTypeUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentTypeUpdateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:createRoleWithPolicies\(\) has parameter \$policiesData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\FieldDefinitionCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinitionCreateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:createRoleWithPolicies\(\) has parameter \$roleName with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\FieldDefinitionUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinitionUpdateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:createSimpleContentType\(\) has parameter \$fieldsToDefine with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Content'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Content will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 6 + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:createUserWithPolicies\(\) has parameter \$policiesData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Cannot access property \$fieldSettings on Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null\.$#' + identifier: property.nonObject + count: 2 + path: tests/integration/Core/Repository/ContentTypeServiceTest.php + + - + message: '#^Cannot access property \$id on Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null\.$#' + identifier: property.nonObject count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:getSetupFactory\(\) should return Ibexa\\Contracts\\Core\\Test\\Repository\\SetupFactory but returns object\.$#' - identifier: return.type + message: '#^Cannot access property \$id on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Field\|null\.$#' + identifier: property.nonObject + count: 4 + path: tests/integration/Core/Repository/ContentTypeServiceTest.php + + - + message: '#^Cannot call method getDescriptions\(\) on Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null\.$#' + identifier: method.nonObject count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:refreshSearch\(\) has no return type specified\.$#' + message: '#^Cannot call method getNames\(\) on Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null\.$#' + identifier: method.nonObject + count: 2 + path: tests/integration/Core/Repository/ContentTypeServiceTest.php + + - + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:assertContentTypeGroupsCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:sortItems\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:assertCopyContentTypeValues\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:sortItems\(\) has parameter \$items with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:assertCopyContentTypeValues\(\) has parameter \$excludedProperties with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:updateFolder\(\) has parameter \$names with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:getPrioritizedLanguageList\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^PHPDoc tag @param references unknown parameter\: \$propertyNames$#' - identifier: parameter.notFound + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testAddFieldDefinition\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^PHPDoc tag @var for variable \$searchHandler contains unknown class Ibexa\\Solr\\Handler\.$#' - identifier: class.notFound + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testAddFieldDefinitionAddsFieldToContent\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Parameter \#1 \$string1 of function strcmp expects string, bool\|float\|int\|string given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testAddFieldDefinitionStructValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Parameter \#2 \$string2 of function strcmp expects string, bool\|float\|int\|string given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCopyContentType\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Property Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:\$repository \(Ibexa\\Contracts\\Core\\Repository\\Repository\) does not accept null\.$#' - identifier: assign.propertyType + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCopyContentTypeStructValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Property Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:\$setupFactory \(Ibexa\\Contracts\\Core\\Test\\Repository\\SetupFactory\) does not accept object\.$#' - identifier: assign.propertyType + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentType\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/BaseTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTrashServiceTestCase\:\:createTrashItem\(\) should return Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\TrashItem but returns Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\TrashItem\|null\.$#' - identifier: return.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeDraft\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/BaseTrashServiceTestCase.php - - - - message: '#^Access to protected property Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\URL\:\:\$url\.$#' - identifier: property.protected - count: 5 - path: tests/integration/Core/Repository/BaseURLServiceTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\URL\\\\SearchResult'' and Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\SearchResult will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeDraftStructLanguageDependentValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/BaseURLServiceTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseURLServiceTestCase\:\:assertSearchResultItems\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeDraftStructValues\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/BaseURLServiceTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseURLServiceTestCase\:\:assertSearchResultItems\(\) has parameter \$expectedUrls with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeDraftStructValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/BaseURLServiceTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseURLServiceTestCase\:\:assertSearchResultItems\(\) has parameter \$ignoreOrder with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/BaseURLServiceTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseURLServiceTestCase\:\:assertUsagesSearchResultItems\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeGroup\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/BaseURLServiceTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseURLServiceTestCase\:\:assertUsagesSearchResultItems\(\) has parameter \$expectedContentInfoIds with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeGroupStructLanguageDependentValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/BaseURLServiceTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseURLServiceTestCase\:\:doTestFindUrls\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeGroupStructValues\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/BaseURLServiceTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseURLServiceTestCase\:\:doTestFindUrls\(\) has parameter \$expectedUrls with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeGroupStructValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/BaseURLServiceTestCase.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BookmarkServiceTest\:\:testCreateBookmark\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeStructValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/BookmarkServiceTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BookmarkServiceTest\:\:testCreateBookmarkThrowsInvalidArgumentException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentType\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/BookmarkServiceTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BookmarkServiceTest\:\:testDeleteBookmark\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeByRemoteId\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/BookmarkServiceTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BookmarkServiceTest\:\:testDeleteBookmarkThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeByRemoteIdReturnsCorrectInstance\(\) has parameter \$contentType with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/BookmarkServiceTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BookmarkServiceTest\:\:testIsBookmarked\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeGroup\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/BookmarkServiceTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BookmarkServiceTest\:\:testIsNotBookmarked\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeGroupByIdentifier\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/BookmarkServiceTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\BookmarkServiceTest\:\:testLoadBookmarks\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeGroups\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/BookmarkServiceTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Common\\SlugConverter\:\:setConfigurationValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeGroupsIdentifiers\(\) has parameter \$groups with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/Common/SlugConverter.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Cannot call method getValue\(\) on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Field\|null\.$#' - identifier: method.nonObject + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeStructValues\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentService/CopyNonTranslatableFieldsFromPublishedVersionTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Parameter \#2 \$fieldDefinition of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:updateFieldDefinition\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition, Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeStructValues\(\) has parameter \$userGroupType with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentService/VersionValidatorTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testAddRelationThrowsUnauthorizedException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypes\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testCopyContentThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypesContent\(\) has parameter \$types with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testCopyContentThrowsUnauthorizedExceptionWithGivenVersion\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewContentTypeCreateStruct\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testCopyContentToAuthorizedLocation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewContentTypeCreateStructValues\(\) has parameter \$createStruct with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testCopyContentToAuthorizedLocationWithSubtreeLimitation\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewContentTypeGroupCreateStruct\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testCountContentDraftsReturnZero\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewContentTypeGroupCreateStructValues\(\) has parameter \$createStruct with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testCreateContentDraftThrowsUnauthorizedException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewContentTypeUpdateStruct\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testCreateContentDraftThrowsUnauthorizedExceptionWithSecondParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewContentTypeUpdateStructValues\(\) has parameter \$typeUpdate with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testCreateContentThrowsUnauthorizedException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewFieldDefinitionCreateStruct\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testCreateContentThrowsUnauthorizedExceptionWithSecondParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewFieldDefinitionCreateStructValues\(\) has parameter \$createStruct with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testDeleteContentThrowsUnauthorizedException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewFieldDefinitionUpdateStruct\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testDeleteRelationThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testRemoveFieldDefinition\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testDeleteVersionThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testRemoveFieldDefinitionRemoved\(\) has parameter \$data with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadContentByContentInfoThrowsUnauthorizedException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testRemoveFieldDefinitionRemovesFieldFromContent\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadContentByContentInfoThrowsUnauthorizedExceptionWithSecondParameter\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeDraft\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadContentByContentInfoThrowsUnauthorizedExceptionWithThirdParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeDraftStructValues\(\) has parameter \$data with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadContentByRemoteIdThrowsUnauthorizedException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeGroup\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadContentByRemoteIdThrowsUnauthorizedExceptionWithSecondParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeGroupStructLanguageDependentValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadContentByRemoteIdThrowsUnauthorizedExceptionWithThirdParameter\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeGroupStructValues\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadContentByVersionInfoThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeGroupStructValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadContentByVersionInfoThrowsUnauthorizedExceptionWithSecondParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateFieldDefinition\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadContentInfoByRemoteIdThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateFieldDefinitionStructValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadContentInfoListSkipsUnauthorizedItems\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$value of function count expects array\|Countable, iterable\ given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadContentInfoThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#2 \$actualObject of method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertStructPropertiesCorrect\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject, Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadContentThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + message: '#^Parameter \#2 \$array of function array_map expects array, iterable\ given\.$#' + identifier: argument.type + count: 3 + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadContentThrowsUnauthorizedExceptionOnDrafts\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#2 \$array of static method PHPUnit\\Framework\\Assert\:\:assertArrayHasKey\(\) expects array\\|ArrayAccess\<\(int\|string\), mixed\>, iterable\ given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadContentThrowsUnauthorizedExceptionWithSecondParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#2 \$array of static method PHPUnit\\Framework\\Assert\:\:assertArrayNotHasKey\(\) expects array\\|ArrayAccess\<\(int\|string\), mixed\>, iterable\ given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadContentThrowsUnauthorizedExceptionWithThirdParameter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + message: '#^Parameter \#2 \$fieldDefinition of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:removeFieldDefinition\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition, Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null given\.$#' + identifier: argument.type + count: 6 + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadContentThrowsUnauthorizedExceptionsOnArchives\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + message: '#^Parameter \#2 \$fieldDefinition of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:updateFieldDefinition\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition, Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null given\.$#' + identifier: argument.type + count: 6 + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadRelationsWithUnauthorizedRelations\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Variable \$nameValue in PHPDoc tag @var does not exist\.$#' + identifier: varTag.variableNotFound count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadReverseRelationsThrowsUnauthorizedException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadVersionInfoByIdThrowsUnauthorizedException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadVersionInfoByIdThrowsUnauthorizedExceptionForFirstDraft\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadVersionInfoByIdThrowsUnauthorizedExceptionWithSecondParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' + identifier: return.missing count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadVersionInfoThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:getAdditionallyIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadVersionInfoThrowsUnauthorizedExceptionWithSecondParameter\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:getAdditionallyIndexedMultivaluedFieldData\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testLoadVersionsThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testPublishVersionThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testSudo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testUpdateContentMetadataThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceAuthorizationTest\:\:testUpdateContentThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php - - message: '#^Parameter \#1 \$parentLocationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:newLocationCreateStruct\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 2 - path: tests/integration/Core/Repository/ContentServiceAuthorizationTest.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php - - message: '#^Access to an undefined property object\:\:\$content\.$#' - identifier: property.notFound - count: 6 - path: tests/integration/Core/Repository/ContentServiceTest.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php - - message: '#^Access to an undefined property object\:\:\$reverseRelations\.$#' - identifier: property.notFound - count: 9 - path: tests/integration/Core/Repository/ContentServiceTest.php + message: '#^Cannot access property \$value on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Field\|null\.$#' + identifier: property.nonObject + count: 1 + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Argument of an invalid type Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentMetadataUpdateStruct supplied for foreach, only iterables are supported\.$#' - identifier: foreach.nonIterable + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:addFieldDefinition\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\ContentType'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentType will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Language'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Language will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 2 - path: tests/integration/Core/Repository/ContentServiceTest.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' + identifier: missingType.return + count: 1 + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Section'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Section will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:assertUpdatedFieldDataLoadedCorrect\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\User'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\User will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 2 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Cannot access property \$sortField on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null\.$#' - identifier: property.nonObject + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:createContent\(\) has parameter \$contentType with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Cannot access property \$sortOrder on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null\.$#' - identifier: property.nonObject + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:createContentType\(\) has parameter \$fieldCreateOverride with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php - - - - message: '#^Cannot access property \$sourceContentInfo on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Relation\|null\.$#' - identifier: property.nonObject - count: 9 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertAliasesCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:createContentType\(\) has parameter \$typeCreateOverride with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertAliasesCorrect\(\) has parameter \$actualAliases with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:createMultilingualContent\(\) has parameter \$fieldData with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertAliasesCorrect\(\) has parameter \$expectedAliasProperties with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:createMultilingualContent\(\) has parameter \$names with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertAllFieldsEquals\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:getOverride\(\) has parameter \$overrideValues with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertDefaultContentStates\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertExpectedRelations\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:getValidContentTypeConfiguration\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertLocaleFieldsEquals\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:getValidFieldConfiguration\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertTranslationDoesNotExist\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:getValidMultilingualFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:contentRemoteIdVersionLanguageProvider\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:createUserWithVersionReadLimitations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:postCreationHook\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:filterHiddenLocations\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:getExpectedMediaContentInfoProperties\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:getPrioritizedLanguageList\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:providerForDeleteTranslationFromDraftRemovesUrlAliasOnPublishing\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testAddRelationAddsRelationToContent\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testAddRelationSetsExpectedRelations\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testAddRelationThrowsBadStateException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:removeFieldDefinition\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testChangeContentName\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testAddFieldDefinition\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCopyContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testContentTypeField\(\) has parameter \$contentType with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCopyContentInTransactionWithCommit\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCopiedFieldType\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCopyContentInTransactionWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCopiedFieldType\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCopyContentWithGivenVersion\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCopyField\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCopyContentWithNewOwner\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCopyField\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCopyTranslationsFromInvalidPublishedContentToDraft\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCreateContent\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCopyTranslationsFromPublishedToDraft\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCreateContentType\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentDraftAndLoadAccess\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCreateContentWithEmptyFieldValue\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentDraftInOtherLanguage\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCreatedEmptyFieldValue\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentDraftInTransactionWithCommit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCreatedEmptyFieldValue\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentDraftInTransactionWithRollback\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCreatedFieldType\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentDraftLoadContentByContentInfoStillLoadsPublishedVersion\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCreatedFieldType\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentDraftLoadContentByRemoteIdStillLoadsPublishedVersion\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testDeleteContent\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentDraftLoadContentStillLoadsPublishedVersion\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testFromHash\(\) has parameter \$expectedValue with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentDraftLoadVersionInfoStillLoadsPublishedVersion\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testFromHash\(\) has parameter \$hash with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentDraftSetsContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testIsEmptyValue\(\) has parameter \$value with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentDraftSetsExpectedProperties\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testIsNotEmptyValue\(\) has parameter \$value with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentDraftSetsVersionInfo\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadContentTypeField\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentDraftWithRelationsCreatesExpectedRelations\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadContentTypeFieldType\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentDraftWithSecondParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadContentTypeFieldType\(\) has parameter \$contentType with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentDraftWithThirdParameter\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadEmptyFieldValue\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentInTransactionWithCommit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadEmptyFieldValueData\(\) has parameter \$field with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentInTransactionWithRollback\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadEmptyFieldValueType\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentRequiredFieldMissing\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadEmptyFieldValueType\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentSetsExpectedContentInfo\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadField\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentSetsExpectedContentType\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadFieldType\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentSetsExpectedVersionInfo\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testPublishContent\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentThrowsContentFieldValidationException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testPublishedFieldType\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testPublishedFieldType\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentThrowsInvalidArgumentExceptionOnFieldTypeNotAccept\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testToHash\(\) has parameter \$expectedHash with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentThrowsInvalidArgumentExceptionWithLocationCreateParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testToHash\(\) has parameter \$value with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentWithLocationCreateParameterCreatesExpectedLocation\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testUpdateContentFails\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentWithLocationCreateParameterCreatesExpectedLocation\(\) has parameter \$testData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testUpdateField\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentWithLocationCreateParameterDoesNotCreateLocationImmediately\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testUpdateFieldNoNewContent\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentWithLocationCreateParameterInTransactionWithCommit\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testUpdateNoNewContentTypeFieldStillAvailable\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentWithLocationCreateParameterInTransactionWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testUpdateNoNewContentTypeFieldStillAvailable\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCreateContentWithRomanianSpecialCharsInTitle\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testUpdateTypeFieldStillAvailable\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testCustomURLAliasesNotHistorizedOnUpdatedContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testUpdateTypeFieldStillAvailable\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^PHPDoc tag @param for parameter \$repository with type Ibexa\\Contracts\\Core\\Repository is not subtype of native type Ibexa\\Contracts\\Core\\Repository\\Repository\.$#' + identifier: parameter.phpDocType count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteContentInTransactionWithCommit\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + message: '#^PHPDoc tag @var with type Ibexa\\Core\\FieldType\\FieldType is not subtype of native type Ibexa\\Contracts\\Core\\Repository\\FieldType\.$#' + identifier: varTag.nativeType + count: 2 + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteContentInTransactionWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$exception of method PHPUnit\\Framework\\TestCase\:\:expectException\(\) expects class\-string\, string given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteContentWithEmptyBinaryField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$exception of method PHPUnit\\Framework\\TestCase\:\:expectException\(\) expects class\-string\, string\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteRelation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$field of method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:assertUpdatedFieldDataLoadedCorrect\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Field, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Field\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteRelationThrowsBadStateException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#2 \$fieldDefinition of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:removeFieldDefinition\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition, Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteRelationThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \$repository of method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:postCreationHook\(\) has invalid type Ibexa\\Contracts\\Core\\Repository\.$#' + identifier: class.notFound count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteTranslation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Cannot access property \$value on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Field\|null\.$#' + identifier: property.nonObject count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteTranslationDeletesSingleTranslationVersions\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteTranslationFromDraft\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteTranslationFromDraftArchivesUrlAliasOnPublishing\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteTranslationFromDraftRemovesUrlAliasOnPublishing\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' + identifier: return.missing count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteTranslationFromDraftThrowsBadStateExceptionOnMainTranslation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:getDataForTestFindContentFieldCriterion\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteTranslationFromDraftThrowsBadStateExceptionOnPublishedVersion\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteTranslationFromDraftThrowsBadStateExceptionOnSingleTranslation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteTranslationFromDraftThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\Checkbox\\Value\.$#' + identifier: return.type count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteTranslationFromDraftThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteTranslationMainLanguageThrowsBadStateException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteTranslationThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteTranslationThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteTranslationUpdatesInitialLanguageCodeVersion\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteTranslationUpdatesUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$boolValue of class Ibexa\\Core\\FieldType\\Checkbox\\Value constructor expects bool, null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteVersion\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$boolValue of class Ibexa\\Core\\FieldType\\Checkbox\\Value constructor expects bool, stdClass given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteVersionInTransactionWithCommit\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteVersionInTransactionWithRollback\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteVersionThrowsBadStateExceptionOnPublishedVersion\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testDeleteVersionWorksIfOnlyVersionIsDraft\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' + identifier: return.missing count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testHideContentWithParentLocation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:getAdditionallyIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContent\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:getAdditionallyIndexedMultivaluedFieldData\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentByContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentByContentInfoThrowsNotFoundExceptionWithVersionNumberParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentByContentInfoWithLanguageParameters\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentByContentInfoWithVersionNumberParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\Country\\Value\.$#' + identifier: return.type count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentByRemoteId\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentByRemoteId\(\) has parameter \$languages with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentByRemoteIdThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentByRemoteIdThrowsNotFoundExceptionWithThirdParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentByRemoteIdWithSecondParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentByRemoteIdWithThirdParameter\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentByVersionInfo\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentByVersionInfoWithSecondParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentDraftsReturnsEmptyArrayByDefault\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' + identifier: return.missing count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentDraftsWithFirstParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentInfoByRemoteId\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\DateAndTime\\Value\.$#' + identifier: return.type count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentInfoByRemoteIdSetsExpectedContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentInfoByRemoteIdThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentInfoList\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentInfoListSkipsNotFoundItems\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentInfoSetsExpectedContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentInfoThrowsNotFoundException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:testUpdateContentFails\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentListByContentInfo\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentThrowsNotFoundException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentThrowsNotFoundExceptionWithThirdParameter\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentWithPrioritizedLanguages\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentWithPrioritizedLanguagesList\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentWithPrioritizedLanguagesThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadContentWithThirdParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadRelationsSkipsArchivedContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadRelationsSkipsDraftContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/DateIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadReverseRelationListSkipsDraftContent\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadReverseRelations\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadReverseRelationsSkipsArchivedContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadReverseRelationsSkipsDraftContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' + identifier: return.missing count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadVersionInfo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadVersionInfoById\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadVersionInfoByIdSetsExpectedVersionInfo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadVersionInfoByIdThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\EmailAddress\\Value\.$#' + identifier: return.type count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadVersionInfoByIdThrowsNotFoundExceptionWithSecondParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadVersionInfoByIdWithSecondParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadVersionInfoByIdWithSecondParameterSetsExpectedVersionInfo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadVersionInfoByIdWithSecondParameterSetsExpectedVersionInfo\(\) has parameter \$data with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadVersionInfoThrowsNotFoundExceptionWithSecondParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadVersionInfoWithSecondParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$email of class Ibexa\\Core\\FieldType\\EmailAddress\\Value constructor expects string, null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadVersionsAfterDeletingTwoDrafts\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FileSearchBaseIntegrationTestCase\:\:cleanupStorageDir\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadVersionsOfStatusArchived\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FileSearchBaseIntegrationTestCase\:\:setUpIgnoredPath\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadVersionsOfStatusDraft\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FileSearchBaseIntegrationTestCase\:\:setUpIgnoredPath\(\) has parameter \$ignoredFiles with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testLoadVersionsSetsExpectedVersionInfo\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FileSearchBaseIntegrationTestCase\:\:uriExistsOnIO\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testNewContentCreateStruct\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FileSearchBaseIntegrationTestCase\:\:uriExistsOnIO\(\) has parameter \$uri with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testNewContentMetadataUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FileSearchBaseIntegrationTestCase\:\:\$ignoredPathList type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testNewContentUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FileSearchBaseIntegrationTestCase\:\:\$storageDirConfigKey has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testPublishContentWithoutPublishPolicyThrowsException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Static property Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FileSearchBaseIntegrationTestCase\:\:\$installDir \(string\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testPublishVersionCreatesLocationsDefinedOnCreate\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testPublishVersionDoesNotChangePublishedDate\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testPublishVersionFromContentDraft\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testPublishVersionFromContentDraftArchivesOldVersion\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' + identifier: return.missing count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testPublishVersionFromContentDraftUpdatesContentInfoCurrentVersion\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testPublishVersionFromOldContentDraftArchivesNewerVersionNo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testPublishVersionInTransactionWithCommit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testPublishVersionInTransactionWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testPublishVersionSetsExpectedContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testPublishVersionSetsExpectedContentType\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testPublishVersionSetsExpectedVersionInfo\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testPublishVersionThrowsBadStateException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testPublishVersionWithSelectedLanguages\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testPublishWorkflow\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' + identifier: return.missing count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testRevealContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testRevealContentWithHiddenChildren\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testRevealContentWithHiddenParent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testURLAliasesCreatedForNewContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\ISBN\\Value\.$#' + identifier: return.type count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testURLAliasesCreatedForUpdatedContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testUpdateContentInTransactionWithCommit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testUpdateContentInTransactionWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testUpdateContentMetadataCheckWithinTransaction\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testUpdateContentMetadataInTransactionWithCommit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testUpdateContentMetadataInTransactionWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$isbn of class Ibexa\\Core\\FieldType\\ISBN\\Value constructor expects string, null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testUpdateContentMetadataNotUpdatesContentVersion\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Cannot access property \$alternativeText on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' + identifier: property.nonObject count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testUpdateContentMetadataSetsExpectedProperties\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + message: '#^Cannot access property \$uri on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' + identifier: property.nonObject + count: 1 + path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testUpdateContentMetadataThrowsInvalidArgumentExceptionOnDuplicateRemoteId\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ImageIntegrationTest\:\:getAdditionallyIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testUpdateContentMetadataThrowsInvalidArgumentExceptionOnNoMetadataPropertiesSet\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ImageIntegrationTest\:\:getFixtureData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testUpdateContentSetsExpectedFields\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ImageIntegrationTest\:\:getStoragePrefix\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testUpdateContentThrowsBadStateException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ImageIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testUpdateContentThrowsContentFieldValidationException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ImageIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testUpdateContentThrowsInvalidArgumentExceptionWhenFieldTypeDoesNotAccept\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ImageIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testUpdateContentValidatorIgnoresRequiredFieldsOfNotUpdatedLanguages\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ImageIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testUpdateContentWhenMandatoryFieldIsEmpty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ImageIntegrationTest\:\:publishNewImage\(\) has parameter \$parentLocationIDs with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php + + - + message: '#^Property Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ImageIntegrationTest\:\:\$loadedImagePath has no type specified\.$#' + identifier: missingType.property + count: 1 + path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testUpdateContentWithNotUpdatingMandatoryField\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:testUpdatingDraftDoesNotUpdateOldVersions\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php - - message: '#^PHPDoc tag @var for variable \$field has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php - - message: '#^Parameter \#1 \$fields of method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertAllFieldsEquals\(\) expects array\, iterable\ given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' + identifier: return.missing count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php - - message: '#^Parameter \#1 \$fields of method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertLocaleFieldsEquals\(\) expects array\, iterable\ given\.$#' - identifier: argument.type - count: 2 - path: tests/integration/Core/Repository/ContentServiceTest.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php - - message: '#^Parameter \#1 \$fields of method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:normalizeFields\(\) expects array\, iterable\ given\.$#' - identifier: argument.type - count: 4 - path: tests/integration/Core/Repository/ContentServiceTest.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php - - message: '#^Parameter \#1 \$locations of method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:filterHiddenLocations\(\) expects array\, iterable\ given\.$#' - identifier: argument.type - count: 5 - path: tests/integration/Core/Repository/ContentServiceTest.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php - - message: '#^Parameter \#1 \$string of function md5 expects string, float given\.$#' - identifier: argument.type - count: 3 - path: tests/integration/Core/Repository/ContentServiceTest.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\Integer\\Value\.$#' + identifier: return.type + count: 1 + path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php - - message: '#^Parameter \#1 \$value of function count expects array\|Countable, iterable\ given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php - - message: '#^Parameter \#2 \$actualAliases of method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentServiceTest\:\:assertAliasesCorrect\(\) expects array, iterable\ given\.$#' - identifier: argument.type - count: 4 - path: tests/integration/Core/Repository/ContentServiceTest.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php - - message: '#^Parameter \#2 \$code of class InvalidArgumentException constructor expects int, string given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php - - message: '#^Parameter \#2 \$fieldDefinition of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:updateFieldDefinition\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition, Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentServiceTest.php + path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceAuthorizationTest\:\:testAddFieldDefinitionThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceAuthorizationTest\:\:testAssignContentTypeGroupThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$value of class Ibexa\\Core\\FieldType\\Integer\\Value constructor expects int\|null, float given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceAuthorizationTest\:\:testCopyContentTypeThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php + message: '#^Cannot access property \$value on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Field\|null\.$#' + identifier: property.nonObject + count: 5 + path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceAuthorizationTest\:\:testCreateContentTypeDraftThrowsUnauthorizedException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:assertContentFieldHasCorrectData\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceAuthorizationTest\:\:testCreateContentTypeGroupThrowsUnauthorizedException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceAuthorizationTest\:\:testCreateContentTypeThrowsUnauthorizedException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceAuthorizationTest\:\:testDeleteContentTypeGroupThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceAuthorizationTest\:\:testDeleteContentTypeThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' + identifier: return.missing count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceAuthorizationTest\:\:testPublishContentTypeDraftThrowsUnauthorizedException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:checkFullTextSupport\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceAuthorizationTest\:\:testRemoveFieldDefinitionThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:createContent\(\) has parameter \$contentType with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceAuthorizationTest\:\:testUnassignContentTypeGroupThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceAuthorizationTest\:\:testUpdateContentTypeDraftThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceAuthorizationTest\:\:testUpdateContentTypeGroupThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:getValidMultilingualFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceAuthorizationTest\:\:testUpdateFieldDefinitionThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php - - message: '#^Parameter \#2 \$fieldDefinition of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:removeFieldDefinition\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition, Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\Keyword\\Value\.$#' + identifier: return.type count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php - - message: '#^Parameter \#2 \$fieldDefinition of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:updateFieldDefinition\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition, Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php + path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php - - message: '#^Argument of an invalid type Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinitionCreateStruct supplied for foreach, only iterables are supported\.$#' - identifier: foreach.nonIterable + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php - - message: '#^Argument of an invalid type Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinitionUpdateStruct supplied for foreach, only iterables are supported\.$#' - identifier: foreach.nonIterable + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\ContentType'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentType will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 5 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\ContentType'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentTypeDraft will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\ContentTypeCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentTypeCreateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\ContentTypeDraft'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentTypeDraft will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 4 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' + identifier: missingType.return + count: 1 + path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\ContentTypeGroup'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentTypeGroup will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 3 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\ContentTypeGroupCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentTypeGroupCreateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' + identifier: return.missing count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\ContentTypeGroupUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentTypeGroupUpdateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 2 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\ContentTypeUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentTypeUpdateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\FieldDefinitionCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinitionCreateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\MapLocation\\Value\.$#' + identifier: return.type count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ContentType\\\\FieldDefinitionUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinitionUpdateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Content'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Content will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 6 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php - - message: '#^Cannot access property \$fieldSettings on Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null\.$#' - identifier: property.nonObject - count: 2 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php - - message: '#^Cannot access property \$id on Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null\.$#' - identifier: property.nonObject + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php - - message: '#^Cannot access property \$id on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Field\|null\.$#' - identifier: property.nonObject - count: 4 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php - - message: '#^Cannot call method getDescriptions\(\) on Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null\.$#' - identifier: method.nonObject + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php - - message: '#^Cannot call method getNames\(\) on Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null\.$#' - identifier: method.nonObject - count: 2 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:assertContentTypeGroupsCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:assertCopyContentTypeValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:assertCopyContentTypeValues\(\) has parameter \$excludedProperties with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:getPrioritizedLanguageList\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testAddFieldDefinition\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testAddFieldDefinitionAddsFieldToContent\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testAddFieldDefinitionAddsFieldToContentAdded\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testAddFieldDefinitionStructValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testAddFieldDefinitionStructValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testAddFieldDefinitionThrowsBadStateExceptionContentInstances\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testAddFieldDefinitionThrowsBadStateExceptionNonRepeatableField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testAddFieldDefinitionThrowsContentTypeFieldDefinitionValidationException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testAddFieldDefinitionThrowsInvalidArgumentExceptionDuplicateFieldIdentifier\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:assertFindResult\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testAssignContentTypeGroup\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:assertFindResult\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testAssignContentTypeGroupInTransactionWithCommit\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:assertSortResult\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testAssignContentTypeGroupInTransactionWithRollback\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:checkCustomFieldsSupport\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testAssignContentTypeGroupThrowsInvalidArgumentException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:checkFullTextSupport\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCanLoadContentTypeDraftEvenIfDiffrentOwner\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:checkSearchEngineSupport\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCopyContentType\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:findProvider\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCopyContentTypeInTransactionWithCommit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:getAdditionallyIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCopyContentTypeInTransactionWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + + - + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:getResultContentIdList\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCopyContentTypeStructValues\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:modifyFieldSortClause\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCopyContentTypeStructValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testCreateTestContent\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCopyContentTypeWithSecondParameter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenOneTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentThrowsContentTypeValidationException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenOneTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentType\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenOneTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeDraft\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenOneTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeDraftStructLanguageDependentValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenOneTwo\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeDraftStructLanguageDependentValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenOneTwo\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeDraftStructValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenTwoOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeDraftStructValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenTwoOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeDraftThrowsBadStateException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenTwoOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeGroup\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenTwoOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeGroupInTransactionWithCommit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenTwoOne\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeGroupInTransactionWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenTwoOne\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeGroupStructLanguageDependentValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeGroupStructLanguageDependentValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeGroupStructValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeGroupStructValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeGroupThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsOne\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeInTransactionWithCommit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsOne\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeInTransactionWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeStructValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeStructValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeThrowsContentTypeFieldDefinitionValidationException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeThrowsInvalidArgumentExceptionDuplicateContentTypeIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsTwo\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeThrowsInvalidArgumentExceptionDuplicateFieldIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsTwo\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeThrowsInvalidArgumentExceptionDuplicateIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeThrowsInvalidArgumentExceptionDuplicateRemoteId\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testCreateContentTypeThrowsInvalidArgumentExceptionGroupsEmpty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testDeleteContentType\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testDeleteContentTypeGroup\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsOne\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testDeleteContentTypeGroupThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsOne\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testDeleteContentTypeGroupWithCommit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testDeleteContentTypeGroupWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testDeleteContentTypeInTransactionWithCommit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testDeleteContentTypeInTransactionWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testDeleteContentTypeThrowsBadStateException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsTwo\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testDeleteUserDrafts\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsTwo\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testIsContentTypeUsed\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentType\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeByIdentifierReturnsCorrectInstance\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeByIdentifierThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeByRemoteId\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOne\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeByRemoteIdReturnsCorrectInstance\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOne\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeByRemoteIdReturnsCorrectInstance\(\) has parameter \$contentType with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualOne\(\) has parameter \$content with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeByRemoteIdThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeDraft\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeDraftThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeDraftThrowsNotFoundExceptionIfDiffrentOwner\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualOne\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeFieldDefinitions\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualOne\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeGroup\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeGroupByIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeGroupByIdentifierStructValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeGroupByIdentifierThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeGroupStructValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualTwo\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeGroupThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualTwo\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeGroups\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeGroupsIdentifiers\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeGroupsIdentifiers\(\) has parameter \$groups with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanTwo\(\) has parameter \$filter with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeList\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeStructValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanTwo\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeStructValues\(\) has parameter \$userGroupType with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanTwo\(\) has parameter \$valueTwo with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypeWithPrioritizedLanguagesList\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypes\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypesContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testLoadContentTypesContent\(\) has parameter \$types with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOne\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewContentTypeCreateStruct\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOne\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewContentTypeCreateStructValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOneTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewContentTypeCreateStructValues\(\) has parameter \$createStruct with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOneTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewContentTypeGroupCreateStruct\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOneTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewContentTypeGroupCreateStructValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOneTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewContentTypeGroupCreateStructValues\(\) has parameter \$createStruct with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOneTwo\(\) has parameter \$valueOne with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewContentTypeGroupUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOneTwo\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewContentTypeUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewContentTypeUpdateStructValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewContentTypeUpdateStructValues\(\) has parameter \$typeUpdate with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInTwo\(\) has parameter \$filter with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewFieldDefinitionCreateStruct\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewFieldDefinitionCreateStructValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInTwo\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewFieldDefinitionCreateStructValues\(\) has parameter \$createStruct with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInTwo\(\) has parameter \$valueTwo with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewFieldDefinitionUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testNewFieldDefinitionUpdateStructValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testPublishContentTypeDraft\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testPublishContentTypeDraftRefreshesContentTypesList\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testPublishContentTypeDraftSetsNameSchema\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeOne\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testPublishContentTypeDraftThrowsBadStateException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeOne\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testPublishContentTypeDraftThrowsInvalidArgumentExceptionWithoutFields\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testRemoveContentTypeTranslation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testRemoveContentTypeTranslationWithMultilingualData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testRemoveFieldDefinition\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testRemoveFieldDefinitionRemoved\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeTwo\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testRemoveFieldDefinitionRemoved\(\) has parameter \$data with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeTwo\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testRemoveFieldDefinitionRemovesFieldFromContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testRemoveFieldDefinitionRemovesFieldFromContentRemoved\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testRemoveFieldDefinitionThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testRemoveFieldDefinitionThrowsInvalidArgumentExceptionOnWrongDraft\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUnassignContentTypeGroup\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOne\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUnassignContentTypeGroupThrowsBadStateException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOne\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUnassignContentTypeGroupThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeDraft\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeDraftStructValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeDraftStructValues\(\) has parameter \$data with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualOne\(\) has parameter \$modifyField with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeDraftThrowsInvalidArgumentExceptionDuplicateIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualOne\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeDraftThrowsInvalidArgumentExceptionDuplicateRemoteId\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualOne\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeDraftThrowsInvalidArgumentExceptionNoDraftForAuthenticatedUser\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeDraftWithNewTranslation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeDraftWithNewTranslationWithMultilingualData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeGroup\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeGroupInTransactionWithCommit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualTwo\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeGroupInTransactionWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualTwo\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeGroupStructLanguageDependentValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeGroupStructLanguageDependentValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeGroupStructValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeGroupStructValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateContentTypeGroupThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanTwo\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateFieldDefinition\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanTwo\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateFieldDefinitionStructValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenOneTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateFieldDefinitionStructValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenOneTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateFieldDefinitionThrowsInvalidArgumentExceptionFieldIdentifierExists\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenOneTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateFieldDefinitionThrowsInvalidArgumentExceptionForUndefinedField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenOneTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateFieldDefinitionWithEmptyStruct\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenOneTwo\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ContentTypeServiceTest\:\:testUpdateFieldDefinitionWithNewTranslation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenOneTwo\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Parameter \#1 \$value of function count expects array\|Countable, iterable\ given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenTwoOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Parameter \#2 \$actualObject of method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertStructPropertiesCorrect\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject, Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenTwoOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php - - - - message: '#^Parameter \#2 \$array of function array_map expects array, iterable\ given\.$#' - identifier: argument.type - count: 3 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Parameter \#2 \$array of static method PHPUnit\\Framework\\Assert\:\:assertArrayHasKey\(\) expects array\|ArrayAccess, iterable\ given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenTwoOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Parameter \#2 \$array of static method PHPUnit\\Framework\\Assert\:\:assertArrayNotHasKey\(\) expects array\|ArrayAccess, iterable\ given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenTwoOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Parameter \#2 \$fieldDefinition of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:removeFieldDefinition\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition, Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null given\.$#' - identifier: argument.type - count: 6 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenTwoOne\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter + count: 1 + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Parameter \#2 \$fieldDefinition of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:updateFieldDefinition\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition, Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null given\.$#' - identifier: argument.type - count: 6 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenTwoOne\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter + count: 1 + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Variable \$nameValue in PHPDoc tag @var does not exist\.$#' - identifier: varTag.variableNotFound + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/ContentTypeServiceTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' - identifier: return.missing + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsOne\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:getAdditionallyIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsOne\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:getAdditionallyIndexedMultivaluedFieldData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsTwo\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsTwo\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\AuthorIntegrationTest\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Cannot access property \$value on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Field\|null\.$#' - identifier: property.nonObject + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsOne\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:addFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsOne\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:assertUpdatedFieldDataLoadedCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:createContent\(\) has parameter \$contentType with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsTwo\(\) has parameter \$modifyField with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:createContentType\(\) has parameter \$fieldCreateOverride with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsTwo\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:createContentType\(\) has parameter \$typeCreateOverride with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsTwo\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:createMultilingualContent\(\) has parameter \$fieldData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:createMultilingualContent\(\) has parameter \$names with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:getOverride\(\) has parameter \$overrideValues with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:getValidContentTypeConfiguration\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOne\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:getValidFieldConfiguration\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOne\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:getValidMultilingualFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqual\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqual\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:postCreationHook\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqual\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqual\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqual\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqual\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqualTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqualTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqualTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:removeFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqualTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testAddFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqualTwo\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testContentTypeField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqualTwo\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testContentTypeField\(\) has parameter \$contentType with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanTwo\(\) has parameter \$content with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCopiedExternalData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCopiedFieldType\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCopiedFieldType\(\) has parameter \$content with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanTwo\(\) has parameter \$modifyField with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCopyField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanTwo\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCopyField\(\) has parameter \$content with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanTwo\(\) has parameter \$valueTwo with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCreateContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCreateContentType\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCreateContentTypeFailsWithInvalidFieldSettings\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCreateContentTypeFailsWithInvalidValidatorConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCreateContentWithEmptyFieldValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOne\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCreatedEmptyFieldValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOne\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCreatedEmptyFieldValue\(\) has parameter \$content with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOneTwo\(\) has parameter \$content with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCreatedFieldType\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOneTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testCreatedFieldType\(\) has parameter \$content with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOneTwo\(\) has parameter \$filter with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testDeleteContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOneTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testDeleteContent\(\) has parameter \$content with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOneTwo\(\) has parameter \$valueOne with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testDeleteDraftOfPublishedContentDoesNotDeleteData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOneTwo\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testDeleteTranslation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testExceededVersionArchiveLimitHasNoEffectOnContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testFromHash\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testFromHash\(\) has parameter \$expectedValue with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInTwo\(\) has parameter \$modifyField with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testFromHash\(\) has parameter \$hash with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInTwo\(\) has parameter \$valueOne with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testIsEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInTwo\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testIsEmptyValue\(\) has parameter \$value with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeOne\(\) has parameter \$content with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testIsNotEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testIsNotEmptyValue\(\) has parameter \$value with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeOne\(\) has parameter \$filter with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadContentTypeField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadContentTypeFieldData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeOne\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadContentTypeFieldType\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeOne\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadContentTypeFieldType\(\) has parameter \$contentType with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeTwo\(\) has parameter \$content with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadEmptyFieldValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadEmptyFieldValueData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadEmptyFieldValueData\(\) has parameter \$field with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeTwo\(\) has parameter \$modifyField with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadEmptyFieldValueType\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeTwo\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadEmptyFieldValueType\(\) has parameter \$content with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeTwo\(\) has parameter \$valueTwo with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadExternalData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testLoadFieldType\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testPublishContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testPublishContentWithEmptyFieldValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOne\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testPublishedFieldType\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOne\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testPublishedFieldType\(\) has parameter \$content with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualOne\(\) has parameter \$content with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testPublishedName\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testRemoveFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testSettingsSchema\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testToHash\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualOne\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testToHash\(\) has parameter \$expectedHash with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualOne\(\) has parameter \$valueTwo with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testToHash\(\) has parameter \$value with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualTwo\(\) has parameter \$content with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testUpdateContentFails\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testUpdateContentWithNewTranslationOnEmptyField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testUpdateField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testUpdateFieldNoNewContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualTwo\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testUpdateNoNewContentTypeFieldStillAvailable\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualTwo\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testUpdateNoNewContentTypeFieldStillAvailable\(\) has parameter \$content with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanTwo\(\) has parameter \$content with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testUpdateTypeFieldStillAvailable\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testUpdateTypeFieldStillAvailable\(\) has parameter \$content with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanTwo\(\) has parameter \$filter with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testUpdatedDataCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testUpdatedNoNewContentDataCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanTwo\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:testValidatorSchema\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanTwo\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^PHPDoc tag @param for parameter \$repository with type Ibexa\\Contracts\\Core\\Repository is not subtype of native type Ibexa\\Contracts\\Core\\Repository\\Repository\.$#' - identifier: parameter.phpDocType + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^PHPDoc tag @var with type Ibexa\\Core\\FieldType\\FieldType is not subtype of native type Ibexa\\Contracts\\Core\\Repository\\FieldType\.$#' - identifier: varTag.nativeType - count: 2 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Parameter \#1 \$exception of method PHPUnit\\Framework\\TestCase\:\:expectException\(\) expects class\-string\, string given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Parameter \#1 \$exception of method PHPUnit\\Framework\\TestCase\:\:expectException\(\) expects class\-string\, string\|null given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindOne\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Parameter \#1 \$field of method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:assertUpdatedFieldDataLoadedCorrect\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Field, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Field\|null given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindOne\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Parameter \#2 \$fieldDefinition of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:removeFieldDefinition\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition, Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Parameter \$repository of method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\BaseIntegrationTestCase\:\:postCreationHook\(\) has invalid type Ibexa\\Contracts\\Core\\Repository\.$#' - identifier: class.notFound + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Cannot access property \$value on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Field\|null\.$#' - identifier: property.nonObject + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindTwo\(\) has parameter \$valueOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindTwo\(\) has parameter \$valueTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testSort\(\) has parameter \$ascending with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' - identifier: return.missing + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testSort\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:getDataForTestFindContentFieldCriterion\(\) return type has no value type specified in iterable type iterable\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testSort\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testSort\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#2 \$fieldName of method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:doModifyField\(\) expects string, string\|false given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\Checkbox\\Value\.$#' - identifier: return.type + message: '#^Parameter \#2 \$fieldName of method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:doModifyField\(\) expects string, string\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:checkOperatorSupport\(\) has parameter \$operator with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:findMultivaluedProvider\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:getAdditionallyIndexedMultivaluedFieldData\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testCreateMultivaluedTestContent\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenOneTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenOneTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CheckboxIntegrationTest\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenOneTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Parameter \#1 \$boolValue of class Ibexa\\Core\\FieldType\\Checkbox\\Value constructor expects bool, null given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenOneTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Parameter \#1 \$boolValue of class Ibexa\\Core\\FieldType\\Checkbox\\Value constructor expects bool, stdClass given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenOneTwo\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenOneTwo\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenTwoOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenTwoOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' - identifier: return.missing + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenTwoOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:getAdditionallyIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenTwoOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:getAdditionallyIndexedMultivaluedFieldData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenTwoOne\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenTwoOne\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedContainsOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedContainsOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\Country\\Value\.$#' - identifier: return.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedContainsOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedContainsOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedContainsOne\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedContainsOne\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedEqualsOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedEqualsOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\CountryIntegrationTest\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedEqualsOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedEqualsOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedEqualsOne\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedEqualsOne\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' - identifier: return.missing + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsOneTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsOneTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsOneTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\DateAndTime\\Value\.$#' - identifier: return.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsOneTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsOneTwo\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsOneTwo\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsTwo\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateAndTimeIntegrationTest\:\:testUpdateContentFails\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsTwo\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOrEqualOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOrEqualOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/DateIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOrEqualOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOrEqualOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOrEqualOne\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOrEqualOne\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/DateIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateIntegrationTest\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\DateIntegrationTest\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOne\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/DateIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOne\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOneTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOneTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' - identifier: return.missing + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOneTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOneTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOneTwo\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOneTwo\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\EmailAddress\\Value\.$#' - identifier: return.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneEmpty\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneEmpty\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneEmpty\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneEmpty\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneEmpty\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneEmpty\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneFindsOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\EmailAddressIntegrationTest\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneFindsOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Parameter \#1 \$email of class Ibexa\\Core\\FieldType\\EmailAddress\\Value constructor expects string, null given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneFindsOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FileSearchBaseIntegrationTestCase\:\:cleanupStorageDir\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneFindsOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FileSearchBaseIntegrationTestCase\:\:setUpIgnoredPath\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneFindsOne\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FileSearchBaseIntegrationTestCase\:\:setUpIgnoredPath\(\) has parameter \$ignoredFiles with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneFindsOne\(\) has parameter \$valuesTwo with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FileSearchBaseIntegrationTestCase\:\:testUpdateWithRemove\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOrEqualOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FileSearchBaseIntegrationTestCase\:\:uriExistsOnIO\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOrEqualOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FileSearchBaseIntegrationTestCase\:\:uriExistsOnIO\(\) has parameter \$uri with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOrEqualOne\(\) has parameter \$filter with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php - - - - message: '#^Property Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FileSearchBaseIntegrationTestCase\:\:\$ignoredPathList type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Property Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FileSearchBaseIntegrationTestCase\:\:\$storageDirConfigKey has no type specified\.$#' - identifier: missingType.property + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOrEqualOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Static property Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FileSearchBaseIntegrationTestCase\:\:\$installDir \(string\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOrEqualOne\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOrEqualOne\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenOneTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenOneTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' - identifier: return.missing + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenOneTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenOneTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenOneTwo\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenOneTwo\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenTwoOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenTwoOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenTwoOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenTwoOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\FloatIntegrationTest\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenTwoOne\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenTwoOne\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotContainsOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotContainsOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' - identifier: return.missing + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotContainsOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotContainsOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotContainsOne\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotContainsOne\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\ISBN\\Value\.$#' - identifier: return.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotEqualsOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotEqualsOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotEqualsOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotEqualsOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotEqualsOne\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotEqualsOne\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsOneTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ISBNIntegrationTest\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsOneTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Parameter \#1 \$isbn of class Ibexa\\Core\\FieldType\\ISBN\\Value constructor expects string, null given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php - - - - message: '#^Cannot access property \$alternativeText on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' - identifier: property.nonObject + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsOneTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Cannot access property \$uri on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' - identifier: property.nonObject + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsOneTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ImageIntegrationTest\:\:getAdditionallyIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsOneTwo\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ImageIntegrationTest\:\:getFixtureData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsOneTwo\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ImageIntegrationTest\:\:getStoragePrefix\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ImageIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ImageIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ImageIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ImageIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsTwo\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ImageIntegrationTest\:\:publishNewImage\(\) has parameter \$parentLocationIDs with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsTwo\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Property Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\ImageIntegrationTest\:\:\$loadedImagePath has no type specified\.$#' - identifier: missingType.property + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOrEqual\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOrEqual\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOrEqual\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOrEqual\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' - identifier: return.missing + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOrEqual\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOrEqual\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\Integer\\Value\.$#' - identifier: return.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOne\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOne\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOneTwo\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOneTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOneTwo\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\IntegerIntegrationTest\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOneTwo\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Parameter \#1 \$value of class Ibexa\\Core\\FieldType\\Integer\\Value constructor expects int\|null, float given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOneTwo\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php - - - - message: '#^Cannot access property \$value on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Field\|null\.$#' - identifier: property.nonObject - count: 5 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:assertContentFieldHasCorrectData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOneTwo\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneEmpty\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneEmpty\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneEmpty\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' - identifier: return.missing + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneEmpty\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:checkFullTextSupport\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneEmpty\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:createContent\(\) has parameter \$contentType with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneEmpty\(\) has parameter \$valuesTwo with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneFindsOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneFindsOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:getValidMultilingualFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneFindsOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneFindsOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\Keyword\\Value\.$#' - identifier: return.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneFindsOne\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneFindsOne\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOrEqualOne\(\) has parameter \$content with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOrEqualOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOrEqualOne\(\) has parameter \$filter with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOrEqualOne\(\) has parameter \$modifyField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOrEqualOne\(\) has parameter \$valuesOne with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOrEqualOne\(\) has parameter \$valuesTwo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:providerForTestTruncateField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:\$legacyUnsupportedOperators type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:testFindContentFieldCriterion\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:testKeywordsAreCaseSensitive\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:testTruncateField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\KeywordIntegrationTest\:\:testUpdateContentKeywords\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' + identifier: return.missing count: 1 - path: tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:getAdditionallyIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:getAdditionallyIndexedMultivaluedFieldData\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\MapLocation\\Value\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\Selection\\Value\.$#' identifier: return.type count: 1 - path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionMultilingualIntegrationTest\:\:getAdditionallyIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SelectionMultilingualIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\MapLocationIntegrationTest\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionMultilingualIntegrationTest\:\:getAdditionallyIndexedMultivaluedFieldData\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SelectionMultilingualIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionMultilingualIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SelectionMultilingualIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionMultilingualIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SelectionMultilingualIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionMultilingualIntegrationTest\:\:getValidFieldConfiguration\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/SelectionMultilingualIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' + identifier: return.missing count: 1 - path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationIntegrationTest\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationIntegrationTest\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\TextBlock\\Value\.$#' + identifier: return.type count: 1 - path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\RelationListIntegrationTest\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php + path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:assertFindResult\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:assertFindResult\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' + identifier: return.missing count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:assertSortResult\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:checkCustomFieldsSupport\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:checkFullTextSupport\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:checkSearchEngineSupport\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\TextLine\\Value\.$#' + identifier: return.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:findProvider\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:fullTextFindProvider\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:getAdditionallyIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:getResultContentIdList\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:modifyFieldSortClause\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:sortProvider\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testCreateTestContent\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenOneTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' + identifier: return.missing count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenOneTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenOneTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenOneTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenOneTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenOneTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenOneTwo\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenTwoOne\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:testUpdateContentFails\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenTwoOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenTwoOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenTwoOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenTwoOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenTwoOne\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindBetweenTwoOne\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' + identifier: return.missing count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsOne\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:getAdditionallyIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\Url\\Value\.$#' + identifier: return.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsOne\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsOne\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$link of class Ibexa\\Core\\FieldType\\Url\\Value constructor expects string\|null, int given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#2 \$text of class Ibexa\\Core\\FieldType\\Url\\Value constructor expects string\|null, int given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\User\\User\:\:\$content\.$#' + identifier: property.notFound + count: 2 + path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindContainsTwo\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsOne\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' + identifier: return.missing count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsOne\(\) has parameter \$filter with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:createContent\(\) has parameter \$contentType with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsOne\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsOne\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:testAddFieldDefinition\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsTwo\(\) has parameter \$modifyField with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:testCopiedFieldType\(\) has parameter \$content with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:testCopyField\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindEqualsTwo\(\) has parameter \$valueTwo with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:testCopyField\(\) has parameter \$content with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOne\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\FieldType'' and Ibexa\\Contracts\\Core\\Repository\\FieldType will always evaluate to true\.$#' + identifier: method.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/FieldTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Cannot access property \$pathString on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null\.$#' + identifier: property.nonObject count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Filtering/BaseRepositoryFilteringTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\BaseRepositoryFilteringTestCase\:\:assertFoundContentItemsByRemoteIds\(\) has parameter \$expectedContentRemoteIds with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Filtering/BaseRepositoryFilteringTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\BaseRepositoryFilteringTestCase\:\:assertFoundContentItemsByRemoteIds\(\) has parameter \$list with no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Filtering/BaseRepositoryFilteringTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\BaseRepositoryFilteringTestCase\:\:find\(\) has parameter \$contextLanguages with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Filtering/BaseRepositoryFilteringTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOne\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\BaseRepositoryFilteringTestCase\:\:find\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Filtering/BaseRepositoryFilteringTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOne\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\BaseRepositoryFilteringTestCase\:\:getFilterFactories\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Filtering/BaseRepositoryFilteringTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualOne\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\BaseRepositoryFilteringTestCase\:\:getUserLimitationData\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Filtering/BaseRepositoryFilteringTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#1 \$value of class Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\Criterion\\ParentLocationId constructor expects array\\|int, int\|null given\.$#' + identifier: argument.type + count: 5 + path: tests/integration/Core/Repository/Filtering/BaseRepositoryFilteringTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Call to an undefined method Traversable\\:\:offsetGet\(\)\.$#' + identifier: method.notFound count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Cannot use array destructuring on iterable\\.$#' + identifier: offsetAccess.nonArray count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\ContentFilteringTest\:\:assertFoundContentItemsByRemoteIds\(\) has parameter \$expectedContentRemoteIds with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualOne\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\ContentFilteringTest\:\:assertFoundContentItemsByRemoteIds\(\) has parameter \$list with no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualOne\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\ContentFilteringTest\:\:createMultiplePagesOfContentItems\(\) should return int but returns int\|null\.$#' + identifier: return.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\ContentFilteringTest\:\:find\(\) has parameter \$contextLanguages with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\ContentFilteringTest\:\:getDataForTestFindContentWithLocationCriterion\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\ContentFilteringTest\:\:getFilterFactories\(\) return type has no value type specified in iterable type iterable\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\ContentFilteringTest\:\:getListOfSupportedSortClauses\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#1 \$sortClause of method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\ContentFilteringTest\:\:performAndAssertSimpleSortClauseQuery\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Filter\\FilteringSortClause, object given\.$#' + identifier: argument.type + count: 2 + path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$value of class Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\Criterion\\ParentLocationId constructor expects array\\|int, int\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanOrEqualTwo\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\LocationFilteringTest\:\:assertFoundContentItemsByRemoteIds\(\) has parameter \$expectedContentRemoteIds with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Filtering/LocationFilteringTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\LocationFilteringTest\:\:assertFoundContentItemsByRemoteIds\(\) has parameter \$list with no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Filtering/LocationFilteringTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\LocationFilteringTest\:\:find\(\) has parameter \$contextLanguages with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Filtering/LocationFilteringTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Comparison operation "\<" between int\<80300, 80599\> and 50400 is always false\.$#' + identifier: smaller.alwaysFalse count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LanguageServiceMaximumSupportedLanguagesTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$value of function count expects array\|Countable, iterable\ given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LanguageServiceMaximumSupportedLanguagesTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceMaximumSupportedLanguagesTest\:\:\$createdLanguages type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LanguageServiceMaximumSupportedLanguagesTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Result of && is always false\.$#' + identifier: booleanAnd.alwaysFalse count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LanguageServiceMaximumSupportedLanguagesTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindGreaterThanTwo\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Language'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Language will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 3 + path: tests/integration/Core/Repository/LanguageServiceTest.php + + - + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\LanguageCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\LanguageCreateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LanguageServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOne\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:loadLanguagesReturnsAnEmptyArrayByDefault\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LanguageServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#1 \$value of function count expects array\|Countable, iterable\ given\.$#' + identifier: argument.type + count: 2 + path: tests/integration/Core/Repository/LanguageServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Limitation\\PermissionResolver\\BaseLimitationIntegrationTestCase\:\:assertCanUser\(\) has parameter \$limitations with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Limitation/PermissionResolver/BaseLimitationIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Limitation\\PermissionResolver\\BaseLimitationIntegrationTestCase\:\:assertCanUser\(\) has parameter \$targets with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Limitation/PermissionResolver/BaseLimitationIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Limitation\\PermissionResolver\\BaseLimitationIntegrationTestCase\:\:loginAsEditorUserWithLimitations\(\) has parameter \$limitations with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Limitation/PermissionResolver/BaseLimitationIntegrationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOne\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Limitation\\PermissionResolver\\ContentLimitationsMixIntegrationTest\:\:providerForCanUser\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Limitation/PermissionResolver/ContentLimitationsMixIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOne\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Limitation\\PermissionResolver\\ContentLimitationsMixIntegrationTest\:\:testCanUser\(\) has parameter \$limitations with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Limitation/PermissionResolver/ContentLimitationsMixIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOneTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Limitation/PermissionResolver/ContentLimitationsMixIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOneTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Cannot access property \$contentInfo on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\TrashItem\|null\.$#' + identifier: property.nonObject count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Limitation/PermissionResolver/LocationLimitationIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOneTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Limitation\\PermissionResolver\\LocationLimitationIntegrationTest\:\:providerForCanUserEditOrPublishContent\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Limitation/PermissionResolver/LocationLimitationIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOneTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Limitation\\PermissionResolver\\LocationLimitationIntegrationTest\:\:testCanUserEditContent\(\) has parameter \$limitations with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Limitation/PermissionResolver/LocationLimitationIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOneTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Limitation\\PermissionResolver\\LocationLimitationIntegrationTest\:\:testCanUserReadTrashedContent\(\) has parameter \$limitations with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Limitation/PermissionResolver/LocationLimitationIntegrationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOneTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' + identifier: argument.type + count: 2 + path: tests/integration/Core/Repository/LocationServiceAuthorizationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInOneTwo\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$parentLocationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:newLocationCreateStruct\(\) expects int, string given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceAuthorizationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInTwo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Content'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Content will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 2 + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Location'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 10 + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\LocationCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\LocationCreateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\LocationList'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\LocationList will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\LocationUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\LocationUpdateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertTrue\(\) with true will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindInTwo\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Cannot access property \$id on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null\.$#' + identifier: property.nonObject + count: 9 + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeOne\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Cannot call method getContentInfo\(\) on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null\.$#' + identifier: method.nonObject + count: 2 + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:assertAliasesBeforeCopy\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:assertAliasesBeforeCopy\(\) has parameter \$expectedSubItemAliases with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:assertDefaultContentStates\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:assertGeneratedAliases\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeOne\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:assertGeneratedAliases\(\) has parameter \$expectedAliases with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeOne\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:assertSubtreeProperties\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:assertSubtreeProperties\(\) has parameter \$expectedValues with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeTwo\(\) has parameter \$content with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:assertSubtreeProperties\(\) has parameter \$stopId with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:loadLocationProperties\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:loadSubtreeProperties\(\) has parameter \$properties with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:loadSubtreeProperties\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:providerForLoadLocationChildrenRespectsParentSortingClauses\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLikeTwo\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testCreateLocation\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOne\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testCreateLocationStructValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOne\(\) has parameter \$content with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testCreateLocationThrowsInvalidArgumentExceptionPriorityIsOutOfRange\(\) has parameter \$priority with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocationChildren\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocationChildrenRespectsParentSortingClauses\(\) has parameter \$expectedChildrenNames with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocations\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOne\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocationsContent\(\) has parameter \$locations with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOne\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadParentLocationsForDraftContent\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualOne\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testSwapLocationForMainAndSecondaryLocation\(\) should return array\ but returns array\\.$#' + identifier: return.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testUpdateLocation\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testUpdateLocationStructValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualOne\(\) has parameter \$filter with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testUpdateLocationThrowsInvalidArgumentExceptionPriorityIsOutOfRange\(\) has parameter \$priority with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$expectedLocations of method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:assertContentHasExpectedLocations\(\) expects array\, array\ given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualOne\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#1 \$location of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:moveSubtree\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null given\.$#' + identifier: argument.type + count: 3 + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualOne\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' + identifier: argument.type + count: 23 + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualTwo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#1 \$parentLocationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:newLocationCreateStruct\(\) expects int, int\|null given\.$#' + identifier: argument.type + count: 2 + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#2 \$actualObject of method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertPropertiesCorrect\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null given\.$#' + identifier: argument.type + count: 2 + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#2 \$array of function array_map expects array, iterable\ given\.$#' + identifier: argument.type + count: 3 + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#2 \$location2 of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:swapLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#2 \$newParentLocation of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:moveSubtree\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null given\.$#' + identifier: argument.type + count: 2 + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#2 \$parentLocationId of method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:publishContentWithParentLocation\(\) expects int, int\|null given\.$#' + identifier: argument.type + count: 8 + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanOrEqualTwo\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#2 \$targetParentLocation of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:copySubtree\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|false given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanTwo\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\NonRedundantFieldSetTest\:\:assertFieldIds\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/NonRedundantFieldSetTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\NonRedundantFieldSetTest\:\:mapFields\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/NonRedundantFieldSetTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#1 \$fields of method Ibexa\\Tests\\Integration\\Core\\Repository\\NonRedundantFieldSetTest\:\:mapFields\(\) expects array\, iterable\ given\.$#' + identifier: argument.type + count: 2 + path: tests/integration/Core/Repository/NonRedundantFieldSetTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\ObjectState\\ObjectState\:\:\$defaultLanguageCode\.$#' + identifier: property.notFound + count: 2 + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\ObjectState\\ObjectState\:\:\$names\.$#' + identifier: property.notFound count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ObjectState\\\\ObjectState'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ObjectState\\ObjectState will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 9 + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindLowerThanTwo\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenOneTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ObjectState\\\\ObjectStateCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ObjectState\\ObjectStateCreateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenOneTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ObjectState\\\\ObjectStateGroup'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ObjectState\\ObjectStateGroup will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 7 + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenOneTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ObjectState\\\\ObjectStateGroupCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ObjectState\\ObjectStateGroupCreateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenOneTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ObjectState\\\\ObjectStateGroupUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ObjectState\\ObjectStateGroupUpdateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenOneTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ObjectState\\\\ObjectStateUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ObjectState\\ObjectStateUpdateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenOneTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:assertObjectsLoadedByIdentifiers\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenOneTwo\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:assertObjectsLoadedByIdentifiers\(\) has parameter \$expectedIdentifiers with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenTwoOne\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:assertObjectsLoadedByIdentifiers\(\) has parameter \$loadedObjects with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenTwoOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:createObjectState\(\) has parameter \$descriptions with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenTwoOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:createObjectState\(\) has parameter \$names with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenTwoOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:deleteExistingObjectStateGroups\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenTwoOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:getGroupIdentifierMap\(\) has parameter \$groups with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenTwoOne\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:getGroupIdentifierMap\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotBetweenTwoOne\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:getPrioritizedLanguagesList\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsOne\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testCreateObjectState\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testCreateObjectStateGroup\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testCreateObjectStateStructValues\(\) has parameter \$testData with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testLoadObjectState\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testNewObjectStateCreateStruct\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsOne\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testNewObjectStateGroupCreateStruct\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsOne\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testNewObjectStateGroupUpdateStruct\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsTwo\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testNewObjectStateUpdateStruct\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testUpdateObjectState\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testUpdateObjectStateGroup\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testUpdateObjectStateGroupStructValues\(\) has parameter \$testData with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testUpdateObjectStateStructValues\(\) has parameter \$testData with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#1 \$groups of method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:getGroupIdentifierMap\(\) expects array, iterable\ given\.$#' + identifier: argument.type + count: 2 + path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotContainsTwo\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$execution of class Jenner\\SimpleFork\\Process constructor expects string\|null, Closure given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Parallel/BaseParallelTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsOne\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Access to protected property Ibexa\\Contracts\\Core\\Repository\\Values\\User\\LookupLimitationResult\:\:\$hasAccess\.$#' + identifier: property.protected + count: 3 + path: tests/integration/Core/Repository/PermissionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Access to protected property Ibexa\\Contracts\\Core\\Repository\\Values\\User\\LookupLimitationResult\:\:\$lookupPolicyLimitations\.$#' + identifier: property.protected + count: 8 + path: tests/integration/Core/Repository/PermissionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Access to protected property Ibexa\\Contracts\\Core\\Repository\\Values\\User\\LookupLimitationResult\:\:\$roleLimitations\.$#' + identifier: property.protected + count: 3 + path: tests/integration/Core/Repository/PermissionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Access to protected property Ibexa\\Contracts\\Core\\Repository\\Values\\User\\LookupPolicyLimitations\:\:\$policy\.$#' + identifier: property.protected + count: 3 + path: tests/integration/Core/Repository/PermissionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' + identifier: property.nonObject + count: 2 + path: tests/integration/Core/Repository/PermissionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsOne\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:getDataForTestCanUserWithLimitations\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/PermissionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsOne\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testCanUserWithLimitations\(\) has parameter \$targets with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/PermissionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$array of function array_filter expects array, iterable\ given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/PermissionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$policy of class Ibexa\\Contracts\\Core\\Repository\\Values\\User\\LookupPolicyLimitations constructor expects Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy, Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy\|false given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/PermissionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Class Ibexa\\Tests\\Solr\\SetupFactory\\LegacySetupFactory not found\.$#' + identifier: class.notFound count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Regression/EZP20018LanguageTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP21089Test\:\:\$contentType \(Ibexa\\Core\\Repository\\Values\\ContentType\\ContentType\) does not accept Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentType\.$#' + identifier: assign.propertyType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Regression/EZP21089Test.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\VersionInfo\:\:\$names\.$#' + identifier: property.notFound count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Regression/EZP21771IbexaStringTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$value of function count expects array\|Countable, iterable\ given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Regression/EZP21798Test.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotEqualsTwo\(\) has parameter \$valueTwo with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP21906SearchOneContentMultipleLocationsTest\:\:testSearchContentMultipleLocations\(\) has parameter \$expectedResultCount with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Regression/EZP21906SearchOneContentMultipleLocationsTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOne\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22408DeleteRelatedObjectTest\:\:createReferenceObject\(\) has parameter \$relationListTarget with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Regression/EZP22408DeleteRelatedObjectTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22408DeleteRelatedObjectTest\:\:createTestContentType\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Regression/EZP22408DeleteRelatedObjectTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22409RelationListTypeStateTest\:\:createContentWithRelationList\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Regression/EZP22409RelationListTypeStateTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\URLAlias'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\URLAlias will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Regression/EZP22612URLAliasTranslationsTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22612URLAliasTranslationsTest\:\:getFolderCreateStruct\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Regression/EZP22612URLAliasTranslationsTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOne\(\) has parameter \$valueOne with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22612URLAliasTranslationsTest\:\:getFolderCreateStruct\(\) has parameter \$name with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Regression/EZP22612URLAliasTranslationsTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOne\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$parentLocationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:newLocationCreateStruct\(\) expects int, int\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Regression/EZP22612URLAliasTranslationsTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqual\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22958SearchSubtreePathstringFormatTest\:\:testSearchContentSubtree\(\) has parameter \$pathString with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Regression/EZP22958SearchSubtreePathstringFormatTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqual\(\) has parameter \$content with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22958SearchSubtreePathstringFormatTest\:\:testSearchContentSubtreeShouldThrowException\(\) has parameter \$pathString with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/Regression/EZP22958SearchSubtreePathstringFormatTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqual\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' + identifier: argument.type + count: 4 + path: tests/integration/Core/Repository/Regression/EZP26367UrlAliasHistoryRedirectLoopTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqual\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#1 \$parentLocationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:newLocationCreateStruct\(\) expects int, int\|null given\.$#' + identifier: argument.type + count: 2 + path: tests/integration/Core/Repository/Regression/EZP26367UrlAliasHistoryRedirectLoopTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqual\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' + identifier: argument.type + count: 2 + path: tests/integration/Core/Repository/Regression/EZP28799SubtreeSearchTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqual\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#1 \$parentLocationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:newLocationCreateStruct\(\) expects int, int\|null given\.$#' + identifier: argument.type + count: 2 + path: tests/integration/Core/Repository/Regression/EZP28799SubtreeSearchTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqual\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\ContentService'' and Ibexa\\Contracts\\Core\\Repository\\ContentService will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RepositoryTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqualTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\ContentTypeService'' and Ibexa\\Contracts\\Core\\Repository\\ContentTypeService will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RepositoryTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqualTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\FieldTypeService'' and Ibexa\\Contracts\\Core\\Repository\\FieldTypeService will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RepositoryTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqualTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\LanguageService'' and Ibexa\\Contracts\\Core\\Repository\\LanguageService will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RepositoryTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqualTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\LocationService'' and Ibexa\\Contracts\\Core\\Repository\\LocationService will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RepositoryTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqualTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\NotificationService'' and Ibexa\\Contracts\\Core\\Repository\\NotificationService will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RepositoryTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqualTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\ObjectStateService'' and Ibexa\\Contracts\\Core\\Repository\\ObjectStateService will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RepositoryTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanOrEqualTwo\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\PermissionResolver'' and Ibexa\\Contracts\\Core\\Repository\\PermissionResolver will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RepositoryTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\RoleService'' and Ibexa\\Contracts\\Core\\Repository\\RoleService will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RepositoryTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\SearchService'' and Ibexa\\Contracts\\Core\\Repository\\SearchService will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RepositoryTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\SectionService'' and Ibexa\\Contracts\\Core\\Repository\\SectionService will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RepositoryTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\TrashService'' and Ibexa\\Contracts\\Core\\Repository\\TrashService will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RepositoryTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\URLAliasService'' and Ibexa\\Contracts\\Core\\Repository\\URLAliasService will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RepositoryTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\URLWildcardService'' and Ibexa\\Contracts\\Core\\Repository\\URLWildcardService will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RepositoryTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotGreaterThanTwo\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\UserService'' and Ibexa\\Contracts\\Core\\Repository\\UserService will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RepositoryTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOne\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#2 \$policy of method Ibexa\\Contracts\\Core\\Repository\\RoleService\:\:updatePolicyByRoleDraft\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft, Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy\|false given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#2 \$policyDraft of method Ibexa\\Contracts\\Core\\Repository\\RoleService\:\:removePolicyByRoleDraft\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft, Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy\|false given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Access to protected property Ibexa\\Contracts\\Core\\Repository\\Values\\User\\UserGroupRoleAssignment\:\:\$id\.$#' + identifier: property.protected count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\Limitation'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Limitation will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\Policy'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 2 + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOne\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\PolicyCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyCreateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOne\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\PolicyUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyUpdateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOneTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\Role'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Role will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOneTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\Role'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\RoleDraft will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOneTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\RoleCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\RoleCreateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOneTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\RoleDraft'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\RoleDraft will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 4 + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOneTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\RoleUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\RoleUpdateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOneTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Cannot access property \$limitation on Ibexa\\Contracts\\Core\\Repository\\Values\\User\\RoleAssignment\|false\.$#' + identifier: property.nonObject count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInOneTwo\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Cannot call method getIdentifier\(\) on Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Limitation\\RoleLimitation\|null\.$#' + identifier: method.nonObject count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Contracts\\Core\\Repository\\RoleService\:\:newRoleUpdateStruct\(\) invoked with 1 parameter, 0 required\.$#' + identifier: arguments.count count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:providerForCopyRoleTests\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testAddPolicyByRoleDraftSetsPolicyProperties\(\) has parameter \$roleAndPolicy with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testAddPolicyByRoleDraftUpdatesRole\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testCreateRole\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testCreateRoleWithPolicy\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotInTwo\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testRoleCreateStructValues\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeOne\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testRoleCreateStructValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testRoleCreateStructValuesWithPolicy\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testRoleCreateStructValuesWithPolicy\(\) has parameter \$data with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testUpdatePolicyByRoleDraft\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testUpdatePolicyUpdatesLimitations\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeOne\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testUpdatePolicyUpdatesLimitations\(\) has parameter \$roleAndPolicy with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeOne\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$value of function count expects array\|Countable, iterable\ given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeTwo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#1 \$value of function count expects array\|Countable, iterable\ given\.$#' + identifier: argument.type + count: 3 + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \.\.\.\$arrays of function array_merge expects array, iterable\ given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#2 \$policy of method Ibexa\\Contracts\\Core\\Repository\\RoleService\:\:updatePolicyByRoleDraft\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft, Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft\|null given\.$#' + identifier: argument.type + count: 3 + path: tests/integration/Core/Repository/RoleServiceTest.php + + - + message: '#^Parameter \#2 \$policyDraft of method Ibexa\\Contracts\\Core\\Repository\\RoleService\:\:removePolicyByRoleDraft\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft, Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Variable \$role might not be defined\.$#' + identifier: variable.undefined count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/RoleServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Access to an undefined property Ibexa\\Core\\Repository\\Values\\Content\\Content\:\:\$mainLocationId\.$#' + identifier: property.notFound count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Access to an undefined property Ibexa\\Core\\Repository\\Values\\Content\\Content\:\:\$publishedDate\.$#' + identifier: property.notFound count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLikeTwo\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Access to an undefined property Ibexa\\Core\\Repository\\Values\\Content\\Content\:\:\$remoteId\.$#' + identifier: property.notFound count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOne\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:assertContentIdSearch\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:assertSubtreeInvisibleProperty\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:createContent\(\) has parameter \$parentLocationIdList with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOne\(\) has parameter \$filter with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:createContentWithNameAndDescription\(\) has parameter \$contentDescription with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:createContentWithNameAndDescription\(\) has parameter \$parentLocationIdList with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOne\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:getEmailAddressesCases\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOne\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:getSpecialFullTextCases\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualOne\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testFindContentInfoFullTextIsSearchable\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^PHPDoc tag @param references unknown parameter\: \$ignoreForSetupFactories$#' + identifier: parameter.notFound count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' + identifier: argument.type + count: 4 + path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#1 \$value of class Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\Criterion\\LocationId constructor expects array\\|int, int\|null given\.$#' + identifier: argument.type + count: 2 + path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$value of class Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\Criterion\\ParentLocationId constructor expects array\\|int, int\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualOne\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#2 \$fieldDefinition of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:updateFieldDefinition\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition, Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualOne\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Parameter \#2 \$parentLocationIdList of method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:createContentWithName\(\) expects array\, array\ given\.$#' + identifier: argument.type + count: 2 + path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualTwo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + message: '#^Cannot call method first\(\) on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Search\\AggregationResultCollection\|null\.$#' + identifier: method.nonObject + count: 2 + path: tests/integration/Core/Repository/SearchService/Aggregation/AbstractAggregationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\AbstractAggregationTestCase\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/AbstractAggregationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\AbstractAggregationTestCase\:\:dataProviderForTestFindLocationWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/AbstractAggregationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\ContentTypeGroupTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/ContentTypeGroupTermAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\ContentTypeTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/ContentTypeTermAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\DataSetBuilder\\TermAggregationDataSetBuilder\:\:build\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/DataSetBuilder/TermAggregationDataSetBuilder.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanOrEqualTwo\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\DataSetBuilder\\TermAggregationDataSetBuilder\:\:setExpectedEntries\(\) has parameter \$entries with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/DataSetBuilder/TermAggregationDataSetBuilder.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\DataSetBuilder\\TermAggregationDataSetBuilder\:\:\$entries type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/DataSetBuilder/TermAggregationDataSetBuilder.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\DateMetadataRangeAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/DateMetadataRangeAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\AuthorTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/Field/AuthorTermAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\CheckboxTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/Field/CheckboxTermAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\CountryTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/Field/CountryTermAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\DateRangeAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/Field/DateRangeAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFindNotLowerThanTwo\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\DateTimeRangeAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/Field/DateTimeRangeAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindOne\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\FloatRangeAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/Field/FloatRangeAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\FloatStatsAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/Field/FloatStatsAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\IntegerRangeAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/Field/IntegerRangeAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\IntegerStatsAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/Field/IntegerStatsAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindOne\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\KeywordTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/Field/KeywordTermAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindOne\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\SelectionTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/Field/SelectionTermAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\TimeRangeAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/Field/TimeRangeAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\FixtureGenerator\\FieldAggregationFixtureGenerator\:\:createFieldAggregationFixtures\(\) has parameter \$values with no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/FixtureGenerator/FieldAggregationFixtureGenerator.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\FixtureGenerator\\FieldAggregationFixtureGenerator\:\:setValues\(\) has parameter \$values with no value type specified in iterable type iterable\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/FixtureGenerator/FieldAggregationFixtureGenerator.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$contentTypeIdentifier of method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\FixtureGenerator\\FieldAggregationFixtureGenerator\:\:createContentTypeForFieldAggregation\(\) expects string, string\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/FixtureGenerator/FieldAggregationFixtureGenerator.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindTwo\(\) has parameter \$valueOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#2 \$fieldDefinitionIdentifier of method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\FixtureGenerator\\FieldAggregationFixtureGenerator\:\:createContentTypeForFieldAggregation\(\) expects string, string\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/FixtureGenerator/FieldAggregationFixtureGenerator.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testFullTextFindTwo\(\) has parameter \$valueTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#2 \$fieldDefinitionIdentifier of method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\FixtureGenerator\\FieldAggregationFixtureGenerator\:\:createFieldAggregationFixtures\(\) expects string, string\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/FixtureGenerator/FieldAggregationFixtureGenerator.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testSort\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#3 \$fieldTypeIdentifier of method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\FixtureGenerator\\FieldAggregationFixtureGenerator\:\:createContentTypeForFieldAggregation\(\) expects string, string\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/FixtureGenerator/FieldAggregationFixtureGenerator.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testSort\(\) has parameter \$ascending with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#3 \$values of method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\FixtureGenerator\\FieldAggregationFixtureGenerator\:\:createFieldAggregationFixtures\(\) expects iterable, iterable\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/FixtureGenerator/FieldAggregationFixtureGenerator.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testSort\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\FixtureGenerator\\FieldAggregationFixtureGenerator\:\:\$values type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/FixtureGenerator/FieldAggregationFixtureGenerator.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testSort\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\LanguageTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/LanguageTermAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:testSort\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\LocationChildrenTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/LocationChildrenTermAggregationTest.php - - message: '#^Parameter \#2 \$fieldName of method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:doModifyField\(\) expects string, string\|false given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\ObjectStateTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/ObjectStateTermAggregationTest.php - - message: '#^Parameter \#2 \$fieldName of method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchBaseIntegrationTestCase\:\:doModifyField\(\) expects string, string\|null given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\RawRangeAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/RawRangeAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:checkOperatorSupport\(\) has parameter \$operator with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\RawStatsAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/RawStatsAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:findMultivaluedProvider\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\RawTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/RawTermAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:getAdditionallyIndexedMultivaluedFieldData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\SectionTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/SectionTermAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testCreateMultivaluedTestContent\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\SubtreeTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/SubtreeTermAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenOneTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\UserMetadataTermAggregationTest\:\:createGroupTermAggregationDataSet\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/UserMetadataTermAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenOneTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\UserMetadataTermAggregationTest\:\:createModifierTermAggregationDataSet\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/UserMetadataTermAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenOneTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\UserMetadataTermAggregationTest\:\:createOwnerTermAggregationDataSet\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/UserMetadataTermAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenOneTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\UserMetadataTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/UserMetadataTermAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenOneTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\UserMetadataTermAggregationTest\:\:dataProviderForTestFindLocationWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/UserMetadataTermAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenOneTwo\(\) has parameter \$valuesOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\VisibilityTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/Aggregation/VisibilityTermAggregationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenOneTwo\(\) has parameter \$valuesTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\DeleteTranslationTest\:\:createTestContentWithLanguages\(\) has parameter \$languages with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/DeleteTranslationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenTwoOne\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$array of function array_column expects array, iterable\ given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/MultilingualContentSearchIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenTwoOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Cannot access offset 0 on array\\|bool\|float\|int\|string\.$#' + identifier: offsetAccess.nonOffsetAccessible count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/RemoteIdIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenTwoOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\RemoteIdIndexingTest\:\:getRemoteIDs\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/RemoteIdIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenTwoOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\RemoteIdIndexingTest\:\:providerForTestIndexingRemoteId\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/RemoteIdIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenTwoOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Part \$criterion\-\>value \(array\\|bool\|float\|int\|string\) of encapsed string cannot be cast to string\.$#' + identifier: encapsedStringPart.nonString count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/RemoteIdIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenTwoOne\(\) has parameter \$valuesOne with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + message: '#^Possibly invalid array key type bool\|float\|int\|string\.$#' + identifier: offsetAccess.invalidOffset + count: 2 + path: tests/integration/Core/Repository/SearchService/RemoteIdIndexingTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedBetweenTwoOne\(\) has parameter \$valuesTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\:\:\$remoteId\.$#' + identifier: property.notFound count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/SortClause/AbstractSortClauseTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedContainsOne\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\AbstractSortClauseTestCase\:\:assertSearchResultOrderByRemoteId\(\) has parameter \$expectedOrderedIds with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/SortClause/AbstractSortClauseTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedContainsOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ContentTranslatedNameTest\:\:createContentForContentTranslatedNameTesting\(\) has parameter \$values with no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedContainsOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ContentTranslatedNameTest\:\:dataProviderForTestSortingByContentTranslatedName\(\) return type has no value type specified in iterable type iterable\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedContainsOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ContentTranslatedNameTest\:\:testContentSortingByContentTranslatedName\(\) has parameter \$expectedOrderedRemoteIds with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedContainsOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ContentTranslatedNameTest\:\:testContentSortingByContentTranslatedName\(\) has parameter \$inputValues with no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedContainsOne\(\) has parameter \$valuesOne with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedContainsOne\(\) has parameter \$valuesTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ContentTranslatedNameTest\:\:testContentSortingByContentTranslatedName\(\) has parameter \$languageFilter with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedEqualsOne\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ContentTranslatedNameTest\:\:testLocationSortingByContentTranslatedName\(\) has parameter \$expectedOrderedRemoteIds with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedEqualsOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ContentTranslatedNameTest\:\:testLocationSortingByContentTranslatedName\(\) has parameter \$inputValues with no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedEqualsOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ContentTranslatedNameTest\:\:testLocationSortingByContentTranslatedName\(\) has parameter \$languageFilter with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedEqualsOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + message: '#^PHPDoc tag @param references unknown parameter\: \$values$#' + identifier: parameter.notFound + count: 2 + path: tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedEqualsOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ScoreTest\:\:dataProviderForTestSortingByScore\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/SortClause/ScoreTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedEqualsOne\(\) has parameter \$valuesOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ScoreTest\:\:testSortingByScore\(\) has parameter \$expectedOrderedIds with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/SortClause/ScoreTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedEqualsOne\(\) has parameter \$valuesTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ScoreTest\:\:testSortingByScore\(\) has parameter \$inputValues with no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/SortClause/ScoreTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsOneTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^PHPDoc tag @param references unknown parameter\: \$values$#' + identifier: parameter.notFound count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchService/SortClause/ScoreTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsOneTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:assertFulltextSearch\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsOneTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:assertFulltextSearch\(\) has parameter \$expectedKeys with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsOneTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsOneTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsOneTwo\(\) has parameter \$valuesOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:assertFulltextSearch\(\) has parameter \$idMap with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsOneTwo\(\) has parameter \$valuesTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:doTestFulltextContentSearch\(\) has parameter \$expectedKeys with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:doTestFulltextContentSearch\(\) has parameter \$idMap with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:doTestFulltextLocationSearch\(\) has parameter \$expectedKeys with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:doTestFulltextLocationSearch\(\) has parameter \$idMap with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsTwo\(\) has parameter \$filter with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:doTestFulltextLocationSearch\(\) has parameter \$searchString with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:mapKeysToIds\(\) has parameter \$expectedKeys with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsTwo\(\) has parameter \$valuesOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:mapKeysToIds\(\) has parameter \$idMap with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOneFindsTwo\(\) has parameter \$valuesTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:mapKeysToIds\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOrEqualOne\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:mapSearchResultToIds\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOrEqualOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:providerForTestFulltextSearchSolr7\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOrEqualOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:testFulltextContentSearchSolr7\(\) has parameter \$expectedKeys with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOrEqualOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:testFulltextContentSearchSolr7\(\) has parameter \$idMap with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOrEqualOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:testFulltextLocationSearchSolr7\(\) has parameter \$expectedKeys with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOrEqualOne\(\) has parameter \$valuesOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:testFulltextLocationSearchSolr7\(\) has parameter \$idMap with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedGreaterThanOrEqualOne\(\) has parameter \$valuesTwo with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:testFulltextLocationSearchSolr7\(\) has parameter \$searchString with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOne\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:testPrepareContent\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^PHPDoc tag @var for variable \$keyGroup has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\:\:\$id\.$#' + identifier: property.notFound count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\Criterion\:\:setCustomField\(\)\.$#' + identifier: method.notFound count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Cannot access offset ''id'' on Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\.$#' + identifier: offsetAccess.nonOffsetAccessible count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOne\(\) has parameter \$valuesOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Cannot access offset ''title'' on Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\.$#' + identifier: offsetAccess.nonOffsetAccessible count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOne\(\) has parameter \$valuesTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Class Ibexa\\Tests\\Solr\\SetupFactory\\LegacySetupFactory not found\.$#' + identifier: class.notFound count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOneTwo\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:assertQueryFixture\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOneTwo\(\) has parameter \$content with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:assertQueryFixture\(\) has parameter \$ignoreScore with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOneTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:mapResultLocationIds\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOneTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:simplifySearchResult\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOneTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOneTwo\(\) has parameter \$valuesOne with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + message: '#^Parameter \#1 \$parentLocationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:newLocationCreateStruct\(\) expects int, int\|null given\.$#' + identifier: argument.type + count: 2 + path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedInOneTwo\(\) has parameter \$valuesTwo with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\:\:\$id\.$#' + identifier: property.notFound + count: 3 + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneEmpty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\Criterion\:\:setCustomField\(\)\.$#' + identifier: method.notFound count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneEmpty\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Search\\\\SearchResult'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Search\\SearchResult will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneEmpty\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + message: '#^Cannot access offset ''id'' on Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\.$#' + identifier: offsetAccess.nonOffsetAccessible + count: 3 + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneEmpty\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Cannot access offset ''title'' on Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\.$#' + identifier: offsetAccess.nonOffsetAccessible count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneEmpty\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + message: '#^Class Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\Criterion\\ContentTypeIdentifier constructor invoked with 2 parameters, 1 required\.$#' + identifier: arguments.count + count: 2 + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneEmpty\(\) has parameter \$valuesOne with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + message: '#^Class Ibexa\\Tests\\Solr\\SetupFactory\\LegacySetupFactory not found\.$#' + identifier: class.notFound + count: 5 + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneEmpty\(\) has parameter \$valuesTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Instanceof between Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query will always evaluate to true\.$#' + identifier: instanceof.alwaysTrue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneFindsOne\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:assertMultilingualFieldFilter\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneFindsOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneFindsOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:assertMultilingualFieldFilter\(\) has parameter \$contentDataList with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneFindsOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:assertMultilingualFieldFilter\(\) has parameter \$expected with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneFindsOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:assertMultilingualFieldFilter\(\) has parameter \$languageSettings with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneFindsOne\(\) has parameter \$valuesOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:assertMultilingualFieldSort\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOneFindsOne\(\) has parameter \$valuesTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:assertMultilingualFieldSort\(\) has parameter \$contentDataList with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOrEqualOne\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:assertMultilingualFieldSort\(\) has parameter \$expected with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOrEqualOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:assertMultilingualFieldSort\(\) has parameter \$languageSettings with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOrEqualOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:createContentForTestUserMetadataGroupHorizontal\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOrEqualOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:createContentWithFieldType\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOrEqualOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:find\(\) has parameter \$languages with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOrEqualOne\(\) has parameter \$valuesOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:mapResultContentIds\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedLowerThanOrEqualOne\(\) has parameter \$valuesTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:providerForTestSortingByNumericFieldsWithValuesOfDifferentLength\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenOneTwo\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:simplifySearchResult\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenOneTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:skipIfSeedNotImplemented\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenOneTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:sortSearchHitsById\(\) has parameter \$searchHits with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenOneTwo\(\) has parameter \$filter with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContent\(\) has parameter \$closure with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenOneTwo\(\) has parameter \$modifyField with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContent\(\) has parameter \$fixture with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenOneTwo\(\) has parameter \$valuesOne with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContent\(\) has parameter \$queryData with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenOneTwo\(\) has parameter \$valuesTwo with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContentInfo\(\) has parameter \$closure with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenTwoOne\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContentInfo\(\) has parameter \$fixture with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenTwoOne\(\) has parameter \$content with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContentInfo\(\) has parameter \$queryData with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenTwoOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContentLocations\(\) has parameter \$closure with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenTwoOne\(\) has parameter \$filter with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContentLocations\(\) has parameter \$fixture with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenTwoOne\(\) has parameter \$modifyField with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContentLocations\(\) has parameter \$queryData with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenTwoOne\(\) has parameter \$valuesOne with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortLocations\(\) has parameter \$closure with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotBetweenTwoOne\(\) has parameter \$valuesTwo with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortLocations\(\) has parameter \$fixture with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotContainsOne\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortLocations\(\) has parameter \$queryData with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotContainsOne\(\) has parameter \$content with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindContentFieldFiltersCaseSensitivity\(\) has parameter \$queryData with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotContainsOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindContentFiltered\(\) has parameter \$closure with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotContainsOne\(\) has parameter \$filter with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindContentFiltered\(\) has parameter \$fixture with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotContainsOne\(\) has parameter \$modifyField with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindContentFiltered\(\) has parameter \$queryData with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotContainsOne\(\) has parameter \$valuesOne with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindContentInfoFiltered\(\) has parameter \$closure with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotContainsOne\(\) has parameter \$valuesTwo with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindContentInfoFiltered\(\) has parameter \$fixture with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotEqualsOne\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindContentInfoFiltered\(\) has parameter \$queryData with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotEqualsOne\(\) has parameter \$content with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindLocationsContentFiltered\(\) has parameter \$closure with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotEqualsOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindLocationsContentFiltered\(\) has parameter \$fixture with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotEqualsOne\(\) has parameter \$filter with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindLocationsContentFiltered\(\) has parameter \$queryData with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotEqualsOne\(\) has parameter \$modifyField with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindLocationsFieldFiltersCaseSensitivity\(\) has parameter \$queryData with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotEqualsOne\(\) has parameter \$valuesOne with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindRelationFieldContentInfoFiltered\(\) has parameter \$fixture with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotEqualsOne\(\) has parameter \$valuesTwo with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindRelationFieldContentInfoFiltered\(\) has parameter \$queryData with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsOneTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindRelationFieldLocationsFiltered\(\) has parameter \$fixture with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsOneTwo\(\) has parameter \$content with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindRelationFieldLocationsFiltered\(\) has parameter \$queryData with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsOneTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFulltextComplex\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsOneTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFulltextContentSearchComplex\(\) has parameter \$data with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsOneTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFulltextContentTranslationSearch\(\) has parameter \$data with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsOneTwo\(\) has parameter \$valuesOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFulltextLocationSearchComplex\(\) has parameter \$data with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsOneTwo\(\) has parameter \$valuesTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFulltextLocationTranslationSearch\(\) has parameter \$data with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldFilterContent\(\) has parameter \$contentDataList with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsTwo\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldFilterContent\(\) has parameter \$expected with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldFilterContent\(\) has parameter \$languageSettings with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsTwo\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldFilterLocation\(\) has parameter \$contentDataList with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldFilterLocation\(\) has parameter \$expected with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsTwo\(\) has parameter \$valuesOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldFilterLocation\(\) has parameter \$languageSettings with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOneFindsTwo\(\) has parameter \$valuesTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldSortContent\(\) has parameter \$contentDataList with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOrEqual\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldSortContent\(\) has parameter \$expected with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOrEqual\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldSortContent\(\) has parameter \$languageSettings with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOrEqual\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldSortLocation\(\) has parameter \$contentDataList with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOrEqual\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldSortLocation\(\) has parameter \$expected with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOrEqual\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldSortLocation\(\) has parameter \$languageSettings with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOrEqual\(\) has parameter \$valuesOne with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContent\(\) has parameter \$closure with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotGreaterThanOrEqual\(\) has parameter \$valuesTwo with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContent\(\) has parameter \$fixture with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOne\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContent\(\) has parameter \$queryData with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOne\(\) has parameter \$content with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContentInfo\(\) has parameter \$closure with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContentInfo\(\) has parameter \$fixture with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOne\(\) has parameter \$filter with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContentInfo\(\) has parameter \$queryData with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOne\(\) has parameter \$modifyField with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContentLocations\(\) has parameter \$closure with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOne\(\) has parameter \$valuesOne with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContentLocations\(\) has parameter \$fixture with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOne\(\) has parameter \$valuesTwo with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContentLocations\(\) has parameter \$queryData with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOneTwo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryLocations\(\) has parameter \$closure with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOneTwo\(\) has parameter \$content with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryLocations\(\) has parameter \$fixture with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOneTwo\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryLocations\(\) has parameter \$queryData with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOneTwo\(\) has parameter \$filter with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testUserMetadataGroupHorizontalFilterLocation\(\) has parameter \$queryType with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOneTwo\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^PHPDoc tag @var has invalid value \(\$data \\Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Search\\SearchResult\)\: Unexpected token "\$data", expected type at offset 9 on line 1$#' + identifier: phpDoc.parseError count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOneTwo\(\) has parameter \$valuesOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$parentLocationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:newLocationCreateStruct\(\) expects int, int\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotInOneTwo\(\) has parameter \$valuesTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$query of method Ibexa\\Contracts\\Core\\Repository\\SearchService\:\:findLocations\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\LocationQuery, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneEmpty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + message: '#^Unreachable statement \- code above always terminates\.$#' + identifier: deadCode.unreachable + count: 3 + path: tests/integration/Core/Repository/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneEmpty\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Class Ibexa\\Tests\\Solr\\SetupFactory\\LegacySetupFactory not found\.$#' + identifier: class.notFound + count: 3 + path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php + + - + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:createContent\(\) has parameter \$parentLocationIds with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneEmpty\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:createContent\(\) has parameter \$searchValuesMap with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneEmpty\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:createTestContent\(\) has parameter \$parentLocationIds with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneEmpty\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:createTestContent\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneEmpty\(\) has parameter \$valuesOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:getIndexesToMatchData\(\) has parameter \$inputContentData with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneEmpty\(\) has parameter \$valuesTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:getIndexesToMatchData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneFindsOne\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:getSetupType\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneFindsOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testCreateTestContent\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneFindsOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindContent\(\) has parameter \$contentDataList with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneFindsOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindContent\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneFindsOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindContent\(\) has parameter \$languageSettings with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneFindsOne\(\) has parameter \$valuesOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindLocationsMultiple\(\) has parameter \$contentDataList with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOneFindsOne\(\) has parameter \$valuesTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindLocationsMultiple\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOrEqualOne\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindLocationsMultiple\(\) has parameter \$languageSettings with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOrEqualOne\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindLocationsSingle\(\) has parameter \$contentDataList with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOrEqualOne\(\) has parameter \$context with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindLocationsSingle\(\) has parameter \$context with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOrEqualOne\(\) has parameter \$filter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindLocationsSingle\(\) has parameter \$languageSettings with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOrEqualOne\(\) has parameter \$modifyField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to function is_object\(\) with Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo will always evaluate to true\.$#' + identifier: function.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SectionServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOrEqualOne\(\) has parameter \$valuesOne with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Section'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Section will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 4 + path: tests/integration/Core/Repository/SectionServiceTest.php + + - + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\SectionCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\SectionCreateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SectionServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:testFindMultivaluedNotLowerThanOrEqualOne\(\) has parameter \$valuesTwo with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\SectionUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\SectionUpdateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SectionServiceTest.php - - message: '#^Property Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SearchMultivaluedBaseIntegrationTestCase\:\:\$legacyUnsupportedOperators type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SettingServiceTest\:\:dataProviderForCreateSetting\(\) return type has no value type specified in iterable type iterable\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php + path: tests/integration/Core/Repository/SettingServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SettingServiceTest\:\:testCreateSetting\(\) has parameter \$value with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php + path: tests/integration/Core/Repository/SettingServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Generator expects value type array\{string, int, string\|null, int\|null\}, array\{''foo'', 100, null\} given\.$#' + identifier: generator.valueType count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php + path: tests/integration/Core/Repository/TokenServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php + message: '#^Access to protected property Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\TrashItem\:\:\$trashed\.$#' + identifier: property.protected + count: 4 + path: tests/integration/Core/Repository/TrashServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' - identifier: return.missing + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Content'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Content will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php + path: tests/integration/Core/Repository/TrashServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:getAdditionallyIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Location'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php + path: tests/integration/Core/Repository/TrashServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:getAdditionallyIndexedMultivaluedFieldData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\TrashItem'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\TrashItem will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php + path: tests/integration/Core/Repository/TrashServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Trash\\\\SearchResult'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Trash\\SearchResult will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 3 + path: tests/integration/Core/Repository/TrashServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertTrue\(\) with true will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php + path: tests/integration/Core/Repository/TrashServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Cannot access property \$id on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\TrashItem\|null\.$#' + identifier: property.nonObject count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php + path: tests/integration/Core/Repository/TrashServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\Selection\\Value\.$#' - identifier: return.type + message: '#^Cannot access property \$remoteId on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\TrashItem\|null\.$#' + identifier: property.nonObject + count: 4 + path: tests/integration/Core/Repository/TrashServiceTest.php + + - + message: '#^Cannot call method getRemovedLocationContentIdMap\(\) on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\TrashItem\|null\.$#' + identifier: method.nonObject count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php + path: tests/integration/Core/Repository/TrashServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:assertAliasNotExists\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php + path: tests/integration/Core/Repository/TrashServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testFindTrashItems\(\) has parameter \$filters with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php + path: tests/integration/Core/Repository/TrashServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testFindTrashItemsSort\(\) has parameter \$sortClausesClasses with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php + path: tests/integration/Core/Repository/TrashServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:trashFiltersProvider\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php + path: tests/integration/Core/Repository/TrashServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:trashSortClausesProvider\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php + path: tests/integration/Core/Repository/TrashServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php + message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' + identifier: argument.type + count: 6 + path: tests/integration/Core/Repository/TrashServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionIntegrationTest\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php + message: '#^Parameter \#1 \$trashItem of method Ibexa\\Contracts\\Core\\Repository\\TrashService\:\:recover\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\TrashItem, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\TrashItem\|null given\.$#' + identifier: argument.type + count: 2 + path: tests/integration/Core/Repository/TrashServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionMultilingualIntegrationTest\:\:getAdditionallyIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionMultilingualIntegrationTest.php + message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\:\:\$sortClauses \(array\\) does not accept array\\.$#' + identifier: assign.propertyType + count: 2 + path: tests/integration/Core/Repository/TrashServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionMultilingualIntegrationTest\:\:getAdditionallyIndexedMultivaluedFieldData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionMultilingualIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasService/CustomUrlAliasForMultilingualContentTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionMultilingualIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Cannot access property \$id on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null\.$#' + identifier: property.nonObject count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionMultilingualIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasService/UrlAliasLookupTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionMultilingualIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$location of method Ibexa\\Contracts\\Core\\Repository\\URLAliasService\:\:listLocationAliases\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionMultilingualIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasService/UrlAliasLookupTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\SelectionMultilingualIntegrationTest\:\:getValidFieldConfiguration\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$aliasList of method Ibexa\\Contracts\\Core\\Repository\\URLAliasService\:\:removeAliases\(\) expects array\, iterable\ given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/SelectionMultilingualIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceAuthorizationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceAuthorizationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to function is_object\(\) with Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location will always evaluate to true\.$#' + identifier: function.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\URLAlias'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\URLAlias will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 10 + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' - identifier: return.missing + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:assertLookupHistory\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:assertUrlAliasPropertiesCorrect\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:assertUrlAliasPropertiesCorrect\(\) has parameter \$expectedIsHistory with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:assertUrlAliasPropertiesCorrect\(\) has parameter \$expectedLanguageCodes with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\TextBlock\\Value\.$#' - identifier: return.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:assertUrlAliasPropertiesCorrect\(\) has parameter \$expectedPath with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:assertUrlAliasPropertiesSame\(\) has parameter \$expectedValues with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:assertUrlIsCurrent\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:assertUrlIsHistory\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:changeContentTypeUrlAliasSchema\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:changeSlugConverterConfiguration\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:createGlobalAliases\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextBlockIntegrationTest\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateGlobalUrlAlias\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateGlobalUrlAliasForLocation\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateGlobalUrlAliasForLocationVariation\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateGlobalUrlAliasWithAlwaysAvailable\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' - identifier: return.missing + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateGlobalUrlAliasWithForward\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateUrlAlias\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateUrlAliasPropertyValues\(\) has parameter \$testData with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateUrlAliasPropertyValuesWithAlwaysAvailable\(\) has parameter \$testData with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\TextLine\\Value\.$#' - identifier: return.type - count: 1 - path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateUrlAliasPropertyValuesWithForwarding\(\) has parameter \$testData with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateUrlAliasWithAlwaysAvailable\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateUrlAliasWithForwarding\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testListLocationAliases\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testListLocationAliasesLoadsCorrectly\(\) has parameter \$testData with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testLookUp\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TextLineIntegrationTest\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testLookupOnMultilingualNestedLocations\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:updateContentField\(\) has parameter \$fieldDefinitionIdentifier with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:updateContentField\(\) has parameter \$fieldValues with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php + message: '#^Parameter \#1 \$aliasList of method Ibexa\\Contracts\\Core\\Repository\\URLAliasService\:\:removeAliases\(\) expects array\, iterable\ given\.$#' + identifier: argument.type + count: 2 + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php + message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' + identifier: argument.type + count: 11 + path: tests/integration/Core/Repository/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php + message: '#^Access to protected property Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\URL\:\:\$modified\.$#' + identifier: property.protected + count: 4 + path: tests/integration/Core/Repository/URLServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\URL\\\\URL'' and Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\URL will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 4 + path: tests/integration/Core/Repository/URLServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\URL\\\\URLUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\URLUpdateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php + path: tests/integration/Core/Repository/URLServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\URL\\\\UsageSearchResult'' and Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\UsageSearchResult will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 2 + path: tests/integration/Core/Repository/URLServiceTest.php + + - + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUrlsWithSorting\(\) has parameter \$expectedUrls with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php + path: tests/integration/Core/Repository/URLServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUsages\(\) has parameter \$expectedContentInfos with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php + path: tests/integration/Core/Repository/URLServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUsages\(\) has parameter \$expectedTotalCount with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php + path: tests/integration/Core/Repository/URLServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUsages\(\) has parameter \$limit with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php + path: tests/integration/Core/Repository/URLServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUsages\(\) has parameter \$offset with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php + path: tests/integration/Core/Repository/URLServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\TimeIntegrationTest\:\:testUpdateContentFails\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUsages\(\) has parameter \$urlId with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php + path: tests/integration/Core/Repository/URLServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\URLQuery\:\:\$limit \(int\) does not accept string\.$#' + identifier: assign.propertyType count: 1 - path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php + path: tests/integration/Core/Repository/URLServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\URLQuery\:\:\$offset \(int\) does not accept string\.$#' + identifier: assign.propertyType count: 1 - path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php + path: tests/integration/Core/Repository/URLServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLWildcardService\\CriterionTest\:\:getUrlWildcards\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php + path: tests/integration/Core/Repository/URLWildcardService/CriterionTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' - identifier: return.missing + message: '#^Parameter \#1 \$criteria of class Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\URLWildcard\\Query\\Criterion\\LogicalAnd constructor expects array\, array\ given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php + path: tests/integration/Core/Repository/URLWildcardService/CriterionTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:getAdditionallyIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$expectedCount of static method PHPUnit\\Framework\\Assert\:\:assertCount\(\) expects int, int\|null given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php + path: tests/integration/Core/Repository/URLWildcardService/CriterionTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:getFullTextIndexedFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\URLWildcard'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\URLWildcard will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 2 + path: tests/integration/Core/Repository/URLWildcardServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\URLWildcardTranslationResult'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\URLWildcardTranslationResult will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php + path: tests/integration/Core/Repository/URLWildcardServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:getValidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\UserPreference\\\\UserPreference'' and Ibexa\\Contracts\\Core\\Repository\\Values\\UserPreference\\UserPreference will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 2 + path: tests/integration/Core/Repository/UserPreferenceServiceTest.php + + - + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\UserPreference\\\\UserPreferenceList'' and Ibexa\\Contracts\\Core\\Repository\\Values\\UserPreference\\UserPreferenceList will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php + path: tests/integration/Core/Repository/UserPreferenceServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:getValidUpdateFieldData\(\) should return array but returns Ibexa\\Core\\FieldType\\Url\\Value\.$#' - identifier: return.type + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\User'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\User will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 7 + path: tests/integration/Core/Repository/UserServiceTest.php + + - + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\UserCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\UserCreateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php + path: tests/integration/Core/Repository/UserServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\UserGroupCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\UserGroupCreateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php + path: tests/integration/Core/Repository/UserServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\UserGroupUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\UserGroupUpdateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php + path: tests/integration/Core/Repository/UserServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\UserUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\UserUpdateStruct will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php + path: tests/integration/Core/Repository/UserServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Cannot call method add\(\) on DateTimeImmutable\|false\|null\.$#' + identifier: method.nonObject + count: 3 + path: tests/integration/Core/Repository/UserServiceTest.php + + - + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:createUserContentTypeWithAccountSettings\(\) has parameter \$fieldSetting with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php + path: tests/integration/Core/Repository/UserServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:createUserContentTypeWithAccountSettings\(\) has parameter \$validatorConfiguration with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php + path: tests/integration/Core/Repository/UserServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:dataProviderForValidatePassword\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php + path: tests/integration/Core/Repository/UserServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UrlIntegrationTest\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:getDataForTestPasswordUpdateRespectsAllValidationSettings\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php + path: tests/integration/Core/Repository/UserServiceTest.php - - message: '#^Parameter \#1 \$link of class Ibexa\\Core\\FieldType\\Url\\Value constructor expects string\|null, int given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:getPrioritizedLanguageList\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php + path: tests/integration/Core/Repository/UserServiceTest.php - - message: '#^Parameter \#2 \$text of class Ibexa\\Core\\FieldType\\Url\\Value constructor expects string\|null, int given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testNewUserCreateStruct\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php + path: tests/integration/Core/Repository/UserServiceTest.php - - message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\User\\User\:\:\$content\.$#' - identifier: property.notFound + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testValidatePassword\(\) has parameter \$expectedErrors with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/integration/Core/Repository/UserServiceTest.php + + - + message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' + identifier: argument.type count: 2 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/UserServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:assertCopiedFieldDataLoadedCorrectly\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#2 \$array of function array_map expects array, iterable\ given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/UserServiceTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:assertFieldDataLoadedCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$string of function md5 expects string, int\<1, max\> given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/BaseLimitationTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ChangeOwnerLimitationTest\:\:getContentCreatePolicyDraft\(\) should return Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft but returns Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy\.$#' + identifier: return.type count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/ChangeOwnerLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:assertUpdatedFieldDataLoadedCorrect\(\) should return array but return statement is missing\.$#' - identifier: return.missing + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ChangeOwnerLimitationTest\:\:getDataForDeniedAccess\(\) should return array\\}\> but returns array\{array\{123, array\{\-1\}\}, array\{123, array\{456, 789\}\}\}\.$#' + identifier: return.type count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/ChangeOwnerLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:createContent\(\) has parameter \$contentType with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ChangeOwnerLimitationTest\:\:getDataForGrantedAccess\(\) should return array\\}\> but returns array\{array\{null, array\{\}\}, array\{null, array\{\-1\}\}, array\{null, array\{123, 456, \-1\}\}, array\{123, array\{123, 456, \-1\}\}, array\{123, array\{\}\}\}\.$#' + identifier: return.type count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/ChangeOwnerLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:getSettingsSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' + identifier: property.nonObject count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/ContentTypeLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:getValidatorSchema\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^PHPDoc tag @var with type Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft is not subtype of native type null\.$#' + identifier: varTag.nativeType count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/ContentTypeLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:provideFromHashData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#2 \$policy of method Ibexa\\Contracts\\Core\\Repository\\RoleService\:\:updatePolicyByRoleDraft\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft, Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/ContentTypeLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:provideInvalidCreationFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Cannot access property \$value on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Field\|null\.$#' + identifier: property.nonObject + count: 2 + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php + + - + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:createEditorUserWithLanguageLimitation\(\) has parameter \$allowedTranslationsList with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:provideInvalidUpdateFieldData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:providerForCanUserWithLimitationTargets\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:provideToHashData\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:providerForCreateAndPublishContent\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:providerForTestIsEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:providerForTestIsNotEmptyValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:providerForPublishVersionWithLanguageLimitation\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:testAddFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testCanUserWithLimitationTargets\(\) has parameter \$allowedTranslationsList with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:testCopiedExternalData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testCanUserWithLimitationTargets\(\) has parameter \$folderNames with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:testCopiedFieldType\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testCopyContentWithLanguageLimitationAndDifferentContentTranslations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:testCopiedFieldType\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testCopySubtreeWithLanguageLimitationAndDifferentContentTranslations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:testCopyField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testCreateAndPublishContent\(\) has parameter \$allowedTranslationsList with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:testCopyField\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testCreateAndPublishContent\(\) has parameter \$names with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:testCreateContentWithEmptyFieldValue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testHideContentWithLanguageLimitationAndDifferentContentTranslations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:testRemoveFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testHideLocationWithLanguageLimitationAndDifferentContentTranslations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldType\\UserIntegrationTest\:\:testUpdateFieldDefinitionWithIncompleteSettingsSchema\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testMoveSubtreeWithLanguageLimitationAndDifferentContentTranslations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldType/UserIntegrationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Call to method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\FieldType'' and Ibexa\\Contracts\\Core\\Repository\\FieldType will always evaluate to true\.$#' - identifier: method.alreadyNarrowedType + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldTypeServiceTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldTypeServiceTest\:\:testGetFieldType\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testPublishVersion\(\) has parameter \$allowedTranslationsList with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldTypeServiceTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldTypeServiceTest\:\:testGetFieldTypeThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testPublishVersion\(\) has parameter \$names with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldTypeServiceTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldTypeServiceTest\:\:testGetFieldTypes\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testPublishVersion\(\) has parameter \$namesToUpdate with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldTypeServiceTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldTypeServiceTest\:\:testHasFieldTypeReturnsFalse\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testPublishVersionIsNotAllowedIfModifiedOtherTranslations\(\) has parameter \$names with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldTypeServiceTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\FieldTypeServiceTest\:\:testHasFieldTypeReturnsTrue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testRevealContentWithLanguageLimitationAndDifferentContentTranslations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/FieldTypeServiceTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Cannot access property \$pathString on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null\.$#' - identifier: property.nonObject + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testSwapLocationWithLanguageLimitationAndDifferentContentTranslations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/Filtering/BaseRepositoryFilteringTestCase.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\BaseRepositoryFilteringTestCase\:\:assertFoundContentItemsByRemoteIds\(\) has parameter \$expectedContentRemoteIds with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testUnhideLocationWithLanguageLimitationAndDifferentContentTranslations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/Filtering/BaseRepositoryFilteringTestCase.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\BaseRepositoryFilteringTestCase\:\:assertFoundContentItemsByRemoteIds\(\) has parameter \$list with no value type specified in iterable type iterable\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testUpdateLocationWithLanguageLimitationAndDifferentContentTranslations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/Filtering/BaseRepositoryFilteringTestCase.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\BaseRepositoryFilteringTestCase\:\:find\(\) has parameter \$contextLanguages with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^PHPDoc tag @return with type iterable\\|bool\>\> is not subtype of native type array\.$#' + identifier: return.phpDocType count: 1 - path: tests/integration/Core/Repository/Filtering/BaseRepositoryFilteringTestCase.php + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\BaseRepositoryFilteringTestCase\:\:find\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' + identifier: argument.type + count: 7 + path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php + + - + message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' + identifier: property.nonObject count: 1 - path: tests/integration/Core/Repository/Filtering/BaseRepositoryFilteringTestCase.php + path: tests/integration/Core/Repository/Values/User/Limitation/LocationLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\BaseRepositoryFilteringTestCase\:\:getFilterFactories\(\) return type has no value type specified in iterable type iterable\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ObjectStateLimitationTest\:\:createUserWithObjectStateLimitation\(\) has parameter \$objectStateIDs with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/Filtering/BaseRepositoryFilteringTestCase.php + path: tests/integration/Core/Repository/Values/User/Limitation/ObjectStateLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\BaseRepositoryFilteringTestCase\:\:getUserLimitationData\(\) return type has no value type specified in iterable type iterable\.$#' + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ObjectStateLimitationTest\:\:createUserWithObjectStateLimitationOnContentRead\(\) has parameter \$values with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/Filtering/BaseRepositoryFilteringTestCase.php + path: tests/integration/Core/Repository/Values/User/Limitation/ObjectStateLimitationTest.php - - message: '#^Parameter \#1 \$value of class Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\Criterion\\ParentLocationId constructor expects array\\|int, int\|null given\.$#' + message: '#^Parameter \#2 \$policy of method Ibexa\\Contracts\\Core\\Repository\\RoleService\:\:updatePolicyByRoleDraft\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft, Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy given\.$#' identifier: argument.type - count: 5 - path: tests/integration/Core/Repository/Filtering/BaseRepositoryFilteringTestCase.php + count: 2 + path: tests/integration/Core/Repository/Values/User/Limitation/OwnerLimitationTest.php - - message: '#^Call to an undefined method Traversable\\:\:offsetGet\(\)\.$#' - identifier: method.notFound - count: 1 - path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php + message: '#^Variable \$policy in PHPDoc tag @var does not match assigned variable \$removePolicy\.$#' + identifier: varTag.differentVariable + count: 2 + path: tests/integration/Core/Repository/Values/User/Limitation/OwnerLimitationTest.php - - message: '#^Cannot use array destructuring on iterable\\.$#' - identifier: offsetAccess.nonArray + message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' + identifier: property.nonObject count: 1 - path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/ParentContentTypeLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\ContentFilteringTest\:\:assertFoundContentItemsByRemoteIds\(\) has parameter \$expectedContentRemoteIds with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' + identifier: property.nonObject count: 1 - path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/ParentDepthLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\ContentFilteringTest\:\:assertFoundContentItemsByRemoteIds\(\) has parameter \$list with no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\ContentFilteringTest\:\:createMultiplePagesOfContentItems\(\) should return int but returns int\|null\.$#' - identifier: return.type + message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' + identifier: property.nonObject count: 1 - path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/ParentOwnerLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\ContentFilteringTest\:\:find\(\) has parameter \$contextLanguages with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' + identifier: property.nonObject count: 1 - path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/ParentUserGroupLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\ContentFilteringTest\:\:getDataForTestFindContentWithLocationCriterion\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\RolePolicyLimitationTest\:\:addPolicyToNewRole\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/RolePolicyLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\ContentFilteringTest\:\:getFilterFactories\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\RolePolicyLimitationTest\:\:getSubtreeLocationsCount\(\) has parameter \$subtreePathString with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/RolePolicyLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\ContentFilteringTest\:\:getListOfSupportedSortClauses\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' + identifier: property.nonObject count: 1 - path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/SectionLimitationTest.php - - message: '#^Parameter \#1 \$sortClause of method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\ContentFilteringTest\:\:performAndAssertSimpleSortClauseQuery\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Filter\\FilteringSortClause, object given\.$#' + message: '#^Parameter \#2 \$policy of method Ibexa\\Contracts\\Core\\Repository\\RoleService\:\:updatePolicyByRoleDraft\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft, Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy given\.$#' identifier: argument.type count: 2 - path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/SectionLimitationTest.php - - message: '#^Parameter \#1 \$value of class Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\Criterion\\ParentLocationId constructor expects array\\|int, int\|null given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/Filtering/ContentFilteringTest.php + message: '#^Variable \$policy in PHPDoc tag @var does not match assigned variable \$readPolicy\.$#' + identifier: varTag.differentVariable + count: 2 + path: tests/integration/Core/Repository/Values/User/Limitation/SectionLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\LocationFilteringTest\:\:assertFoundContentItemsByRemoteIds\(\) has parameter \$expectedContentRemoteIds with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' + identifier: property.nonObject count: 1 - path: tests/integration/Core/Repository/Filtering/LocationFilteringTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/StatusLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\LocationFilteringTest\:\:assertFoundContentItemsByRemoteIds\(\) has parameter \$list with no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' + identifier: property.nonObject count: 1 - path: tests/integration/Core/Repository/Filtering/LocationFilteringTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/SubtreeLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Filtering\\LocationFilteringTest\:\:find\(\) has parameter \$contextLanguages with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\SubtreeLimitationTest\:\:prepareLimitation\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/Filtering/LocationFilteringTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/SubtreeLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceAuthorizationTest\:\:testCreateLanguageThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#2 \$policy of method Ibexa\\Contracts\\Core\\Repository\\RoleService\:\:updatePolicyByRoleDraft\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft, Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/LanguageServiceAuthorizationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/SubtreeLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceAuthorizationTest\:\:testDeleteLanguageThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Variable \$policy in PHPDoc tag @var does not match assigned variable \$editPolicy\.$#' + identifier: varTag.differentVariable count: 1 - path: tests/integration/Core/Repository/LanguageServiceAuthorizationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/SubtreeLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceAuthorizationTest\:\:testDisableLanguageThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' + identifier: property.nonObject count: 1 - path: tests/integration/Core/Repository/LanguageServiceAuthorizationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/UserGroupLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceAuthorizationTest\:\:testEnableLanguageThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#2 \$policy of method Ibexa\\Contracts\\Core\\Repository\\RoleService\:\:updatePolicyByRoleDraft\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft, Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy given\.$#' + identifier: argument.type count: 1 - path: tests/integration/Core/Repository/LanguageServiceAuthorizationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/UserGroupLimitationTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceAuthorizationTest\:\:testUpdateLanguageNameThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Variable \$policy in PHPDoc tag @var does not match assigned variable \$editPolicy\.$#' + identifier: varTag.differentVariable count: 1 - path: tests/integration/Core/Repository/LanguageServiceAuthorizationTest.php + path: tests/integration/Core/Repository/Values/User/Limitation/UserGroupLimitationTest.php - - message: '#^Comparison operation "\<" between int\<80300, 80599\> and 50400 is always false\.$#' - identifier: smaller.alwaysFalse + message: '#^Method Ibexa\\Tests\\Integration\\Core\\User\\UserStorage\\UserStorageGatewayTestCase\:\:getDataForTestCountUsersWithUnsupportedHashType\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/LanguageServiceMaximumSupportedLanguagesTest.php + path: tests/integration/Core/User/UserStorage/UserStorageGatewayTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceMaximumSupportedLanguagesTest\:\:testCreateMaximumLanguageLimit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Integration\\Core\\User\\UserStorage\\UserStorageGatewayTestCase\:\:providerForGetFieldData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/LanguageServiceMaximumSupportedLanguagesTest.php + path: tests/integration/Core/User/UserStorage/UserStorageGatewayTestCase.php - - message: '#^Parameter \#1 \$value of function count expects array\|Countable, iterable\ given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Integration\\Core\\User\\UserStorage\\UserStorageGatewayTestCase\:\:testGetFieldData\(\) has parameter \$expectedUserData with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/LanguageServiceMaximumSupportedLanguagesTest.php + path: tests/integration/Core/User/UserStorage/UserStorageGatewayTestCase.php - - message: '#^Property Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceMaximumSupportedLanguagesTest\:\:\$createdLanguages type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\FieldTypeRegistryPassTest\:\:tagsProvider\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/LanguageServiceMaximumSupportedLanguagesTest.php + path: tests/lib/Base/Container/Compiler/FieldTypeRegistryPassTest.php - - message: '#^Result of && is always false\.$#' - identifier: booleanAnd.alwaysFalse + message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\GenericFieldTypeConverterPassTest\:\:assertContainerBuilderHasNoServiceDefinitionWithMethodCall\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/LanguageServiceMaximumSupportedLanguagesTest.php + path: tests/lib/Base/Container/Compiler/GenericFieldTypeConverterPassTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Language'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Language will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 3 - path: tests/integration/Core/Repository/LanguageServiceTest.php + message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\GenericFieldTypeConverterPassTest\:\:assertContainerBuilderHasNoServiceDefinitionWithMethodCall\(\) has parameter \$index with no type specified\.$#' + identifier: missingType.parameter + count: 1 + path: tests/lib/Base/Container/Compiler/GenericFieldTypeConverterPassTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\LanguageCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\LanguageCreateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType + message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Storage\\ExternalStorageRegistryPassTest\:\:externalStorageHandlerGatewayTagsProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Base/Container/Compiler/Storage/ExternalStorageRegistryPassTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:loadLanguagesReturnsAnEmptyArrayByDefault\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Storage\\ExternalStorageRegistryPassTest\:\:externalStorageHandlerTagsProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Base/Container/Compiler/Storage/ExternalStorageRegistryPassTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testCreateLanguageInTransactionWithCommit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Class Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Stubs\\GatewayBasedStorageHandler extends generic class Ibexa\\Contracts\\Core\\FieldType\\GatewayBasedStorage but does not specify its types\: T$#' + identifier: missingType.generics count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Base/Container/Compiler/Stubs/GatewayBasedStorageHandler.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testCreateLanguageInTransactionWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Stubs\\GatewayBasedStorageHandler\:\:deleteFieldData\(\) has parameter \$fieldIds with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Base/Container/Compiler/Stubs/GatewayBasedStorageHandler.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testCreateLanguageSetsExpectedProperties\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Stubs\\GatewayBasedStorageHandler\:\:deleteFieldData\(\) should return bool but return statement is missing\.$#' + identifier: return.missing count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Base/Container/Compiler/Stubs/GatewayBasedStorageHandler.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testCreateLanguageSetsIdPropertyOnReturnedLanguage\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Stubs\\GatewayBasedStorageHandler\:\:getFieldData\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Base/Container/Compiler/Stubs/GatewayBasedStorageHandler.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testCreateLanguageThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Stubs\\GatewayBasedStorageHandler\:\:hasFieldData\(\) should return bool but return statement is missing\.$#' + identifier: return.missing count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Base/Container/Compiler/Stubs/GatewayBasedStorageHandler.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testDeleteLanguage\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\TaggedServiceIdsIterator\\DeprecationErrorCollector\:\:getErrors\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Base/Container/Compiler/TaggedServiceIdsIterator/DeprecationErrorCollector.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testDeleteLanguageThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\TaggedServiceIdsIterator\\DeprecationErrorCollector\:\:\$errors type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Base/Container/Compiler/TaggedServiceIdsIterator/DeprecationErrorCollector.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testDisableLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Collection\\CollectionInterface\:\:filter\(\)\.$#' + identifier: method.notFound + count: 2 + path: tests/lib/Collection/AbstractCollectionTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testEnableLanguage\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''IteratorAggregate'' and Ibexa\\Contracts\\Core\\Collection\\CollectionInterface will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Collection/AbstractCollectionTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testGetDefaultLanguageCode\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\:\:createCollection\(\) has invalid return type Ibexa\\Contracts\\Core\\Repository\\Collection\\CollectionInterfaces\.$#' + identifier: class.notFound count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Collection/AbstractCollectionTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testLoadLanguage\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\:\:createCollection\(\) has parameter \$data with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Collection/AbstractCollectionTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testLoadLanguageById\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\:\:createCollection\(\) return type with generic interface Ibexa\\Contracts\\Core\\Collection\\CollectionInterface does not specify its types\: TValue$#' + identifier: missingType.generics count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Collection/AbstractCollectionTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testLoadLanguageByIdThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\:\:createCollectionWithExampleData\(\) has invalid return type Ibexa\\Contracts\\Core\\Repository\\Collection\\CollectionInterfaces\.$#' + identifier: class.notFound count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Collection/AbstractCollectionTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testLoadLanguageThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\:\:createCollectionWithExampleData\(\) return type with generic interface Ibexa\\Contracts\\Core\\Collection\\CollectionInterface does not specify its types\: TValue$#' + identifier: missingType.generics count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Collection/AbstractCollectionTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testLoadLanguageThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\:\:createEmptyCollection\(\) has invalid return type Ibexa\\Contracts\\Core\\Repository\\Collection\\CollectionInterfaces\.$#' + identifier: class.notFound count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Collection/AbstractCollectionTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testLoadLanguages\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\:\:createEmptyCollection\(\) return type with generic interface Ibexa\\Contracts\\Core\\Collection\\CollectionInterface does not specify its types\: TValue$#' + identifier: missingType.generics count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Collection/AbstractCollectionTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testNewLanguageCreateStruct\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\:\:getExampleData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Collection/AbstractCollectionTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testUpdateLanguageName\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + message: '#^PHPDoc tag @return with type TCollection of Ibexa\\Contracts\\Core\\Repository\\Collection\\CollectionInterfaces is not subtype of native type Ibexa\\Contracts\\Core\\Collection\\CollectionInterface\.$#' + identifier: return.phpDocType + count: 3 + path: tests/lib/Collection/AbstractCollectionTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testUpdateLanguageNameInTransactionWithCommit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^PHPDoc tag @template TCollection for class Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase has invalid bound type Ibexa\\Contracts\\Core\\Repository\\Collection\\CollectionInterfaces\.$#' + identifier: class.notFound count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Collection/AbstractCollectionTestCase.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testUpdateLanguageNameInTransactionWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Collection\\ArrayListTest\:\:createCollection\(\) has parameter \$data with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Collection/ArrayListTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LanguageServiceTest\:\:testUpdateLanguageNameThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Collection\\ArrayListTest\:\:createCollection\(\) return type with generic class Ibexa\\Contracts\\Core\\Collection\\ArrayList does not specify its types\: TValue$#' + identifier: missingType.generics count: 1 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Collection/ArrayListTest.php - - message: '#^Parameter \#1 \$value of function count expects array\|Countable, iterable\ given\.$#' - identifier: argument.type + message: '#^PHPDoc tag @var for variable \$list contains generic class Ibexa\\Contracts\\Core\\Collection\\ArrayList but does not specify its types\: TValue$#' + identifier: missingType.generics count: 2 - path: tests/integration/Core/Repository/LanguageServiceTest.php + path: tests/lib/Collection/ArrayListTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Limitation\\PermissionResolver\\BaseLimitationIntegrationTestCase\:\:assertCanUser\(\) has parameter \$limitations with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Type Ibexa\\Contracts\\Core\\Collection\\ArrayList in generic type Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\ in PHPDoc tag @extends is not subtype of template type TCollection of Ibexa\\Contracts\\Core\\Repository\\Collection\\CollectionInterfaces of class Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\.$#' + identifier: generics.notSubtype count: 1 - path: tests/integration/Core/Repository/Limitation/PermissionResolver/BaseLimitationIntegrationTestCase.php + path: tests/lib/Collection/ArrayListTest.php - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Limitation\\PermissionResolver\\BaseLimitationIntegrationTestCase\:\:assertCanUser\(\) has parameter \$targets with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Limitation/PermissionResolver/BaseLimitationIntegrationTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Limitation\\PermissionResolver\\BaseLimitationIntegrationTestCase\:\:loginAsEditorUserWithLimitations\(\) has parameter \$limitations with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Limitation/PermissionResolver/BaseLimitationIntegrationTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Limitation\\PermissionResolver\\ContentLimitationsMixIntegrationTest\:\:providerForCanUser\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Limitation/PermissionResolver/ContentLimitationsMixIntegrationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Limitation\\PermissionResolver\\ContentLimitationsMixIntegrationTest\:\:testCanUser\(\) has parameter \$limitations with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Limitation/PermissionResolver/ContentLimitationsMixIntegrationTest.php - - - - message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/Limitation/PermissionResolver/ContentLimitationsMixIntegrationTest.php - - - - message: '#^Cannot access property \$contentInfo on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\TrashItem\|null\.$#' - identifier: property.nonObject - count: 1 - path: tests/integration/Core/Repository/Limitation/PermissionResolver/LocationLimitationIntegrationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Limitation\\PermissionResolver\\LocationLimitationIntegrationTest\:\:providerForCanUserEditOrPublishContent\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Limitation/PermissionResolver/LocationLimitationIntegrationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Limitation\\PermissionResolver\\LocationLimitationIntegrationTest\:\:testCanUserEditContent\(\) has parameter \$limitations with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Limitation/PermissionResolver/LocationLimitationIntegrationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Limitation\\PermissionResolver\\LocationLimitationIntegrationTest\:\:testCanUserReadTrashedContent\(\) has parameter \$limitations with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Limitation/PermissionResolver/LocationLimitationIntegrationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceAuthorizationTest\:\:testCopySubtreeThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceAuthorizationTest\:\:testCreateLocationThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceAuthorizationTest\:\:testCreateLocationThrowsUnauthorizedExceptionDueToLackOfContentManageLocationsPolicy\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceAuthorizationTest\:\:testDeleteLocationThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceAuthorizationTest\:\:testDeleteLocationWithSubtreeThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceAuthorizationTest\:\:testHideLocationThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceAuthorizationTest\:\:testLoadLocationByRemoteIdThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceAuthorizationTest\:\:testLoadLocationThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceAuthorizationTest\:\:testLoadLocationsNoAccess\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceAuthorizationTest\:\:testMoveSubtreeThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceAuthorizationTest\:\:testSwapLocationThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceAuthorizationTest\:\:testUnhideLocationThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceAuthorizationTest\:\:testUpdateLocationThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceAuthorizationTest.php - - - - message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 2 - path: tests/integration/Core/Repository/LocationServiceAuthorizationTest.php - - - - message: '#^Parameter \#1 \$parentLocationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:newLocationCreateStruct\(\) expects int, string given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/LocationServiceAuthorizationTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Content'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Content will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 2 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Location'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 10 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\LocationCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\LocationCreateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\LocationList'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\LocationList will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\LocationUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\LocationUpdateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertTrue\(\) with true will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Cannot access property \$id on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null\.$#' - identifier: property.nonObject - count: 9 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Cannot call method getContentInfo\(\) on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null\.$#' - identifier: method.nonObject - count: 2 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:assertAliasesBeforeCopy\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:assertAliasesBeforeCopy\(\) has parameter \$expectedSubItemAliases with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:assertDefaultContentStates\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:assertGeneratedAliases\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:assertGeneratedAliases\(\) has parameter \$expectedAliases with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:assertSubtreeProperties\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:assertSubtreeProperties\(\) has parameter \$expectedValues with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:assertSubtreeProperties\(\) has parameter \$stopId with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:dataProviderForOutOfRangeLocationPriority\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:loadLocationProperties\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:loadSubtreeProperties\(\) has parameter \$properties with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:loadSubtreeProperties\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:providerForLoadLocationChildrenRespectsParentSortingClauses\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testBookmarksAreSwappedAfterSwapLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testCopySubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testCopySubtreeIncrementsChildCountOfNewParent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testCopySubtreeThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testCopySubtreeUpdatesSubtreeProperties\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testCopySubtreeWithAliases\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testCreateLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testCreateLocationInTransactionWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testCreateLocationStructValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testCreateLocationStructValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testCreateLocationThrowsInvalidArgumentExceptionContentAlreadyBelowParent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testCreateLocationThrowsInvalidArgumentExceptionParentIsSubLocationOfContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testCreateLocationThrowsInvalidArgumentExceptionPriorityIsOutOfRange\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testCreateLocationThrowsInvalidArgumentExceptionPriorityIsOutOfRange\(\) has parameter \$priority with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testCreateLocationThrowsInvalidArgumentExceptionRemoteIdExists\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testDeleteContentObjectLastLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testDeleteLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testDeleteLocationDecrementsChildCountOnParent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testDeleteLocationDeletesRelatedBookmarks\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testGetLocationChildCount\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testHideLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocationByRemoteId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocationByRemoteIdThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocationChildren\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocationChildrenData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocationChildrenRespectsParentSortingClauses\(\) has parameter \$expectedChildrenNames with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocationListInCorrectOrder\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocationListWithRootLocationId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocationPrioritizedLanguagesFallback\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocationRootStructValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocationStructValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocationThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocationsContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocationsContent\(\) has parameter \$locations with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocationsLimitedSubtreeContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocationsThrowsBadStateException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadLocationsThrowsBadStateExceptionLimitedSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadParentLocationsForDraftContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testLoadParentLocationsForDraftContentThrowsBadStateException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testMoveInvisibleSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testMoveSubtreeDecrementsChildCountOfOldParent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testMoveSubtreeIncrementsChildCountOfNewParent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testMoveSubtreeUpdatesSubtreeProperties\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testMoveSubtreeUpdatesSubtreePropertiesHidden\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testNewLocationCreateStructValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testNewLocationUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testSwapLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testSwapLocationDoesNotCorruptSearchResults\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testSwapLocationForMainAndSecondaryLocation\(\) should return array\ but returns array\\.$#' - identifier: return.type - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testSwapLocationUpdatesMainLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testUnhideLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testUnhideLocationNotUnhidesHiddenSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testUpdateLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testUpdateLocationStructValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testUpdateLocationStructValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testUpdateLocationThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testUpdateLocationThrowsInvalidArgumentExceptionPriorityIsOutOfRange\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testUpdateLocationThrowsInvalidArgumentExceptionPriorityIsOutOfRange\(\) has parameter \$priority with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testUpdateLocationTwice\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:testUpdateLocationWithSameRemoteId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Parameter \#1 \$expectedLocations of method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:assertContentHasExpectedLocations\(\) expects array\, array\ given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Parameter \#1 \$location of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:moveSubtree\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null given\.$#' - identifier: argument.type - count: 3 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 23 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Parameter \#1 \$parentLocationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:newLocationCreateStruct\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 2 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Parameter \#2 \$actualObject of method Ibexa\\Tests\\Integration\\Core\\Repository\\BaseTestCase\:\:assertPropertiesCorrect\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null given\.$#' - identifier: argument.type - count: 2 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Parameter \#2 \$array of function array_map expects array, iterable\ given\.$#' - identifier: argument.type - count: 3 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Parameter \#2 \$location2 of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:swapLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Parameter \#2 \$newParentLocation of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:moveSubtree\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null given\.$#' - identifier: argument.type - count: 2 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Parameter \#2 \$parentLocationId of method Ibexa\\Tests\\Integration\\Core\\Repository\\LocationServiceTest\:\:publishContentWithParentLocation\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 8 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Parameter \#2 \$targetParentLocation of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:copySubtree\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|false given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\NonRedundantFieldSetTest\:\:assertFieldIds\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/NonRedundantFieldSetTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\NonRedundantFieldSetTest\:\:mapFields\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/NonRedundantFieldSetTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\NonRedundantFieldSetTest\:\:testCreateContentDefaultValuesFields\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/NonRedundantFieldSetTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\NonRedundantFieldSetTest\:\:testCreateContentDefaultValuesNoStructFieldsFields\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/NonRedundantFieldSetTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\NonRedundantFieldSetTest\:\:testCreateContentDraftFields\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/NonRedundantFieldSetTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\NonRedundantFieldSetTest\:\:testCreateContentDraftFieldsRetainsIds\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/NonRedundantFieldSetTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\NonRedundantFieldSetTest\:\:testCreateContentEmptyValuesFields\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/NonRedundantFieldSetTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\NonRedundantFieldSetTest\:\:testCreateContentEmptyValuesTranslationNotStoredFields\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/NonRedundantFieldSetTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\NonRedundantFieldSetTest\:\:testCreateContentTwoLanguagesMainTranslationStoredFields\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/NonRedundantFieldSetTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\NonRedundantFieldSetTest\:\:testCreateContentTwoLanguagesNoValuesForMainLanguageFields\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/NonRedundantFieldSetTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\NonRedundantFieldSetTest\:\:testCreateContentTwoLanguagesSecondTranslationNotStoredFields\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/NonRedundantFieldSetTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\NonRedundantFieldSetTest\:\:testUpdateContentUpdatingNonTranslatableFieldUpdatesFieldCopyFields\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/NonRedundantFieldSetTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\NonRedundantFieldSetTest\:\:testUpdateContentWithNewLanguageFields\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/NonRedundantFieldSetTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\NonRedundantFieldSetTest\:\:testUpdateContentWithNewLanguageNoValuesFields\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/NonRedundantFieldSetTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\NonRedundantFieldSetTest\:\:testUpdateContentWithNewLanguageVariantFields\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/NonRedundantFieldSetTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\NonRedundantFieldSetTest\:\:testUpdateContentWithTwoLanguagesInitialLanguageTranslationNotCreatedFields\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/NonRedundantFieldSetTest.php - - - - message: '#^Parameter \#1 \$fields of method Ibexa\\Tests\\Integration\\Core\\Repository\\NonRedundantFieldSetTest\:\:mapFields\(\) expects array\, iterable\ given\.$#' - identifier: argument.type - count: 2 - path: tests/integration/Core/Repository/NonRedundantFieldSetTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceAuthorizationTest\:\:testCreateObjectStateGroupThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceAuthorizationTest\:\:testCreateObjectStateThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceAuthorizationTest\:\:testDeleteObjectStateGroupThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceAuthorizationTest\:\:testDeleteObjectStateThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceAuthorizationTest\:\:testSetContentStateThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceAuthorizationTest\:\:testSetPriorityOfObjectStateThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceAuthorizationTest\:\:testUpdateObjectStateGroupThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceAuthorizationTest\:\:testUpdateObjectStateThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceAuthorizationTest.php - - - - message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\ObjectState\\ObjectState\:\:\$defaultLanguageCode\.$#' - identifier: property.notFound - count: 2 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\ObjectState\\ObjectState\:\:\$names\.$#' - identifier: property.notFound - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ObjectState\\\\ObjectState'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ObjectState\\ObjectState will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 9 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ObjectState\\\\ObjectStateCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ObjectState\\ObjectStateCreateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ObjectState\\\\ObjectStateGroup'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ObjectState\\ObjectStateGroup will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 7 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ObjectState\\\\ObjectStateGroupCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ObjectState\\ObjectStateGroupCreateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ObjectState\\\\ObjectStateGroupUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ObjectState\\ObjectStateGroupUpdateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\ObjectState\\\\ObjectStateUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\ObjectState\\ObjectStateUpdateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:assertObjectsLoadedByIdentifiers\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:assertObjectsLoadedByIdentifiers\(\) has parameter \$expectedIdentifiers with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:assertObjectsLoadedByIdentifiers\(\) has parameter \$loadedObjects with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:createObjectState\(\) has parameter \$descriptions with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:createObjectState\(\) has parameter \$names with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:deleteExistingObjectStateGroups\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:getGroupIdentifierMap\(\) has parameter \$groups with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:getGroupIdentifierMap\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:getPrioritizedLanguagesList\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testCreateObjectState\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testCreateObjectStateGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testCreateObjectStateGroupStructValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testCreateObjectStateGroupThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testCreateObjectStateInEmptyGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testCreateObjectStateStructValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testCreateObjectStateStructValues\(\) has parameter \$testData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testCreateObjectStateThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testDeleteObjectState\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testDeleteObjectStateGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testGetContentCount\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testGetContentState\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testGetInitialObjectState\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testLoadObjectState\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testLoadObjectStateGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testLoadObjectStateGroupThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testLoadObjectStateGroupWithPrioritizedLanguagesList\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testLoadObjectStateGroups\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testLoadObjectStateGroupsWithOffset\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testLoadObjectStateGroupsWithOffsetAndLimit\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testLoadObjectStateGroupsWithPrioritizedLanguagesList\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testLoadObjectStateStructValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testLoadObjectStateThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testLoadObjectStateWithPrioritizedLanguagesList\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testLoadObjectStates\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testLoadObjectStatesWithPrioritizedLanguagesList\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testNewObjectStateCreateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testNewObjectStateCreateStructValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testNewObjectStateGroupCreateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testNewObjectStateGroupCreateStructValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testNewObjectStateGroupUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testNewObjectStateGroupUpdateStructValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testNewObjectStateUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testNewObjectStateUpdateStructValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testSetContentState\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testSetContentStateThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testSetPriorityOfObjectState\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testUpdateObjectState\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testUpdateObjectStateChosenFieldsOnly\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testUpdateObjectStateGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testUpdateObjectStateGroupChosenFieldsOnly\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testUpdateObjectStateGroupStructValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testUpdateObjectStateGroupStructValues\(\) has parameter \$testData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testUpdateObjectStateGroupThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testUpdateObjectStateStructValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testUpdateObjectStateStructValues\(\) has parameter \$testData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:testUpdateObjectStateThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Parameter \#1 \$groups of method Ibexa\\Tests\\Integration\\Core\\Repository\\ObjectStateServiceTest\:\:getGroupIdentifierMap\(\) expects array, iterable\ given\.$#' - identifier: argument.type - count: 2 - path: tests/integration/Core/Repository/ObjectStateServiceTest.php - - - - message: '#^Parameter \#1 \$execution of class Jenner\\SimpleFork\\Process constructor expects string\|null, Closure given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/Parallel/BaseParallelTestCase.php - - - - message: '#^Access to protected property Ibexa\\Contracts\\Core\\Repository\\Values\\User\\LookupLimitationResult\:\:\$hasAccess\.$#' - identifier: property.protected - count: 3 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Access to protected property Ibexa\\Contracts\\Core\\Repository\\Values\\User\\LookupLimitationResult\:\:\$lookupPolicyLimitations\.$#' - identifier: property.protected - count: 8 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Access to protected property Ibexa\\Contracts\\Core\\Repository\\Values\\User\\LookupLimitationResult\:\:\$roleLimitations\.$#' - identifier: property.protected - count: 3 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Access to protected property Ibexa\\Contracts\\Core\\Repository\\Values\\User\\LookupPolicyLimitations\:\:\$policy\.$#' - identifier: property.protected - count: 3 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' - identifier: property.nonObject - count: 2 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:getDataForTestCanUserWithLimitations\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testCanUserForAdministratorUser\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testCanUserForAnonymousUserNo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testCanUserThrowsBadStateException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testCanUserThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testCanUserWithLimitationNo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testCanUserWithLimitationYes\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testCanUserWithLimitations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testCanUserWithLimitations\(\) has parameter \$targets with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testCanUserWithMultipleTargetsNo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testCanUserWithMultipleTargetsYes\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testCanUserWithTargetNo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testCanUserWithTargetThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testCanUserWithTargetYes\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testGetCurrentUserReferenceReturnsAnonymousUserReference\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testHasAccessForCurrentUserNo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testHasAccessForCurrentUserYes\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testHasAccessLimited\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testHasAccessWithAdministratorUser\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testHasAccessWithAnonymousUserNo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\PermissionResolverTest\:\:testSetCurrentUserReference\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Parameter \#1 \$array of function array_filter expects array, iterable\ given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Parameter \#1 \$policy of class Ibexa\\Contracts\\Core\\Repository\\Values\\User\\LookupPolicyLimitations constructor expects Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy, Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy\|false given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/PermissionResolverTest.php - - - - message: '#^Class Ibexa\\Tests\\Solr\\SetupFactory\\LegacySetupFactory not found\.$#' - identifier: class.notFound - count: 1 - path: tests/integration/Core/Repository/Regression/EZP20018LanguageTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP20018LanguageTest\:\:testSearchOnNotExistingLanguageGivesException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP20018LanguageTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP20018LanguageTest\:\:testSearchOnNotUsedInstalledLanguageGivesNoResult\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP20018LanguageTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP20018LanguageTest\:\:testSearchOnStandardLanguageGivesManyResult\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP20018LanguageTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP20018LanguageTest\:\:testSearchOnUsedLanguageGivesOneResult\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP20018LanguageTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP20018ObjectStateTest\:\:testSearchForNonUsedObjectState\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP20018ObjectStateTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP20018ObjectStateTest\:\:testSearchForUsedObjectState\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP20018ObjectStateTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP20018VisibilityTest\:\:testSearchForHiddenContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP20018VisibilityTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP20018VisibilityTest\:\:testSearchForVisibleContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP20018VisibilityTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP21069Test\:\:testSearchOnCurrentAttributeContentGivesOnesResult\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP21069Test.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP21069Test\:\:testSearchOnDraftAttributeContentGivesNoResult\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP21069Test.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP21069Test\:\:testSearchOnPreviousAttributeContentGivesNoResult\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP21069Test.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP21089Test\:\:testCreateContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP21089Test.php - - - - message: '#^Property Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP21089Test\:\:\$contentType \(Ibexa\\Core\\Repository\\Values\\ContentType\\ContentType\) does not accept Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentType\.$#' - identifier: assign.propertyType - count: 1 - path: tests/integration/Core/Repository/Regression/EZP21089Test.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP21109IbexaIntegerTest\:\:validIntegerValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP21109IbexaIntegerTest.php - - - - message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\VersionInfo\:\:\$names\.$#' - identifier: property.notFound - count: 1 - path: tests/integration/Core/Repository/Regression/EZP21771IbexaStringTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP21771IbexaStringTest\:\:test11NumbersOnIbexaString\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP21771IbexaStringTest.php - - - - message: '#^Parameter \#1 \$value of function count expects array\|Countable, iterable\ given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/Regression/EZP21798Test.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP21906SearchOneContentMultipleLocationsTest\:\:searchContentQueryProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP21906SearchOneContentMultipleLocationsTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP21906SearchOneContentMultipleLocationsTest\:\:testSearchContentMultipleLocations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP21906SearchOneContentMultipleLocationsTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP21906SearchOneContentMultipleLocationsTest\:\:testSearchContentMultipleLocations\(\) has parameter \$expectedResultCount with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/Regression/EZP21906SearchOneContentMultipleLocationsTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22408DeleteRelatedObjectTest\:\:createReferenceObject\(\) has parameter \$relationListTarget with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Regression/EZP22408DeleteRelatedObjectTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22408DeleteRelatedObjectTest\:\:createTestContentType\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP22408DeleteRelatedObjectTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22408DeleteRelatedObjectTest\:\:testRelationListIsUpdatedWhenRelatedObjectIsDeleted\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP22408DeleteRelatedObjectTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22408DeleteRelatedObjectTest\:\:testSingleRelationIsUpdatedWhenRelatedObjectIsDeleted\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP22408DeleteRelatedObjectTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22409RelationListTypeStateTest\:\:createContentWithRelationList\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP22409RelationListTypeStateTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22409RelationListTypeStateTest\:\:testCreateObjectWithRelationToContentType\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP22409RelationListTypeStateTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22409RelationListTypeStateTest\:\:testCreateObjectWithRelationToContentTypeWithExistingDraft\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP22409RelationListTypeStateTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\URLAlias'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\URLAlias will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/Regression/EZP22612URLAliasTranslations.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22612URLAliasTranslations\:\:getFolderCreateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP22612URLAliasTranslations.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22612URLAliasTranslations\:\:getFolderCreateStruct\(\) has parameter \$name with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/Regression/EZP22612URLAliasTranslations.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22612URLAliasTranslations\:\:testURLAliasLoadedInRightLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP22612URLAliasTranslations.php - - - - message: '#^Parameter \#1 \$parentLocationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:newLocationCreateStruct\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/Regression/EZP22612URLAliasTranslations.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22840RoleLimitations\:\:testSectionRoleAssignLimitation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP22840RoleLimitations.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22840RoleLimitations\:\:testSubtreeRoleAssignLimitation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP22840RoleLimitations.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22958SearchSubtreePathstringFormatTest\:\:searchContentQueryProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP22958SearchSubtreePathstringFormatTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22958SearchSubtreePathstringFormatTest\:\:searchContentQueryWithInvalidDataProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP22958SearchSubtreePathstringFormatTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22958SearchSubtreePathstringFormatTest\:\:testSearchContentSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP22958SearchSubtreePathstringFormatTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22958SearchSubtreePathstringFormatTest\:\:testSearchContentSubtree\(\) has parameter \$pathString with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/Regression/EZP22958SearchSubtreePathstringFormatTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22958SearchSubtreePathstringFormatTest\:\:testSearchContentSubtreeShouldThrowException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP22958SearchSubtreePathstringFormatTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP22958SearchSubtreePathstringFormatTest\:\:testSearchContentSubtreeShouldThrowException\(\) has parameter \$pathString with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/Regression/EZP22958SearchSubtreePathstringFormatTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP26327UrlAliasHistorizationTest\:\:testHistorization\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP26327UrlAliasHistorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP26367UrlAliasHistoryRedirectLoopTest\:\:testLookupHistoryUrlReturnsActiveAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP26367UrlAliasHistoryRedirectLoopTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP26367UrlAliasHistoryRedirectLoopTest\:\:testReverseLookupReturnsHistoryAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP26367UrlAliasHistoryRedirectLoopTest.php - - - - message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 4 - path: tests/integration/Core/Repository/Regression/EZP26367UrlAliasHistoryRedirectLoopTest.php - - - - message: '#^Parameter \#1 \$parentLocationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:newLocationCreateStruct\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 2 - path: tests/integration/Core/Repository/Regression/EZP26367UrlAliasHistoryRedirectLoopTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP26551DeleteContentTypeDraftTest\:\:testDeleteContentTypeGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP26551DeleteContentTypeDraftTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP28799SubtreeSearchTest\:\:testConflictingConditions\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP28799SubtreeSearchTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EZP28799SubtreeSearchTest\:\:testNegativeSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EZP28799SubtreeSearchTest.php - - - - message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 2 - path: tests/integration/Core/Repository/Regression/EZP28799SubtreeSearchTest.php - - - - message: '#^Parameter \#1 \$parentLocationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:newLocationCreateStruct\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 2 - path: tests/integration/Core/Repository/Regression/EZP28799SubtreeSearchTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\EnvTest\:\:testVerifyCacheDriver\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/EnvTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\PureNegativeQueryTest\:\:providerForTestMatchAll\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/PureNegativeQueryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\PureNegativeQueryTest\:\:testMatchAllContentInfoFilter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/PureNegativeQueryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\PureNegativeQueryTest\:\:testMatchAllContentInfoQuery\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/PureNegativeQueryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\PureNegativeQueryTest\:\:testMatchAllLocationFilter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/PureNegativeQueryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Regression\\PureNegativeQueryTest\:\:testMatchAllLocationQuery\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Regression/PureNegativeQueryTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\ContentService'' and Ibexa\\Contracts\\Core\\Repository\\ContentService will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\ContentTypeService'' and Ibexa\\Contracts\\Core\\Repository\\ContentTypeService will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\FieldTypeService'' and Ibexa\\Contracts\\Core\\Repository\\FieldTypeService will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\LanguageService'' and Ibexa\\Contracts\\Core\\Repository\\LanguageService will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\LocationService'' and Ibexa\\Contracts\\Core\\Repository\\LocationService will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\NotificationService'' and Ibexa\\Contracts\\Core\\Repository\\NotificationService will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\ObjectStateService'' and Ibexa\\Contracts\\Core\\Repository\\ObjectStateService will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\PermissionResolver'' and Ibexa\\Contracts\\Core\\Repository\\PermissionResolver will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\RoleService'' and Ibexa\\Contracts\\Core\\Repository\\RoleService will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\SearchService'' and Ibexa\\Contracts\\Core\\Repository\\SearchService will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\SectionService'' and Ibexa\\Contracts\\Core\\Repository\\SectionService will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\TrashService'' and Ibexa\\Contracts\\Core\\Repository\\TrashService will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\URLAliasService'' and Ibexa\\Contracts\\Core\\Repository\\URLAliasService will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\URLWildcardService'' and Ibexa\\Contracts\\Core\\Repository\\URLWildcardService will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\UserService'' and Ibexa\\Contracts\\Core\\Repository\\UserService will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RepositoryTest\:\:testCommit\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RepositoryTest\:\:testCommitThrowsRuntimeException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RepositoryTest\:\:testGetContentLanguageService\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RepositoryTest\:\:testGetContentService\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RepositoryTest\:\:testGetContentTypeService\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RepositoryTest\:\:testGetFieldTypeService\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RepositoryTest\:\:testGetLocationService\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RepositoryTest\:\:testGetNotificationService\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RepositoryTest\:\:testGetObjectStateService\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RepositoryTest\:\:testGetPermissionResolver\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RepositoryTest\:\:testGetRoleService\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RepositoryTest\:\:testGetSearchService\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RepositoryTest\:\:testGetSectionService\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RepositoryTest\:\:testGetTrashService\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RepositoryTest\:\:testGetURLAliasService\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RepositoryTest\:\:testGetURLWildcardService\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RepositoryTest\:\:testGetUserService\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RepositoryTest\:\:testRollback\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RepositoryTest\:\:testRollbackThrowsRuntimeException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RepositoryTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceAuthorizationTest\:\:testAssignRoleToUserGroupThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceAuthorizationTest\:\:testAssignRoleToUserGroupThrowsUnauthorizedExceptionWithRoleLimitationParameter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceAuthorizationTest\:\:testAssignRoleToUserThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceAuthorizationTest\:\:testAssignRoleToUserThrowsUnauthorizedExceptionWithRoleLimitationParameter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceAuthorizationTest\:\:testCreateRoleThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceAuthorizationTest\:\:testDeletePolicyThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceAuthorizationTest\:\:testDeleteRoleThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceAuthorizationTest\:\:testGetRoleAssignmentsForUserGroupThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceAuthorizationTest\:\:testGetRoleAssignmentsForUserLoadsEmptyListForAnonymousUser\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceAuthorizationTest\:\:testGetRoleAssignmentsForUserWithSubtreeLimitation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceAuthorizationTest\:\:testGetRoleAssignmentsThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceAuthorizationTest\:\:testLoadRoleByIdentifierThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceAuthorizationTest\:\:testLoadRoleThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceAuthorizationTest\:\:testLoadRolesForUserWithSubtreeLimitation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceAuthorizationTest\:\:testLoadRolesLoadsEmptyListForAnonymousUser\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceAuthorizationTest\:\:testRemovePolicyThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceAuthorizationTest\:\:testRemoveRoleAssignmentFromUserGroupThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceAuthorizationTest\:\:testRemoveRoleAssignmentThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceAuthorizationTest\:\:testUpdatePolicyByRoleDraftThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Parameter \#2 \$policy of method Ibexa\\Contracts\\Core\\Repository\\RoleService\:\:updatePolicyByRoleDraft\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft, Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy\|false given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Parameter \#2 \$policyDraft of method Ibexa\\Contracts\\Core\\Repository\\RoleService\:\:removePolicyByRoleDraft\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft, Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy\|false given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/RoleServiceAuthorizationTest.php - - - - message: '#^Access to protected property Ibexa\\Contracts\\Core\\Repository\\Values\\User\\UserGroupRoleAssignment\:\:\$id\.$#' - identifier: property.protected - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\Limitation'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Limitation will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\Policy'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 2 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\PolicyCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyCreateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\PolicyUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyUpdateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\Role'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Role will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\Role'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\RoleDraft will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\RoleCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\RoleCreateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\RoleDraft'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\RoleDraft will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 4 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\RoleUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\RoleUpdateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Cannot access property \$limitation on Ibexa\\Contracts\\Core\\Repository\\Values\\User\\RoleAssignment\|false\.$#' - identifier: property.nonObject - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Cannot call method getIdentifier\(\) on Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Limitation\\RoleLimitation\|null\.$#' - identifier: method.nonObject - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Contracts\\Core\\Repository\\RoleService\:\:newRoleUpdateStruct\(\) invoked with 1 parameter, 0 required\.$#' - identifier: arguments.count - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:providerForCopyRoleTests\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testAddPolicyByRoleDraft\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testAddPolicyByRoleDraftSetsPolicyProperties\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testAddPolicyByRoleDraftSetsPolicyProperties\(\) has parameter \$roleAndPolicy with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testAddPolicyByRoleDraftThrowsLimitationValidationException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testAddPolicyByRoleDraftUpdatesRole\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testAddPolicyWithRoleAssignment\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testAssignRoleToUser\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testAssignRoleToUserGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testAssignRoleToUserGroupAffectsRoleAssignmentsForUser\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testAssignRoleToUserGroupThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testAssignRoleToUserGroupWithRoleLimitation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testAssignRoleToUserGroupWithRoleLimitationThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testAssignRoleToUserGroupWithRoleLimitationThrowsLimitationValidationException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testAssignRoleToUserThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testAssignRoleToUserWithRoleLimitation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testAssignRoleToUserWithRoleLimitationThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testAssignRoleToUserWithRoleLimitationThrowsLimitationValidationException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testCreateRole\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testCreateRoleDraft\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testCreateRoleDraftInTransactionWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testCreateRoleDraftThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testCreateRoleDraftWithAddPolicy\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testCreateRoleInTransactionWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testCreateRoleThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testCreateRoleThrowsLimitationValidationException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testCreateRoleWithAddPolicy\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testCreateRoleWithMultiplePolicies\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testCreateRoleWithPolicy\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testDeleteRole\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testDeleteRoleDraft\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testGetRoleAssignmentsContainExpectedLimitation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testGetRoleAssignmentsForUserDirect\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testGetRoleAssignmentsForUserEmpty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testGetRoleAssignmentsForUserGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testGetRoleAssignmentsForUserInherited\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testLoadPoliciesByUserId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testLoadRole\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testLoadRoleByIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testLoadRoleByIdentifierThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testLoadRoleDraft\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testLoadRoleDraftByRoleId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testLoadRoleDraftByRoleIdThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testLoadRoleDraftThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testLoadRoleThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testLoadRoles\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testLoadRolesReturnsExpectedSetOfDefaultRoles\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testNewPolicyCreateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testNewPolicyCreateStructSetsStructProperties\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testNewPolicyUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testNewRoleCreateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testNewRoleCreateStructSetsNamePropertyOnStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testNewRoleUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testPublishRoleDraft\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testPublishRoleDraftAddPolicies\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testRemovePolicyByRoleDraft\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testRemoveRoleAssignment\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testRemoveRoleAssignmentFromUserGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testRoleCreateStructValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testRoleCreateStructValues\(\) has parameter \$data with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testRoleCreateStructValuesWithPolicy\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testRoleCreateStructValuesWithPolicy\(\) has parameter \$data with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testUnassignRoleByAssignment\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testUnassignRoleByAssignmentThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testUnassignRoleByAssignmentThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testUpdatePolicyByRoleDraft\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testUpdatePolicyByRoleDraftNoLimitation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testUpdatePolicyByRoleDraftThrowsLimitationValidationException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testUpdatePolicyUpdatesLimitations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testUpdatePolicyUpdatesLimitations\(\) has parameter \$roleAndPolicy with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testUpdatePolicyUpdatesRole\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testUpdateRoleDraft\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\RoleServiceTest\:\:testUpdateRoleDraftThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Parameter \#1 \$value of function count expects array\|Countable, iterable\ given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Parameter \#1 \$value of function count expects array\|Countable, iterable\ given\.$#' - identifier: argument.type - count: 3 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Parameter \#1 \.\.\.\$arrays of function array_merge expects array, iterable\ given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Parameter \#2 \$policy of method Ibexa\\Contracts\\Core\\Repository\\RoleService\:\:updatePolicyByRoleDraft\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft, Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft\|null given\.$#' - identifier: argument.type - count: 3 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Parameter \#2 \$policyDraft of method Ibexa\\Contracts\\Core\\Repository\\RoleService\:\:removePolicyByRoleDraft\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft, Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Variable \$role might not be defined\.$#' - identifier: variable.undefined - count: 1 - path: tests/integration/Core/Repository/RoleServiceTest.php - - - - message: '#^Access to an undefined property Ibexa\\Core\\Repository\\Values\\Content\\Content\:\:\$mainLocationId\.$#' - identifier: property.notFound - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Access to an undefined property Ibexa\\Core\\Repository\\Values\\Content\\Content\:\:\$publishedDate\.$#' - identifier: property.notFound - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Access to an undefined property Ibexa\\Core\\Repository\\Values\\Content\\Content\:\:\$remoteId\.$#' - identifier: property.notFound - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:assertContentIdSearch\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:assertSubtreeInvisibleProperty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:createContent\(\) has parameter \$parentLocationIdList with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:createContentWithNameAndDescription\(\) has parameter \$contentDescription with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:createContentWithNameAndDescription\(\) has parameter \$parentLocationIdList with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:getEmailAddressesCases\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:getSpecialFullTextCases\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testAssignSection\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testCopyContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testCopySubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testCreateLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testCreateUser\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testCreateUserGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testDeleteContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testDeleteLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testDeleteTranslation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testDeleteUser\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testDeleteUserGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testDeleteVersion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testFindContentInfoFullTextIsNotSearchable\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testFindContentInfoFullTextIsSearchable\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testFindLocationsFullTextIsNotSearchable\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testFindLocationsFullTextIsSearchable\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testHideSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testIndexContentWithNullField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testIndexingSpecialFullTextCases\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testMoveSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testPublishVersion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testRecoverLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testRemovedContentFieldValueIsNotFound\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testRevealSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testSetContentState\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testSwapLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testUpdateContentDraftMetadataIsNotIndexed\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testUpdateContentMetadata\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testUpdateLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testUpdateUser\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:testUserFullTextSearch\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^PHPDoc tag @param references unknown parameter\: \$ignoreForSetupFactories$#' - identifier: parameter.notFound - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 4 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Parameter \#1 \$value of class Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\Criterion\\LocationId constructor expects array\\|int, int\|null given\.$#' - identifier: argument.type - count: 2 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Parameter \#1 \$value of class Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\Criterion\\ParentLocationId constructor expects array\\|int, int\|null given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Parameter \#2 \$fieldDefinition of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:updateFieldDefinition\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition, Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\FieldDefinition\|null given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Parameter \#2 \$parentLocationIdList of method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchEngineIndexingTest\:\:createContentWithName\(\) expects array\, array\ given\.$#' - identifier: argument.type - count: 2 - path: tests/integration/Core/Repository/SearchEngineIndexingTest.php - - - - message: '#^Cannot call method first\(\) on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Search\\AggregationResultCollection\|null\.$#' - identifier: method.nonObject - count: 2 - path: tests/integration/Core/Repository/SearchService/Aggregation/AbstractAggregationTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\AbstractAggregationTestCase\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/AbstractAggregationTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\AbstractAggregationTestCase\:\:dataProviderForTestFindLocationWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/AbstractAggregationTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\ContentTypeGroupTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/ContentTypeGroupTermAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\ContentTypeTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/ContentTypeTermAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\DataSetBuilder\\TermAggregationDataSetBuilder\:\:build\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/DataSetBuilder/TermAggregationDataSetBuilder.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\DataSetBuilder\\TermAggregationDataSetBuilder\:\:setExpectedEntries\(\) has parameter \$entries with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/DataSetBuilder/TermAggregationDataSetBuilder.php - - - - message: '#^Property Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\DataSetBuilder\\TermAggregationDataSetBuilder\:\:\$entries type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/DataSetBuilder/TermAggregationDataSetBuilder.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\DateMetadataRangeAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/DateMetadataRangeAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\AuthorTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/Field/AuthorTermAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\CheckboxTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/Field/CheckboxTermAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\CountryTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/Field/CountryTermAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\DateRangeAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/Field/DateRangeAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\DateTimeRangeAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/Field/DateTimeRangeAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\FloatRangeAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/Field/FloatRangeAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\FloatStatsAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/Field/FloatStatsAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\IntegerRangeAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/Field/IntegerRangeAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\IntegerStatsAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/Field/IntegerStatsAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\KeywordTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/Field/KeywordTermAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\SelectionTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/Field/SelectionTermAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\Field\\TimeRangeAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/Field/TimeRangeAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\FixtureGenerator\\FieldAggregationFixtureGenerator\:\:createFieldAggregationFixtures\(\) has parameter \$values with no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/FixtureGenerator/FieldAggregationFixtureGenerator.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\FixtureGenerator\\FieldAggregationFixtureGenerator\:\:setValues\(\) has parameter \$values with no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/FixtureGenerator/FieldAggregationFixtureGenerator.php - - - - message: '#^Parameter \#1 \$contentTypeIdentifier of method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\FixtureGenerator\\FieldAggregationFixtureGenerator\:\:createContentTypeForFieldAggregation\(\) expects string, string\|null given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/FixtureGenerator/FieldAggregationFixtureGenerator.php - - - - message: '#^Parameter \#2 \$fieldDefinitionIdentifier of method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\FixtureGenerator\\FieldAggregationFixtureGenerator\:\:createContentTypeForFieldAggregation\(\) expects string, string\|null given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/FixtureGenerator/FieldAggregationFixtureGenerator.php - - - - message: '#^Parameter \#2 \$fieldDefinitionIdentifier of method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\FixtureGenerator\\FieldAggregationFixtureGenerator\:\:createFieldAggregationFixtures\(\) expects string, string\|null given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/FixtureGenerator/FieldAggregationFixtureGenerator.php - - - - message: '#^Parameter \#3 \$fieldTypeIdentifier of method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\FixtureGenerator\\FieldAggregationFixtureGenerator\:\:createContentTypeForFieldAggregation\(\) expects string, string\|null given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/FixtureGenerator/FieldAggregationFixtureGenerator.php - - - - message: '#^Parameter \#3 \$values of method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\FixtureGenerator\\FieldAggregationFixtureGenerator\:\:createFieldAggregationFixtures\(\) expects iterable, iterable\|null given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/FixtureGenerator/FieldAggregationFixtureGenerator.php - - - - message: '#^Property Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\FixtureGenerator\\FieldAggregationFixtureGenerator\:\:\$values type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/FixtureGenerator/FieldAggregationFixtureGenerator.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\LanguageTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/LanguageTermAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\LocationChildrenTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/LocationChildrenTermAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\ObjectStateTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/ObjectStateTermAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\RawRangeAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/RawRangeAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\RawStatsAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/RawStatsAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\RawTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/RawTermAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\SectionTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/SectionTermAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\SubtreeTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/SubtreeTermAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\UserMetadataTermAggregationTest\:\:createGroupTermAggregationDataSet\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/UserMetadataTermAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\UserMetadataTermAggregationTest\:\:createModifierTermAggregationDataSet\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/UserMetadataTermAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\UserMetadataTermAggregationTest\:\:createOwnerTermAggregationDataSet\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/UserMetadataTermAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\UserMetadataTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/UserMetadataTermAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\UserMetadataTermAggregationTest\:\:dataProviderForTestFindLocationWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/UserMetadataTermAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\Aggregation\\VisibilityTermAggregationTest\:\:dataProviderForTestFindContentWithAggregation\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/Aggregation/VisibilityTermAggregationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\DeleteTranslationTest\:\:createTestContentWithLanguages\(\) has parameter \$languages with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/DeleteTranslationTest.php - - - - message: '#^Parameter \#1 \$array of function array_column expects array, iterable\ given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/SearchService/MultilingualContentSearchIndexingTest.php - - - - message: '#^Cannot access offset 0 on array\\|bool\|float\|int\|string\.$#' - identifier: offsetAccess.nonOffsetAccessible - count: 1 - path: tests/integration/Core/Repository/SearchService/RemoteIdIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\RemoteIdIndexingTest\:\:getRemoteIDs\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/RemoteIdIndexingTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\RemoteIdIndexingTest\:\:providerForTestIndexingRemoteId\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/RemoteIdIndexingTest.php - - - - message: '#^Part \$criterion\-\>value \(array\\|bool\|float\|int\|string\) of encapsed string cannot be cast to string\.$#' - identifier: encapsedStringPart.nonString - count: 1 - path: tests/integration/Core/Repository/SearchService/RemoteIdIndexingTest.php - - - - message: '#^Possibly invalid array key type bool\|float\|int\|string\.$#' - identifier: offsetAccess.invalidOffset - count: 2 - path: tests/integration/Core/Repository/SearchService/RemoteIdIndexingTest.php - - - - message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\:\:\$remoteId\.$#' - identifier: property.notFound - count: 1 - path: tests/integration/Core/Repository/SearchService/SortClause/AbstractSortClauseTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\AbstractSortClauseTestCase\:\:assertSearchResultOrderByRemoteId\(\) has parameter \$expectedOrderedIds with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/SortClause/AbstractSortClauseTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ContentTranslatedNameTest\:\:createContentForContentTranslatedNameTesting\(\) has parameter \$values with no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ContentTranslatedNameTest\:\:dataProviderForTestSortingByContentTranslatedName\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ContentTranslatedNameTest\:\:testContentSortingByContentTranslatedName\(\) has parameter \$expectedOrderedRemoteIds with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ContentTranslatedNameTest\:\:testContentSortingByContentTranslatedName\(\) has parameter \$inputValues with no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ContentTranslatedNameTest\:\:testContentSortingByContentTranslatedName\(\) has parameter \$languageFilter with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ContentTranslatedNameTest\:\:testLocationSortingByContentTranslatedName\(\) has parameter \$expectedOrderedRemoteIds with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ContentTranslatedNameTest\:\:testLocationSortingByContentTranslatedName\(\) has parameter \$inputValues with no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ContentTranslatedNameTest\:\:testLocationSortingByContentTranslatedName\(\) has parameter \$languageFilter with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php - - - - message: '#^PHPDoc tag @param references unknown parameter\: \$values$#' - identifier: parameter.notFound - count: 2 - path: tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ScoreTest\:\:dataProviderForTestSortingByScore\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/SortClause/ScoreTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ScoreTest\:\:testSortingByScore\(\) has parameter \$expectedOrderedIds with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/SortClause/ScoreTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchService\\SortClause\\ScoreTest\:\:testSortingByScore\(\) has parameter \$inputValues with no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchService/SortClause/ScoreTest.php - - - - message: '#^PHPDoc tag @param references unknown parameter\: \$values$#' - identifier: parameter.notFound - count: 1 - path: tests/integration/Core/Repository/SearchService/SortClause/ScoreTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceAuthorizationTest\:\:testFindContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceAuthorizationTest\:\:testFindContentEmptyResult\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceAuthorizationTest\:\:testFindContentWithUserPermissionFilter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceAuthorizationTest\:\:testFindSingleThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceAuthorizationTest\:\:testFindSingleThrowsNotFoundExceptionWithUserPermissionFilter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceAuthorizationTest\:\:testFindSingleWithUserPermissionFilter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:assertFulltextSearch\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:assertFulltextSearch\(\) has parameter \$expectedKeys with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:assertFulltextSearch\(\) has parameter \$idMap with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:doTestFulltextContentSearch\(\) has parameter \$expectedKeys with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:doTestFulltextContentSearch\(\) has parameter \$idMap with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:doTestFulltextLocationSearch\(\) has parameter \$expectedKeys with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:doTestFulltextLocationSearch\(\) has parameter \$idMap with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:doTestFulltextLocationSearch\(\) has parameter \$searchString with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:mapKeysToIds\(\) has parameter \$expectedKeys with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:mapKeysToIds\(\) has parameter \$idMap with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:mapKeysToIds\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:mapSearchResultToIds\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:providerForTestFulltextSearchSolr7\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:testFulltextContentSearchSolr7\(\) has parameter \$expectedKeys with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:testFulltextContentSearchSolr7\(\) has parameter \$idMap with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:testFulltextLocationSearchSolr7\(\) has parameter \$expectedKeys with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:testFulltextLocationSearchSolr7\(\) has parameter \$idMap with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:testFulltextLocationSearchSolr7\(\) has parameter \$searchString with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceFulltextTest\:\:testPrepareContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - - - message: '#^PHPDoc tag @var for variable \$keyGroup has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceFulltextTest.php - - - - message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\:\:\$id\.$#' - identifier: property.notFound - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\Criterion\:\:setCustomField\(\)\.$#' - identifier: method.notFound - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Cannot access offset ''id'' on Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\.$#' - identifier: offsetAccess.nonOffsetAccessible - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Cannot access offset ''title'' on Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\.$#' - identifier: offsetAccess.nonOffsetAccessible - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Class Ibexa\\Tests\\Solr\\SetupFactory\\LegacySetupFactory not found\.$#' - identifier: class.notFound - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:assertQueryFixture\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:assertQueryFixture\(\) has parameter \$ignoreScore with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:mapResultLocationIds\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:simplifySearchResult\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:testFieldCollectionContains\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:testFieldCollectionContainsNoMatch\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:testFieldIsEmptyInLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:testFieldIsNotEmptyInLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:testFindLocationsWithNonSearchableField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:testInvalidFieldIdentifierIn\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:testInvalidFieldIdentifierRange\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:testMapLocationDistanceBetween\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:testMapLocationDistanceGreaterThanOrEqual\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:testMapLocationDistanceLessThanOrEqual\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:testMapLocationDistanceSortAscending\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:testMapLocationDistanceSortDescending\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:testMapLocationDistanceWithCustomField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:testMapLocationDistanceWithCustomFieldSort\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:testQueryCustomField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:testQueryModifiedField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceLocationTest\:\:testVisibilityCriterionWithHiddenContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Parameter \#1 \$parentLocationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:newLocationCreateStruct\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 2 - path: tests/integration/Core/Repository/SearchServiceLocationTest.php - - - - message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\:\:\$id\.$#' - identifier: property.notFound - count: 3 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\Criterion\:\:setCustomField\(\)\.$#' - identifier: method.notFound - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Search\\\\SearchResult'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Search\\SearchResult will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Cannot access offset ''id'' on Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\.$#' - identifier: offsetAccess.nonOffsetAccessible - count: 3 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Cannot access offset ''title'' on Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\.$#' - identifier: offsetAccess.nonOffsetAccessible - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Class Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\Criterion\\ContentTypeIdentifier constructor invoked with 2 parameters, 1 required\.$#' - identifier: arguments.count - count: 2 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Class Ibexa\\Tests\\Solr\\SetupFactory\\LegacySetupFactory not found\.$#' - identifier: class.notFound - count: 5 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Instanceof between Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query will always evaluate to true\.$#' - identifier: instanceof.alwaysTrue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:assertMultilingualFieldFilter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:assertMultilingualFieldFilter\(\) has parameter \$contentDataList with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:assertMultilingualFieldFilter\(\) has parameter \$expected with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:assertMultilingualFieldFilter\(\) has parameter \$languageSettings with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:assertMultilingualFieldSort\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:assertMultilingualFieldSort\(\) has parameter \$contentDataList with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:assertMultilingualFieldSort\(\) has parameter \$expected with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:assertMultilingualFieldSort\(\) has parameter \$languageSettings with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:createContentForTestUserMetadataGroupHorizontal\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:createContentWithFieldType\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:find\(\) has parameter \$languages with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:getCaseInsensitiveSearches\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:getContentQuerySearches\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:getFilterContentSearches\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:getLocationQuerySearches\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:getRelationFieldFilterSearches\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:getSeedsForRandomSortClause\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:getSortedContentSearches\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:getSortedLocationSearches\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:mapResultContentIds\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:providerForTestMultilingualFieldFilter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:providerForTestMultilingualFieldSort\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:providerForTestSortingByNumericFieldsWithValuesOfDifferentLength\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:simplifySearchResult\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:skipIfSeedNotImplemented\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:sortSearchHitsById\(\) has parameter \$searchHits with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testContentWithMultipleLocations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFieldCollectionContains\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFieldCollectionContainsNoMatch\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFieldCriterionForContentsWithIdenticalFieldIdentifiers\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFieldIsNotEmpty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContent\(\) has parameter \$closure with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContent\(\) has parameter \$fixture with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContent\(\) has parameter \$queryData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContentInfo\(\) has parameter \$closure with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContentInfo\(\) has parameter \$fixture with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContentInfo\(\) has parameter \$queryData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContentLocations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContentLocations\(\) has parameter \$closure with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContentLocations\(\) has parameter \$fixture with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortContentLocations\(\) has parameter \$queryData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortLocations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortLocations\(\) has parameter \$closure with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortLocations\(\) has parameter \$fixture with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindAndSortLocations\(\) has parameter \$queryData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindContentFieldFiltersCaseSensitivity\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindContentFieldFiltersCaseSensitivity\(\) has parameter \$queryData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindContentFiltered\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindContentFiltered\(\) has parameter \$closure with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindContentFiltered\(\) has parameter \$fixture with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindContentFiltered\(\) has parameter \$queryData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindContentInfoFiltered\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindContentInfoFiltered\(\) has parameter \$closure with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindContentInfoFiltered\(\) has parameter \$fixture with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindContentInfoFiltered\(\) has parameter \$queryData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindContentWithLanguageFilter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindContentWithNonSearchableField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindLocationsContentFiltered\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindLocationsContentFiltered\(\) has parameter \$closure with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindLocationsContentFiltered\(\) has parameter \$fixture with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindLocationsContentFiltered\(\) has parameter \$queryData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindLocationsFieldFiltersCaseSensitivity\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindLocationsFieldFiltersCaseSensitivity\(\) has parameter \$queryData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindLocationsNoPerformCount\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindLocationsNoPerformCountException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindMainLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindNoPerformCount\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindNoPerformCountException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindNonMainLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindRelationFieldContentInfoFiltered\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindRelationFieldContentInfoFiltered\(\) has parameter \$fixture with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindRelationFieldContentInfoFiltered\(\) has parameter \$queryData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindRelationFieldLocationsFiltered\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindRelationFieldLocationsFiltered\(\) has parameter \$fixture with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindRelationFieldLocationsFiltered\(\) has parameter \$queryData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindSingle\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindSingleFailMultiple\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFindSingleWithNonSearchableField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFullTextOnNewContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFulltextComplex\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFulltextContentSearchComplex\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFulltextContentSearchComplex\(\) has parameter \$data with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFulltextContentTranslationSearch\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFulltextContentTranslationSearch\(\) has parameter \$data with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFulltextLocationSearchComplex\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFulltextLocationSearchComplex\(\) has parameter \$data with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testFulltextLocationTranslationSearch\(\) has parameter \$data with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testInvalidFieldIdentifierIn\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testInvalidFieldIdentifierRange\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testLanguageAnalysisSameContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testLanguageAnalysisSameContentNotFound\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testLanguageAnalysisSeparateContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMapLocationDistanceBetween\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMapLocationDistanceBetweenPolar\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMapLocationDistanceGreaterThanOrEqual\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMapLocationDistanceLessThanOrEqual\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMapLocationDistanceSortAscending\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMapLocationDistanceSortDescending\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMapLocationDistanceWithCustomField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMapLocationDistanceWithCustomFieldSort\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldFilterContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldFilterContent\(\) has parameter \$contentDataList with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldFilterContent\(\) has parameter \$expected with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldFilterContent\(\) has parameter \$languageSettings with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldFilterLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldFilterLocation\(\) has parameter \$contentDataList with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldFilterLocation\(\) has parameter \$expected with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldFilterLocation\(\) has parameter \$languageSettings with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldSortContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldSortContent\(\) has parameter \$contentDataList with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldSortContent\(\) has parameter \$expected with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldSortContent\(\) has parameter \$languageSettings with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldSortLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldSortLocation\(\) has parameter \$contentDataList with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldSortLocation\(\) has parameter \$expected with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testMultilingualFieldSortLocation\(\) has parameter \$languageSettings with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContent\(\) has parameter \$closure with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContent\(\) has parameter \$fixture with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContent\(\) has parameter \$queryData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContentInfo\(\) has parameter \$closure with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContentInfo\(\) has parameter \$fixture with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContentInfo\(\) has parameter \$queryData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContentLocations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContentLocations\(\) has parameter \$closure with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContentLocations\(\) has parameter \$fixture with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryContentLocations\(\) has parameter \$queryData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryCustomField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryLocations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryLocations\(\) has parameter \$closure with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryLocations\(\) has parameter \$fixture with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryLocations\(\) has parameter \$queryData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testQueryModifiedField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testRandomSortContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testRandomSortLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testRelationContentCreation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testSortFieldWithNonSearchableField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testSortMainLocationAscending\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testSortMainLocationDescending\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testSortMapLocationDistanceWithNonSearchableField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testSortModifiedField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testUserMetadataGroupHorizontalFilterContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testUserMetadataGroupHorizontalFilterLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testUserMetadataGroupHorizontalFilterLocation\(\) has parameter \$queryType with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testUserMetadataGroupHorizontalQueryContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTest\:\:testUserMetadataGroupHorizontalQueryLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^PHPDoc tag @var has invalid value \(\$data \\Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Search\\SearchResult\)\: Unexpected token "\$data", expected type at offset 9 on line 1$#' - identifier: phpDoc.parseError - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Parameter \#1 \$parentLocationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:newLocationCreateStruct\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Parameter \#1 \$query of method Ibexa\\Contracts\\Core\\Repository\\SearchService\:\:findLocations\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\LocationQuery, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 3 - path: tests/integration/Core/Repository/SearchServiceTest.php - - - - message: '#^Class Ibexa\\Tests\\Solr\\SetupFactory\\LegacySetupFactory not found\.$#' - identifier: class.notFound - count: 3 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:createContent\(\) has parameter \$parentLocationIds with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:createContent\(\) has parameter \$searchValuesMap with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:createTestContent\(\) has parameter \$parentLocationIds with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:createTestContent\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:getIndexesToMatchData\(\) has parameter \$inputContentData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:getIndexesToMatchData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:getSetupType\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:providerForTestFind\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testCreateTestContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindContent\(\) has parameter \$contentDataList with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindContent\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindContent\(\) has parameter \$languageSettings with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindLocationsMultiple\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindLocationsMultiple\(\) has parameter \$contentDataList with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindLocationsMultiple\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindLocationsMultiple\(\) has parameter \$languageSettings with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindLocationsSingle\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindLocationsSingle\(\) has parameter \$contentDataList with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindLocationsSingle\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SearchServiceTranslationLanguageFallbackTest\:\:testFindLocationsSingle\(\) has parameter \$languageSettings with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceAuthorizationTest\:\:testAssignSectionThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceAuthorizationTest\:\:testCreateSectionThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceAuthorizationTest\:\:testDeleteSectionThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceAuthorizationTest\:\:testLoadSectionByIdentifierThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceAuthorizationTest\:\:testLoadSectionFiltersSections\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceAuthorizationTest\:\:testLoadSectionThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceAuthorizationTest\:\:testLoadSectionsLoadsEmptyListForAnonymousUser\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceAuthorizationTest\:\:testUpdateSectionThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceAuthorizationTest.php - - - - message: '#^Call to function is_object\(\) with Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo will always evaluate to true\.$#' - identifier: function.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Section'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Section will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 4 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\SectionCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\SectionCreateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\SectionUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\SectionUpdateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testAssignSection\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testAssignSectionToSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testCountAssignedContents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testCountAssignedContentsReturnsZeroByDefault\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testCreateSection\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testCreateSectionForUserWithSectionLimitation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testCreateSectionInTransactionWithCommit\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testCreateSectionInTransactionWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testCreateSectionThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testDeleteSection\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testDeleteSectionThrowsBadStateException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testDeleteSectionThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testIsSectionUsed\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testIsSectionUsedReturnsZeroByDefault\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testLoadSection\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testLoadSectionByIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testLoadSectionByIdentifierThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testLoadSectionThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testLoadSections\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testLoadSectionsReturnsDefaultSectionsByDefault\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testNewSectionCreateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testNewSectionUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testUpdateSection\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testUpdateSectionForUserWithSectionLimitation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testUpdateSectionInTransactionWithCommit\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testUpdateSectionInTransactionWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testUpdateSectionKeepsSectionIdentifierOnNameUpdate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testUpdateSectionKeepsSectionNameOnIdentifierUpdate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testUpdateSectionThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SectionServiceTest\:\:testUpdateSectionWithSectionIdentifierOnNameUpdate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SettingServiceTest\:\:dataProviderForCreateSetting\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/SettingServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\SettingServiceTest\:\:testCreateSetting\(\) has parameter \$value with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/SettingServiceTest.php - - - - message: '#^Generator expects value type array\{string, int, string\|null, int\|null\}, array\{''foo'', 100, null\} given\.$#' - identifier: generator.valueType - count: 1 - path: tests/integration/Core/Repository/TokenServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceAuthorizationTest\:\:testDeleteTrashItemThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceAuthorizationTest\:\:testEmptyTrashThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceAuthorizationTest\:\:testLoadTrashItemThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceAuthorizationTest\:\:testRecoverThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceAuthorizationTest\:\:testRecoverThrowsUnauthorizedExceptionWithNewParentLocationParameter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceAuthorizationTest\:\:testTrashRequiresContentRemovePolicy\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceAuthorizationTest\:\:testTrashRequiresPremissionsToRemoveAllSubitems\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceAuthorizationTest\:\:testTrashThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceAuthorizationTest.php - - - - message: '#^Access to protected property Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\TrashItem\:\:\$trashed\.$#' - identifier: property.protected - count: 4 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Content'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Content will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Location'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\TrashItem'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\TrashItem will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Trash\\\\SearchResult'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Trash\\SearchResult will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 3 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertTrue\(\) with true will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Cannot access property \$id on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\TrashItem\|null\.$#' - identifier: property.nonObject - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Cannot access property \$remoteId on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\TrashItem\|null\.$#' - identifier: property.nonObject - count: 4 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Cannot call method getRemovedLocationContentIdMap\(\) on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\TrashItem\|null\.$#' - identifier: method.nonObject - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:assertAliasNotExists\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testAliasesForRemovedItems\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testDeleteThrowsNotFoundExceptionForNonExistingTrashItem\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testDeleteTrashItem\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testEmptyTrash\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testEmptyTrashForUserWithSubtreeLimitation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testFindTrashItems\(\) has parameter \$filters with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testFindTrashItemsLimitedAccess\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testFindTrashItemsLimits\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testFindTrashItemsSort\(\) has parameter \$sortClausesClasses with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testFindTrashItemsSubtreeLimitation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testLoadTrashItem\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testLoadTrashItemThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testNotFoundAliasAfterRemoveIt\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testRecover\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testRecoverDoesNotRestoreChildLocations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testRecoverIncrementsChildCountOnOriginalParent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testRecoverThrowsNotFoundExceptionForNonExistingTrashItem\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testRecoverToNonExistingLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testRecoverWithLocationCreateStructParameter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testRecoverWithLocationCreateStructParameterIncrementsChildCountOnNewParent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testTrash\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testTrashDecrementsChildCountOnParentLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testTrashRemovesChildLocationsFromMainStorage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testTrashRemovesLocationFromMainStorage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testTrashReturnsNull\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testTrashSetsExpectedTrashItemProperties\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:testTrashUpdatesMainLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:trashFiltersProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\TrashServiceTest\:\:trashSortClausesProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 6 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Parameter \#1 \$trashItem of method Ibexa\\Contracts\\Core\\Repository\\TrashService\:\:recover\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\TrashItem, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\TrashItem\|null given\.$#' - identifier: argument.type - count: 2 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\:\:\$sortClauses \(array\\) does not accept array\\.$#' - identifier: assign.propertyType - count: 2 - path: tests/integration/Core/Repository/TrashServiceTest.php - - - - message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/URLAliasService/CustomUrlAliasForMultilingualContentTest.php - - - - message: '#^Cannot access property \$id on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null\.$#' - identifier: property.nonObject - count: 1 - path: tests/integration/Core/Repository/URLAliasService/UrlAliasLookupTest.php - - - - message: '#^Parameter \#1 \$location of method Ibexa\\Contracts\\Core\\Repository\\URLAliasService\:\:listLocationAliases\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\|null given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/URLAliasService/UrlAliasLookupTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceAuthorizationTest\:\:testCreateGlobalUrlAliasThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceAuthorizationTest\:\:testCreateUrlAliasThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceAuthorizationTest\:\:testRemoveAliasesThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceAuthorizationTest.php - - - - message: '#^Parameter \#1 \$aliasList of method Ibexa\\Contracts\\Core\\Repository\\URLAliasService\:\:removeAliases\(\) expects array\, iterable\ given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceAuthorizationTest.php - - - - message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceAuthorizationTest.php - - - - message: '#^Call to function is_object\(\) with Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location will always evaluate to true\.$#' - identifier: function.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\URLAlias'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\URLAlias will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 10 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:assertLookupHistory\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:assertUrlAliasPropertiesCorrect\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:assertUrlAliasPropertiesCorrect\(\) has parameter \$expectedIsHistory with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:assertUrlAliasPropertiesCorrect\(\) has parameter \$expectedLanguageCodes with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:assertUrlAliasPropertiesCorrect\(\) has parameter \$expectedPath with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:assertUrlAliasPropertiesSame\(\) has parameter \$expectedValues with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:assertUrlIsCurrent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:assertUrlIsHistory\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:changeContentTypeUrlAliasSchema\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:changeSlugConverterConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:createGlobalAliases\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateGlobalUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateGlobalUrlAliasForLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateGlobalUrlAliasForLocationPropertyValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateGlobalUrlAliasForLocationVariation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateGlobalUrlAliasForLocationVariationPropertyValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateGlobalUrlAliasPropertyValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateGlobalUrlAliasThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateGlobalUrlAliasWithAlwaysAvailable\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateGlobalUrlAliasWithAlwaysAvailablePropertyValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateGlobalUrlAliasWithForward\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateGlobalUrlAliasWithForwardPropertyValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateNonLatinNonEmptyUniqueAliases\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateSameAliasForDifferentLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateUrlAliasPropertyValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateUrlAliasPropertyValues\(\) has parameter \$testData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateUrlAliasPropertyValuesWithAlwaysAvailable\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateUrlAliasPropertyValuesWithAlwaysAvailable\(\) has parameter \$testData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateUrlAliasPropertyValuesWithForwarding\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateUrlAliasPropertyValuesWithForwarding\(\) has parameter \$testData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateUrlAliasThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateUrlAliasWithAlwaysAvailable\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testCreateUrlAliasWithForwarding\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testDeleteCorruptedUrlAliases\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testListGlobalAliases\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testListGlobalAliasesWithLanguageFilter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testListGlobalAliasesWithLimit\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testListGlobalAliasesWithOffset\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testListLocationAliases\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testListLocationAliasesLoadsCorrectly\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testListLocationAliasesLoadsCorrectly\(\) has parameter \$testData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testListLocationAliasesWithCustomFilter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testListLocationAliasesWithLanguageCodeFilter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testLookUp\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testLookUpThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testLookUpThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testLookUpThrowsNotFoundExceptionWithLanguageFilter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testLookUpWithLanguageFilter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testLookupOnMultilingualNestedLocations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testLookupOnRenamedParent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testRefreshSystemUrlAliasesForContentsWithUpdatedContentTypes\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testRefreshSystemUrlAliasesForLocationWithChangedSlugConverterConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testRefreshSystemUrlAliasesForMissingUrlWithHistory\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testRefreshSystemUrlAliasesForMovedLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testRemoveAliases\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:testRemoveAliasesThrowsInvalidArgumentExceptionIfAutogeneratedAliasesAreToBeRemoved\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:updateContentField\(\) has parameter \$fieldDefinitionIdentifier with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLAliasServiceTest\:\:updateContentField\(\) has parameter \$fieldValues with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Parameter \#1 \$aliasList of method Ibexa\\Contracts\\Core\\Repository\\URLAliasService\:\:removeAliases\(\) expects array\, iterable\ given\.$#' - identifier: argument.type - count: 2 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 11 - path: tests/integration/Core/Repository/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceAuthorizationTest\:\:testFindUrlsThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceAuthorizationTest\:\:testLoadByIdThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceAuthorizationTest\:\:testLoadByUrlThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceAuthorizationTest\:\:testUpdateUrlThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceAuthorizationTest.php - - - - message: '#^Access to protected property Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\URL\:\:\$modified\.$#' - identifier: property.protected - count: 4 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\URL\\\\URL'' and Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\URL will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 4 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\URL\\\\URLUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\URLUpdateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\URL\\\\UsageSearchResult'' and Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\UsageSearchResult will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 2 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:dataProviderForFindUrlsWithSorting\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:dataProviderForFindUsages\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testCreateUpdateStructValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUrls\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUrlsUsingMatchNone\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUrlsUsingPatternCriterion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUrlsUsingValidityCriterionInvalid\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUrlsUsingValidityCriterionValid\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUrlsUsingVisibleOnlyCriterion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUrlsWithInvalidLimitThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUrlsWithInvalidOffsetThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUrlsWithLimitZero\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUrlsWithOffset\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUrlsWithOffsetAndLimit\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUrlsWithSorting\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUrlsWithSorting\(\) has parameter \$expectedUrls with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUrlsWithoutCounting\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUsages\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUsages\(\) has parameter \$expectedContentInfos with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUsages\(\) has parameter \$expectedTotalCount with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUsages\(\) has parameter \$limit with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUsages\(\) has parameter \$offset with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUsages\(\) has parameter \$urlId with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testFindUsagesReturnsEmptySearchResults\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testLoadById\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testLoadByIdThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testLoadByUrl\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testLoadByUrlThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testUpdateUrl\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testUpdateUrlStatus\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLServiceTest\:\:testUpdateUrlWithNonUniqueUrl\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\URLQuery\:\:\$limit \(int\) does not accept string\.$#' - identifier: assign.propertyType - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\URLQuery\:\:\$offset \(int\) does not accept string\.$#' - identifier: assign.propertyType - count: 1 - path: tests/integration/Core/Repository/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLWildcardService\\CriterionTest\:\:getUrlWildcards\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/URLWildcardService/CriterionTest.php - - - - message: '#^Parameter \#1 \$criteria of class Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\URLWildcard\\Query\\Criterion\\LogicalAnd constructor expects array\, array\ given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/URLWildcardService/CriterionTest.php - - - - message: '#^Parameter \#1 \$expectedCount of static method PHPUnit\\Framework\\Assert\:\:assertCount\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/URLWildcardService/CriterionTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLWildcardServiceAuthorizationTest\:\:testRemoveThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLWildcardServiceAuthorizationTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\URLWildcard'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\URLWildcard will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 2 - path: tests/integration/Core/Repository/URLWildcardServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\URLWildcardTranslationResult'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\URLWildcardTranslationResult will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLWildcardServiceTest\:\:testCreateSetsPropertiesOnURLWildcard\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLWildcardServiceTest\:\:testCreateThrowsContentValidationExceptionWhenPatternsAndPlaceholdersNotMatch\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLWildcardServiceTest\:\:testCreateThrowsContentValidationExceptionWhenPlaceholdersNotValidNumberSequence\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLWildcardServiceTest\:\:testCreateThrowsInvalidArgumentExceptionOnDuplicateSourceUrl\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLWildcardServiceTest\:\:testCreateWithOptionalForwardParameter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLWildcardServiceTest\:\:testLoadAll\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLWildcardServiceTest\:\:testLoadAllReturnsEmptyArrayByDefault\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLWildcardServiceTest\:\:testLoadAllWithOffsetAndLimitParameter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLWildcardServiceTest\:\:testLoadAllWithOffsetParameter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLWildcardServiceTest\:\:testLoadSetsPropertiesOnURLWildcard\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLWildcardServiceTest\:\:testLoadThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLWildcardServiceTest\:\:testRemove\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLWildcardServiceTest\:\:testTranslateReturnsLongestMatchingWildcard\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLWildcardServiceTest\:\:testTranslateSetsPropertiesOnTranslationResult\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLWildcardServiceTest\:\:testTranslateThrowsNotFoundExceptionWhenNotAliasOrWildcardMatches\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\URLWildcardServiceTest\:\:testTranslateWithForwardSetToTrue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/URLWildcardServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\UserPreference\\\\UserPreference'' and Ibexa\\Contracts\\Core\\Repository\\Values\\UserPreference\\UserPreference will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 2 - path: tests/integration/Core/Repository/UserPreferenceServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\UserPreference\\\\UserPreferenceList'' and Ibexa\\Contracts\\Core\\Repository\\Values\\UserPreference\\UserPreferenceList will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/UserPreferenceServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserPreferenceServiceTest\:\:testGetUserPreference\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserPreferenceServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserPreferenceServiceTest\:\:testGetUserPreferenceCount\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserPreferenceServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserPreferenceServiceTest\:\:testLoadUserPreferences\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserPreferenceServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserPreferenceServiceTest\:\:testSetUserPreference\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserPreferenceServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserPreferenceServiceTest\:\:testSetUserPreferenceThrowsInvalidArgumentExceptionOnEmptyName\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserPreferenceServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserPreferenceServiceTest\:\:testSetUserPreferenceThrowsInvalidArgumentExceptionOnInvalidValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserPreferenceServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceAuthorizationTest\:\:testAssignUserToUserGroupThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceAuthorizationTest\:\:testCreateUserGroupThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceAuthorizationTest\:\:testCreateUserThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceAuthorizationTest\:\:testDeleteUserGroupThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceAuthorizationTest\:\:testDeleteUserThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceAuthorizationTest\:\:testLoadSubUserGroupsThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceAuthorizationTest\:\:testLoadUserGroupThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceAuthorizationTest\:\:testLoadUserGroupsOfUserThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceAuthorizationTest\:\:testLoadUsersOfUserGroupThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceAuthorizationTest\:\:testMoveUserGroupThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceAuthorizationTest\:\:testUnAssignUserFromUserGroupThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceAuthorizationTest\:\:testUpdateUserGroupThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceAuthorizationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceAuthorizationTest\:\:testUpdateUserThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceAuthorizationTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\User'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\User will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 7 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\UserCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\UserCreateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\UserGroupCreateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\UserGroupCreateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\UserGroupUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\UserGroupUpdateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\User\\\\UserUpdateStruct'' and Ibexa\\Contracts\\Core\\Repository\\Values\\User\\UserUpdateStruct will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Cannot call method add\(\) on DateTimeImmutable\|false\|null\.$#' - identifier: method.nonObject - count: 3 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:createUserContentTypeWithAccountSettings\(\) has parameter \$fieldSetting with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:createUserContentTypeWithAccountSettings\(\) has parameter \$validatorConfiguration with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:dataProviderForValidatePassword\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:getDataForTestPasswordUpdateRespectsAllValidationSettings\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:getPrioritizedLanguageList\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testAssignUserToUserGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testAssignUserToUserGroupThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testCreateUserGroupSetsExpectedProperties\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testCreateUserGroupThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testCreateUserGroupThrowsInvalidArgumentExceptionFieldTypeNotAccept\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testCreateUserGroupWhenMissingField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testCreateUserSetsExpectedProperties\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testCreateUserThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testCreateUserThrowsInvalidArgumentExceptionOnFieldTypeNotAccept\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testCreateUserThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testCreateUserWhenMissingField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testCreateUserWithStrongPassword\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testCreateUserWithWeakPasswordThrowsUserPasswordValidationException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testDeleteUser\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testDeleteUserDeletesRelatedBookmarks\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testDeleteUserGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testDeleteUserGroupThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testExpireUserToken\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadSubUserGroups\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadSubUserGroupsThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadSubUserGroupsWithPrioritizedLanguagesList\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadUserByEmailReturnsEmptyInUnknownEmail\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadUserByLogin\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadUserByLoginThrowsNotFoundExceptionForUnknownLogin\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadUserByLoginThrowsNotFoundExceptionForUnknownLoginByEmail\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadUserByLoginWithPrioritizedLanguagesList\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadUserByLoginWorksForLoginWithWrongCase\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadUserGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadUserGroupThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadUserGroupWithNoAccessToParent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadUserGroupWithPrioritizedLanguagesList\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadUserGroupWithPrioritizedLanguagesListAfterMainLanguageUpdate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadUserGroupsOfUser\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadUserGroupsOfUserWithPrioritizedLanguagesList\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadUserThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadUserWithPrioritizedLanguagesList\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadUserWithPrioritizedLanguagesListAfterMainLanguageUpdate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadUsersByEmailWithPrioritizedLanguagesList\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadUsersOfUserGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testLoadUsersOfUserGroupWithPrioritizedLanguagesList\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testMoveUserGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testMoveUserGroupThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testNewUserCreateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testNewUserCreateStructSetsExpectedProperties\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testNewUserCreateStructWithFifthParameter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testNewUserGroupCreateStructSetsContentType\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testNewUserGroupCreateStructSetsMainLanguageCode\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testNewUserGroupCreateStructWithSecondParameter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testNewUserGroupUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testNewUserUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testUnAssignUserFromUserGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testUnAssignUserFromUserGroupThrowsBadStateArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testUnAssignUserFromUserGroupThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testUpdateUserGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testUpdateUserGroupThrowsContentFieldValidationExceptionOnRequiredFieldEmpty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testUpdateUserGroupThrowsInvalidArgumentExceptionOnFieldTypeNotAccept\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testUpdateUserGroupWithSubContentMetadataUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testUpdateUserGroupWithSubContentUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testUpdateUserReturnsPublishedVersion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testUpdateUserThrowsInvalidArgumentExceptionOnFieldTypeNotAccept\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testUpdateUserToken\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testUpdateUserUpdatesExpectedProperties\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testUpdateUserWhenMissingField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testUpdateUserWithContentMetadataUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testUpdateUserWithContentUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testUpdateUserWithStrongPassword\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testUpdateUserWithWeakPasswordThrowsUserPasswordValidationException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testValidatePassword\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testValidatePassword\(\) has parameter \$expectedErrors with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\UserServiceTest\:\:testValidatePasswordWithDefaultContext\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 2 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Parameter \#2 \$array of function array_map expects array, iterable\ given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/UserServiceTest.php - - - - message: '#^Parameter \#1 \$string of function md5 expects string, int\<1, max\> given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/BaseLimitationTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ChangeOwnerLimitationTest\:\:getContentCreatePolicyDraft\(\) should return Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft but returns Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy\.$#' - identifier: return.type - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ChangeOwnerLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ChangeOwnerLimitationTest\:\:getDataForDeniedAccess\(\) should return array\\}\> but returns array\{array\{123, array\{\-1\}\}, array\{123, array\{456, 789\}\}\}\.$#' - identifier: return.type - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ChangeOwnerLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ChangeOwnerLimitationTest\:\:getDataForGrantedAccess\(\) should return array\\}\> but returns array\{array\{null, array\{\}\}, array\{null, array\{\-1\}\}, array\{null, array\{123, 456, \-1\}\}, array\{123, array\{123, 456, \-1\}\}, array\{123, array\{\}\}\}\.$#' - identifier: return.type - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ChangeOwnerLimitationTest.php - - - - message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' - identifier: property.nonObject - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ContentTypeLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ContentTypeLimitationTest\:\:testContentTypeLimitationAllow\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ContentTypeLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ContentTypeLimitationTest\:\:testContentTypeLimitationForbid\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ContentTypeLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ContentTypeLimitationTest\:\:testContentTypeLimitationForbidVariant\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ContentTypeLimitationTest.php - - - - message: '#^PHPDoc tag @var with type Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft is not subtype of native type null\.$#' - identifier: varTag.nativeType - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ContentTypeLimitationTest.php - - - - message: '#^Parameter \#2 \$policy of method Ibexa\\Contracts\\Core\\Repository\\RoleService\:\:updatePolicyByRoleDraft\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft, Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ContentTypeLimitationTest.php - - - - message: '#^Cannot access property \$value on Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Field\|null\.$#' - identifier: property.nonObject - count: 2 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:createEditorUserWithLanguageLimitation\(\) has parameter \$allowedTranslationsList with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:providerForCanUserWithLimitationTargets\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:providerForCreateAndPublishContent\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:providerForPublishVersionWithLanguageLimitation\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testCanUserWithLimitationTargets\(\) has parameter \$allowedTranslationsList with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testCanUserWithLimitationTargets\(\) has parameter \$folderNames with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testCopyContentWithLanguageLimitationAndDifferentContentTranslations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testCopySubtreeWithLanguageLimitationAndDifferentContentTranslations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testCreateAndPublishContent\(\) has parameter \$allowedTranslationsList with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testCreateAndPublishContent\(\) has parameter \$names with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testHideContentWithLanguageLimitationAndDifferentContentTranslations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testHideLocationWithLanguageLimitationAndDifferentContentTranslations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testMoveSubtreeWithLanguageLimitationAndDifferentContentTranslations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testPublishVersion\(\) has parameter \$allowedTranslationsList with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testPublishVersion\(\) has parameter \$names with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testPublishVersion\(\) has parameter \$namesToUpdate with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testPublishVersionIsNotAllowedIfModifiedOtherTranslations\(\) has parameter \$names with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testRevealContentWithLanguageLimitationAndDifferentContentTranslations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testSwapLocationWithLanguageLimitationAndDifferentContentTranslations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testUnhideLocationWithLanguageLimitationAndDifferentContentTranslations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LanguageLimitationTest\:\:testUpdateLocationWithLanguageLimitationAndDifferentContentTranslations\(\) has parameter \$limitationValues with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^PHPDoc tag @return with type iterable\\|bool\>\> is not subtype of native type array\.$#' - identifier: return.phpDocType - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Parameter \#1 \$locationId of method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:loadLocation\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 7 - path: tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php - - - - message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' - identifier: property.nonObject - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LocationLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LocationLimitationTest\:\:testLocationLimitationAllow\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LocationLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\LocationLimitationTest\:\:testLocationLimitationForbid\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/LocationLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\NewObjectStateLimitationTest\:\:testNewObjectStateLimitationAllow\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/NewObjectStateLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\NewObjectStateLimitationTest\:\:testNewObjectStateLimitationForbid\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/NewObjectStateLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\NewSectionLimitationTest\:\:testNewSectionLimitationAllow\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/NewSectionLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\NewSectionLimitationTest\:\:testNewSectionLimitationForbid\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/NewSectionLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ObjectStateLimitationTest\:\:createUserWithObjectStateLimitation\(\) has parameter \$objectStateIDs with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ObjectStateLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ObjectStateLimitationTest\:\:createUserWithObjectStateLimitationOnContentRead\(\) has parameter \$values with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ObjectStateLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\OwnerLimitationTest\:\:testOwnerLimitationAllow\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/OwnerLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\OwnerLimitationTest\:\:testOwnerLimitationForbid\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/OwnerLimitationTest.php - - - - message: '#^Parameter \#2 \$policy of method Ibexa\\Contracts\\Core\\Repository\\RoleService\:\:updatePolicyByRoleDraft\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft, Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy given\.$#' - identifier: argument.type - count: 2 - path: tests/integration/Core/Repository/Values/User/Limitation/OwnerLimitationTest.php - - - - message: '#^Variable \$policy in PHPDoc tag @var does not match assigned variable \$removePolicy\.$#' - identifier: varTag.differentVariable - count: 2 - path: tests/integration/Core/Repository/Values/User/Limitation/OwnerLimitationTest.php - - - - message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' - identifier: property.nonObject - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ParentContentTypeLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ParentContentTypeLimitationTest\:\:testParentContentTypeLimitationAllow\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ParentContentTypeLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ParentContentTypeLimitationTest\:\:testParentContentTypeLimitationForbid\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ParentContentTypeLimitationTest.php - - - - message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' - identifier: property.nonObject - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ParentDepthLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ParentDepthLimitationTest\:\:testParentDepthLimitationAllow\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ParentDepthLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ParentDepthLimitationTest\:\:testParentDepthLimitationAllowPublish\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ParentDepthLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ParentDepthLimitationTest\:\:testParentDepthLimitationForbid\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ParentDepthLimitationTest.php - - - - message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' - identifier: property.nonObject - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ParentOwnerLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ParentOwnerLimitationTest\:\:testParentOwnerLimitationAllow\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ParentOwnerLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ParentOwnerLimitationTest\:\:testParentOwnerLimitationForbid\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ParentOwnerLimitationTest.php - - - - message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' - identifier: property.nonObject - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ParentUserGroupLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ParentUserGroupLimitationTest\:\:testParentUserGroupLimitationAllow\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ParentUserGroupLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\ParentUserGroupLimitationTest\:\:testParentUserGroupLimitationForbid\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/ParentUserGroupLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\RolePolicyLimitationTest\:\:addPolicyToNewRole\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/RolePolicyLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\RolePolicyLimitationTest\:\:getSubtreeLocationsCount\(\) has parameter \$subtreePathString with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/RolePolicyLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\RolePolicyLimitationTest\:\:providerForTestRolePoliciesWithOverlappingLimitations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/RolePolicyLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\RolePolicyLimitationTest\:\:testRolePoliciesWithOverlappingLimitations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/RolePolicyLimitationTest.php - - - - message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' - identifier: property.nonObject - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/SectionLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\SectionLimitationTest\:\:testSectionLimitationAllow\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/SectionLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\SectionLimitationTest\:\:testSectionLimitationForbid\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/SectionLimitationTest.php - - - - message: '#^Parameter \#2 \$policy of method Ibexa\\Contracts\\Core\\Repository\\RoleService\:\:updatePolicyByRoleDraft\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft, Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy given\.$#' - identifier: argument.type - count: 2 - path: tests/integration/Core/Repository/Values/User/Limitation/SectionLimitationTest.php - - - - message: '#^Variable \$policy in PHPDoc tag @var does not match assigned variable \$readPolicy\.$#' - identifier: varTag.differentVariable - count: 2 - path: tests/integration/Core/Repository/Values/User/Limitation/SectionLimitationTest.php - - - - message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' - identifier: property.nonObject - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/StatusLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\StatusLimitationTest\:\:testStatusLimitationAllow\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/StatusLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\StatusLimitationTest\:\:testStatusLimitationForbid\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/StatusLimitationTest.php - - - - message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' - identifier: property.nonObject - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/SubtreeLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\SubtreeLimitationTest\:\:prepareLimitation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/SubtreeLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\SubtreeLimitationTest\:\:testSubtreeLimitationAllow\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/SubtreeLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\SubtreeLimitationTest\:\:testSubtreeLimitationForbid\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/SubtreeLimitationTest.php - - - - message: '#^Parameter \#2 \$policy of method Ibexa\\Contracts\\Core\\Repository\\RoleService\:\:updatePolicyByRoleDraft\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft, Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/SubtreeLimitationTest.php - - - - message: '#^Variable \$policy in PHPDoc tag @var does not match assigned variable \$editPolicy\.$#' - identifier: varTag.differentVariable - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/SubtreeLimitationTest.php - - - - message: '#^Cannot access property \$text on Ibexa\\Contracts\\Core\\FieldType\\Value\|null\.$#' - identifier: property.nonObject - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/UserGroupLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\UserGroupLimitationTest\:\:testUserGroupLimitationAllow\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/UserGroupLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\Repository\\Values\\User\\Limitation\\UserGroupLimitationTest\:\:testUserGroupLimitationForbid\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/UserGroupLimitationTest.php - - - - message: '#^Parameter \#2 \$policy of method Ibexa\\Contracts\\Core\\Repository\\RoleService\:\:updatePolicyByRoleDraft\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PolicyDraft, Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy given\.$#' - identifier: argument.type - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/UserGroupLimitationTest.php - - - - message: '#^Variable \$policy in PHPDoc tag @var does not match assigned variable \$editPolicy\.$#' - identifier: varTag.differentVariable - count: 1 - path: tests/integration/Core/Repository/Values/User/Limitation/UserGroupLimitationTest.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\User\\UserStorage\\UserStorageGatewayTestCase\:\:getDataForTestCountUsersWithUnsupportedHashType\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/User/UserStorage/UserStorageGatewayTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\User\\UserStorage\\UserStorageGatewayTestCase\:\:providerForGetFieldData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/User/UserStorage/UserStorageGatewayTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Integration\\Core\\User\\UserStorage\\UserStorageGatewayTestCase\:\:testGetFieldData\(\) has parameter \$expectedUserData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/integration/Core/User/UserStorage/UserStorageGatewayTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\FieldTypeRegistryPassTest\:\:tagsProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Base/Container/Compiler/FieldTypeRegistryPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\FieldTypeRegistryPassTest\:\:testRegisterFieldType\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Base/Container/Compiler/FieldTypeRegistryPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\FieldTypeRegistryPassTest\:\:testRegisterFieldTypeNoAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Base/Container/Compiler/FieldTypeRegistryPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\GenericFieldTypeConverterPassTest\:\:assertContainerBuilderHasNoServiceDefinitionWithMethodCall\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Base/Container/Compiler/GenericFieldTypeConverterPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\GenericFieldTypeConverterPassTest\:\:assertContainerBuilderHasNoServiceDefinitionWithMethodCall\(\) has parameter \$index with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Base/Container/Compiler/GenericFieldTypeConverterPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Search\\FieldTypeRegistryPassTest\:\:testRegisterFieldType\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Base/Container/Compiler/Search/FieldTypeRegistryPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Search\\FieldTypeRegistryPassTest\:\:testRegisterFieldTypeNoAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Base/Container/Compiler/Search/FieldTypeRegistryPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Search\\Legacy\\CriterionFieldValueHandlerRegistryPassTest\:\:testRegisterValueHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Base/Container/Compiler/Search/Legacy/CriterionFieldValueHandlerRegistryPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Search\\Legacy\\CriterionFieldValueHandlerRegistryPassTest\:\:testRegisterValueHandlerNoAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Base/Container/Compiler/Search/Legacy/CriterionFieldValueHandlerRegistryPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Search\\Legacy\\SortClauseConverterPassTest\:\:testAddContentHandlers\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Base/Container/Compiler/Search/Legacy/SortClauseConverterPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Search\\Legacy\\SortClauseConverterPassTest\:\:testAddLocationAndContentHandlers\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Base/Container/Compiler/Search/Legacy/SortClauseConverterPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Search\\Legacy\\SortClauseConverterPassTest\:\:testAddLocationHandlers\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Base/Container/Compiler/Search/Legacy/SortClauseConverterPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Storage\\ExternalStorageRegistryPassTest\:\:externalStorageHandlerGatewayTagsProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Base/Container/Compiler/Storage/ExternalStorageRegistryPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Storage\\ExternalStorageRegistryPassTest\:\:externalStorageHandlerTagsProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Base/Container/Compiler/Storage/ExternalStorageRegistryPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Storage\\ExternalStorageRegistryPassTest\:\:testRegisterExternalStorageHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Base/Container/Compiler/Storage/ExternalStorageRegistryPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Storage\\ExternalStorageRegistryPassTest\:\:testRegisterExternalStorageHandlerNoAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Base/Container/Compiler/Storage/ExternalStorageRegistryPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Storage\\ExternalStorageRegistryPassTest\:\:testRegisterExternalStorageHandlerWithGateway\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Base/Container/Compiler/Storage/ExternalStorageRegistryPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Storage\\ExternalStorageRegistryPassTest\:\:testRegisterExternalStorageHandlerWithGatewayNoAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Base/Container/Compiler/Storage/ExternalStorageRegistryPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Storage\\ExternalStorageRegistryPassTest\:\:testRegisterExternalStorageHandlerWithGatewayNoIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Base/Container/Compiler/Storage/ExternalStorageRegistryPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Storage\\ExternalStorageRegistryPassTest\:\:testRegisterExternalStorageHandlerWithoutRegisteredGateway\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Base/Container/Compiler/Storage/ExternalStorageRegistryPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Storage\\Legacy\\FieldValueConverterRegistryPassTest\:\:testRegisterConverterNoLazy\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Base/Container/Compiler/Storage/Legacy/FieldValueConverterRegistryPassTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Storage\\Legacy\\RoleLimitationConverterPassTest\:\:testRegisterRoleLimitationConverter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Base/Container/Compiler/Storage/Legacy/RoleLimitationConverterPassTest.php - - - - message: '#^Class Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Stubs\\GatewayBasedStorageHandler extends generic class Ibexa\\Contracts\\Core\\FieldType\\GatewayBasedStorage but does not specify its types\: T$#' - identifier: missingType.generics - count: 1 - path: tests/lib/Base/Container/Compiler/Stubs/GatewayBasedStorageHandler.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Stubs\\GatewayBasedStorageHandler\:\:deleteFieldData\(\) has parameter \$fieldIds with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Base/Container/Compiler/Stubs/GatewayBasedStorageHandler.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Stubs\\GatewayBasedStorageHandler\:\:deleteFieldData\(\) should return bool but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: tests/lib/Base/Container/Compiler/Stubs/GatewayBasedStorageHandler.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Stubs\\GatewayBasedStorageHandler\:\:getFieldData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Base/Container/Compiler/Stubs/GatewayBasedStorageHandler.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\Stubs\\GatewayBasedStorageHandler\:\:hasFieldData\(\) should return bool but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: tests/lib/Base/Container/Compiler/Stubs/GatewayBasedStorageHandler.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\TaggedServiceIdsIterator\\DeprecationErrorCollector\:\:getErrors\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Base/Container/Compiler/TaggedServiceIdsIterator/DeprecationErrorCollector.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Base\\Container\\Compiler\\TaggedServiceIdsIterator\\DeprecationErrorCollector\:\:\$errors type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Base/Container/Compiler/TaggedServiceIdsIterator/DeprecationErrorCollector.php - - - - message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Collection\\CollectionInterface\:\:filter\(\)\.$#' - identifier: method.notFound - count: 2 - path: tests/lib/Collection/AbstractCollectionTestCase.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''IteratorAggregate'' and Ibexa\\Contracts\\Core\\Collection\\CollectionInterface will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/lib/Collection/AbstractCollectionTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\:\:createCollection\(\) has invalid return type Ibexa\\Contracts\\Core\\Repository\\Collection\\CollectionInterfaces\.$#' - identifier: class.notFound - count: 1 - path: tests/lib/Collection/AbstractCollectionTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\:\:createCollection\(\) has parameter \$data with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Collection/AbstractCollectionTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\:\:createCollection\(\) return type with generic interface Ibexa\\Contracts\\Core\\Collection\\CollectionInterface does not specify its types\: TValue$#' - identifier: missingType.generics - count: 1 - path: tests/lib/Collection/AbstractCollectionTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\:\:createCollectionWithExampleData\(\) has invalid return type Ibexa\\Contracts\\Core\\Repository\\Collection\\CollectionInterfaces\.$#' - identifier: class.notFound - count: 1 - path: tests/lib/Collection/AbstractCollectionTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\:\:createCollectionWithExampleData\(\) return type with generic interface Ibexa\\Contracts\\Core\\Collection\\CollectionInterface does not specify its types\: TValue$#' - identifier: missingType.generics - count: 1 - path: tests/lib/Collection/AbstractCollectionTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\:\:createEmptyCollection\(\) has invalid return type Ibexa\\Contracts\\Core\\Repository\\Collection\\CollectionInterfaces\.$#' - identifier: class.notFound - count: 1 - path: tests/lib/Collection/AbstractCollectionTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\:\:createEmptyCollection\(\) return type with generic interface Ibexa\\Contracts\\Core\\Collection\\CollectionInterface does not specify its types\: TValue$#' - identifier: missingType.generics - count: 1 - path: tests/lib/Collection/AbstractCollectionTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\:\:getExampleData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Collection/AbstractCollectionTestCase.php - - - - message: '#^PHPDoc tag @return with type TCollection of Ibexa\\Contracts\\Core\\Repository\\Collection\\CollectionInterfaces is not subtype of native type Ibexa\\Contracts\\Core\\Collection\\CollectionInterface\.$#' - identifier: return.phpDocType - count: 3 - path: tests/lib/Collection/AbstractCollectionTestCase.php - - - - message: '#^PHPDoc tag @template TCollection for class Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase has invalid bound type Ibexa\\Contracts\\Core\\Repository\\Collection\\CollectionInterfaces\.$#' - identifier: class.notFound - count: 1 - path: tests/lib/Collection/AbstractCollectionTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Collection\\ArrayListTest\:\:createCollection\(\) has parameter \$data with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Collection/ArrayListTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Collection\\ArrayListTest\:\:createCollection\(\) return type with generic class Ibexa\\Contracts\\Core\\Collection\\ArrayList does not specify its types\: TValue$#' - identifier: missingType.generics - count: 1 - path: tests/lib/Collection/ArrayListTest.php - - - - message: '#^PHPDoc tag @var for variable \$list contains generic class Ibexa\\Contracts\\Core\\Collection\\ArrayList but does not specify its types\: TValue$#' - identifier: missingType.generics - count: 2 - path: tests/lib/Collection/ArrayListTest.php - - - - message: '#^Type Ibexa\\Contracts\\Core\\Collection\\ArrayList in generic type Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\ in PHPDoc tag @extends is not subtype of template type TCollection of Ibexa\\Contracts\\Core\\Repository\\Collection\\CollectionInterfaces of class Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\.$#' - identifier: generics.notSubtype - count: 1 - path: tests/lib/Collection/ArrayListTest.php - - - - message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Collection\\MapInterface\:\:exists\(\)\.$#' - identifier: method.notFound - count: 2 - path: tests/lib/Collection/ArrayMapTest.php - - - - message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Collection\\MapInterface\:\:filter\(\)\.$#' - identifier: method.notFound - count: 1 - path: tests/lib/Collection/ArrayMapTest.php - - - - message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Collection\\MapInterface\:\:forAll\(\)\.$#' - identifier: method.notFound - count: 2 - path: tests/lib/Collection/ArrayMapTest.php - - - - message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Collection\\MapInterface\:\:map\(\)\.$#' - identifier: method.notFound - count: 1 - path: tests/lib/Collection/ArrayMapTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Collection\\ArrayMapTest\:\:createCollection\(\) has parameter \$data with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Collection/ArrayMapTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Collection\\ArrayMapTest\:\:createCollection\(\) return type with generic interface Ibexa\\Contracts\\Core\\Collection\\MapInterface does not specify its types\: TKey, TValue$#' - identifier: missingType.generics - count: 1 - path: tests/lib/Collection/ArrayMapTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Collection\\ArrayMapTest\:\:getExampleData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Collection/ArrayMapTest.php - - - - message: '#^PHPDoc tag @return with type Ibexa\\Contracts\\Core\\Collection\\MapInterface\|Ibexa\\Contracts\\Core\\Collection\\StreamableInterface is not subtype of native type Ibexa\\Contracts\\Core\\Collection\\MapInterface\.$#' - identifier: return.phpDocType - count: 1 - path: tests/lib/Collection/ArrayMapTest.php - - - - message: '#^PHPDoc tag @var for variable \$map contains generic class Ibexa\\Contracts\\Core\\Collection\\ArrayMap but does not specify its types\: TKey, TValue$#' - identifier: missingType.generics - count: 1 - path: tests/lib/Collection/ArrayMapTest.php - - - - message: '#^Type Ibexa\\Contracts\\Core\\Collection\\ArrayMap in generic type Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\ in PHPDoc tag @extends is not subtype of template type TCollection of Ibexa\\Contracts\\Core\\Repository\\Collection\\CollectionInterfaces of class Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\.$#' - identifier: generics.notSubtype - count: 1 - path: tests/lib/Collection/ArrayMapTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Collection\\MutableArrayListTest\:\:createCollection\(\) has parameter \$data with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Collection/MutableArrayListTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Collection\\MutableArrayListTest\:\:createCollection\(\) return type with generic class Ibexa\\Contracts\\Core\\Collection\\MutableArrayList does not specify its types\: TValue$#' - identifier: missingType.generics - count: 1 - path: tests/lib/Collection/MutableArrayListTest.php - - - - message: '#^PHPDoc tag @var for variable \$list contains generic class Ibexa\\Contracts\\Core\\Collection\\MutableArrayList but does not specify its types\: TValue$#' - identifier: missingType.generics - count: 4 - path: tests/lib/Collection/MutableArrayListTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Collection\\MutableArrayMapTest\:\:createCollection\(\) has parameter \$data with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Collection/MutableArrayMapTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Collection\\MutableArrayMapTest\:\:createCollection\(\) return type with generic class Ibexa\\Contracts\\Core\\Collection\\MutableArrayMap does not specify its types\: TKey, TValue$#' - identifier: missingType.generics - count: 1 - path: tests/lib/Collection/MutableArrayMapTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\BookmarkServiceTest\:\:testCreateBookmarkEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/BookmarkServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\BookmarkServiceTest\:\:testCreateBookmarkStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/BookmarkServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\BookmarkServiceTest\:\:testDeleteBookmarkEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/BookmarkServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\BookmarkServiceTest\:\:testDeleteBookmarkStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/BookmarkServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testAddRelationEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testAddRelationStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testCopyContentEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testCopyContentStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testCreateContentDraftEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testCreateContentDraftStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testCreateContentEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testCreateContentStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testDeleteContentEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testDeleteContentStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testDeleteRelationEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testDeleteRelationStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testDeleteTranslationEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testDeleteTranslationStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testDeleteVersionEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testDeleteVersionStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testHideContentEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testHideContentStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testPublishVersionEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testPublishVersionStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testReturnAddRelationResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testReturnCopyContentResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testReturnCreateContentDraftResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testReturnCreateContentResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testReturnDeleteContentResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testReturnPublishVersionResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testReturnUpdateContentMetadataResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testReturnUpdateContentResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testRevealContentEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testRevealContentStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testUpdateContentEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testUpdateContentMetadataEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testUpdateContentMetadataStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentServiceTest\:\:testUpdateContentStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testAddFieldDefinitionEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testAddFieldDefinitionStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testAssignContentTypeGroupEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testAssignContentTypeGroupStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testCopyContentTypeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testCopyContentTypeStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testCreateContentTypeDraftEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testCreateContentTypeDraftStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testCreateContentTypeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testCreateContentTypeGroupEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testCreateContentTypeGroupStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testCreateContentTypeStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testDeleteContentTypeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testDeleteContentTypeGroupEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testDeleteContentTypeGroupStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testDeleteContentTypeStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testPublishContentTypeDraftEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testPublishContentTypeDraftStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testRemoveContentTypeTranslationEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testRemoveContentTypeTranslationStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testRemoveFieldDefinitionEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testRemoveFieldDefinitionStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testReturnCopyContentTypeResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testReturnCreateContentTypeDraftResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testReturnCreateContentTypeGroupResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testReturnCreateContentTypeResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testReturnRemoveContentTypeTranslationResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testUnassignContentTypeGroupEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testUnassignContentTypeGroupStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testUpdateContentTypeDraftEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testUpdateContentTypeDraftStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testUpdateContentTypeGroupEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testUpdateContentTypeGroupStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testUpdateFieldDefinitionEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ContentTypeServiceTest\:\:testUpdateFieldDefinitionStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ContentTypeServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LanguageServiceTest\:\:testCreateLanguageEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LanguageServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LanguageServiceTest\:\:testCreateLanguageStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LanguageServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LanguageServiceTest\:\:testDeleteLanguageEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LanguageServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LanguageServiceTest\:\:testDeleteLanguageStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LanguageServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LanguageServiceTest\:\:testDisableLanguageEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LanguageServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LanguageServiceTest\:\:testDisableLanguageStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LanguageServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LanguageServiceTest\:\:testEnableLanguageEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LanguageServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LanguageServiceTest\:\:testEnableLanguageStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LanguageServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LanguageServiceTest\:\:testReturnCreateLanguageResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LanguageServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LanguageServiceTest\:\:testReturnDisableLanguageResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LanguageServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LanguageServiceTest\:\:testReturnEnableLanguageResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LanguageServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LanguageServiceTest\:\:testReturnUpdateLanguageNameResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LanguageServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LanguageServiceTest\:\:testUpdateLanguageNameEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LanguageServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LanguageServiceTest\:\:testUpdateLanguageNameStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LanguageServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testCopySubtreeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testCopySubtreeStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testCreateLocationEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testCreateLocationStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testDeleteLocationEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testDeleteLocationStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testHideLocationEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testHideLocationStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testMoveSubtreeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testMoveSubtreeStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testReturnCopySubtreeResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testReturnCreateLocationResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testReturnHideLocationResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testReturnUnhideLocationResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testReturnUpdateLocationResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testSwapLocationEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testSwapLocationStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testUnhideLocationEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testUnhideLocationStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testUpdateLocationEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\LocationServiceTest\:\:testUpdateLocationStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/LocationServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ObjectStateServiceTest\:\:testCreateObjectStateEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ObjectStateServiceTest\:\:testCreateObjectStateGroupEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ObjectStateServiceTest\:\:testCreateObjectStateGroupStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ObjectStateServiceTest\:\:testCreateObjectStateStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ObjectStateServiceTest\:\:testDeleteObjectStateEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ObjectStateServiceTest\:\:testDeleteObjectStateGroupEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ObjectStateServiceTest\:\:testDeleteObjectStateGroupStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ObjectStateServiceTest\:\:testDeleteObjectStateStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ObjectStateServiceTest\:\:testReturnCreateObjectStateGroupResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ObjectStateServiceTest\:\:testReturnCreateObjectStateResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ObjectStateServiceTest\:\:testReturnUpdateObjectStateGroupResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ObjectStateServiceTest\:\:testReturnUpdateObjectStateResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ObjectStateServiceTest\:\:testSetContentStateEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ObjectStateServiceTest\:\:testSetContentStateStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ObjectStateServiceTest\:\:testSetPriorityOfObjectStateEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ObjectStateServiceTest\:\:testSetPriorityOfObjectStateStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ObjectStateServiceTest\:\:testUpdateObjectStateEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ObjectStateServiceTest\:\:testUpdateObjectStateGroupEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ObjectStateServiceTest\:\:testUpdateObjectStateGroupStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\ObjectStateServiceTest\:\:testUpdateObjectStateStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/ObjectStateServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testAddPolicyByRoleDraftEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testAddPolicyByRoleDraftStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testAssignRoleToUserEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testAssignRoleToUserGroupEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testAssignRoleToUserGroupStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testAssignRoleToUserStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testCreateRoleDraftEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testCreateRoleDraftStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testCreateRoleEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testCreateRoleStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testDeleteRoleDraftEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testDeleteRoleDraftStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testDeleteRoleEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testDeleteRoleStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testPublishRoleDraftEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testPublishRoleDraftStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testRemovePolicyByRoleDraftEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testRemovePolicyByRoleDraftStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testRemoveRoleAssignmentEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testRemoveRoleAssignmentStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testReturnAddPolicyByRoleDraftResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testReturnCreateRoleDraftResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testReturnCreateRoleResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testReturnRemovePolicyByRoleDraftResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testReturnUpdatePolicyByRoleDraftResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testReturnUpdateRoleDraftResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testUpdatePolicyByRoleDraftEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testUpdatePolicyByRoleDraftStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testUpdateRoleDraftEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\RoleServiceTest\:\:testUpdateRoleDraftStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/RoleServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\SectionServiceTest\:\:testAssignSectionEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\SectionServiceTest\:\:testAssignSectionStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\SectionServiceTest\:\:testAssignSectionToSubtreeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\SectionServiceTest\:\:testAssignSectionToSubtreeStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\SectionServiceTest\:\:testCreateSectionEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\SectionServiceTest\:\:testCreateSectionStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\SectionServiceTest\:\:testDeleteSectionEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\SectionServiceTest\:\:testDeleteSectionStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\SectionServiceTest\:\:testReturnCreateSectionResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\SectionServiceTest\:\:testReturnUpdateSectionResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\SectionServiceTest\:\:testUpdateSectionEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/SectionServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\SectionServiceTest\:\:testUpdateSectionStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/SectionServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertSame\(\) with Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Trash\\TrashItemDeleteResult and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Trash\\TrashItemDeleteResult will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/lib/Event/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\TrashServiceTest\:\:testDeleteTrashItemEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\TrashServiceTest\:\:testDeleteTrashItemStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\TrashServiceTest\:\:testEmptyTrashEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\TrashServiceTest\:\:testEmptyTrashStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\TrashServiceTest\:\:testRecoverEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\TrashServiceTest\:\:testRecoverStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\TrashServiceTest\:\:testReturnDeleteTrashItemResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\TrashServiceTest\:\:testReturnEmptyTrashResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\TrashServiceTest\:\:testReturnRecoverResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\TrashServiceTest\:\:testReturnTrashResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\TrashServiceTest\:\:testTrashEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\TrashServiceTest\:\:testTrashStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/TrashServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLAliasServiceTest\:\:testCreateGlobalUrlAliasEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLAliasServiceTest\:\:testCreateGlobalUrlAliasStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLAliasServiceTest\:\:testCreateUrlAliasEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLAliasServiceTest\:\:testCreateUrlAliasStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLAliasServiceTest\:\:testRefreshSystemUrlAliasesForLocationEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLAliasServiceTest\:\:testRefreshSystemUrlAliasesForLocationStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLAliasServiceTest\:\:testRemoveAliasesEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLAliasServiceTest\:\:testRemoveAliasesStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLAliasServiceTest\:\:testReturnCreateGlobalUrlAliasResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLAliasServiceTest\:\:testReturnCreateUrlAliasResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLAliasServiceTest.php - - - - message: '#^Parameter \#4 \$forwarding of method Ibexa\\Core\\Event\\URLAliasService\:\:createGlobalUrlAlias\(\) expects bool, string given\.$#' - identifier: argument.type - count: 3 - path: tests/lib/Event/URLAliasServiceTest.php - - - - message: '#^Parameter \#4 \$forwarding of method Ibexa\\Core\\Event\\URLAliasService\:\:createUrlAlias\(\) expects bool, string given\.$#' - identifier: argument.type - count: 3 - path: tests/lib/Event/URLAliasServiceTest.php - - - - message: '#^Parameter \#5 \$alwaysAvailable of method Ibexa\\Core\\Event\\URLAliasService\:\:createGlobalUrlAlias\(\) expects bool, string given\.$#' - identifier: argument.type - count: 3 - path: tests/lib/Event/URLAliasServiceTest.php - - - - message: '#^Parameter \#5 \$alwaysAvailable of method Ibexa\\Core\\Event\\URLAliasService\:\:createUrlAlias\(\) expects bool, string given\.$#' - identifier: argument.type - count: 3 - path: tests/lib/Event/URLAliasServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLServiceTest\:\:testReturnUpdateUrlResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLServiceTest\:\:testUpdateUrlEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLServiceTest\:\:testUpdateUrlStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLServiceTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertSame\(\) with Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\URLWildcardTranslationResult and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\URLWildcardTranslationResult will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/lib/Event/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLWildcardServiceTest\:\:testCreateEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLWildcardServiceTest\:\:testCreateStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLWildcardServiceTest\:\:testRemoveEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLWildcardServiceTest\:\:testRemoveStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLWildcardServiceTest\:\:testReturnCreateResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLWildcardServiceTest\:\:testReturnTranslateResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLWildcardServiceTest\:\:testTranslateEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\URLWildcardServiceTest\:\:testTranslateStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/URLWildcardServiceTest.php - - - - message: '#^Parameter \#3 \$forward of method Ibexa\\Core\\Event\\URLWildcardService\:\:create\(\) expects bool, string given\.$#' - identifier: argument.type - count: 3 - path: tests/lib/Event/URLWildcardServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserPreferenceServiceTest\:\:testSetUserPreferenceEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserPreferenceServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserPreferenceServiceTest\:\:testSetUserPreferenceStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserPreferenceServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testAssignUserToUserGroupEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testAssignUserToUserGroupStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testCreateUserEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testCreateUserGroupEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testCreateUserGroupStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testCreateUserStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testDeleteUserEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testDeleteUserGroupEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testDeleteUserGroupStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testDeleteUserStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testMoveUserGroupEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testMoveUserGroupStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testReturnCreateUserGroupResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testReturnCreateUserResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testReturnDeleteUserGroupResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testReturnDeleteUserResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testReturnUpdateUserGroupResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testReturnUpdateUserResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testReturnUpdateUserTokenResultInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testUnAssignUserFromUserGroupEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testUnAssignUserFromUserGroupStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testUpdateUserEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testUpdateUserGroupEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testUpdateUserGroupStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testUpdateUserStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testUpdateUserTokenEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Event\\UserServiceTest\:\:testUpdateUserTokenStopPropagationInBeforeEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Event/UserServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\APIFieldTypeTest\:\:testValidateFieldSettings\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/APIFieldTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\APIFieldTypeTest\:\:testValidateFieldSettingsNoError\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/APIFieldTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\APIFieldTypeTest\:\:testValidateValidatorConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/APIFieldTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\APIFieldTypeTest\:\:testValidateValidatorConfigurationNoError\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/APIFieldTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\APIFieldTypeTest\:\:testValidateValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/APIFieldTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\APIFieldTypeTest\:\:testValidateValueNoError\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/APIFieldTypeTest.php - - - - message: '#^Access to an undefined property Ibexa\\Core\\FieldType\\Validator\\EmailAddressValidator\:\:\$Extent\.$#' - identifier: property.notFound - count: 4 - path: tests/lib/FieldType/EmailAddressValidatorTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Core\\\\FieldType\\\\Validator'' and Ibexa\\Core\\FieldType\\Validator\\EmailAddressValidator will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/lib/FieldType/EmailAddressValidatorTest.php - - - - message: '#^Access to an undefined property Ibexa\\Core\\FieldType\\Validator\\FileSizeValidator\:\:\$unexisting\.$#' - identifier: property.notFound - count: 2 - path: tests/lib/FieldType/FileSizeValidatorTest.php - - - - message: '#^Access to protected property Ibexa\\Contracts\\Core\\Repository\\Values\\Translation\\Message\:\:\$message\.$#' - identifier: property.protected - count: 1 - path: tests/lib/FieldType/FileSizeValidatorTest.php - - - - message: '#^Access to protected property Ibexa\\Contracts\\Core\\Repository\\Values\\Translation\\Message\:\:\$values\.$#' - identifier: property.protected - count: 1 - path: tests/lib/FieldType/FileSizeValidatorTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Core\\\\FieldType\\\\Validator'' and Ibexa\\Core\\FieldType\\Validator\\FileSizeValidator will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/lib/FieldType/FileSizeValidatorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\FileSizeValidatorTest\:\:providerForValidateKO\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/FileSizeValidatorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\FileSizeValidatorTest\:\:providerForValidateOK\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/FileSizeValidatorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\FileSizeValidatorTest\:\:testValidateCorrectValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/FileSizeValidatorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\FileSizeValidatorTest\:\:testValidateWrongValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/FileSizeValidatorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\FileSizeValidatorTest\:\:testValidateWrongValues\(\) has parameter \$message with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/FieldType/FileSizeValidatorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\FileSizeValidatorTest\:\:testValidateWrongValues\(\) has parameter \$size with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/FieldType/FileSizeValidatorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\FileSizeValidatorTest\:\:testValidateWrongValues\(\) has parameter \$values with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/FieldType/FileSizeValidatorTest.php - - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 3 - path: tests/lib/FieldType/FileSizeValidatorTest.php - - - - message: '#^Parameter \#1 \$value of class Ibexa\\Core\\FieldType\\Float\\Value constructor expects float\|null, string given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/FieldType/FloatTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\Generic\\Stubs\\Value\:\:__construct\(\) has parameter \$value with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/FieldType/Generic/Stubs/Value.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\Generic\\Stubs\\Value\:\:getValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/Generic/Stubs/Value.php - - - - message: '#^Property Ibexa\\Tests\\Core\\FieldType\\Generic\\Stubs\\Value\:\:\$value has no type specified\.$#' - identifier: missingType.property - count: 1 - path: tests/lib/FieldType/Generic/Stubs/Value.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\Image\\PathGenerator\\LegacyPathGeneratorTest\:\:provideStoragePathForFieldData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/Image/PathGenerator/LegacyPathGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\Image\\PathGenerator\\LegacyPathGeneratorTest\:\:testGetStoragePathForField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/Image/PathGenerator/LegacyPathGeneratorTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\FieldType\\ImageAsset\\AssetMapper\:\:expects\(\)\.$#' - identifier: method.notFound - count: 4 - path: tests/lib/FieldType/ImageAsset/AssetMapperTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Repository\\Values\\Content\\Content\:\:expects\(\)\.$#' - identifier: method.notFound - count: 2 - path: tests/lib/FieldType/ImageAsset/AssetMapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\ImageAsset\\AssetMapperTest\:\:createPartialMapper\(\) has parameter \$methods with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/FieldType/ImageAsset/AssetMapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\ImageAsset\\AssetMapperTest\:\:dataProviderForIsAsset\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/FieldType/ImageAsset/AssetMapperTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\FieldType\\ImageAsset\\AssetMapperTest\:\:\$mappings type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/FieldType/ImageAsset/AssetMapperTest.php - - - - message: '#^Parameter \#1 \$value of class Ibexa\\Core\\FieldType\\Integer\\Value constructor expects int\|null, string given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/FieldType/IntegerTest.php - - - - message: '#^Parameter \#1 \$contentId of method Ibexa\\Tests\\Core\\FieldType\\RelationListTest\:\:generateValidationError\(\) expects string, int given\.$#' - identifier: argument.type - count: 2 - path: tests/lib/FieldType/RelationListTest.php - - - - message: '#^Parameter \#1 \$value of method Ibexa\\Core\\FieldType\\RelationList\\Type\:\:getRelations\(\) expects Ibexa\\Core\\FieldType\\RelationList\\Value, Ibexa\\Core\\FieldType\\Value given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/FieldType/RelationListTest.php - - - - message: '#^Parameter \#1 \$fieldValue of method Ibexa\\Core\\FieldType\\Relation\\Type\:\:getRelations\(\) expects Ibexa\\Core\\FieldType\\Relation\\Value, Ibexa\\Core\\FieldType\\Value given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/FieldType/RelationTest.php - - - - message: '#^Parameter \#1 \$selection of class Ibexa\\Core\\FieldType\\Selection\\Value constructor expects array\, array\ given\.$#' - identifier: argument.type - count: 4 - path: tests/lib/FieldType/SelectionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\Url\\Gateway\\DoctrineStorageTest\:\:testGetIdUrlMap\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/Url/Gateway/DoctrineStorageTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\Url\\Gateway\\DoctrineStorageTest\:\:testGetUrlIdMap\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/Url/Gateway/DoctrineStorageTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\Url\\Gateway\\DoctrineStorageTest\:\:testInsertUrl\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/Url/Gateway/DoctrineStorageTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\Url\\Gateway\\DoctrineStorageTest\:\:testLinkUrl\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/Url/Gateway/DoctrineStorageTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\Url\\Gateway\\DoctrineStorageTest\:\:testUnlinkUrl\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/Url/Gateway/DoctrineStorageTest.php - - - - message: '#^Cannot access offset ''urlId'' on array\|bool\|float\|int\|string\|null\.$#' - identifier: offsetAccess.nonOffsetAccessible - count: 2 - path: tests/lib/FieldType/Url/UrlStorageTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\Url\\UrlStorageTest\:\:testDeleteFieldData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/Url/UrlStorageTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\Url\\UrlStorageTest\:\:testGetFieldData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/Url/UrlStorageTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\Url\\UrlStorageTest\:\:testGetFieldDataNotFound\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/Url/UrlStorageTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\Url\\UrlStorageTest\:\:testGetFieldDataWithEmptyUrlId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/Url/UrlStorageTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\Url\\UrlStorageTest\:\:testHasFieldData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/Url/UrlStorageTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\Url\\UrlStorageTest\:\:testStoreFieldDataWithEmptyUrl\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/Url/UrlStorageTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\Url\\UrlStorageTest\:\:testStoreFieldDataWithExistingUrl\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/Url/UrlStorageTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\Url\\UrlStorageTest\:\:testStoreFieldDataWithNewUrl\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/FieldType/Url/UrlStorageTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\FieldType\\Url\\UrlStorageTest\:\:\$gatewayMock \(Ibexa\\Core\\FieldType\\Url\\UrlStorage\\Gateway&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/FieldType/Url/UrlStorageTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\FieldType\\Url\\UrlStorageTest\:\:\$loggerMock \(PHPUnit\\Framework\\MockObject\\MockObject&Psr\\Log\\LoggerInterface\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/FieldType/Url/UrlStorageTest.php - - - - message: '#^Parameter \#1 \$link of class Ibexa\\Core\\FieldType\\Url\\Value constructor expects string\|null, int given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/FieldType/UrlTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\UserTest\:\:providerForTestCreatePersistenceValue\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/FieldType/UserTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\UserTest\:\:providerForTestValidate\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/FieldType/UserTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\UserTest\:\:testCreatePersistenceValue\(\) has parameter \$expectedFieldValueExternalData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/FieldType/UserTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\UserTest\:\:testCreatePersistenceValue\(\) has parameter \$userValueDate with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/FieldType/UserTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\FieldType\\UserTest\:\:testValidate\(\) has parameter \$expectedValidationErrors with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/FieldType/UserTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Core\\\\FieldType\\\\Validator'' and Ibexa\\Core\\FieldType\\Validator\\StringLengthValidator will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/lib/FieldType/Validator/StringLengthValidatorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\ContentInfoLocationLoader\\SudoMainLocationLoaderTest\:\:testLoadLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/ContentInfoLocationLoader/SudoMainLocationLoaderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\ContentInfoLocationLoader\\SudoMainLocationLoaderTest\:\:testLoadLocationError\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/ContentInfoLocationLoader/SudoMainLocationLoaderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\ContentInfoLocationLoader\\SudoMainLocationLoaderTest\:\:testLoadLocationNoMainLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/ContentInfoLocationLoader/SudoMainLocationLoaderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\ContentPreviewHelperTest\:\:testChangeConfigScope\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/ContentPreviewHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\ContentPreviewHelperTest\:\:testPreviewActive\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/ContentPreviewHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\ContentPreviewHelperTest\:\:testPreviewedContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/ContentPreviewHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\ContentPreviewHelperTest\:\:testPreviewedLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/ContentPreviewHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\ContentPreviewHelperTest\:\:testRestoreConfigScope\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/ContentPreviewHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\FieldHelperTest\:\:testIsFieldEmpty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/FieldHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\FieldHelperTest\:\:testIsFieldNotEmpty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/FieldHelperTest.php - - - - message: '#^Constant Ibexa\\Tests\\Core\\Helper\\FieldsGroups\\ArrayTranslatorFieldsGroupsListTest\:\:DEFAULT_GROUP_NAME is unused\.$#' - identifier: classConstant.unused - count: 1 - path: tests/lib/Helper/FieldsGroups/ArrayTranslatorFieldsGroupsListTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\FieldsGroups\\ArrayTranslatorFieldsGroupsListTest\:\:getArrayTranslatorFieldsGroupsList\(\) has parameter \$groups with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Helper/FieldsGroups/ArrayTranslatorFieldsGroupsListTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\FieldsGroups\\ArrayTranslatorFieldsGroupsListTest\:\:getFieldDefinitionMock\(\) has parameter \$constructorArgs with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Helper/FieldsGroups/ArrayTranslatorFieldsGroupsListTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Helper\\FieldsGroups\\ArrayTranslatorFieldsGroupsListTest\:\:\$translatorMock has no type specified\.$#' - identifier: missingType.property - count: 1 - path: tests/lib/Helper/FieldsGroups/ArrayTranslatorFieldsGroupsListTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\PreviewLocationProviderTest\:\:testGetPreviewLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/PreviewLocationProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\PreviewLocationProviderTest\:\:testGetPreviewLocationDraft\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/PreviewLocationProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\PreviewLocationProviderTest\:\:testGetPreviewLocationNoLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/PreviewLocationProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:getTranslatedField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:getTranslatedField\(\) has parameter \$prioritizedLanguages with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:getTranslatedFieldProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:getTranslatedNameProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:getTranslationSiteAccessProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetAvailableLanguagesWithTranslationSiteAccesses\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetAvailableLanguagesWithoutTranslationSiteAccesses\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetTranslatedName\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetTranslatedName\(\) has parameter \$prioritizedLanguages with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetTranslatedNameByContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetTranslatedNameByContentInfo\(\) has parameter \$prioritizedLanguages with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetTranslatedNameByContentInfoForcedLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetTranslatedNameByContentInfoForcedLanguageMainLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetTranslatedNameForcedLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetTranslationSiteAccess\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetTranslationSiteAccess\(\) has parameter \$expectedResult with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetTranslationSiteAccess\(\) has parameter \$language with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetTranslationSiteAccess\(\) has parameter \$relatedSiteAccesses with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetTranslationSiteAccess\(\) has parameter \$translationSiteAccesses with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetTranslationSiteAccessUnkownLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:\$siteAccessByLanguages has no type specified\.$#' - identifier: missingType.property - count: 1 - path: tests/lib/Helper/TranslationHelperTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\IO\\ConfigScopeChangeAwareIOServiceTest\:\:\$innerIOService \(Ibexa\\Core\\IO\\ConfigScopeChangeAwareIOService&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept Ibexa\\Core\\IO\\IOServiceInterface&PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: assign.propertyType - count: 1 - path: tests/lib/IO/ConfigScopeChangeAwareIOServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\FilePathNormalizer\\FlysystemTest\:\:providerForTestNormalizePath\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/IO/FilePathNormalizer/FlysystemTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\BaseVisibilityConverterTestCase\:\:getDataForTestForDirectory\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/IO/Flysystem/VisibilityConverter/BaseVisibilityConverterTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\BaseVisibilityConverterTestCase\:\:getDataForTestForFile\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/IO/Flysystem/VisibilityConverter/BaseVisibilityConverterTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\BaseVisibilityConverterTestCase\:\:getDataForTestInverseForDirectory\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/IO/Flysystem/VisibilityConverter/BaseVisibilityConverterTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\BaseVisibilityConverterTestCase\:\:getDataForTestInverseForFile\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/IO/Flysystem/VisibilityConverter/BaseVisibilityConverterTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\DFSVisibilityConverterTest\:\:getDataForTestForDirectory\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/IO/Flysystem/VisibilityConverter/DFSVisibilityConverterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\DFSVisibilityConverterTest\:\:getDataForTestForFile\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/IO/Flysystem/VisibilityConverter/DFSVisibilityConverterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\DFSVisibilityConverterTest\:\:getDataForTestInverseForDirectory\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/IO/Flysystem/VisibilityConverter/DFSVisibilityConverterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\DFSVisibilityConverterTest\:\:getDataForTestInverseForFile\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/IO/Flysystem/VisibilityConverter/DFSVisibilityConverterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\SiteAccessAwareVisibilityConverterTest\:\:getDataForTestForDirectory\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/IO/Flysystem/VisibilityConverter/SiteAccessAwareVisibilityConverterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\SiteAccessAwareVisibilityConverterTest\:\:getDataForTestForFile\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/IO/Flysystem/VisibilityConverter/SiteAccessAwareVisibilityConverterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\SiteAccessAwareVisibilityConverterTest\:\:getDataForTestInverseForDirectory\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/IO/Flysystem/VisibilityConverter/SiteAccessAwareVisibilityConverterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\SiteAccessAwareVisibilityConverterTest\:\:getDataForTestInverseForFile\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/IO/Flysystem/VisibilityConverter/SiteAccessAwareVisibilityConverterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\IOBinarydataHandler\\FlysystemTest\:\:testDelete\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/IO/IOBinarydataHandler/FlysystemTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\IOMetadataHandler\\FlysystemTest\:\:getDataForFileExists\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/IO/IOMetadataHandler/FlysystemTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\IOMetadataHandler\\FlysystemTest\:\:testDelete\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/IO/IOMetadataHandler/FlysystemTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\IO\\IOMetadataHandler\\FlysystemTest\:\:\$handler \(Ibexa\\Core\\IO\\IOMetadataHandler&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept Ibexa\\Core\\IO\\IOMetadataHandler\\Flysystem\.$#' - identifier: assign.propertyType - count: 1 - path: tests/lib/IO/IOMetadataHandler/FlysystemTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\UrlDecorator\\AbsolutePrefixTest\:\:provideData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/IO/UrlDecorator/AbsolutePrefixTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\UrlDecorator\\PrefixTest\:\:provideData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/IO/UrlDecorator/PrefixTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\UrlDecorator\\PrefixTest\:\:testDecorate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/IO/UrlDecorator/PrefixTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\UrlDecorator\\PrefixTest\:\:testDecorate\(\) has parameter \$decoratedUrl with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/IO/UrlDecorator/PrefixTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\UrlDecorator\\PrefixTest\:\:testDecorate\(\) has parameter \$prefix with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/IO/UrlDecorator/PrefixTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\UrlDecorator\\PrefixTest\:\:testDecorate\(\) has parameter \$url with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/IO/UrlDecorator/PrefixTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\UrlDecorator\\PrefixTest\:\:testUndecorate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/IO/UrlDecorator/PrefixTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\UrlDecorator\\PrefixTest\:\:testUndecorate\(\) has parameter \$decoratedUrl with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/IO/UrlDecorator/PrefixTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\UrlDecorator\\PrefixTest\:\:testUndecorate\(\) has parameter \$prefix with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/IO/UrlDecorator/PrefixTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\UrlDecorator\\PrefixTest\:\:testUndecorate\(\) has parameter \$url with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/IO/UrlDecorator/PrefixTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\UrlRedecoratorTest\:\:testRedecorateFromSource\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/IO/UrlRedecoratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\IO\\UrlRedecoratorTest\:\:testRedecorateFromTarget\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/IO/UrlRedecoratorTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\IO\\UrlRedecoratorTest\:\:\$redecorator \(Ibexa\\Core\\IO\\UrlRedecorator&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept Ibexa\\Core\\IO\\UrlRedecorator\.$#' - identifier: assign.propertyType - count: 1 - path: tests/lib/IO/UrlRedecoratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\Base\:\:getPersistenceMock\(\) has parameter \$mockMethods with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/Base.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\Base\:\:getUserMock\(\) has parameter \$mockMethods with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/Base.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:providerForTestEvaluateInvalidArgument\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:providerForTestValidateError\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:providerForTestValidatePass\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:testAcceptValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:testAcceptValueException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:testBuildValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:testEvaluate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:testEvaluate\(\) has parameter \$targets with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$targets with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:testGetCriterion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:testValidateError\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:testValidatePass\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:testValueSchema\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:providerForTestEvaluateInvalidArgument\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:providerForTestValidateError\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:providerForTestValidatePass\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:testAcceptValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:testAcceptValueException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:testBuildValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:testEvaluate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:testEvaluate\(\) has parameter \$expected with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:testEvaluate\(\) has parameter \$targets with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$targets with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:testGetCriterionInvalidValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:testGetCriterionMultipleValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:testGetCriterionSingleValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:testValidateError\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:testValidatePass\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:testValueSchema\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LanguageLimitation\\ContentDeleteEvaluatorTest\:\:dataProviderForAccept\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/LanguageLimitation/ContentDeleteEvaluatorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LanguageLimitation\\ContentDeleteEvaluatorTest\:\:dataProviderForEvaluate\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/LanguageLimitation/ContentDeleteEvaluatorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LanguageLimitation\\ContentDeleteEvaluatorTest\:\:getLanguageLimitation\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/LanguageLimitation/ContentDeleteEvaluatorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LanguageLimitation\\ContentDeleteEvaluatorTest\:\:getTergetVersion\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/LanguageLimitation/ContentDeleteEvaluatorTest.php - - - - message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\:\:\$id\.$#' - identifier: property.notFound - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:providerForTestEvaluateInvalidArgument\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:providerForTestValidateError\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:providerForTestValidatePass\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testAcceptValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testAcceptValueException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testBuildValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testEvaluate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testEvaluate\(\) has parameter \$expected with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testEvaluate\(\) has parameter \$persistenceLocations with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testEvaluate\(\) has parameter \$targets with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$persistenceLocations with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$targets with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testGetCriterionInvalidValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testGetCriterionMultipleValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testGetCriterionSingleValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testValidateError\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testValidatePass\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testValueSchema\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/LocationLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\MemberOfLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/MemberOfLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\MemberOfLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/MemberOfLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\MemberOfLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/MemberOfLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\MemberOfLimitationTypeTest\:\:providerForTestEvaluateSelfGroup\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/MemberOfLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\MemberOfLimitationTypeTest\:\:providerForTestValidateError\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/MemberOfLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\MemberOfLimitationTypeTest\:\:testEvaluateSelfGroup\(\) has parameter \$currentUserGroupLocations with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/MemberOfLimitationTypeTest.php - - - - message: '#^Method PHPUnit\\Framework\\MockObject\\Builder\\InvocationMocker\:\:willReturnOnConsecutiveCalls\(\) invoked with unpacked array with possibly string key, but it''s not allowed because of @no\-named\-arguments\.$#' - identifier: argument.named - count: 1 - path: tests/lib/Limitation/MemberOfLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:providerForTestEvaluateInvalidArgument\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:providerForTestValidateError\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:providerForTestValidatePass\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:testAcceptValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:testAcceptValueException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:testBuildValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:testEvaluate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:testEvaluate\(\) has parameter \$expected with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:testEvaluate\(\) has parameter \$targets with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$targets with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:testGetCriterion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:testValidateError\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:testValidatePass\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:testValueSchema\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ObjectStateLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ObjectStateLimitationTypeTest\:\:testEvaluate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ObjectStateLimitationTypeTest\:\:testEvaluate\(\) has parameter \$expected with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/ObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ObjectStateLimitationTypeTest\:\:testGetCriterionInvalidValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ObjectStateLimitationTypeTest\:\:testGetCriterionMultipleValuesFromMultipleGroups\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ObjectStateLimitationTypeTest\:\:testGetCriterionMultipleValuesFromSingleGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ObjectStateLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ObjectStateLimitationTypeTest\:\:testGetCriterionSingleValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ObjectStateLimitationTypeTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Limitation\\ObjectStateLimitationTypeTest\:\:\$loadObjectStatesMap type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ObjectStateLimitationTypeTest.php - - - - message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\:\:\$id\.$#' - identifier: property.notFound - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:assertContentHandlerExpectations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:assertContentHandlerExpectations\(\) has parameter \$callNo with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:assertContentHandlerExpectations\(\) has parameter \$contentId with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:assertContentHandlerExpectations\(\) has parameter \$contentInfo with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:assertContentHandlerExpectations\(\) has parameter \$persistenceCalled with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:getTestEvaluateContentMock\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:getTestEvaluateVersionInfoMock\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:providerForTestEvaluateInvalidArgument\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:providerForTestValidateError\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:providerForTestValidatePass\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:testAcceptValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:testAcceptValueException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:testBuildValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:testEvaluate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:testEvaluate\(\) has parameter \$expected with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:testEvaluate\(\) has parameter \$persistence with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:testEvaluate\(\) has parameter \$targets with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$targets with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:testGetCriterionInvalidValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:testValidateError\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:testValidatePass\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:testValueSchema\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - - - message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\:\:\$id\.$#' - identifier: property.notFound - count: 1 - path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:providerForTestEvaluateInvalidArgument\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:providerForTestValidatePass\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:testAcceptValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:testAcceptValueException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:testBuildValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:testEvaluate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:testEvaluate\(\) has parameter \$expected with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:testEvaluate\(\) has parameter \$persistenceLocations with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:testEvaluate\(\) has parameter \$targets with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$persistenceLocations with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$targets with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:testValidatePass\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - - - message: '#^Instanceof between Ibexa\\Core\\Repository\\Values\\User\\UserRoleAssignment and Ibexa\\Core\\Repository\\Values\\User\\User will always evaluate to false\.$#' - identifier: instanceof.alwaysFalse - count: 1 - path: tests/lib/Limitation/RoleLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\RoleLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/RoleLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\RoleLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/RoleLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\RoleLimitationTypeTest\:\:providerForTestEvaluate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/RoleLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\RoleLimitationTypeTest\:\:providerForTestValidateError\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/RoleLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\RoleLimitationTypeTest\:\:testEvaluate\(\) has parameter \$targets with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/RoleLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/SectionLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/SectionLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/SectionLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:providerForTestEvaluateInvalidArgument\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/SectionLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:providerForTestValidateError\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/SectionLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:providerForTestValidatePass\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/SectionLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:testAcceptValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SectionLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:testAcceptValueException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SectionLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:testBuildValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SectionLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:testEvaluate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SectionLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:testEvaluate\(\) has parameter \$expected with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/SectionLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:testEvaluate\(\) has parameter \$targets with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/SectionLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SectionLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$targets with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/SectionLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:testGetCriterionInvalidValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SectionLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:testGetCriterionMultipleValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SectionLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:testGetCriterionSingleValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SectionLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:testValidateError\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SectionLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:testValidatePass\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SectionLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:testValueSchema\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SectionLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SiteAccessLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/SiteAccessLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SiteAccessLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/SiteAccessLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SiteAccessLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/SiteAccessLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SiteAccessLimitationTypeTest\:\:providerForTestEvaluateInvalidArgument\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/SiteAccessLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SiteAccessLimitationTypeTest\:\:providerForTestValidateError\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/SiteAccessLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SiteAccessLimitationTypeTest\:\:testAcceptValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SiteAccessLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SiteAccessLimitationTypeTest\:\:testAcceptValueException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SiteAccessLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SiteAccessLimitationTypeTest\:\:testBuildValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SiteAccessLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SiteAccessLimitationTypeTest\:\:testEvaluate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SiteAccessLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SiteAccessLimitationTypeTest\:\:testEvaluate\(\) has parameter \$expected with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/SiteAccessLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SiteAccessLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SiteAccessLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SiteAccessLimitationTypeTest\:\:testGetCriterion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SiteAccessLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SiteAccessLimitationTypeTest\:\:testValidateError\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SiteAccessLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SiteAccessLimitationTypeTest\:\:testValueSchema\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SiteAccessLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:getContentMock\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/StatusLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:getVersionInfoMock\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/StatusLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:getVersionInfoMock\(\) has parameter \$shouldBeCalled with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/StatusLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/StatusLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/StatusLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/StatusLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:providerForTestEvaluateInvalidArgument\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/StatusLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:providerForTestValidateError\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/StatusLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:testAcceptValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/StatusLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:testAcceptValueException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/StatusLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:testBuildValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/StatusLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:testEvaluate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/StatusLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:testEvaluate\(\) has parameter \$expected with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/StatusLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/StatusLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:testGetCriterion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/StatusLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:testValidateError\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/StatusLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:testValueSchema\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/StatusLimitationTypeTest.php - - - - message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\:\:\$id\.$#' - identifier: property.notFound - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:providerForTestEvaluateInvalidArgument\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:providerForTestValidateError\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:providerForTestValidatePass\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testAcceptValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testAcceptValueException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testBuildValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testEvaluate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testEvaluate\(\) has parameter \$expected with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testEvaluate\(\) has parameter \$persistenceLocations with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testEvaluate\(\) has parameter \$targets with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$persistenceLocations with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$targets with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testGetCriterionInvalidValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testGetCriterionMultipleValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testGetCriterionSingleValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testValidateError\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testValidateErrorWrongPath\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testValidatePass\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testValueSchema\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Controller\\ControllerTest\:\:testRender\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Controller/ControllerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Controller\\ControllerTest\:\:testRenderWithResponse\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Controller/ControllerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Event\\RouteReferenceGenerationEventTest\:\:testConstruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Event/RouteReferenceGenerationEventTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Event\\RouteReferenceGenerationEventTest\:\:testGetSet\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Event/RouteReferenceGenerationEventTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Event\\ScopeChangeEventTest\:\:testGetSiteAccess\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Event/ScopeChangeEventTest.php - - - - message: '#^Method Ibexa\\Contracts\\Core\\MVC\\View\\VariableProvider@anonymous/tests/lib/MVC/Symfony/EventListener/ContentViewTwigVariablesSubscriberTest\.php\:47\:\:getTwigVariables\(\) has parameter \$options with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/EventListener/ContentViewTwigVariablesSubscriberTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\EventListener\\ContentViewTwigVariablesSubscriberTest\:\:getRegistry\(\) has parameter \$providers with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/EventListener/ContentViewTwigVariablesSubscriberTest.php - - - - message: '#^Property Ibexa\\Contracts\\Core\\MVC\\View\\VariableProvider@anonymous/tests/lib/MVC/Symfony/EventListener/ContentViewTwigVariablesSubscriberTest\.php\:47\:\:\$identifier has no type specified\.$#' - identifier: missingType.property - count: 1 - path: tests/lib/MVC/Symfony/EventListener/ContentViewTwigVariablesSubscriberTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\EventListener\\LanguageSwitchListenerTest\:\:testGetSubscribedEvents\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/EventListener/LanguageSwitchListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\EventListener\\LanguageSwitchListenerTest\:\:testOnRouteReferenceGeneration\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/EventListener/LanguageSwitchListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\EventListener\\LanguageSwitchListenerTest\:\:testOnRouteReferenceGenerationNoLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/EventListener/LanguageSwitchListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\EventListener\\LanguageSwitchListenerTest\:\:testOnRouteReferenceGenerationNoTranslationSiteAccess\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/EventListener/LanguageSwitchListenerTest.php - - - - message: '#^Parameter \#1 \$translationHelper of class Ibexa\\Core\\MVC\\Symfony\\EventListener\\LanguageSwitchListener constructor expects Ibexa\\Core\\Helper\\TranslationHelper, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type - count: 3 - path: tests/lib/MVC/Symfony/EventListener/LanguageSwitchListenerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\ImageAsset\\ParameterProviderTest\:\:dataProviderForTestGetViewParameters\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/FieldType/ImageAsset/ParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\ImageAsset\\ParameterProviderTest\:\:testGetViewParameters\(\) has parameter \$expected with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/FieldType/ImageAsset/ParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\ImageAsset\\ParameterProviderTest\:\:testGetViewParameters\(\) has parameter \$status with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/FieldType/ImageAsset/ParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\Relation\\ParameterProviderTest\:\:providerForTestGetViewParameters\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/FieldType/Relation/ParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\Relation\\ParameterProviderTest\:\:testGetViewParameters\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/FieldType/Relation/ParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\Relation\\ParameterProviderTest\:\:testGetViewParameters\(\) has parameter \$expected with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/FieldType/Relation/ParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\Relation\\ParameterProviderTest\:\:testGetViewParameters\(\) has parameter \$status with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/FieldType/Relation/ParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\Relation\\ParameterProviderTest\:\:testNotFoundGetViewParameters\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/FieldType/Relation/ParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\Relation\\ParameterProviderTest\:\:testUnauthorizedGetViewParameters\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/FieldType/Relation/ParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\RelationList\\ParameterProviderTest\:\:providerForTestGetViewParameters\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/FieldType/RelationList/ParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\RelationList\\ParameterProviderTest\:\:testGetViewParameters\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/FieldType/RelationList/ParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\RelationList\\ParameterProviderTest\:\:testGetViewParameters\(\) has parameter \$desinationContentIds with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/FieldType/RelationList/ParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\RelationList\\ParameterProviderTest\:\:testGetViewParameters\(\) has parameter \$expected with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/FieldType/RelationList/ParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\RelationList\\ParameterProviderTest\:\:testNotFoundGetViewParameters\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/FieldType/RelationList/ParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\RelationList\\ParameterProviderTest\:\:testUnauthorizedGetViewParameters\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/FieldType/RelationList/ParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\View\\ParameterProvider\\LocaleParameterProviderTest\:\:getLocaleConverterMock\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/FieldType/View/ParameterProvider/LocaleParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\View\\ParameterProvider\\LocaleParameterProviderTest\:\:getRequestStackMock\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/FieldType/View/ParameterProvider/LocaleParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\View\\ParameterProvider\\LocaleParameterProviderTest\:\:getRequestStackMock\(\) has parameter \$hasLocale with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/FieldType/View/ParameterProvider/LocaleParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\View\\ParameterProvider\\LocaleParameterProviderTest\:\:providerForTestGetViewParameters\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/FieldType/View/ParameterProvider/LocaleParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\View\\ParameterProvider\\LocaleParameterProviderTest\:\:testGetViewParameters\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/FieldType/View/ParameterProvider/LocaleParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\View\\ParameterProvider\\LocaleParameterProviderTest\:\:testGetViewParameters\(\) has parameter \$expectedLocale with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/FieldType/View/ParameterProvider/LocaleParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\View\\ParameterProvider\\LocaleParameterProviderTest\:\:testGetViewParameters\(\) has parameter \$hasRequestLocale with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/FieldType/View/ParameterProvider/LocaleParameterProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\View\\ParameterProviderRegistryTest\:\:testGetParameterProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/FieldType/View/ParameterProviderRegistryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\View\\ParameterProviderRegistryTest\:\:testGetParameterProviderFail\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/FieldType/View/ParameterProviderRegistryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\View\\ParameterProviderRegistryTest\:\:testSetHasParameterProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/FieldType/View/ParameterProviderRegistryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Locale\\LocaleConverterTest\:\:convertToPOSIXProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/Locale/LocaleConverterTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\Locale\\LocaleConverterTest\:\:\$conversionMap \(array\{array\{string, string\|null\}\}\) does not accept array\{eng\-GB\: ''en_GB'', eng\-US\: ''en_US'', fre\-FR\: ''fr_FR'', ger\-DE\: ''de_DE'', nor\-NO\: ''no_NO'', cro\-HR\: ''hr_HR''\}\.$#' - identifier: assign.propertyType - count: 1 - path: tests/lib/MVC/Symfony/Locale/LocaleConverterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\BaseTestCase\:\:getContentInfoMock\(\) has parameter \$properties with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/BaseTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\BaseTestCase\:\:getLocationMock\(\) has parameter \$properties with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/BaseTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\BaseTestCase\:\:getPartiallyMockedViewProvider\(\) has parameter \$matchingConfig with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/BaseTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\BaseTestCase\:\:getPermissionResolverMock\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/BaseTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\DepthTest\:\:matchContentInfoProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/DepthTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\DepthTest\:\:matchLocationProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/DepthTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\DepthTest\:\:testMatchContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/DepthTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\DepthTest\:\:testMatchLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/DepthTest.php - - - - message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Depth\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/DepthTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ContentTest\:\:matchContentInfoProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ContentTest\:\:matchLocationProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ContentTest\:\:testMatchContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ContentTest\:\:testMatchLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ContentTypeGroupTest\:\:matchContentInfoProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeGroupTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ContentTypeGroupTest\:\:matchLocationProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeGroupTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ContentTypeGroupTest\:\:testMatchContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeGroupTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ContentTypeGroupTest\:\:testMatchLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeGroupTest.php - - - - message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ContentTypeGroup\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeGroupTest.php - - - - message: '#^Parameter \#1 \$location of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ContentTypeGroup\:\:matchLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeGroupTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ContentTypeTest\:\:matchContentInfoProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ContentTypeTest\:\:matchLocationProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ContentTypeTest\:\:testMatchContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ContentTypeTest\:\:testMatchLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\LocationTest\:\:matchContentInfoProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/LocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\LocationTest\:\:matchLocationProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/LocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\LocationTest\:\:testMatchContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/LocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\LocationTest\:\:testMatchLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/LocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ParentContentTypeTest\:\:matchLocationProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentContentTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ParentContentTypeTest\:\:testMatchContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentContentTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ParentContentTypeTest\:\:testMatchLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentContentTypeTest.php - - - - message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ParentContentType\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentContentTypeTest.php - - - - message: '#^Parameter \#1 \$location of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ParentContentType\:\:matchLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentContentTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ParentLocationTest\:\:matchContentInfoProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ParentLocationTest\:\:matchLocationProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ParentLocationTest\:\:testMatchContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ParentLocationTest\:\:testMatchLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentLocationTest.php - - - - message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ParentLocation\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentLocationTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\RemoteTest\:\:matchContentInfoProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/RemoteTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\RemoteTest\:\:matchLocationProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/RemoteTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\RemoteTest\:\:testMatchContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/RemoteTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\RemoteTest\:\:testMatchLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/RemoteTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\SectionTest\:\:matchContentInfoProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/SectionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\SectionTest\:\:matchLocationProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/SectionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\SectionTest\:\:testMatchContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/SectionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\SectionTest\:\:testMatchLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/SectionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\ContentTypeTest\:\:matchContentInfoProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ContentTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\ContentTypeTest\:\:matchLocationProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ContentTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\ContentTypeTest\:\:testMatchContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ContentTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\ContentTypeTest\:\:testMatchLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ContentTypeTest.php - - - - message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\ContentType\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ContentTypeTest.php - - - - message: '#^Parameter \#1 \$contentTypeIdentifier of method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\ContentTypeTest\:\:generateRepositoryMockForContentTypeIdentifier\(\) expects int, string given\.$#' - identifier: argument.type - count: 8 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ContentTypeTest.php - - - - message: '#^Parameter \#1 \$location of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\ContentType\:\:matchLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ContentTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\ParentContentTypeTest\:\:matchLocationProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ParentContentTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\ParentContentTypeTest\:\:testMatchContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ParentContentTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\ParentContentTypeTest\:\:testMatchLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ParentContentTypeTest.php - - - - message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\ParentContentType\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ParentContentTypeTest.php - - - - message: '#^Parameter \#1 \$location of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\ParentContentType\:\:matchLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ParentContentTypeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\SectionTest\:\:matchSectionProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/SectionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\SectionTest\:\:testMatchContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/SectionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\SectionTest\:\:testMatchLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/SectionTest.php - - - - message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\Section\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/SectionTest.php - - - - message: '#^Parameter \#1 \$location of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\Section\:\:matchLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/SectionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\MultipleValuedTest\:\:getMultipleValuedMatcherMock\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/MultipleValuedTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\MultipleValuedTest\:\:matchingConfigProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/MultipleValuedTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\MultipleValuedTest\:\:testInjectRepository\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/MultipleValuedTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\MultipleValuedTest\:\:testSetMatchingConfig\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/MultipleValuedTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\MultipleValuedTest\:\:testSetMatchingConfig\(\) has parameter \$matchingConfig with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/MultipleValuedTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\UrlAliasTest\:\:matchLocationProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/UrlAliasTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\UrlAliasTest\:\:setMatchingConfigProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/UrlAliasTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\UrlAliasTest\:\:testMatchContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/UrlAliasTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\UrlAliasTest\:\:testMatchLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/UrlAliasTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\UrlAliasTest\:\:testSetMatchingConfig\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/UrlAliasTest.php - - - - message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\UrlAlias\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/UrlAliasTest.php - - - - message: '#^Parameter \#1 \$location of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\UrlAlias\:\:matchLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/MVC/Symfony/Matcher/ContentBased/UrlAliasTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ConfigurableMatcherFactoryInterface\:\:expects\(\)\.$#' - identifier: method.notFound - count: 1 - path: tests/lib/MVC/Symfony/Matcher/DynamicallyConfiguredMatcherFactoryDecoratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\DynamicallyConfiguredMatcherFactoryDecoratorTest\:\:matchConfigProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/Matcher/DynamicallyConfiguredMatcherFactoryDecoratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\DynamicallyConfiguredMatcherFactoryDecoratorTest\:\:testMatch\(\) has parameter \$matchedConfig with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Matcher/DynamicallyConfiguredMatcherFactoryDecoratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\DynamicallyConfiguredMatcherFactoryDecoratorTest\:\:testMatch\(\) has parameter \$namespace with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Matcher/DynamicallyConfiguredMatcherFactoryDecoratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\DynamicallyConfiguredMatcherFactoryDecoratorTest\:\:testMatch\(\) has parameter \$parameterName with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Matcher/DynamicallyConfiguredMatcherFactoryDecoratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\DynamicallyConfiguredMatcherFactoryDecoratorTest\:\:testMatch\(\) has parameter \$scope with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Matcher/DynamicallyConfiguredMatcherFactoryDecoratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\DynamicallyConfiguredMatcherFactoryDecoratorTest\:\:testMatch\(\) has parameter \$viewsConfiguration with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Matcher/DynamicallyConfiguredMatcherFactoryDecoratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\GeneratorTest\:\:generateProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/GeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\GeneratorTest\:\:testGenerateWithSiteAccessNoReverseMatch\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/GeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\GeneratorTest\:\:testGenerateWithSiteAccessNoReverseMatch\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/Routing/GeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\GeneratorTest\:\:testGenerateWithSiteAccessNoReverseMatch\(\) has parameter \$referenceType with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Routing/GeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\GeneratorTest\:\:testGenerateWithSiteAccessNoReverseMatch\(\) has parameter \$urlResource with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Routing/GeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\GeneratorTest\:\:testSimpleGenerate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/GeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\GeneratorTest\:\:testSimpleGenerate\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/Routing/GeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\GeneratorTest\:\:testSimpleGenerate\(\) has parameter \$referenceType with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Routing/GeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\GeneratorTest\:\:testSimpleGenerate\(\) has parameter \$urlResource with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Routing/GeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\RouteReferenceGeneratorTest\:\:generateGenerator\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/RouteReferenceGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\RouteReferenceGeneratorTest\:\:testGenerate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/RouteReferenceGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\RouteReferenceGeneratorTest\:\:testGenerate\(\) has parameter \$params with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/Routing/RouteReferenceGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\RouteReferenceGeneratorTest\:\:testGenerate\(\) has parameter \$resource with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Routing/RouteReferenceGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\RouteReferenceGeneratorTest\:\:testGenerateNullResource\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/RouteReferenceGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\RouteReferenceGeneratorTest\:\:testGenerateNullResourceAndPassedParams\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/RouteReferenceGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\RouteReferenceGeneratorTest\:\:testGenerateNullResourceWithoutRoute\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/RouteReferenceGeneratorTest.php - - - - message: '#^Parameter \#1 \$dispatcher of class Ibexa\\Core\\MVC\\Symfony\\Routing\\Generator\\RouteReferenceGenerator constructor expects Symfony\\Component\\EventDispatcher\\EventDispatcherInterface, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type - count: 4 - path: tests/lib/MVC/Symfony/Routing/RouteReferenceGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\RouteReferenceTest\:\:testConstruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/RouteReferenceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\RouteReferenceTest\:\:testGetSetParams\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/RouteReferenceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\RouteReferenceTest\:\:testGetSetRoute\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/RouteReferenceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\RouteReferenceTest\:\:testRemoveParam\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/RouteReferenceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\SimplifiedRequestTest\:\:fromUrlProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/SimplifiedRequestTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\SimplifiedRequestTest\:\:testFromUrl\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/SimplifiedRequestTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:getPermissionResolverMock\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:providerTestDoGenerate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:providerTestDoGenerateRootLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:providerTestDoGenerateWithSiteaccess\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:providerTestIsPrefixExcluded\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testDoGenerate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testDoGenerate\(\) has parameter \$expected with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testDoGenerate\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testDoGenerateNoUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testDoGenerateRootLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testDoGenerateRootLocation\(\) has parameter \$expected with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testDoGenerateRootLocation\(\) has parameter \$isOutsideAndNotExcluded with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testDoGenerateRootLocation\(\) has parameter \$pathPrefix with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testDoGenerateWithSiteAccessParam\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testDoGenerateWithSiteAccessParam\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testGetPathPrefixByRootLocationId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testIsPrefixExcluded\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testIsPrefixExcluded\(\) has parameter \$expectedIsExcluded with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testIsPrefixExcluded\(\) has parameter \$uri with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testLoadLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:getRequestByPathInfo\(\) has parameter \$pathInfo with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:providerTestSupports\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testGenerateFail\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testGenerateInvalidLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testGenerateNoLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testGenerateWithContentId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testGenerateWithContentIdWithMissingMainLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testGenerateWithLocationAsParameter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testGenerateWithLocationId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testGetRouteCollection\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testMatch\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testMatchRequestFail\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testMatchRequestLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testMatchRequestLocationCorrectCaseUriPrefixExcluded\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testMatchRequestLocationCustom\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testMatchRequestLocationCustomForward\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testMatchRequestLocationHistory\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testMatchRequestLocationWithCaseRedirect\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testMatchRequestLocationWrongCaseUriPrefixExcluded\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testMatchRequestResource\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testMatchRequestResourceCaseIncorrectWithForwardRedirect\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testMatchRequestResourceWithCaseRedirect\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testMatchRequestResourceWithRedirect\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testMatchRequestVirtual\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testMatchRequestVirtualWithCaseRedirect\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testRequestContext\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testSupports\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testSupports\(\) has parameter \$isSupported with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testSupports\(\) has parameter \$routeReference with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:\$requestContext has no type specified\.$#' - identifier: missingType.property - count: 1 - path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:checkRequestPathProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:generateUriProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:generateUriStandardProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testCheckRequestPath\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testCheckRequestPath\(\) has parameter \$expected with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testCheckRequestPath\(\) has parameter \$path with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testCheckRequestPath\(\) has parameter \$requestUri with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testCheckRequestPath\(\) has parameter \$siteAccessUri with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testCheckRequestPathStandard\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testGenerateUri\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testGenerateUri\(\) has parameter \$expected with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testGenerateUri\(\) has parameter \$isUriRouteName with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testGenerateUri\(\) has parameter \$siteAccessUri with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testGenerateUri\(\) has parameter \$uri with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testGenerateUriStandard\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testGenerateUriStandard\(\) has parameter \$expected with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testGenerateUriStandard\(\) has parameter \$isUriRouteName with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testGenerateUriStandard\(\) has parameter \$uri with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - - - message: '#^Property Ibexa\\Core\\MVC\\Symfony\\SiteAccess\:\:\$matcher \(Ibexa\\Core\\MVC\\Symfony\\SiteAccess\\Matcher\) does not accept Ibexa\\Core\\MVC\\Symfony\\SiteAccess\\URILexer&PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: assign.propertyType - count: 2 - path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - - - message: '#^Parameter \#1 \$expirationDate of class Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PasswordInfo constructor expects DateTimeImmutable\|null, DateTimeImmutable\|false given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/MVC/Symfony/Security/UserCheckerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\UserTest\:\:testConstruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/UserTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\UserTest\:\:testIsEqualTo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/UserTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\UserTest\:\:testIsEqualToNotSameUserType\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/UserTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\UserTest\:\:testIsNotEqualTo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/UserTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\UserTest\:\:testSetAPIUser\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/UserTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\UserWrappedTest\:\:testIsEqualTo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/UserWrappedTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\CoreVoterTest\:\:supportsAttributeProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\CoreVoterTest\:\:supportsClassProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\CoreVoterTest\:\:testSupportsAttribute\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\CoreVoterTest\:\:testSupportsAttribute\(\) has parameter \$attribute with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\CoreVoterTest\:\:testSupportsAttribute\(\) has parameter \$expectedResult with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\CoreVoterTest\:\:testSupportsClass\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\CoreVoterTest\:\:testSupportsClass\(\) has parameter \$class with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\CoreVoterTest\:\:testVote\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\CoreVoterTest\:\:testVote\(\) has parameter \$expectedResult with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\CoreVoterTest\:\:testVote\(\) has parameter \$repositoryCanUser with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\CoreVoterTest\:\:testVoteInvalidAttribute\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\CoreVoterTest\:\:testVoteInvalidAttribute\(\) has parameter \$attributes with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\CoreVoterTest\:\:voteInvalidAttributeProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\CoreVoterTest\:\:voteProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\ValueObjectVoterTest\:\:supportsAttributeProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\ValueObjectVoterTest\:\:supportsClassProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\ValueObjectVoterTest\:\:testSupportsAttribute\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\ValueObjectVoterTest\:\:testSupportsAttribute\(\) has parameter \$attribute with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\ValueObjectVoterTest\:\:testSupportsAttribute\(\) has parameter \$expectedResult with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\ValueObjectVoterTest\:\:testSupportsClass\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\ValueObjectVoterTest\:\:testSupportsClass\(\) has parameter \$class with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\ValueObjectVoterTest\:\:testVote\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\ValueObjectVoterTest\:\:testVote\(\) has parameter \$expectedResult with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\ValueObjectVoterTest\:\:testVote\(\) has parameter \$repositoryCanUser with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\ValueObjectVoterTest\:\:testVoteInvalidAttribute\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\ValueObjectVoterTest\:\:testVoteInvalidAttribute\(\) has parameter \$attributes with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\ValueObjectVoterTest\:\:voteInvalidAttributeProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\ValueObjectVoterTest\:\:voteProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\Compound\\CompoundAndTest\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/Compound/CompoundAndTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\Compound\\CompoundAndTest\:\:testMatch\(\) has parameter \$expectedMatch with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/Compound/CompoundAndTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\Compound\\CompoundOrTest\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/Compound/CompoundOrTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\Provider\\ChainSiteAccessProviderTest\:\:getExistingSiteProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/Provider/ChainSiteAccessProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\Provider\\ChainSiteAccessProviderTest\:\:siteAccessNamesProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/Provider/ChainSiteAccessProviderTest.php - - - - message: '#^Parameter \#2 \$groupsBySiteAccess of class Ibexa\\Core\\MVC\\Symfony\\SiteAccess\\Provider\\StaticSiteAccessProvider constructor expects array\, array\\> given\.$#' - identifier: argument.type - count: 2 - path: tests/lib/MVC/Symfony/SiteAccess/Provider/ChainSiteAccessProviderTest.php - - - - message: '#^Property Ibexa\\Core\\MVC\\Symfony\\SiteAccess\:\:\$groups \(array\\) does not accept array\\.$#' - identifier: assign.propertyType - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/Provider/ChainSiteAccessProviderTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\Provider\\ChainSiteAccessProviderTest\:\:\$groupsBySiteAccess type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/Provider/ChainSiteAccessProviderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterBaseTestCase\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterBaseTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterBaseTestCase\:\:testMatch\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterBaseTestCase.php - - - - message: '#^Class Ibexa\\Core\\MVC\\Symfony\\SiteAccess\\Matcher\\Map\\Host constructor invoked with 2 parameters, 1 required\.$#' - identifier: arguments.count - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostElementTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostElementTest\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostElementTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostElementTest\:\:reverseMatchProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostElementTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostElementTest\:\:testGetName\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostElementTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostElementTest\:\:testReverseMatch\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostElementTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostElementTest\:\:testReverseMatch\(\) has parameter \$elementNumber with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostElementTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostElementTest\:\:testReverseMatch\(\) has parameter \$expectedHost with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostElementTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostElementTest\:\:testReverseMatch\(\) has parameter \$siteAccessName with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostElementTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostElementTest\:\:testReverseMatchFail\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostElementTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostElementTest\:\:testSerialize\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostElementTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostPortURITest\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostPortURITest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostPortURITest\:\:testReverseHostMatchFail\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostPortURITest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostPortURITest\:\:testReverseMatchHost\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostPortURITest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostPortURITest\:\:testReverseMatchPort\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostPortURITest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostPortURITest\:\:testReversePortMatchFail\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostPortURITest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostPortURITest\:\:testSetGetRequestMapHost\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostPortURITest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostPortURITest\:\:testSetGetRequestMapPort\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostPortURITest.php - - - - message: '#^Parameter \#1 \$map of class Ibexa\\Core\\MVC\\Symfony\\SiteAccess\\Matcher\\Map\\Port constructor expects array\, array\ given\.$#' - identifier: argument.type - count: 2 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostPortURITest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Core\\\\MVC\\\\Symfony\\\\Routing\\\\SimplifiedRequest'' and Ibexa\\Core\\MVC\\Symfony\\Routing\\SimplifiedRequest will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostTextTest.php - - - - message: '#^Class Ibexa\\Core\\MVC\\Symfony\\SiteAccess\\Matcher\\HostText constructor invoked with 2 parameters, 1 required\.$#' - identifier: arguments.count - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostTextTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostTextTest\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostTextTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostTextTest\:\:testGetName\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostTextTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostTextTest\:\:testReverseMatch\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterHostTextTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterMapURITest\:\:fixupURIProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterMapURITest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterMapURITest\:\:setRequestProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterMapURITest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterMapURITest\:\:testAnalyseLink\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterMapURITest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterMapURITest\:\:testAnalyseURI\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterMapURITest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterMapURITest\:\:testReverseMatch\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterMapURITest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterMapURITest\:\:testReverseMatchFail\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterMapURITest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterMapURITest\:\:testSetGetRequest\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterMapURITest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterMapURITest\:\:testSetGetRequest\(\) has parameter \$config with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterMapURITest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterPortHostURITest\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterPortHostURITest.php - - - - message: '#^Class Ibexa\\Core\\MVC\\Symfony\\SiteAccess\\Matcher\\Map\\Port constructor invoked with 2 parameters, 1 required\.$#' - identifier: arguments.count - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterSpecialPortsTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterSpecialPortsTest\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterSpecialPortsTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterSpecialPortsTest\:\:testGetName\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterSpecialPortsTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterTest\:\:createRouter\(\) has parameter \$debug with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterTest\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterTest\:\:testConstructDebug\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterTest\:\:testMatch\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterTest\:\:testMatch\(\) has parameter \$siteAccess with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterTest\:\:testMatchByName\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterTest\:\:testMatchByNameInvalidSiteAccess\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterTest\:\:testMatchByNameNoVersatileMatcher\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterTest\:\:testMatchWithDevEnvFail\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterTest\:\:testMatchWithEnv\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterTest\:\:testMatchWithProdEnvFail\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElement2Test\:\:analyseProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElement2Test.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElement2Test\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElement2Test.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElement2Test\:\:reverseMatchProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElement2Test.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElement2Test\:\:testAnalyseLink\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElement2Test.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElement2Test\:\:testAnalyseURI\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElement2Test.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElement2Test\:\:testAnalyseURILevelAsInt\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElement2Test.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElement2Test\:\:testReverseMatch\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElement2Test.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElement2Test\:\:testReverseMatch\(\) has parameter \$originalPathinfo with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElement2Test.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElement2Test\:\:testReverseMatch\(\) has parameter \$siteAccessName with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElement2Test.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElement2Test\:\:testReverseMatchFail\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElement2Test.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElement2Test\:\:testSerialize\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElement2Test.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElementTest\:\:analyseProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElementTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElementTest\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElementTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElementTest\:\:reverseMatchProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElementTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElementTest\:\:testAnalyseLink\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElementTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElementTest\:\:testAnalyseURI\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElementTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElementTest\:\:testGetName\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElementTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElementTest\:\:testReverseMatch\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElementTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElementTest\:\:testReverseMatch\(\) has parameter \$originalPathinfo with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElementTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElementTest\:\:testReverseMatch\(\) has parameter \$siteAccessName with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElementTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElementTest\:\:testSerialize\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElementTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Core\\\\MVC\\\\Symfony\\\\Routing\\\\SimplifiedRequest'' and Ibexa\\Core\\MVC\\Symfony\\Routing\\SimplifiedRequest will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURITextTest.php - - - - message: '#^Class Ibexa\\Core\\MVC\\Symfony\\SiteAccess\\Matcher\\URIText constructor invoked with 2 parameters, 1 required\.$#' - identifier: arguments.count - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURITextTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURITextTest\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURITextTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURITextTest\:\:testAnalyseLink\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURITextTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURITextTest\:\:testAnalyseURI\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURITextTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURITextTest\:\:testGetName\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURITextTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURITextTest\:\:testReverseMatch\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/RouterURITextTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\SiteAccessServiceTest\:\:getAvailableSitAccesses\(\) return type with generic class ArrayIterator does not specify its types\: TKey, TValue$#' - identifier: missingType.generics - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/SiteAccessServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\SiteAccessServiceTest\:\:getConfigResolverParameters\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/SiteAccessServiceTest.php - - - - message: '#^Parameter \#2 \$groupsBySiteAccess of class Ibexa\\Core\\MVC\\Symfony\\SiteAccess\\Provider\\StaticSiteAccessProvider constructor expects array\, array\\> given\.$#' - identifier: argument.type - count: 2 - path: tests/lib/MVC/Symfony/SiteAccess/SiteAccessServiceTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\SiteAccessServiceTest\:\:\$availableSiteAccesses with generic class ArrayIterator does not specify its types\: TKey, TValue$#' - identifier: missingType.generics - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/SiteAccessServiceTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\SiteAccessServiceTest\:\:\$configResolverParameters type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/SiteAccess/SiteAccessServiceTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\GlobalHelperTest\:\:testGetAvailableLanguages\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Templating/GlobalHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\GlobalHelperTest\:\:testGetConfigResolver\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Templating/GlobalHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\GlobalHelperTest\:\:testGetRequestedUriString\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Templating/GlobalHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\GlobalHelperTest\:\:testGetRootLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Templating/GlobalHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\GlobalHelperTest\:\:testGetSiteaccess\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Templating/GlobalHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\GlobalHelperTest\:\:testGetSystemUriString\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Templating/GlobalHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\GlobalHelperTest\:\:testGetSystemUriStringNoUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Templating/GlobalHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\GlobalHelperTest\:\:testGetTranslationSiteAccess\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Templating/GlobalHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\GlobalHelperTest\:\:testGetViewParameters\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Templating/GlobalHelperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\GlobalHelperTest\:\:testGetViewParametersString\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Templating/GlobalHelperTest.php - - - - message: '#^Anonymous function has an unused use \$content\.$#' - identifier: closure.unusedUse - count: 1 - path: tests/lib/MVC/Symfony/Templating/RenderLocationStrategyTest.php - - - - message: '#^Anonymous function has an unused use \$siteAccess\.$#' - identifier: closure.unusedUse - count: 1 - path: tests/lib/MVC/Symfony/Templating/RenderLocationStrategyTest.php - - - - message: '#^Call to method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Symfony\\\\Component\\\\HttpKernel\\\\Controller\\\\ControllerReference'' and Symfony\\Component\\HttpKernel\\Controller\\ControllerReference will always evaluate to true\.$#' - identifier: method.alreadyNarrowedType - count: 1 - path: tests/lib/MVC/Symfony/Templating/RenderLocationStrategyTest.php - - - - message: '#^Argument of an invalid type string supplied for foreach, only iterables are supported\.$#' - identifier: foreach.nonIterable - count: 1 - path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\Twig\\Extension\\FileSizeExtensionTest\:\:getExtensions\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\Twig\\Extension\\FileSizeExtensionTest\:\:getLocale\(\) should return string but returns array\\.$#' - identifier: return.type - count: 1 - path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\Twig\\Extension\\FileSizeExtensionTest\:\:setConfigurationLocale\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - - - message: '#^PHPDoc tag @param has invalid value \(\\Ibexa\\Contracts\\Core\\SiteAccess\\ConfigResolverInterface\|\\PHPUnit\\Framework\\MockObject\\MockObject\)\: Unexpected token "\\n ", expected variable at offset 115 on line 2$#' - identifier: phpDoc.parseError - count: 1 - path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - - - message: '#^PHPDoc tag @param has invalid value \(\\Ibexa\\Core\\MVC\\Symfony\\Locale\\LocaleConverterInterface\|\\PHPUnit\\Framework\\MockObject\\MockObject\)\: Unexpected token "\\n ", expected variable at offset 114 on line 2$#' - identifier: phpDoc.parseError - count: 1 - path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - - - message: '#^PHPDoc tag @param has invalid value \(\\Symfony\\Contracts\\Translation\\TranslatorInterface\|\\PHPUnit\\Framework\\MockObject\\MockObject\)\: Unexpected token "\\n ", expected variable at offset 109 on line 2$#' - identifier: phpDoc.parseError - count: 1 - path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\Twig\\Extension\\FileSizeExtensionTest\:\:\$configResolverInterfaceMock has no type specified\.$#' - identifier: missingType.property - count: 1 - path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\Twig\\Extension\\FileSizeExtensionTest\:\:\$locale has no type specified\.$#' - identifier: missingType.property - count: 1 - path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\Twig\\Extension\\FileSizeExtensionTest\:\:\$localeConverterInterfaceMock has no type specified\.$#' - identifier: missingType.property - count: 1 - path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\Twig\\Extension\\FileSizeExtensionTest\:\:\$suffixes has no type specified\.$#' - identifier: missingType.property - count: 1 - path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\Twig\\Extension\\FileSizeExtensionTest\:\:\$translatorMock has no type specified\.$#' - identifier: missingType.property - count: 1 - path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - - - message: '#^Anonymous function should return non\-empty\-string but returns non\-empty\-string\|false\.$#' - identifier: return.type - count: 1 - path: tests/lib/MVC/Symfony/Templating/Twig/Extension/RoutingExtensionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\Twig\\Extension\\RoutingExtensionTest\:\:getExampleRouteReference\(\) has parameter \$name with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/Templating/Twig/Extension/RoutingExtensionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\Twig\\Extension\\RoutingExtensionTest\:\:getExampleRouteReference\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/Templating/Twig/Extension/RoutingExtensionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\AbstractViewTestCase\:\:badTemplateIdentifierProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/View/AbstractViewTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\AbstractViewTestCase\:\:createViewUnderTest\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/View/AbstractViewTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\AbstractViewTestCase\:\:createViewUnderTest\(\) has parameter \$template with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/View/AbstractViewTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\AbstractViewTestCase\:\:createViewUnderTest\(\) has parameter \$viewType with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/View/AbstractViewTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\AbstractViewTestCase\:\:getAlwaysAvailableParams\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/View/AbstractViewTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\AbstractViewTestCase\:\:goodTemplateIdentifierProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/View/AbstractViewTestCase.php - - - - message: '#^Parameter \#1 \$templateIdentifier of method Ibexa\\Core\\MVC\\Symfony\\View\\View\:\:setTemplateIdentifier\(\) expects \(Closure\(array\\)\: string\)\|string, \(callable\(\)\: mixed\)\|string given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/MVC/Symfony/View/AbstractViewTestCase.php - - - - message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\Builder\\ContentViewBuilderTest\:\:\$contentViewBuilder \(Ibexa\\Core\\MVC\\Symfony\\View\\Builder\\ContentViewBuilder&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept Ibexa\\Core\\MVC\\Symfony\\View\\Builder\\ContentViewBuilder\.$#' - identifier: assign.propertyType - count: 1 - path: tests/lib/MVC/Symfony/View/Builder/ContentViewBuilderTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ContentViewTest\:\:constructFailProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/View/ContentViewTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ContentViewTest\:\:constructProvider\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/View/ContentViewTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ContentViewTest\:\:createViewUnderTest\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/View/ContentViewTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ContentViewTest\:\:createViewUnderTest\(\) has parameter \$template with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/View/ContentViewTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ContentViewTest\:\:createViewUnderTest\(\) has parameter \$viewType with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/View/ContentViewTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ContentViewTest\:\:getAlwaysAvailableParams\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/View/ContentViewTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ContentViewTest\:\:testConstruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/View/ContentViewTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ContentViewTest\:\:testConstruct\(\) has parameter \$params with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/View/ContentViewTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ContentViewTest\:\:testConstruct\(\) has parameter \$templateIdentifier with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/View/ContentViewTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ContentViewTest\:\:testConstructFail\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/View/ContentViewTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ContentViewTest\:\:testConstructFail\(\) has parameter \$templateIdentifier with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/View/ContentViewTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ContentViewTest\:\:\$valueParams type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/View/ContentViewTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\LoginFormViewTest\:\:createViewUnderTest\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/View/LoginFormViewTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\LoginFormViewTest\:\:createViewUnderTest\(\) has parameter \$template with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/View/LoginFormViewTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\LoginFormViewTest\:\:createViewUnderTest\(\) has parameter \$viewType with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/MVC/Symfony/View/LoginFormViewTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\LoginFormViewTest\:\:getAlwaysAvailableParams\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/View/LoginFormViewTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\Renderer\\TemplateRendererTest\:\:testRender\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/View/Renderer/TemplateRendererTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\Renderer\\TemplateRendererTest\:\:testRenderNoViewTemplate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/View/Renderer/TemplateRendererTest.php - - - - message: '#^Method Ibexa\\Contracts\\Core\\MVC\\View\\VariableProvider@anonymous/tests/lib/MVC/Symfony/View/VariableProviderRegistryTest\.php\:29\:\:getTwigVariables\(\) has parameter \$options with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/View/VariableProviderRegistryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\VariableProviderRegistryTest\:\:getRegistry\(\) has parameter \$providers with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/MVC/Symfony/View/VariableProviderRegistryTest.php - - - - message: '#^Property Ibexa\\Contracts\\Core\\MVC\\View\\VariableProvider@anonymous/tests/lib/MVC/Symfony/View/VariableProviderRegistryTest\.php\:29\:\:\$identifier has no type specified\.$#' - identifier: missingType.property - count: 1 - path: tests/lib/MVC/Symfony/View/VariableProviderRegistryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ViewManagerTest\:\:testRenderContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/View/ViewManagerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ViewManagerTest\:\:testRenderContentWithClosure\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/View/ViewManagerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ViewManagerTest\:\:testRenderLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/View/ViewManagerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ViewManagerTest\:\:testRenderLocationWithClosure\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/View/ViewManagerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ViewManagerTest\:\:testRenderLocationWithContentPassed\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/MVC/Symfony/View/ViewManagerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ViewManagerTest\:\:\$viewBaseLayout has no type specified\.$#' - identifier: missingType.property - count: 1 - path: tests/lib/MVC/Symfony/View/ViewManagerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Pagination\\AdapterFactory\\SearchHitAdapterFactoryTest\:\:dataProviderForCreateFixedAdapter\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Pagination/AdapterFactory/SearchHitAdapterFactoryTest.php - - - - message: '#^Parameter \#3 \$languageFilter of class Ibexa\\Core\\Pagination\\Pagerfanta\\ContentFilteringAdapter constructor expects array\\|null, array\\|true\> given\.$#' - identifier: argument.type - count: 2 - path: tests/lib/Pagination/ContentFilteringAdapterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractBaseHandlerTestCase\:\:getCacheItem\(\) has parameter \$key with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Cache/AbstractBaseHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractBaseHandlerTestCase\:\:provideAbstractCacheHandlerArguments\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractBaseHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractBaseHandlerTestCase\:\:provideInMemoryCacheHandlerArguments\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractBaseHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$additionalCalls with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$keyGeneratingArguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$keyGeneratingResults with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$tagGeneratingArguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$tagGeneratingResults with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$additionalCalls with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$keyGeneratingArguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$keyGeneratingResults with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$tagGeneratingArguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$tagGeneratingResults with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testUnCachedMethods\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testUnCachedMethods\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testUnCachedMethods\(\) has parameter \$key with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testUnCachedMethods\(\) has parameter \$keyGeneratingArguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testUnCachedMethods\(\) has parameter \$tagGeneratingArguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testUnCachedMethods\(\) has parameter \$tags with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method PHPUnit\\Framework\\MockObject\\Builder\\InvocationMocker\:\:willReturnOnConsecutiveCalls\(\) invoked with unpacked array with possibly string key, but it''s not allowed because of @no\-named\-arguments\.$#' - identifier: argument.named - count: 6 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method PHPUnit\\Framework\\MockObject\\Builder\\InvocationMocker\:\:with\(\) invoked with unpacked array with possibly string key, but it''s not allowed because of @no\-named\-arguments\.$#' - identifier: argument.named - count: 2 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method PHPUnit\\Framework\\MockObject\\Builder\\InvocationMocker\:\:withConsecutive\(\) invoked with unpacked array with possibly string key, but it''s not allowed because of @no\-named\-arguments\.$#' - identifier: argument.named - count: 6 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Only iterables can be unpacked, array\|null given in argument \#1\.$#' - identifier: argument.unpackNonIterable - count: 5 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Parameter \#1 \$callback of function call_user_func_array expects callable\(\)\: mixed, array\{mixed, string\} given\.$#' - identifier: argument.type - count: 3 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Parameter \#1 \$originalClassName of method PHPUnit\\Framework\\TestCase\:\:createMock\(\) expects class\-string\, string given\.$#' - identifier: argument.type - count: 2 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Unable to resolve the template type T in call to method PHPUnit\\Framework\\TestCase\:\:createMock\(\)$#' - identifier: argument.templateType - count: 3 - path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$additionalCalls with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$keyGeneratingArguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$keyGeneratingResults with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$tagGeneratingArguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$tagGeneratingResults with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$additionalCalls with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$keyGeneratingArguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$keyGeneratingResults with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$tagGeneratingArguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$tagGeneratingResults with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testUnCachedMethods\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testUnCachedMethods\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testUnCachedMethods\(\) has parameter \$key with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testUnCachedMethods\(\) has parameter \$keyGeneratingArguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testUnCachedMethods\(\) has parameter \$tagGeneratingArguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testUnCachedMethods\(\) has parameter \$tags with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method PHPUnit\\Framework\\MockObject\\Builder\\InvocationMocker\:\:willReturnOnConsecutiveCalls\(\) invoked with unpacked array with possibly string key, but it''s not allowed because of @no\-named\-arguments\.$#' - identifier: argument.named - count: 6 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method PHPUnit\\Framework\\MockObject\\Builder\\InvocationMocker\:\:with\(\) invoked with unpacked array with possibly string key, but it''s not allowed because of @no\-named\-arguments\.$#' - identifier: argument.named - count: 2 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method PHPUnit\\Framework\\MockObject\\Builder\\InvocationMocker\:\:withConsecutive\(\) invoked with unpacked array with possibly string key, but it''s not allowed because of @no\-named\-arguments\.$#' - identifier: argument.named - count: 6 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Only iterables can be unpacked, array\|null given in argument \#1\.$#' - identifier: argument.unpackNonIterable - count: 5 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Parameter \#1 \$callback of function call_user_func_array expects callable\(\)\: mixed, array\{mixed, string\} given\.$#' - identifier: argument.type - count: 3 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Parameter \#1 \$originalClassName of method PHPUnit\\Framework\\TestCase\:\:createMock\(\) expects class\-string\, string given\.$#' - identifier: argument.type - count: 2 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Unable to resolve the template type T in call to method PHPUnit\\Framework\\TestCase\:\:createMock\(\)$#' - identifier: argument.templateType - count: 3 - path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Adapter\\InMemoryClearingProxyAdapterTest\:\:arrayAsGenerator\(\) has parameter \$array with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Adapter\\InMemoryClearingProxyAdapterTest\:\:createCacheItem\(\) has parameter \$tags with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Adapter\\InMemoryClearingProxyAdapterTest\:\:providerForClearAndInvalidation\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Adapter\\InMemoryClearingProxyAdapterTest\:\:providerForDelete\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Adapter\\InMemoryClearingProxyAdapterTest\:\:testClearAndInvalidation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Adapter\\InMemoryClearingProxyAdapterTest\:\:testClearAndInvalidation\(\) has parameter \$argument with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Adapter\\InMemoryClearingProxyAdapterTest\:\:testDelete\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Adapter\\InMemoryClearingProxyAdapterTest\:\:testDelete\(\) has parameter \$argument with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Adapter\\InMemoryClearingProxyAdapterTest\:\:testGetItem\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Adapter\\InMemoryClearingProxyAdapterTest\:\:testGetItems\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Adapter\\InMemoryClearingProxyAdapterTest\:\:testGetItemsWithGenerator\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Adapter\\InMemoryClearingProxyAdapterTest\:\:testHasItem\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\BookmarkHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/BookmarkHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\BookmarkHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/BookmarkHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\BookmarkHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/BookmarkHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ContentHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ContentHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ContentHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ContentHandlerTest\:\:testDeleteContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ContentLanguageHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/ContentLanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ContentLanguageHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/ContentLanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ContentLanguageHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/ContentLanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ContentTypeHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ContentTypeHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ContentTypeHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ContentTypeHandlerTest\:\:testPublish\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/ContentTypeHandlerTest.php - - - - message: '#^Parameter \#1 \$callback of function call_user_func_array expects callable\(\)\: mixed, array\{mixed, ''publish''\} given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/Persistence/Cache/ContentTypeHandlerTest.php - - - - message: '#^Parameter \#1 \$originalClassName of method PHPUnit\\Framework\\TestCase\:\:createMock\(\) expects class\-string\, string given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/Persistence/Cache/ContentTypeHandlerTest.php - - - - message: '#^Parameter \#2 \$value of method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractBaseHandlerTestCase\:\:getCacheItem\(\) expects null, Ibexa\\Contracts\\Core\\Persistence\\Content\\Type given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/Persistence/Cache/ContentTypeHandlerTest.php - - - - message: '#^Unable to resolve the template type T in call to method PHPUnit\\Framework\\TestCase\:\:createMock\(\)$#' - identifier: argument.templateType - count: 1 - path: tests/lib/Persistence/Cache/ContentTypeHandlerTest.php - - - - message: '#^Variable \$tags in empty\(\) always exists and is not falsy\.$#' - identifier: empty.variable - count: 1 - path: tests/lib/Persistence/Cache/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorTest\:\:providerForTestGenerateKey\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/Identifier/CacheIdentifierGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorTest\:\:providerForTestGenerateKeyThrowsInvalidArgumentException\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/Identifier/CacheIdentifierGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorTest\:\:providerForTestGenerateTag\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/Identifier/CacheIdentifierGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorTest\:\:providerForTestGenerateTagThrowsInvalidArgumentException\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/Identifier/CacheIdentifierGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorTest\:\:testGenerateKey\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/Identifier/CacheIdentifierGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorTest\:\:testGenerateKeyThrowsInvalidArgumentException\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/Identifier/CacheIdentifierGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorTest\:\:testGenerateTag\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/Identifier/CacheIdentifierGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorTest\:\:testGenerateTagThrowsInvalidArgumentException\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/Identifier/CacheIdentifierGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierSanitizerTest\:\:providerForTestEscapeCacheKey\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/Identifier/CacheIdentifierSanitizerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierSanitizerTest\:\:testEscapeCacheKey\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/Identifier/CacheIdentifierSanitizerTest.php - - - - message: '#^Function Ibexa\\Core\\Persistence\\Cache\\InMemory\\microtime\(\) has parameter \$asFloat with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Cache/InMemory/InMemoryCacheTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\LocationHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/LocationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\LocationHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/LocationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\LocationHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/LocationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\LocationPathConverterTest\:\:providerForTestConvertToPathIds\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/LocationPathConverterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\LocationPathConverterTest\:\:testConvertToPathIds\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/LocationPathConverterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\LocationPathConverterTest\:\:testConvertToPathIds\(\) has parameter \$resultArray with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/LocationPathConverterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\NotificationHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/NotificationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\NotificationHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/NotificationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\NotificationHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/NotificationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ObjectStateHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ObjectStateHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ObjectStateHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\PersistenceHandlerTest\:\:testContentHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/PersistenceHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\PersistenceHandlerTest\:\:testContentLocationHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/PersistenceHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\PersistenceHandlerTest\:\:testContentTypeHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/PersistenceHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\PersistenceHandlerTest\:\:testHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/PersistenceHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\PersistenceHandlerTest\:\:testLanguageHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/PersistenceHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\PersistenceHandlerTest\:\:testObjectStateHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/PersistenceHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\PersistenceHandlerTest\:\:testSectionHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/PersistenceHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\PersistenceHandlerTest\:\:testTransactionHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/PersistenceHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\PersistenceHandlerTest\:\:testTrashHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/PersistenceHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\PersistenceHandlerTest\:\:testUrlAliasHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/PersistenceHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\PersistenceHandlerTest\:\:testUrlWildcardHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/PersistenceHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\PersistenceHandlerTest\:\:testUserHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/PersistenceHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\SectionHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/SectionHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\SectionHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/SectionHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\SectionHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/SectionHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\SettingHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/SettingHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\SettingHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/SettingHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\SettingHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/SettingHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\TransactionHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/TransactionHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\TransactionHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/TransactionHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\TransactionHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/TransactionHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\TransactionHandlerTest\:\:testBeginTransactionStartsCacheTransaction\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/TransactionHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\TransactionHandlerTest\:\:testCommitStopsCacheTransaction\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/TransactionHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\TransactionHandlerTest\:\:testRollback\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/TransactionHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\TrashHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/TrashHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\TrashHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/TrashHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\TrashHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/TrashHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\TrashHandlerTest\:\:testDeleteTrashItem\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/TrashHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\TrashHandlerTest\:\:testEmptyTrash\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/TrashHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\TrashHandlerTest\:\:testRecover\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/TrashHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\TrashHandlerTest\:\:testTrashSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/TrashHandlerTest.php - - - - message: '#^Parameter \#1 \$originalClassName of method PHPUnit\\Framework\\TestCase\:\:createMock\(\) expects class\-string\, string given\.$#' - identifier: argument.type - count: 3 - path: tests/lib/Persistence/Cache/TrashHandlerTest.php - - - - message: '#^Unable to resolve the template type T in call to method PHPUnit\\Framework\\TestCase\:\:createMock\(\)$#' - identifier: argument.templateType - count: 3 - path: tests/lib/Persistence/Cache/TrashHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\URLHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/URLHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\URLHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/URLHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\URLHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/URLHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\URLHandlerTest\:\:testUpdateUrlStatusIsUpdated\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/URLHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UrlAliasHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UrlAliasHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UrlAliasHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UrlWildcardHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/UrlWildcardHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UrlWildcardHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/UrlWildcardHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UrlWildcardHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/UrlWildcardHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UserHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/UserHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UserHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/UserHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UserHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/UserHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UserHandlerTest\:\:testAssignRole\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/UserHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UserHandlerTest\:\:testPublishNewRoleDraft\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/UserHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UserHandlerTest\:\:testPublishRoleDraftFromExistingRole\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Cache/UserHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UserPreferenceHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/UserPreferenceHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UserPreferenceHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/UserPreferenceHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UserPreferenceHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Cache/UserPreferenceHandlerTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Persistence\\\\FieldType'' and Ibexa\\Contracts\\Core\\Persistence\\FieldType will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 3 - path: tests/lib/Persistence/FieldTypeRegistryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\FieldTypeRegistryTest\:\:getFieldTypeMock\(\) should return Ibexa\\Contracts\\Core\\Persistence\\FieldType but returns Ibexa\\Contracts\\Core\\FieldType\\FieldType&PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/FieldTypeRegistryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\FieldTypeRegistryTest\:\:testGetFieldTypeInstance\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/FieldTypeRegistryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\FieldTypeRegistryTest\:\:testGetNotFound\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/FieldTypeRegistryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\FieldTypeRegistryTest\:\:testGetNotFoundBCException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/FieldTypeRegistryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\FieldTypeRegistryTest\:\:testGetNotInstance\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/FieldTypeRegistryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\FieldTypeRegistryTest\:\:testRegister\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/FieldTypeRegistryTest.php - - - - message: '#^Parameter \#1 \$coreFieldTypes of class Ibexa\\Core\\Persistence\\FieldTypeRegistry constructor expects array\, array\ given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/Persistence/FieldTypeRegistryTest.php - - - - message: '#^Parameter \#1 \$coreFieldTypes of class Ibexa\\Core\\Persistence\\FieldTypeRegistry constructor expects array\, array\ given\.$#' - identifier: argument.type - count: 2 - path: tests/lib/Persistence/FieldTypeRegistryTest.php - - - - message: '#^Parameter \#2 \$fieldType of method Ibexa\\Core\\Persistence\\FieldTypeRegistry\:\:register\(\) expects Ibexa\\Contracts\\Core\\FieldType\\FieldType, Ibexa\\Contracts\\Core\\Persistence\\FieldType given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/Persistence/FieldTypeRegistryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\FieldValue\\Converter\\ImageConverterTest\:\:dataProviderForTestToFieldDefinition\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/FieldValue/Converter/ImageConverterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\FieldValue\\Converter\\ImageConverterTest\:\:dataProviderForTestToStorageFieldDefinition\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/FieldValue/Converter/ImageConverterTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Bookmark\\Gateway\:\:loadBookmarkDataById\(\)\.$#' - identifier: method.notFound - count: 1 - path: tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\Gateway\\DoctrineDatabaseTest\:\:dataProviderForLoadUserBookmarks\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\Gateway\\DoctrineDatabaseTest\:\:loadBookmark\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\Gateway\\DoctrineDatabaseTest\:\:testCountUserBookmarks\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\Gateway\\DoctrineDatabaseTest\:\:testCountUserBookmarks\(\) has parameter \$expected with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\Gateway\\DoctrineDatabaseTest\:\:testDeleteBookmark\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\Gateway\\DoctrineDatabaseTest\:\:testInsertBookmark\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\Gateway\\DoctrineDatabaseTest\:\:testLoadBookmarkDataById\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\Gateway\\DoctrineDatabaseTest\:\:testLoadBookmarkDataByUserIdAndLocationId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\Gateway\\DoctrineDatabaseTest\:\:testLoadUserBookmarks\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\Gateway\\DoctrineDatabaseTest\:\:testLoadUserBookmarks\(\) has parameter \$expected with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\Gateway\\DoctrineDatabaseTest\:\:testLocationSwapped\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\HandlerTest\:\:testCreate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Bookmark/HandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\HandlerTest\:\:testDelete\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Bookmark/HandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\HandlerTest\:\:testLoadByUserIdAndLocationIdExistingBookmark\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Bookmark/HandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\HandlerTest\:\:testLoadByUserIdAndLocationIdNonExistingBookmark\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Bookmark/HandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\HandlerTest\:\:testLoadUserBookmarks\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Bookmark/HandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\HandlerTest\:\:testLocationSwapped\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Bookmark/HandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\MapperTest\:\:testCreateBookmarkFromCreateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Bookmark/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\MapperTest\:\:testExtractBookmarksFromRows\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Bookmark/MapperTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldHandler\:\:expects\(\)\.$#' - identifier: method.notFound - count: 9 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Handler\:\:expects\(\)\.$#' - identifier: method.notFound - count: 17 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\:\:expects\(\)\.$#' - identifier: method.notFound - count: 8 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper\:\:expects\(\)\.$#' - identifier: method.notFound - count: 17 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\:\:expects\(\)\.$#' - identifier: method.notFound - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\SlugConverter\:\:expects\(\)\.$#' - identifier: method.notFound - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:getContentTypeHandlerMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Handler&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Handler\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:getGatewayMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:getRelationFixture\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:getTreeHandlerMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\TreeHandler&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\TreeHandler\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testAddRelation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testCopyAllVersions\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testCopySingleVersion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testCopyThrowsNotFoundExceptionContentNotFound\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testCopyThrowsNotFoundExceptionVersionNotFound\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testCreate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testCreateDraftFromVersion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testDeleteContentWithLocations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testDeleteContentWithoutLocations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testDeleteVersion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testListVersions\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testLoad\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testLoadContentInfoByRemoteId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testLoadContentList\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testLoadDraftsForUser\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testLoadErrorNotFound\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testLoadReverseRelations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testPublish\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testPublishFirstVersion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testRemoveRawContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testRemoveRelation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testSetStatus\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testUpdateContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testUpdateMetadata\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:testUpdateMetadataUpdatesPathIdentificationString\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:\$contentHandler \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Handler\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:\$contentTypeHandlerMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Handler\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:\$fieldHandlerMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldHandler\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:\$gatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:\$locationGatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:\$mapperMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:\$slugConverterMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\SlugConverter\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:\$treeHandlerMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\TreeHandler\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:\$typeGatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:\$urlAliasGatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:assertCreateExistingFieldsInNewVersion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:assertCreateNewFields\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:assertCreateNewFieldsForMainLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:assertUpdateFieldsExistingLanguages\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:assertUpdateFieldsForInitialLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:assertUpdateFieldsWithNewLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:getContentGatewayMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:getFieldTypeMock\(\) should return Ibexa\\Contracts\\Core\\Persistence\\FieldType&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Contracts\\Core\\FieldType\\FieldType\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:getFieldTypeRegistryMock\(\) should return Ibexa\\Core\\Persistence\\FieldTypeRegistry&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\FieldTypeRegistry\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:getMapperMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:getStorageHandlerMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageHandler&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageHandler\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:testCreateExistingFieldsInNewVersion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:testCreateExistingFieldsInNewVersionUpdatingStorageHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:testCreateNewFields\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:testCreateNewFieldsForMainLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:testCreateNewFieldsForMainLanguageUpdatingStorageHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:testCreateNewFieldsUpdatingStorageHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:testDeleteFields\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:testLoadExternalFieldData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:testUpdateFieldsExistingLanguages\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:testUpdateFieldsExistingLanguagesUpdatingStorageHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:testUpdateFieldsForInitialLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:testUpdateFieldsForInitialLanguageUpdatingStorageHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:testUpdateFieldsWithNewLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:testUpdateFieldsWithNewLanguageUpdatingStorageHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Property Ibexa\\Contracts\\Core\\Persistence\\Content\\Field\:\:\$value \(Ibexa\\Contracts\\Core\\Persistence\\Content\\FieldValue\) does not accept null\.$#' - identifier: assign.propertyType - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:\$contentGatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:\$fieldTypeMock \(Ibexa\\Contracts\\Core\\FieldType\\FieldType\) does not accept Ibexa\\Contracts\\Core\\Persistence\\FieldType&PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: assign.propertyType - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:\$fieldTypeMock \(Ibexa\\Contracts\\Core\\FieldType\\FieldType\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:\$fieldTypeRegistryMock \(Ibexa\\Core\\Persistence\\FieldTypeRegistry\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:\$mapperMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:\$storageHandlerMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageHandler\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Variable \$copyField might not be defined\.$#' - identifier: variable.undefined - count: 2 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Variable \$originalField might not be defined\.$#' - identifier: variable.undefined - count: 2 - path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - - - message: '#^Cannot access offset ''email'' on Ibexa\\Core\\FieldType\\Author\\Author\.$#' - identifier: offsetAccess.nonOffsetAccessible - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/AuthorTest.php - - - - message: '#^Cannot access offset ''id'' on Ibexa\\Core\\FieldType\\Author\\Author\.$#' - identifier: offsetAccess.nonOffsetAccessible - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/AuthorTest.php - - - - message: '#^Cannot access offset ''name'' on Ibexa\\Core\\FieldType\\Author\\Author\.$#' - identifier: offsetAccess.nonOffsetAccessible - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/AuthorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\AuthorTest\:\:testToFieldValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/AuthorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\AuthorTest\:\:testToStorageFieldDefinitionDefaultCurrentUser\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/AuthorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\AuthorTest\:\:testToStorageFieldDefinitionDefaultEmpty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/AuthorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\AuthorTest\:\:testToStorageValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/AuthorTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\AuthorTest\:\:\$authors \(array\\) does not accept array\\>\.$#' - identifier: assign.propertyType - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/AuthorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CheckboxTest\:\:testToFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CheckboxTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CheckboxTest\:\:testToFieldValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CheckboxTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CheckboxTest\:\:testToStorageFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CheckboxTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CheckboxTest\:\:testToStorageValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CheckboxTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:providerForTestToFieldValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:providerForTestToStorageValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:testToFieldDefinitionMultiple\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:testToFieldDefinitionSingle\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:testToFieldValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:testToFieldValue\(\) has parameter \$data with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:testToFieldValue\(\) has parameter \$dataText with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:testToFieldValue\(\) has parameter \$sortKeyString with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:testToStorageFieldDefinitionMultiple\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:testToStorageFieldDefinitionSingle\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:testToStorageValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:testToStorageValue\(\) has parameter \$data with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:testToStorageValue\(\) has parameter \$dataText with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:testToStorageValue\(\) has parameter \$sortKey with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:testToStorageValue\(\) has parameter \$sortKeyString with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - - - message: '#^Cannot access offset ''timestring'' on array\|bool\|float\|int\|string\|null\.$#' - identifier: offsetAccess.nonOffsetAccessible - count: 3 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateAndTimeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\DateAndTimeTest\:\:getXMLToDateIntervalMap\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateAndTimeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\DateAndTimeTest\:\:testGenerateDateIntervalXML\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateAndTimeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\DateAndTimeTest\:\:testGetDateIntervalFromXML\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateAndTimeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\DateAndTimeTest\:\:testToFieldDefinitionCurrentDate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateAndTimeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\DateAndTimeTest\:\:testToFieldDefinitionNoDefault\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateAndTimeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\DateAndTimeTest\:\:testToFieldDefinitionWithAdjustmentAndSeconds\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateAndTimeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\DateAndTimeTest\:\:testToFieldDefinitionWithAdjustmentNoSeconds\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateAndTimeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\DateAndTimeTest\:\:testToFieldValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateAndTimeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\DateAndTimeTest\:\:testToStorageFieldDefinitionCurrentDate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateAndTimeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\DateAndTimeTest\:\:testToStorageFieldDefinitionNoDefault\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateAndTimeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\DateAndTimeTest\:\:testToStorageFieldDefinitionWithAdjustment\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateAndTimeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\DateAndTimeTest\:\:testToStorageValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateAndTimeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\ISBNTest\:\:providerForTestToFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/ISBNTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\ISBNTest\:\:testToFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/ISBNTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\ISBNTest\:\:testToFieldDefinition\(\) has parameter \$dataInt with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/ISBNTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\ISBNTest\:\:testToFieldDefinition\(\) has parameter \$excpectedIsbn13Value with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/ISBNTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\KeywordTest\:\:testToFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/KeywordTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\KeywordTest\:\:testToFieldValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/KeywordTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\KeywordTest\:\:testToStorageFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/KeywordTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\KeywordTest\:\:testToStorageValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/KeywordTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\MediaTest\:\:testToFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/MediaTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\MediaTest\:\:testToStorageFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/MediaTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\MediaTest\:\:\$converter has no type specified\.$#' - identifier: missingType.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/MediaTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\RelationListTest\:\:testToFieldDefinitionMultiple\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/RelationListTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\RelationListTest\:\:testToFieldValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/RelationListTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\RelationListTest\:\:testToFieldValueEmpty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/RelationListTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\RelationListTest\:\:testToStorageFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/RelationListTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\RelationListTest\:\:testToStorageValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/RelationListTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\RelationListTest\:\:testToStorageValueEmpty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/RelationListTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\RelationTest\:\:testToStorageFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/RelationTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\RelationTest\:\:\$converter \(Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\RelationConverter&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\RelationConverter\.$#' - identifier: assign.propertyType - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/RelationTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\SelectionTest\:\:testToFieldDefinitionMultiple\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/SelectionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\SelectionTest\:\:testToFieldDefinitionSingleEmpty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/SelectionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\SelectionTest\:\:testToFieldValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/SelectionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\SelectionTest\:\:testToFieldValueEmpty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/SelectionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\SelectionTest\:\:testToStorageFieldDefinitionMultiple\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/SelectionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\SelectionTest\:\:testToStorageFieldDefinitionSingle\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/SelectionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\SelectionTest\:\:testToStorageValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/SelectionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\SelectionTest\:\:testToStorageValueEmpty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/SelectionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\TextBlockTest\:\:testToFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TextBlockTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\TextBlockTest\:\:testToFieldValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TextBlockTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\TextBlockTest\:\:testToStorageFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TextBlockTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\TextBlockTest\:\:testToStorageValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TextBlockTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\TextBlockTest\:\:\$longText has no type specified\.$#' - identifier: missingType.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TextBlockTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\TextLineTest\:\:testToFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TextLineTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\TextLineTest\:\:testToFieldValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TextLineTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\TextLineTest\:\:testToStorageFieldDefinitionNoValidator\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TextLineTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\TextLineTest\:\:testToStorageFieldDefinitionWithValidator\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TextLineTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\TextLineTest\:\:testToStorageValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TextLineTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\TimeTest\:\:testToFieldDefinitionDefaultCurrentTime\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TimeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\TimeTest\:\:testToFieldDefinitionDefaultEmpty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TimeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\TimeTest\:\:testToFieldValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TimeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\TimeTest\:\:testToStorageFieldDefinitionDefaultCurrentTime\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TimeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\TimeTest\:\:testToStorageFieldDefinitionDefaultEmpty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TimeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\TimeTest\:\:testToStorageValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TimeTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\UrlTest\:\:testToFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/UrlTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\UrlTest\:\:testToFieldValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/UrlTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\UrlTest\:\:testToStorageFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/UrlTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\UrlTest\:\:testToStorageValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/UrlTest.php - - - - message: '#^Property Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageFieldValue\:\:\$sortKeyInt \(int\) does not accept false\.$#' - identifier: assign.propertyType - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/UrlTest.php - - - - message: '#^Property Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageFieldValue\:\:\$sortKeyString \(string\) does not accept false\.$#' - identifier: assign.propertyType - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/UrlTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValueConverterRegistryTest\:\:testGetNotFound\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValueConverterRegistryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValueConverterRegistryTest\:\:testGetStorage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValueConverterRegistryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValueConverterRegistryTest\:\:testRegister\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/FieldValueConverterRegistryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:assertContentVersionAttributesLanguages\(\) has parameter \$expectation with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:assertValuesInRows\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:insertRelationFixture\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:storeFixture\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testCreateFixtureForMapperExtractContentFromRows\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testCreateFixtureForMapperExtractContentFromRowsMultipleVersions\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testDeleteContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testDeleteFields\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testDeleteFieldsWithSecondArgument\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testDeleteNames\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testDeleteNamesWithSecondArgument\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testDeleteRelation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testDeleteRelationsFrom\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testDeleteRelationsTo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testDeleteRelationsWithSecondArgument\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testDeleteVersions\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testDeleteVersionsWithSecondArgument\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testGetAllLocationIds\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testGetFieldIdsByType\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testGetFieldIdsByTypeWithSecondArgument\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testGetLastVersionNumber\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testInsertContentObject\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testInsertNewAlwaysAvailableField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testInsertNewField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testInsertRelation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testInsertVersion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testListVersionNumbers\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testListVersionsForUser\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testLoadNonExistentTranslation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testLoadRelationsByType\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testLoadRelationsByVersion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testLoadRelationsNoResult\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testLoadReverseRelations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testLoadReverseRelationsWithType\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testLoadWithAllTranslations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testLoadWithSingleTranslation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testSetName\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testSetStatus\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testSetStatusPublished\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testSetStatusUnknownVersion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testUpdateContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testUpdateField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testUpdateNonTranslatableField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:testUpdateVersion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Parameter \#2 \$expectedValues of method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:assertValuesInRows\(\) expects array\, array\ given\.$#' - identifier: argument.type - count: 9 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:\$databaseGateway \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabase\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:getCacheIdentifierGeneratorMock\(\) should return Ibexa\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorInterface&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorInterface\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:getInnerLanguageHandlerMock\(\) should return Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:getLanguageCacheMock\(\) should return Ibexa\\Core\\Persistence\\Cache\\InMemory\\InMemoryCache&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Cache\\InMemory\\InMemoryCache\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:getLanguageHandler\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\CachingHandler but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Handler\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:testCreate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:testDelete\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:testLoad\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:testLoadAll\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:testLoadByLanguageCode\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:testLoadByLanguageCodeFailure\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:testLoadFailure\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:testUpdate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:\$cacheIdentifierGeneratorMock \(Ibexa\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorInterface\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:\$innerHandlerMock \(Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:\$languageCacheMock \(Ibexa\\Core\\Persistence\\Cache\\InMemory\\InMemoryCache\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:\$languageHandler \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Handler\) does not accept Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\CachingHandler\.$#' - identifier: assign.propertyType - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:\$languageHandler \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Handler\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\Gateway\\DoctrineDatabaseTest\:\:testDeleteLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\Gateway\\DoctrineDatabaseTest\:\:testInsertLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\Gateway\\DoctrineDatabaseTest\:\:testLoadAllLanguagesData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\Gateway\\DoctrineDatabaseTest\:\:testLoadLanguageListData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\Gateway\\DoctrineDatabaseTest\:\:testUpdateLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\Gateway\\DoctrineDatabaseTest\:\:\$databaseGateway \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Gateway\\DoctrineDatabase\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Result of method Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Gateway\\DoctrineDatabase\:\:deleteLanguage\(\) \(void\) is used\.$#' - identifier: method.void - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Gateway\:\:expects\(\)\.$#' - identifier: method.notFound - count: 11 - path: tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Mapper\:\:expects\(\)\.$#' - identifier: method.notFound - count: 6 - path: tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\LanguageHandlerTest\:\:testCreate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\LanguageHandlerTest\:\:testDeleteFail\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\LanguageHandlerTest\:\:testDeleteSuccess\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\LanguageHandlerTest\:\:testLoad\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\LanguageHandlerTest\:\:testLoadAll\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\LanguageHandlerTest\:\:testLoadByLanguageCode\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\LanguageHandlerTest\:\:testLoadByLanguageCodeFailure\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\LanguageHandlerTest\:\:testLoadFailure\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\LanguageHandlerTest\:\:testUpdate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\LanguageHandlerTest\:\:\$gatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Gateway\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\LanguageHandlerTest\:\:\$languageHandler \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Handler\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\LanguageHandlerTest\:\:\$mapperMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Mapper\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MapperTest\:\:testCreateLanguageFromCreateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MapperTest\:\:testExtractLanguagesFromRows\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:getLanguageHandler\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Handler but returns Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:getLanguageIndicatorData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:isAlwaysAvailableProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:languageIdsFromMaskProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:removeAlwaysAvailableFlagProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:testExtractLanguageIdsFromMask\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:testExtractLanguageIdsFromMask\(\) has parameter \$expectedResult with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:testGenerateLanguageIndicator\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:testIsAlwaysAvailable\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:testIsLanguageAlwaysAvailable\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:testIsLanguageAlwaysAvailableNoDefault\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:testIsLanguageAlwaysAvailableOtherLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:testRemoveAlwaysAvailableFlag\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:testRemoveAlwaysAvailableFlag\(\) has parameter \$expectedResult with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:testRemoveAlwaysAvailableFlag\(\) has parameter \$langMask with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - - - message: '#^Offset string might not exist on array\{\}\|array\{eng\-US\?\: Ibexa\\Contracts\\Core\\Persistence\\Content\\Language, eng\-GB\?\: Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\}\.$#' - identifier: offsetAccess.notFound - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageAwareTestCase\:\:\$languageHandler \(Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageAwareTestCase\:\:getFullTextSearchConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/LanguageAwareTestCase.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageAwareTestCase\:\:\$fieldNameGeneratorMock \(Ibexa\\Core\\Search\\Common\\FieldNameGenerator&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/LanguageAwareTestCase.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageAwareTestCase\:\:\$languageHandler \(Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/LanguageAwareTestCase.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageAwareTestCase\:\:\$languageMaskGenerator \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGenerator\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/LanguageAwareTestCase.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageHandlerMock\:\:delete\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/LanguageHandlerMock.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageHandlerMock\:\:loadList\(\) has parameter \$ids with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/LanguageHandlerMock.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageHandlerMock\:\:update\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/LanguageHandlerMock.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageHandlerMock\:\:\$languages has no type specified\.$#' - identifier: missingType.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/LanguageHandlerMock.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:assertLoadLocationProperties\(\) has parameter \$locationData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:buildContentTreeSelectContentWithParentQuery\(\) has parameter \$fields with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:buildGenericNodeSelectContentWithParentQuery\(\) has parameter \$fields with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:buildNodeAssignmentSelectContentWithParentQuery\(\) has parameter \$fields with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:getConvertNodeAssignmentsLocationValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:getCreateLocationReturnValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:getCreateLocationValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:getLoadLocationValues\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:getLocationGateway\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:getNodeAssignmentValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:getUpdateLocationData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:providerForTestUpdatePathIdentificationString\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testChangeMainLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testConvertNodeAssignments\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testConvertNodeAssignments\(\) has parameter \$field with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testConvertNodeAssignments\(\) has parameter \$value with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testConvertNodeAssignmentsMainLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testConvertNodeAssignmentsParentHidden\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testConvertNodeAssignmentsParentInvisible\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testConvertNodeAssignmentsUpdateAssignment\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testCreateLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testCreateLocationNodeAssignmentCreation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testCreateLocationNodeAssignmentCreation\(\) has parameter \$expectedResult with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testCreateLocationNodeAssignmentCreationMainLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testCreateLocationReturnValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testCreateLocationReturnValues\(\) has parameter \$field with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testCreateLocationReturnValues\(\) has parameter \$value with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testCreateLocationValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testCreateLocationValues\(\) has parameter \$field with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testCreateLocationValues\(\) has parameter \$value with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testDeleteNodeAssignment\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testDeleteNodeAssignmentWithSecondArgument\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testGetChildren\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testGetMainNodeId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testHideUnhideParentTree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testHideUnhidePartialSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testHideUnhideUpdateHidden\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testHideUpdateHidden\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testLoadInvalidLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testLoadLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testLoadLocationByRemoteId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testLoadLocationDataByContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testLoadLocationDataByContentLimitSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testLoadLocationList\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testLoadParentLocationDataForDraftContentAll\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testMoveHiddenDestinationUpdate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testMoveHiddenSourceChildUpdate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testMoveHiddenSourceUpdate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testMoveSubtreeAssignmentUpdate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testMoveSubtreePathUpdate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testRemoveLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testSetSectionForSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testSwapLocations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testUpdateLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testUpdateLocation\(\) has parameter \$field with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testUpdateLocation\(\) has parameter \$value with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testUpdateLocationsContentVersionNo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testUpdatePathIdentificationString\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testUpdatePathIdentificationString\(\) has parameter \$expected with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testUpdatePathIdentificationString\(\) has parameter \$locationId with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testUpdatePathIdentificationString\(\) has parameter \$parentLocationId with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testUpdatePathIdentificationString\(\) has parameter \$text with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Parameter \#2 \$y of method Doctrine\\DBAL\\Query\\Expression\\ExpressionBuilder\:\:in\(\) expects array\\|string, array\ given\.$#' - identifier: argument.type - count: 11 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:getLoadTrashValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:getLocationGateway\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:getTrashValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:getUntrashedLocationValues\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testCleanupTrash\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testCountLocationsByContentId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testCountTrashed\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testListEmptyTrash\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testListFullTrash\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testListTrashItem\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testListTrashItem\(\) has parameter \$key with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testListTrashItem\(\) has parameter \$value with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testListTrashLimited\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testListTrashSortedDepth\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testListTrashSortedPathStringDesc\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testLoadTrashByLocationId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testLoadTrashByLocationId\(\) has parameter \$field with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testLoadTrashByLocationId\(\) has parameter \$value with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testRemoveElementFromTrash\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testTrashLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testTrashLocationUpdateTrashTable\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testUntrashInvalidLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testUntrashLocationDefault\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testUntrashLocationDefault\(\) has parameter \$property with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testUntrashLocationDefault\(\) has parameter \$value with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testUntrashLocationInvalidOldParent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testUntrashLocationInvalidParent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testUntrashLocationNewParent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:trashSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Parameter \#2 \$y of method Doctrine\\DBAL\\Query\\Expression\\ExpressionBuilder\:\:in\(\) expects array\\|string, array\ given\.$#' - identifier: argument.type - count: 3 - path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\MapperTest\:\:testCreateLocationFromRow\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\MapperTest\:\:testCreateLocationFromRowWithPrefix\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\MapperTest\:\:testCreateLocationsFromRows\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\MapperTest\:\:testCreateTrashedFromRow\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\MapperTest\:\:testGetLocationCreateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/MapperTest.php - - - - message: '#^Parameter \#2 \$prefix of method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Mapper\:\:createLocationFromRow\(\) expects string, null given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/MapperTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\MapperTest\:\:\$locationCreateStructValues type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/MapperTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\MapperTest\:\:\$locationRow type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/MapperTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\MapperTest\:\:\$locationValues type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/MapperTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\:\:expects\(\)\.$#' - identifier: method.notFound - count: 34 - path: tests/lib/Persistence/Legacy/Content/Location/TrashHandlerTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Handler\:\:expects\(\)\.$#' - identifier: method.notFound - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/TrashHandlerTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Mapper\:\:expects\(\)\.$#' - identifier: method.notFound - count: 8 - path: tests/lib/Persistence/Legacy/Content/Location/TrashHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\TrashHandlerTest\:\:getTrashHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/TrashHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\TrashHandlerTest\:\:testDeleteTrashItemStillHaveLocations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/TrashHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\TrashHandlerTest\:\:testFindTrashItemsWhenEmpty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/TrashHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\TrashHandlerTest\:\:testFindTrashItemsWithLimits\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/TrashHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\TrashHandlerTest\:\:testLoadTrashItem\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/TrashHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\TrashHandlerTest\:\:testRecover\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/TrashHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\TrashHandlerTest\:\:testTrashSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/TrashHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\TrashHandlerTest\:\:testTrashSubtreeReturnsNull\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/TrashHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\TrashHandlerTest\:\:testTrashSubtreeUpdatesMainLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Location/TrashHandlerTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Handler\:\:expects\(\)\.$#' - identifier: method.notFound - count: 6 - path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\:\:expects\(\)\.$#' - identifier: method.notFound - count: 20 - path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Handler\:\:expects\(\)\.$#' - identifier: method.notFound - count: 4 - path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Mapper\:\:expects\(\)\.$#' - identifier: method.notFound - count: 4 - path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LocationHandlerTest\:\:getLocationHandler\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LocationHandlerTest\:\:loadParentLocationsForDraftContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LocationHandlerTest\:\:testChangeMainLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LocationHandlerTest\:\:testCopySubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LocationHandlerTest\:\:testCreateLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LocationHandlerTest\:\:testHideUnhideUpdateHidden\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LocationHandlerTest\:\:testHideUpdateHidden\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LocationHandlerTest\:\:testLoadLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LocationHandlerTest\:\:testLoadLocationByRemoteId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LocationHandlerTest\:\:testLoadLocationSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LocationHandlerTest\:\:testLoadLocationsByContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LocationHandlerTest\:\:testMoveSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LocationHandlerTest\:\:testRemoveSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LocationHandlerTest\:\:testSetSectionForSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LocationHandlerTest\:\:testSwapLocations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LocationHandlerTest\:\:testUpdateLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - - - message: '#^Argument of an invalid type Ibexa\\Contracts\\Core\\Persistence\\Content\\Relation\\CreateStruct supplied for foreach, only iterables are supported\.$#' - identifier: foreach.nonIterable - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper\:\:createCreateStructFromContent\(\) invoked with 2 parameters, 1 required\.$#' - identifier: arguments.count - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:extractContentInfoFromRowProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:extractVersionInfoFromRowProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:getContentExtractFixture\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:getLanguageHandler\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Handler&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:getMapper\(\) has parameter \$valueConverter with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:getMultipleVersionsNamesExtractFixture\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:getNamesExtractFixture\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:getRelationExtractFixture\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testConvertToStorageValue\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testCreateCreateStructFromContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testCreateCreateStructFromContentBasicProperties\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testCreateCreateStructFromContentBasicProperties\(\) has parameter \$data with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testCreateCreateStructFromContentFieldCount\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testCreateCreateStructFromContentFieldCount\(\) has parameter \$data with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testCreateCreateStructFromContentFieldsNoId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testCreateCreateStructFromContentFieldsNoId\(\) has parameter \$data with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testCreateCreateStructFromContentParentLocationsEmpty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testCreateCreateStructFromContentParentLocationsEmpty\(\) has parameter \$data with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testCreateCreateStructFromContentWithPreserveOriginalLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testCreateRelationFromCreateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testCreateVersionInfoForContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testExtractContentFromRows\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testExtractContentFromRowsMultipleVersions\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testExtractContentInfoFromRow\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testExtractContentInfoFromRow\(\) has parameter \$fixtures with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testExtractRelationsFromRows\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Property Ibexa\\Contracts\\Core\\Persistence\\Content\\CreateStruct\:\:\$name \(array\\) does not accept string\.$#' - identifier: assign.propertyType - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageAwareTestCase\:\:\$languageHandler \(Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:\$valueConverterRegistryMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldValue\\ConverterRegistry\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:testDeleteObjectState\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:testDeleteObjectStateGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:testDeleteObjectStateLinks\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:testGetContentCount\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:testInsertObjectState\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:testInsertObjectStateGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:testInsertObjectStateInEmptyGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:testLoadObjectStateData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:testLoadObjectStateDataByIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:testLoadObjectStateDataForContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:testLoadObjectStateGroupData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:testLoadObjectStateGroupDataByIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:testLoadObjectStateGroupListData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:testLoadObjectStateListData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:testSetContentState\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:testUpdateObjectState\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:testUpdateObjectStateGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:testUpdateObjectStateLinks\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:testUpdateObjectStatePriority\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:\$databaseGateway \(Ibexa\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabase\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\MapperTest\:\:getObjectStateGroupRowsFixture\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\MapperTest\:\:getObjectStateGroupRowsFixture\(\) should return array\\> but returns array\\>\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\MapperTest\:\:getObjectStateRowsFixture\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\MapperTest\:\:getObjectStateRowsFixture\(\) should return array\\> but returns array\\>\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\MapperTest\:\:testCreateObjectStateFromData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\MapperTest\:\:testCreateObjectStateFromInputStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\MapperTest\:\:testCreateObjectStateGroupFromData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\MapperTest\:\:testCreateObjectStateGroupFromInputStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\MapperTest\:\:testCreateObjectStateGroupListFromData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\MapperTest\:\:testCreateObjectStateListFromData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/MapperTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\:\:expects\(\)\.$#' - identifier: method.notFound - count: 39 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Mapper\:\:expects\(\)\.$#' - identifier: method.notFound - count: 18 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testCreate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testCreateGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testDelete\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testDeleteGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testDeleteThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testGetContentCount\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testGetContentState\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testLoad\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testLoadAllGroups\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testLoadByIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testLoadByIdentifierThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testLoadGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testLoadGroupByIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testLoadGroupByIdentifierThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testLoadGroupThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testLoadObjectStates\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testLoadThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testSetContentState\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testSetPriority\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testUpdate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:testUpdateGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:\$gatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:\$mapperMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Mapper\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:\$objectStateHandler \(Ibexa\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Handler\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\Gateway\\DoctrineDatabaseTest\:\:testAssignSectionToContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\Gateway\\DoctrineDatabaseTest\:\:testCountContentObjectsInSection\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\Gateway\\DoctrineDatabaseTest\:\:testCountRoleAssignmentsUsingSection\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\Gateway\\DoctrineDatabaseTest\:\:testDeleteSection\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\Gateway\\DoctrineDatabaseTest\:\:testInsertSection\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\Gateway\\DoctrineDatabaseTest\:\:testLoadAllSectionData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\Gateway\\DoctrineDatabaseTest\:\:testLoadSectionData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\Gateway\\DoctrineDatabaseTest\:\:testLoadSectionDataByIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\Gateway\\DoctrineDatabaseTest\:\:testUpdateSection\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\Gateway\\DoctrineDatabaseTest\:\:\$databaseGateway \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Section\\Gateway\\DoctrineDatabase\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Result of method Ibexa\\Core\\Persistence\\Legacy\\Content\\Section\\Gateway\\DoctrineDatabase\:\:assignSectionToContent\(\) \(void\) is used\.$#' - identifier: method.void - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Section\\Gateway\:\:expects\(\)\.$#' - identifier: method.notFound - count: 12 - path: tests/lib/Persistence/Legacy/Content/Section/SectionHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\SectionHandlerTest\:\:testAssign\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/SectionHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\SectionHandlerTest\:\:testCountRoleAssignmentsUsingSection\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/SectionHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\SectionHandlerTest\:\:testCreate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/SectionHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\SectionHandlerTest\:\:testDelete\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/SectionHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\SectionHandlerTest\:\:testDeleteFailure\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/SectionHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\SectionHandlerTest\:\:testLoad\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/SectionHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\SectionHandlerTest\:\:testLoadAll\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/SectionHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\SectionHandlerTest\:\:testLoadByIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/SectionHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\SectionHandlerTest\:\:testPoliciesCount\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/SectionHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\SectionHandlerTest\:\:testUpdate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/SectionHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\SectionHandlerTest\:\:\$gatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Section\\Gateway\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/SectionHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\SectionHandlerTest\:\:\$sectionHandler \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Section\\Handler\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Section/SectionHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\StorageRegistryTest\:\:testGetNotFound\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/StorageRegistryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\StorageRegistryTest\:\:testGetStorage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/StorageRegistryTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\TreeHandlerTest\:\:getPartlyMockedTreeHandler\(\) has parameter \$methods with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\TreeHandlerTest\:\:testChangeMainLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\TreeHandlerTest\:\:testChangeMainLocationToLocationWithoutContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\TreeHandlerTest\:\:testListVersions\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\TreeHandlerTest\:\:testLoadContentInfoByRemoteId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\TreeHandlerTest\:\:testLoadLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\TreeHandlerTest\:\:testRemoveRawContent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\TreeHandlerTest\:\:testRemoveSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\TreeHandlerTest\:\:testSetSectionForSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\TreeHandlerTest\:\:\$contentGatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\TreeHandlerTest\:\:\$contentMapper \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\TreeHandlerTest\:\:\$fieldHandlerMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldHandler&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\TreeHandlerTest\:\:\$locationGatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\TreeHandlerTest\:\:\$locationMapperMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Mapper&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\:\:expects\(\)\.$#' - identifier: method.notFound - count: 35 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Handler\:\:expects\(\)\.$#' - identifier: method.notFound - count: 3 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Mapper\:\:expects\(\)\.$#' - identifier: method.notFound - count: 21 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Update\\Handler\:\:expects\(\)\.$#' - identifier: method.notFound - count: 6 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:getMapperMock\(\) has parameter \$methods with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:getPartlyMockedHandler\(\) has parameter \$methods with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testAddFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testCopy\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testCreate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testCreateGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testCreateVersion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testDeleteGroupFailure\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testDeleteGroupSuccess\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testDeleteSuccess\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testDeleteThrowsBadStateException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testGetContentCount\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testGetFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testLink\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testLoad\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testLoadAllGroups\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testLoadByIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testLoadByRemoteId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testLoadContentTypes\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testLoadDefaultVersion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testLoadGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testLoadGroupByIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testLoadNotFound\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testPublish\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testPublishNoOldType\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testRemoveContentTypeTranslation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testRemoveFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testUnlinkFailure\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testUnlinkSuccess\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testUpdate\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testUpdateFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:testUpdateGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:\$gatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:\$mapperMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Mapper\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:\$storageDispatcherMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\StorageDispatcherInterface&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:\$updateHandlerMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Update\\Handler\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Core\\\\Persistence\\\\Legacy\\\\Content\\\\Type\\\\ContentUpdater\\\\Action\\\\AddField'' and Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddField will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:getContentFixture\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:getContentGatewayMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:getContentMapperMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:getContentStorageHandlerMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageHandler&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageHandler\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:getFieldValueConverterMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:getMockedAction\(\) has parameter \$methods with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:testApplyMultipleVersionsMultipleTranslations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:testApplyMultipleVersionsSingleTranslation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:testApplySingleVersionMultipleTranslations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:testApplySingleVersionSingleTranslation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:testConstructor\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:testInsertExistingField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:testInsertExistingFieldUpdating\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:testInsertNewField\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:testInsertNewFieldUpdating\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Parameter \#1 \$id of method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:getFieldReference\(\) expects int, null given\.$#' - identifier: argument.type - count: 6 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Parameter \#1 \$id of method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:getFieldReference\(\) expects int, string given\.$#' - identifier: argument.type - count: 3 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Property Ibexa\\Contracts\\Core\\Persistence\\Content\\Field\:\:\$id \(int\) does not accept null\.$#' - identifier: assign.propertyType - count: 2 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:\$contentGatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:\$contentMapperMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:\$contentStorageHandlerMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageHandler\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:\$fieldValueConverterMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveFieldTest\:\:getContentFixture\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveFieldTest\:\:getContentGatewayMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveFieldTest\:\:getContentMapperMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveFieldTest\:\:getContentStorageHandlerMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageHandler&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageHandler\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveFieldTest\:\:testApplyMultipleVersionsMultipleTranslations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveFieldTest\:\:testApplyMultipleVersionsSingleTranslation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveFieldTest\:\:testApplySingleVersionSingleTranslation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveFieldTest\:\:\$contentGatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveFieldTest\:\:\$contentMapperMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveFieldTest\:\:\$contentStorageHandlerMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageHandler\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveFieldTest\:\:\$removeFieldAction \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveField\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldValue\\ConverterRegistry\:\:expects\(\)\.$#' - identifier: method.notFound - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdaterTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\:\:expects\(\)\.$#' - identifier: method.notFound - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdaterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdaterTest\:\:testApplyUpdates\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdaterTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdaterTest\:\:testDetermineActions\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdaterTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdaterTest\:\:\$contentGatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdaterTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdaterTest\:\:\$contentMapperMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdaterTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdaterTest\:\:\$contentStorageHandlerMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageHandler\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdaterTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdaterTest\:\:\$contentUpdater \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdaterTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdaterTest\:\:\$converterRegistryMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldValue\\ConverterRegistry\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdaterTest.php - - - - message: '#^Method Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabase\:\:countInstancesOfType\(\) invoked with 2 parameters, 1 required\.$#' - identifier: arguments.count - count: 2 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:getTypeCreationContentClassNameExpectations\(\) should return array\\> but returns array\\|string\>\>\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:getTypeCreationExpectations\(\) should return array\\> but returns array\\>\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testCountGroupsForType\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testCountInstancesOfTypeExist\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testCountInstancesOfTypeNotExist\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testCountTypesInGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testDeleteFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testDeleteFieldDefinitionsForTypeExisting\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testDeleteFieldDefinitionsForTypeNotExisting\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testDeleteGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testDeleteGroupAssignment\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testDeleteGroupAssignmentsForTypeExisting\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testDeleteGroupAssignmentsForTypeNotExisting\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testDeleteTypeExisting\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testDeleteTypeNotExisting\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testInsertFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testInsertGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testInsertGroupAssignment\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testInsertType\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testInsertType\(\) has parameter \$column with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testInsertType\(\) has parameter \$expectation with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testInsertTypeContentClassName\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testInsertTypeContentClassName\(\) has parameter \$column with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testInsertTypeContentClassName\(\) has parameter \$expectation with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testLoadAllGroupsData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testLoadGroupData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testLoadGroupDataByIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testLoadTypeData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testLoadTypeDataByIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testLoadTypeDataByRemoteId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testLoadTypesDataForGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testPublishTypeAndFields\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testUpdateFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testUpdateGroup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testUpdateType\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testUpdateType\(\) has parameter \$expectedValue with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testUpdateType\(\) has parameter \$fieldName with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testUpdateTypeName\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Property Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\:\:\$description \(array\\) does not accept array\\.$#' - identifier: assign.propertyType - count: 2 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Property Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\FieldDefinition\:\:\$defaultValue \(Ibexa\\Contracts\\Core\\Persistence\\Content\\FieldValue\) does not accept array\\.$#' - identifier: assign.propertyType - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:\$gateway \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabase\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Result of method Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabase\:\:updateGroup\(\) \(void\) is used\.$#' - identifier: method.void - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Argument of an invalid type Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\CreateStruct supplied for foreach, only iterables are supported\.$#' - identifier: foreach.nonIterable - count: 2 - path: tests/lib/Persistence/Legacy/Content/Type/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\MapperTest\:\:getLoadGroupFixture\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\MapperTest\:\:getLoadTypeFixture\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\MapperTest\:\:getMaskGeneratorMock\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\MapperTest\:\:testCreateGroupFromCreateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\MapperTest\:\:testCreateStructFromType\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\MapperTest\:\:testExtractGroupsFromRows\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\MapperTest\:\:testExtractTypesFromRowsSingle\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\MapperTest\:\:testToFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\MapperTest\:\:testToStorageFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\MapperTest\:\:testTypeFromCreateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/MapperTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\MapperTest\:\:testTypeFromUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/MapperTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\:\:expects\(\)\.$#' - identifier: method.notFound - count: 2 - path: tests/lib/Persistence/Legacy/Content/Type/Update/Handler/DoctrineDatabaseTest.php - - - - message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\:\:expects\(\)\.$#' - identifier: method.notFound - count: 2 - path: tests/lib/Persistence/Legacy/Content/Type/Update/Handler/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Update\\Handler\\DoctrineDatabase\:\:deleteOldType\(\) invoked with 2 parameters, 1 required\.$#' - identifier: arguments.count - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Update/Handler/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Update\\Handler\\DoctrineDatabaseTest\:\:testDeleteOldType\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Update/Handler/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Update\\Handler\\DoctrineDatabaseTest\:\:testPublishNewType\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Update/Handler/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Update\\Handler\\DoctrineDatabaseTest\:\:testUpdateContentObjects\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Update/Handler/DoctrineDatabaseTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Update\\Handler\\DoctrineDatabaseTest\:\:\$contentUpdaterMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Update/Handler/DoctrineDatabaseTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Update\\Handler\\DoctrineDatabaseTest\:\:\$gatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/Type/Update/Handler/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:getGateway\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabase but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\.$#' - identifier: return.type - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:providerForTestArchiveUrlAliasesForDeletedTranslations\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:providerForTestCleanupAfterPublishHistorize\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:providerForTestCleanupAfterPublishRemovesLanguage\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:providerForTestLoadPathData\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:providerForTestLoadPathDataMultipleLanguages\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testArchiveUrlAliasesForDeletedTranslations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testCleanupAfterPublishHistorize\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testCleanupAfterPublishHistorize\(\) has parameter \$action with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testCleanupAfterPublishHistorize\(\) has parameter \$languageId with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testCleanupAfterPublishHistorize\(\) has parameter \$parentId with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testCleanupAfterPublishHistorize\(\) has parameter \$textMD5 with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testCleanupAfterPublishRemovesLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testCleanupAfterPublishRemovesLanguage\(\) has parameter \$action with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testCleanupAfterPublishRemovesLanguage\(\) has parameter \$languageId with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testCleanupAfterPublishRemovesLanguage\(\) has parameter \$parentId with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testCleanupAfterPublishRemovesLanguage\(\) has parameter \$textMD5 with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testGetNextId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testLoadPathData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testLoadPathData\(\) has parameter \$id with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testLoadPathData\(\) has parameter \$pathData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testLoadPathDataMultipleLanguages\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testLoadPathDataMultipleLanguages\(\) has parameter \$id with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testLoadPathDataMultipleLanguages\(\) has parameter \$pathData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testLoadUrlaliasData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testLoadUrlaliasDataMultipleLanguages\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testLoadUrlaliasDataNonExistent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testRemove\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testRemoveCustomAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testRemoveCustomAliasFails\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testRemoveWithId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testReparent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:\$gateway \(Ibexa\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - - - message: '#^Argument of an invalid type Ibexa\\Contracts\\Core\\Persistence\\Content\\UrlAlias supplied for foreach, only iterables are supported\.$#' - identifier: foreach.nonIterable - count: 4 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Persistence\\\\Content\\\\UrlAlias'' and Ibexa\\Contracts\\Core\\Persistence\\Content\\UrlAlias will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:assertVirtualUrlAliasValid\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:assertVirtualUrlAliasValid\(\) has parameter \$id with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:getHistoryAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:getPartlyMockedHandler\(\) has parameter \$methods with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:providerForArchiveUrlAliasesForDeletedTranslations\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:providerForTestLookupCustomLocationUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:providerForTestLookupLocationMultipleLanguages\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:providerForTestLookupLocationUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:providerForTestLookupResourceUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:providerForTestLookupVirtualUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:providerForTestPublishUrlAliasForLocationComplex\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:providerForTestPublishUrlAliasForLocationSkipsReservedWord\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testArchiveUrlAliasesForDeletedTranslations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testCreateCustomUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testCreateCustomUrlAliasBehaviour\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testCreateCustomUrlAliasReusesHistory\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testCreateCustomUrlAliasReusesHistoryOfDifferentLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testCreateCustomUrlAliasReusesLocationElement\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testCreateCustomUrlAliasReusesNopElement\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testCreateCustomUrlAliasWithNonameParts\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testCreateGlobalUrlAliasBehaviour\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testCreatedCustomUrlAliasIsLoadable\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testListGlobalURLAliases\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testListGlobalURLAliasesWithLanguageCode\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testListGlobalURLAliasesWithOffset\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testListGlobalURLAliasesWithOffsetAndLimit\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testListURLAliasesForLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadAutogeneratedUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadAutogeneratedUrlAlias\(\) has parameter \$alwaysAvailable with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadAutogeneratedUrlAlias\(\) has parameter \$id with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadAutogeneratedUrlAlias\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadAutogeneratedUrlAlias\(\) has parameter \$locationId with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadAutogeneratedUrlAlias\(\) has parameter \$pathData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadAutogeneratedUrlAlias\(\) has parameter \$url with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadHistoryUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadResourceUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadResourceUrlAlias\(\) has parameter \$alwaysAvailable with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadResourceUrlAlias\(\) has parameter \$destination with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadResourceUrlAlias\(\) has parameter \$forward with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadResourceUrlAlias\(\) has parameter \$id with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadResourceUrlAlias\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadResourceUrlAlias\(\) has parameter \$pathData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadResourceUrlAlias\(\) has parameter \$url with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadUrlAliasThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadVirtualUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadVirtualUrlAlias\(\) has parameter \$id with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadVirtualUrlAlias\(\) has parameter \$url with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationCopiedCopiedLocationAliasIsValid\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationCopiedCopiedSubtreeIsValid\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationCopiedHistoryNotCopied\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationCopiedSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationCopiedSubtreeHistoryNotCopied\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationDeleted\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationMovedHistorize\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationMovedHistory\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationMovedHistorySubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationMovedReparent\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationMovedReparentHistory\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationMovedReparentSubtree\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationMovedReparentSubtreeHistory\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationSwappedMultipleLanguagesDifferentLanguages\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationSwappedMultipleLanguagesDifferentLanguagesSimple\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationSwappedMultipleLanguagesSimple\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationSwappedMultipleLanguagesUpdatesLocationPathIdentificationString\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationSwappedMultipleLanguagesWithCompositeHistory\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationSwappedSiblingsSameName\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationSwappedSiblingsSameNameMultipleLanguages\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationSwappedSiblingsSameNameReverse\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationSwappedSiblingsSimple\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationSwappedSiblingsSimpleReverse\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationSwappedSiblingsSimpleWithHistory\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationSwappedSiblingsSimpleWithHistoryReverse\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationSwappedSimple\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationSwappedSimpleWithConflict\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationSwappedSimpleWithHistory\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationSwappedUpdatesLocationPathIdentificationString\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationSwappedWithReusingExternalHistory\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationSwappedWithReusingNopEntry\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLocationSwappedWithReusingNopEntryCustomAliasIsDestroyed\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookup\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAlias\(\) has parameter \$alwaysAvailable with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAlias\(\) has parameter \$destination with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAlias\(\) has parameter \$forward with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAlias\(\) has parameter \$id with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAlias\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAlias\(\) has parameter \$pathData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAlias\(\) has parameter \$url with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAliasCaseCorrection\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAliasCaseCorrection\(\) has parameter \$alwaysAvailable with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAliasCaseCorrection\(\) has parameter \$destination with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAliasCaseCorrection\(\) has parameter \$forward with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAliasCaseCorrection\(\) has parameter \$id with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAliasCaseCorrection\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAliasCaseCorrection\(\) has parameter \$pathData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAliasCaseCorrection\(\) has parameter \$url with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationCaseCorrection\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationCaseCorrection\(\) has parameter \$alwaysAvailable with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationCaseCorrection\(\) has parameter \$id with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationCaseCorrection\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationCaseCorrection\(\) has parameter \$locationId with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationCaseCorrection\(\) has parameter \$pathData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationCaseCorrection\(\) has parameter \$url with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationHistoryUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationMultipleLanguages\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationMultipleLanguages\(\) has parameter \$alwaysAvailable with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationMultipleLanguages\(\) has parameter \$id with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationMultipleLanguages\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationMultipleLanguages\(\) has parameter \$locationId with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationMultipleLanguages\(\) has parameter \$pathData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationMultipleLanguages\(\) has parameter \$url with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Collection\\MapInterface\:\:exists\(\)\.$#' + identifier: method.notFound + count: 2 + path: tests/lib/Collection/ArrayMapTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Collection\\MapInterface\:\:filter\(\)\.$#' + identifier: method.notFound count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/Collection/ArrayMapTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationUrlAlias\(\) has parameter \$alwaysAvailable with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Collection\\MapInterface\:\:forAll\(\)\.$#' + identifier: method.notFound + count: 2 + path: tests/lib/Collection/ArrayMapTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationUrlAlias\(\) has parameter \$id with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Collection\\MapInterface\:\:map\(\)\.$#' + identifier: method.notFound count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/Collection/ArrayMapTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationUrlAlias\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Collection\\ArrayMapTest\:\:createCollection\(\) has parameter \$data with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/Collection/ArrayMapTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationUrlAlias\(\) has parameter \$locationId with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Collection\\ArrayMapTest\:\:createCollection\(\) return type with generic interface Ibexa\\Contracts\\Core\\Collection\\MapInterface does not specify its types\: TKey, TValue$#' + identifier: missingType.generics count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/Collection/ArrayMapTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationUrlAlias\(\) has parameter \$pathData with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Collection\\ArrayMapTest\:\:getExampleData\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationUrlAlias\(\) has parameter \$url with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAlias\(\) has parameter \$alwaysAvailable with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/Collection/ArrayMapTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAlias\(\) has parameter \$destination with no type specified\.$#' - identifier: missingType.parameter + message: '#^PHPDoc tag @return with type Ibexa\\Contracts\\Core\\Collection\\MapInterface\|Ibexa\\Contracts\\Core\\Collection\\StreamableInterface is not subtype of native type Ibexa\\Contracts\\Core\\Collection\\MapInterface\.$#' + identifier: return.phpDocType count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/Collection/ArrayMapTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAlias\(\) has parameter \$forward with no type specified\.$#' - identifier: missingType.parameter + message: '#^PHPDoc tag @var for variable \$map contains generic class Ibexa\\Contracts\\Core\\Collection\\ArrayMap but does not specify its types\: TKey, TValue$#' + identifier: missingType.generics count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/Collection/ArrayMapTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAlias\(\) has parameter \$id with no type specified\.$#' - identifier: missingType.parameter + message: '#^Type Ibexa\\Contracts\\Core\\Collection\\ArrayMap in generic type Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\ in PHPDoc tag @extends is not subtype of template type TCollection of Ibexa\\Contracts\\Core\\Repository\\Collection\\CollectionInterfaces of class Ibexa\\Tests\\Core\\Collection\\AbstractCollectionTestCase\.$#' + identifier: generics.notSubtype count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/Collection/ArrayMapTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAlias\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Collection\\MutableArrayListTest\:\:createCollection\(\) has parameter \$data with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAlias\(\) has parameter \$pathData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAlias\(\) has parameter \$url with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAliasCaseInsensitive\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAliasCaseInsensitive\(\) has parameter \$alwaysAvailable with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAliasCaseInsensitive\(\) has parameter \$destination with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/Collection/MutableArrayListTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAliasCaseInsensitive\(\) has parameter \$forward with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Collection\\MutableArrayListTest\:\:createCollection\(\) return type with generic class Ibexa\\Contracts\\Core\\Collection\\MutableArrayList does not specify its types\: TValue$#' + identifier: missingType.generics count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/Collection/MutableArrayListTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAliasCaseInsensitive\(\) has parameter \$id with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + message: '#^PHPDoc tag @var for variable \$list contains generic class Ibexa\\Contracts\\Core\\Collection\\MutableArrayList but does not specify its types\: TValue$#' + identifier: missingType.generics + count: 4 + path: tests/lib/Collection/MutableArrayListTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAliasCaseInsensitive\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Collection\\MutableArrayMapTest\:\:createCollection\(\) has parameter \$data with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAliasCaseInsensitive\(\) has parameter \$pathData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAliasCaseInsensitive\(\) has parameter \$url with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupUppercaseIri\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupVirtualUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupVirtualUrlAlias\(\) has parameter \$id with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupVirtualUrlAlias\(\) has parameter \$url with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasCreatesUniqueAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationComplex\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationComplex\(\) has parameter \$alwaysAvailable with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationComplex\(\) has parameter \$id with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/Collection/MutableArrayMapTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationComplex\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Collection\\MutableArrayMapTest\:\:createCollection\(\) return type with generic class Ibexa\\Contracts\\Core\\Collection\\MutableArrayMap does not specify its types\: TKey, TValue$#' + identifier: missingType.generics count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/Collection/MutableArrayMapTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationComplex\(\) has parameter \$locationId with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertSame\(\) with Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Trash\\TrashItemDeleteResult and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Trash\\TrashItemDeleteResult will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/Event/TrashServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationComplex\(\) has parameter \$pathData with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + message: '#^Parameter \#4 \$forwarding of method Ibexa\\Core\\Event\\URLAliasService\:\:createGlobalUrlAlias\(\) expects bool, string given\.$#' + identifier: argument.type + count: 3 + path: tests/lib/Event/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationComplex\(\) has parameter \$url with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + message: '#^Parameter \#4 \$forwarding of method Ibexa\\Core\\Event\\URLAliasService\:\:createUrlAlias\(\) expects bool, string given\.$#' + identifier: argument.type + count: 3 + path: tests/lib/Event/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationDowngradesOldEntryRemovesLanguage\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + message: '#^Parameter \#5 \$alwaysAvailable of method Ibexa\\Core\\Event\\URLAliasService\:\:createGlobalUrlAlias\(\) expects bool, string given\.$#' + identifier: argument.type + count: 3 + path: tests/lib/Event/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationDowngradesOldEntryToHistory\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + message: '#^Parameter \#5 \$alwaysAvailable of method Ibexa\\Core\\Event\\URLAliasService\:\:createUrlAlias\(\) expects bool, string given\.$#' + identifier: argument.type + count: 3 + path: tests/lib/Event/URLAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationRepublish\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertSame\(\) with Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\URLWildcardTranslationResult and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\URLWildcardTranslationResult will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/Event/URLWildcardServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationReusesCustomAlias\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + message: '#^Parameter \#3 \$forward of method Ibexa\\Core\\Event\\URLWildcardService\:\:create\(\) expects bool, string given\.$#' + identifier: argument.type + count: 3 + path: tests/lib/Event/URLWildcardServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationReusesHistory\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + message: '#^Access to an undefined property Ibexa\\Core\\FieldType\\Validator\\EmailAddressValidator\:\:\$Extent\.$#' + identifier: property.notFound + count: 4 + path: tests/lib/FieldType/EmailAddressValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationReusesHistoryOfDifferentLanguage\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Core\\\\FieldType\\\\Validator'' and Ibexa\\Core\\FieldType\\Validator\\EmailAddressValidator will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/FieldType/EmailAddressValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationReusingNopElement\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + message: '#^Access to an undefined property Ibexa\\Core\\FieldType\\Validator\\FileSizeValidator\:\:\$unexisting\.$#' + identifier: property.notFound + count: 2 + path: tests/lib/FieldType/FileSizeValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationReusingNopElementChangesCustomPath\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Access to protected property Ibexa\\Contracts\\Core\\Repository\\Values\\Translation\\Message\:\:\$message\.$#' + identifier: property.protected count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/FieldType/FileSizeValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationReusingNopElementChangesCustomPathAndCreatesHistory\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Access to protected property Ibexa\\Contracts\\Core\\Repository\\Values\\Translation\\Message\:\:\$values\.$#' + identifier: property.protected count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/FieldType/FileSizeValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationSameAliasForMultipleLanguages\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Core\\\\FieldType\\\\Validator'' and Ibexa\\Core\\FieldType\\Validator\\FileSizeValidator will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/FieldType/FileSizeValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationSkipsReservedWord\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\FieldType\\FileSizeValidatorTest\:\:testValidateWrongValues\(\) has parameter \$message with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/FieldType/FileSizeValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationSkipsReservedWord\(\) has parameter \$alias with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\FieldType\\FileSizeValidatorTest\:\:testValidateWrongValues\(\) has parameter \$size with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/FieldType/FileSizeValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationSkipsReservedWord\(\) has parameter \$text with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\FieldType\\FileSizeValidatorTest\:\:testValidateWrongValues\(\) has parameter \$values with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/FieldType/FileSizeValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationUpdatesLocationPathIdentificationString\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + message: '#^Unreachable statement \- code above always terminates\.$#' + identifier: deadCode.unreachable + count: 3 + path: tests/lib/FieldType/FileSizeValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasReuseAutogeneratedCleanup\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$value of class Ibexa\\Core\\FieldType\\Float\\Value constructor expects float\|null, string given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/FieldType/FloatTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasReuseHistoryCleanup\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\FieldType\\Generic\\Stubs\\Value\:\:__construct\(\) has parameter \$value with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/FieldType/Generic/Stubs/Value.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasReuseNopCleanupCustomAliasIsDestroyed\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\FieldType\\Generic\\Stubs\\Value\:\:getValue\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:\$languageHandler \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Handler\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/FieldType/Generic/Stubs/Value.php - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:\$languageMaskGenerator \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGenerator\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Property Ibexa\\Tests\\Core\\FieldType\\Generic\\Stubs\\Value\:\:\$value has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + path: tests/lib/FieldType/Generic/Stubs/Value.php - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:\$locationGateway \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php + message: '#^Call to an undefined method Ibexa\\Core\\FieldType\\ImageAsset\\AssetMapper\:\:expects\(\)\.$#' + identifier: method.notFound + count: 4 + path: tests/lib/FieldType/ImageAsset/AssetMapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasMapperTest\:\:getExpectation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasMapperTest.php + message: '#^Call to an undefined method Ibexa\\Core\\Repository\\Values\\Content\\Content\:\:expects\(\)\.$#' + identifier: method.notFound + count: 2 + path: tests/lib/FieldType/ImageAsset/AssetMapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasMapperTest\:\:providerForTestExtractUrlAliasFromData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\FieldType\\ImageAsset\\AssetMapperTest\:\:createPartialMapper\(\) has parameter \$methods with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasMapperTest.php + path: tests/lib/FieldType/ImageAsset/AssetMapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasMapperTest\:\:testExtractLanguageCodesFromData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\FieldType\\ImageAsset\\AssetMapperTest\:\:dataProviderForIsAsset\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasMapperTest.php + path: tests/lib/FieldType/ImageAsset/AssetMapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasMapperTest\:\:testExtractUrlAliasFromData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\FieldType\\ImageAsset\\AssetMapperTest\:\:\$mappings type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasMapperTest.php + path: tests/lib/FieldType/ImageAsset/AssetMapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasMapperTest\:\:testExtractUrlAliasFromData\(\) has parameter \$index with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$value of class Ibexa\\Core\\FieldType\\Integer\\Value constructor expects int\|null, string given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasMapperTest.php + path: tests/lib/FieldType/IntegerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasMapperTest\:\:testExtractUrlAliasListFromData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasMapperTest.php + message: '#^Parameter \#1 \$contentId of method Ibexa\\Tests\\Core\\FieldType\\RelationListTest\:\:generateValidationError\(\) expects string, int given\.$#' + identifier: argument.type + count: 2 + path: tests/lib/FieldType/RelationListTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasMapperTest\:\:\$fixture has no type specified\.$#' - identifier: missingType.property + message: '#^Parameter \#1 \$value of method Ibexa\\Core\\FieldType\\RelationList\\Type\:\:getRelations\(\) expects Ibexa\\Core\\FieldType\\RelationList\\Value, Ibexa\\Core\\FieldType\\Value given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasMapperTest.php + path: tests/lib/FieldType/RelationListTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\Gateway\\DoctrineDatabaseTest\:\:testDeleteUrlWildcard\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$fieldValue of method Ibexa\\Core\\FieldType\\Relation\\Type\:\:getRelations\(\) expects Ibexa\\Core\\FieldType\\Relation\\Value, Ibexa\\Core\\FieldType\\Value given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlWildcard/Gateway/DoctrineDatabaseTest.php + path: tests/lib/FieldType/RelationTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\Gateway\\DoctrineDatabaseTest\:\:testInsertUrlWildcard\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlWildcard/Gateway/DoctrineDatabaseTest.php + message: '#^Parameter \#1 \$selection of class Ibexa\\Core\\FieldType\\Selection\\Value constructor expects array\, array\ given\.$#' + identifier: argument.type + count: 4 + path: tests/lib/FieldType/SelectionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\Gateway\\DoctrineDatabaseTest\:\:testLoadUrlWildcardData\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlWildcard/Gateway/DoctrineDatabaseTest.php + message: '#^Cannot access offset ''urlId'' on array\|bool\|float\|int\|string\|null\.$#' + identifier: offsetAccess.nonOffsetAccessible + count: 2 + path: tests/lib/FieldType/Url/UrlStorageTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\Gateway\\DoctrineDatabaseTest\:\:testLoadUrlWildcardsData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\FieldType\\Url\\UrlStorageTest\:\:\$gatewayMock \(Ibexa\\Core\\FieldType\\Url\\UrlStorage\\Gateway&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlWildcard/Gateway/DoctrineDatabaseTest.php + path: tests/lib/FieldType/Url/UrlStorageTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\Gateway\\DoctrineDatabaseTest\:\:testLoadUrlWildcardsDataWithOffset\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\FieldType\\Url\\UrlStorageTest\:\:\$loggerMock \(PHPUnit\\Framework\\MockObject\\MockObject&Psr\\Log\\LoggerInterface\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlWildcard/Gateway/DoctrineDatabaseTest.php + path: tests/lib/FieldType/Url/UrlStorageTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\Gateway\\DoctrineDatabaseTest\:\:testLoadUrlWildcardsDataWithOffsetAndLimit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$link of class Ibexa\\Core\\FieldType\\Url\\Value constructor expects string\|null, int given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlWildcard/Gateway/DoctrineDatabaseTest.php + path: tests/lib/FieldType/UrlTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\Gateway\\DoctrineDatabaseTest\:\:\$fixtureData has no type specified\.$#' - identifier: missingType.property + message: '#^Method Ibexa\\Tests\\Core\\FieldType\\UserTest\:\:providerForTestCreatePersistenceValue\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlWildcard/Gateway/DoctrineDatabaseTest.php + path: tests/lib/FieldType/UserTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\Gateway\\DoctrineDatabaseTest\:\:\$gateway \(Ibexa\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\Gateway\\DoctrineDatabase\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Method Ibexa\\Tests\\Core\\FieldType\\UserTest\:\:providerForTestValidate\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlWildcard/Gateway/DoctrineDatabaseTest.php + path: tests/lib/FieldType/UserTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\UrlWildcardHandlerTest\:\:testCreate\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\FieldType\\UserTest\:\:testCreatePersistenceValue\(\) has parameter \$expectedFieldValueExternalData with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardHandlerTest.php + path: tests/lib/FieldType/UserTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\UrlWildcardHandlerTest\:\:testLoad\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\FieldType\\UserTest\:\:testCreatePersistenceValue\(\) has parameter \$userValueDate with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardHandlerTest.php + path: tests/lib/FieldType/UserTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\UrlWildcardHandlerTest\:\:testLoadAll\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\FieldType\\UserTest\:\:testValidate\(\) has parameter \$expectedValidationErrors with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardHandlerTest.php + path: tests/lib/FieldType/UserTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\UrlWildcardHandlerTest\:\:testLoadAllWithOffset\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Core\\\\FieldType\\\\Validator'' and Ibexa\\Core\\FieldType\\Validator\\StringLengthValidator will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardHandlerTest.php + path: tests/lib/FieldType/Validator/StringLengthValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\UrlWildcardHandlerTest\:\:testLoadAllWithOffsetAndLimit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Constant Ibexa\\Tests\\Core\\Helper\\FieldsGroups\\ArrayTranslatorFieldsGroupsListTest\:\:DEFAULT_GROUP_NAME is unused\.$#' + identifier: classConstant.unused count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardHandlerTest.php + path: tests/lib/Helper/FieldsGroups/ArrayTranslatorFieldsGroupsListTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\UrlWildcardHandlerTest\:\:testLoadThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Helper\\FieldsGroups\\ArrayTranslatorFieldsGroupsListTest\:\:getArrayTranslatorFieldsGroupsList\(\) has parameter \$groups with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardHandlerTest.php + path: tests/lib/Helper/FieldsGroups/ArrayTranslatorFieldsGroupsListTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\UrlWildcardHandlerTest\:\:testRemove\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Helper\\FieldsGroups\\ArrayTranslatorFieldsGroupsListTest\:\:getFieldDefinitionMock\(\) has parameter \$constructorArgs with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardHandlerTest.php + path: tests/lib/Helper/FieldsGroups/ArrayTranslatorFieldsGroupsListTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\UrlWildcardHandlerTest\:\:\$fixtureData has no type specified\.$#' + message: '#^Property Ibexa\\Tests\\Core\\Helper\\FieldsGroups\\ArrayTranslatorFieldsGroupsListTest\:\:\$translatorMock has no type specified\.$#' identifier: missingType.property count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardHandlerTest.php - - - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\UrlWildcardHandlerTest\:\:\$urlWildcardHandler \(Ibexa\\Contracts\\Core\\Persistence\\Content\\UrlWildcard\\Handler\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardHandlerTest.php + path: tests/lib/Helper/FieldsGroups/ArrayTranslatorFieldsGroupsListTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\UrlWildcardMapperTest\:\:testCreateUrlWildcard\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:getTranslatedField\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardMapperTest.php + path: tests/lib/Helper/TranslationHelperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\UrlWildcardMapperTest\:\:testExtractUrlWildcardFromRow\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:getTranslatedField\(\) has parameter \$prioritizedLanguages with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardMapperTest.php + path: tests/lib/Helper/TranslationHelperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\UrlWildcardMapperTest\:\:testExtractUrlWildcardsFromRows\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetTranslatedName\(\) has parameter \$prioritizedLanguages with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardMapperTest.php + path: tests/lib/Helper/TranslationHelperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\FieldValue\\Converter\\ImageConverterTest\:\:fieldValueToXmlProvider\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetTranslatedNameByContentInfo\(\) has parameter \$prioritizedLanguages with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/FieldValue/Converter/ImageConverterTest.php + path: tests/lib/Helper/TranslationHelperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\FieldValue\\Converter\\ImageConverterTest\:\:xmlToFieldValueProvider\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetTranslationSiteAccess\(\) has parameter \$expectedResult with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/FieldValue/Converter/ImageConverterTest.php + path: tests/lib/Helper/TranslationHelperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Filter\\BaseCriterionVisitorQueryBuilderTestCase\:\:getBaseCriterionQueryBuilders\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetTranslationSiteAccess\(\) has parameter \$language with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/Filter/BaseCriterionVisitorQueryBuilderTestCase.php + path: tests/lib/Helper/TranslationHelperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Filter\\BaseCriterionVisitorQueryBuilderTestCase\:\:getFilteringCriteriaQueryData\(\) return type has no value type specified in iterable type iterable\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetTranslationSiteAccess\(\) has parameter \$relatedSiteAccesses with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Filter/BaseCriterionVisitorQueryBuilderTestCase.php + path: tests/lib/Helper/TranslationHelperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Filter\\BaseCriterionVisitorQueryBuilderTestCase\:\:testVisitCriteriaProducesQuery\(\) has parameter \$expectedParameterValues with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:testGetTranslationSiteAccess\(\) has parameter \$translationSiteAccesses with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Filter/BaseCriterionVisitorQueryBuilderTestCase.php + path: tests/lib/Helper/TranslationHelperTest.php - - message: '#^Parameter \#1 \.\.\.\$arrays of function array_merge expects array, iterable given\.$#' - identifier: argument.type + message: '#^Property Ibexa\\Tests\\Core\\Helper\\TranslationHelperTest\:\:\$siteAccessByLanguages has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Persistence/Legacy/Filter/BaseCriterionVisitorQueryBuilderTestCase.php + path: tests/lib/Helper/TranslationHelperTest.php - - message: '#^Parameter \#2 \.\.\.\$arrays of function array_merge expects array, iterable\ given\.$#' - identifier: argument.type + message: '#^Property Ibexa\\Tests\\Core\\IO\\ConfigScopeChangeAwareIOServiceTest\:\:\$innerIOService \(Ibexa\\Core\\IO\\ConfigScopeChangeAwareIOService&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept Ibexa\\Core\\IO\\IOServiceInterface&PHPUnit\\Framework\\MockObject\\MockObject\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Persistence/Legacy/Filter/BaseCriterionVisitorQueryBuilderTestCase.php + path: tests/lib/IO/ConfigScopeChangeAwareIOServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Filter\\CriterionQueryBuilder\\Content\\LanguageCodeQueryBuilderQueryBuilderTest\:\:getFilteringCriteriaQueryData\(\) return type has no value type specified in iterable type iterable\.$#' + message: '#^Method Ibexa\\Tests\\Core\\IO\\FilePathNormalizer\\FlysystemTest\:\:providerForTestNormalizePath\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Content/LanguageCodeQueryBuilderQueryBuilderTest.php + path: tests/lib/IO/FilePathNormalizer/FlysystemTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Filter\\CriterionQueryBuilder\\Content\\Type\\ContentTypeGroupIdQueryBuilderTest\:\:getFilteringCriteriaQueryData\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$suffix of static method PHPUnit\\Framework\\Assert\:\:assertStringEndsWith\(\) expects non\-empty\-string, string given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Content/Type/ContentTypeGroupIdQueryBuilderTest.php + path: tests/lib/IO/FilePathNormalizer/FlysystemTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Filter\\CriterionQueryBuilder\\Content\\Type\\ContentTypeQueryBuildersTest\:\:getFilteringCriteriaQueryData\(\) return type has no value type specified in iterable type iterable\.$#' + message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\BaseVisibilityConverterTestCase\:\:getDataForTestForDirectory\(\) return type has no value type specified in iterable type iterable\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Content/Type/ContentTypeQueryBuildersTest.php + path: tests/lib/IO/Flysystem/VisibilityConverter/BaseVisibilityConverterTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Filter\\CriterionQueryBuilder\\Location\\AncestorQueryBuilderTest\:\:getFilteringCriteriaQueryData\(\) return type has no value type specified in iterable type iterable\.$#' + message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\BaseVisibilityConverterTestCase\:\:getDataForTestForFile\(\) return type has no value type specified in iterable type iterable\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/AncestorQueryBuilderTest.php + path: tests/lib/IO/Flysystem/VisibilityConverter/BaseVisibilityConverterTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Filter\\CriterionQueryBuilder\\Location\\LocationIdQueryBuilderTest\:\:getFilteringCriteriaQueryData\(\) return type has no value type specified in iterable type iterable\.$#' + message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\BaseVisibilityConverterTestCase\:\:getDataForTestInverseForDirectory\(\) return type has no value type specified in iterable type iterable\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/LocationIdQueryBuilderTest.php + path: tests/lib/IO/Flysystem/VisibilityConverter/BaseVisibilityConverterTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Filter\\CriterionQueryBuilder\\Location\\ParentLocationQueryBuilderTest\:\:getFilteringCriteriaQueryData\(\) return type has no value type specified in iterable type iterable\.$#' + message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\BaseVisibilityConverterTestCase\:\:getDataForTestInverseForFile\(\) return type has no value type specified in iterable type iterable\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/ParentLocationQueryBuilderTest.php + path: tests/lib/IO/Flysystem/VisibilityConverter/BaseVisibilityConverterTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Filter\\CriterionQueryBuilder\\LogicalOperatorQueryBuilderQueryBuilderTest\:\:getFilteringCriteriaQueryData\(\) return type has no value type specified in iterable type iterable\.$#' + message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\DFSVisibilityConverterTest\:\:getDataForTestForDirectory\(\) return type has no value type specified in iterable type iterable\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/LogicalOperatorQueryBuilderQueryBuilderTest.php + path: tests/lib/IO/Flysystem/VisibilityConverter/DFSVisibilityConverterTest.php - - message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Container\:\:get\(\)\.$#' - identifier: method.notFound + message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\DFSVisibilityConverterTest\:\:getDataForTestForFile\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/HandlerTest.php + path: tests/lib/IO/Flysystem/VisibilityConverter/DFSVisibilityConverterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Notification\\Gateway\\DoctrineDatabaseTest\:\:testCountUserNotifications\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\DFSVisibilityConverterTest\:\:getDataForTestInverseForDirectory\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Notification/Gateway/DoctrineDatabaseTest.php + path: tests/lib/IO/Flysystem/VisibilityConverter/DFSVisibilityConverterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Notification\\Gateway\\DoctrineDatabaseTest\:\:testCountUserPendingNotifications\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\DFSVisibilityConverterTest\:\:getDataForTestInverseForFile\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Notification/Gateway/DoctrineDatabaseTest.php + path: tests/lib/IO/Flysystem/VisibilityConverter/DFSVisibilityConverterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Notification\\Gateway\\DoctrineDatabaseTest\:\:testDelete\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\SiteAccessAwareVisibilityConverterTest\:\:getDataForTestForDirectory\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Notification/Gateway/DoctrineDatabaseTest.php + path: tests/lib/IO/Flysystem/VisibilityConverter/SiteAccessAwareVisibilityConverterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Notification\\Gateway\\DoctrineDatabaseTest\:\:testGetNotificationById\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\SiteAccessAwareVisibilityConverterTest\:\:getDataForTestForFile\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Notification/Gateway/DoctrineDatabaseTest.php + path: tests/lib/IO/Flysystem/VisibilityConverter/SiteAccessAwareVisibilityConverterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Notification\\Gateway\\DoctrineDatabaseTest\:\:testInsert\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\SiteAccessAwareVisibilityConverterTest\:\:getDataForTestInverseForDirectory\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Notification/Gateway/DoctrineDatabaseTest.php + path: tests/lib/IO/Flysystem/VisibilityConverter/SiteAccessAwareVisibilityConverterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Notification\\Gateway\\DoctrineDatabaseTest\:\:testUpdateNotification\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\IO\\Flysystem\\VisibilityConverter\\SiteAccessAwareVisibilityConverterTest\:\:getDataForTestInverseForFile\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Notification/Gateway/DoctrineDatabaseTest.php + path: tests/lib/IO/Flysystem/VisibilityConverter/SiteAccessAwareVisibilityConverterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Notification\\HandlerTest\:\:testCountNotifications\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\IO\\IOMetadataHandler\\FlysystemTest\:\:getDataForFileExists\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Notification/HandlerTest.php + path: tests/lib/IO/IOMetadataHandler/FlysystemTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Notification\\HandlerTest\:\:testCountPendingNotifications\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\IO\\IOMetadataHandler\\FlysystemTest\:\:\$handler \(Ibexa\\Core\\IO\\IOMetadataHandler&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept Ibexa\\Core\\IO\\IOMetadataHandler\\Flysystem\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Persistence/Legacy/Notification/HandlerTest.php + path: tests/lib/IO/IOMetadataHandler/FlysystemTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Notification\\HandlerTest\:\:testCreateNotification\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\IO\\UrlDecorator\\PrefixTest\:\:testDecorate\(\) has parameter \$decoratedUrl with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/Notification/HandlerTest.php + path: tests/lib/IO/UrlDecorator/PrefixTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Notification\\HandlerTest\:\:testDelete\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\IO\\UrlDecorator\\PrefixTest\:\:testDecorate\(\) has parameter \$prefix with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/Notification/HandlerTest.php + path: tests/lib/IO/UrlDecorator/PrefixTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Notification\\HandlerTest\:\:testGetNotificationById\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\IO\\UrlDecorator\\PrefixTest\:\:testDecorate\(\) has parameter \$url with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/Notification/HandlerTest.php + path: tests/lib/IO/UrlDecorator/PrefixTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Notification\\HandlerTest\:\:testUpdateNotification\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\IO\\UrlDecorator\\PrefixTest\:\:testUndecorate\(\) has parameter \$decoratedUrl with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/Notification/HandlerTest.php + path: tests/lib/IO/UrlDecorator/PrefixTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Notification\\MapperTest\:\:testCreateNotificationFromUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\IO\\UrlDecorator\\PrefixTest\:\:testUndecorate\(\) has parameter \$prefix with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/Notification/MapperTest.php + path: tests/lib/IO/UrlDecorator/PrefixTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Notification\\MapperTest\:\:testExtractNotificationsFromRows\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\IO\\UrlDecorator\\PrefixTest\:\:testUndecorate\(\) has parameter \$url with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/Notification/MapperTest.php + path: tests/lib/IO/UrlDecorator/PrefixTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Notification\\MapperTest\:\:testExtractNotificationsFromRowsThrowsRuntimeException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\IO\\UrlRedecoratorTest\:\:\$redecorator \(Ibexa\\Core\\IO\\UrlRedecorator&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept Ibexa\\Core\\IO\\UrlRedecorator\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Persistence/Legacy/Notification/MapperTest.php + path: tests/lib/IO/UrlRedecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Setting\\SettingHandlerTest\:\:getGatewayMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Setting\\Gateway&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Setting\\Gateway\.$#' - identifier: return.type + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\Base\:\:getPersistenceMock\(\) has parameter \$mockMethods with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Setting/SettingHandlerTest.php + path: tests/lib/Limitation/Base.php - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Setting\\SettingHandlerTest\:\:\$gatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Setting\\Gateway\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\Base\:\:getUserMock\(\) has parameter \$mockMethods with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Setting/SettingHandlerTest.php + path: tests/lib/Limitation/Base.php - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Setting\\SettingHandlerTest\:\:\$settingHandler \(Ibexa\\Core\\Persistence\\Legacy\\Setting\\Handler\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/Setting/SettingHandlerTest.php + path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - message: '#^Generator expects value type Doctrine\\DBAL\\Connection\|PHPUnit\\Framework\\MockObject\\MockObject, array\ given\.$#' - identifier: generator.valueType + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/SharedGateway/GatewayFactoryTest.php + path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - message: '#^Parameter \#1 \$expected of static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) expects class\-string\, string given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/SharedGateway/GatewayFactoryTest.php + path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TestCase\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:providerForTestEvaluateInvalidArgument\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/TestCase.php + path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TestCase\:\:assertPropertiesCorrect\(\) has parameter \$properties with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:providerForTestValidateError\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/TestCase.php + path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TestCase\:\:assertQueryResult\(\) has parameter \$expectation with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:providerForTestValidatePass\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/TestCase.php + path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TestCase\:\:assertStructsEqual\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:testEvaluate\(\) has parameter \$targets with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/TestCase.php + path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TestCase\:\:assertStructsEqual\(\) has parameter \$propertyNames with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\BlockingLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$targets with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/TestCase.php + path: tests/lib/Limitation/BlockingLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TestCase\:\:getPublicPropertyNames\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/TestCase.php + path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TestCase\:\:getResultTextRepresentation\(\) has parameter \$result with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/TestCase.php + path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\TestCase\:\:\$db \(string\) does not accept string\|null\.$#' - identifier: assign.propertyType + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/TestCase.php + path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\TestCase\:\:\$dsn \(string\) does not accept string\|false\.$#' - identifier: assign.propertyType + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:providerForTestEvaluateInvalidArgument\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/TestCase.php + path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TransactionHandlerTest\:\:getContentTypeHandlerMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\MemoryCachingHandler&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: return.type + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:providerForTestValidateError\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/TransactionHandlerTest.php + path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TransactionHandlerTest\:\:getLanguageHandlerMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\CachingHandler&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: return.type + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:providerForTestValidatePass\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/TransactionHandlerTest.php + path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TransactionHandlerTest\:\:testBeginTransaction\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:testEvaluate\(\) has parameter \$expected with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/TransactionHandlerTest.php + path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TransactionHandlerTest\:\:testCommit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:testEvaluate\(\) has parameter \$targets with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/TransactionHandlerTest.php + path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TransactionHandlerTest\:\:testCommitException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ContentTypeLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$targets with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/TransactionHandlerTest.php + path: tests/lib/Limitation/ContentTypeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TransactionHandlerTest\:\:testRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LanguageLimitation\\ContentDeleteEvaluatorTest\:\:dataProviderForAccept\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/TransactionHandlerTest.php + path: tests/lib/Limitation/LanguageLimitation/ContentDeleteEvaluatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TransactionHandlerTest\:\:testRollbackException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LanguageLimitation\\ContentDeleteEvaluatorTest\:\:dataProviderForEvaluate\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/TransactionHandlerTest.php + path: tests/lib/Limitation/LanguageLimitation/ContentDeleteEvaluatorTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\TransactionHandlerTest\:\:\$connectionMock \(Doctrine\\DBAL\\Connection&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LanguageLimitation\\ContentDeleteEvaluatorTest\:\:getLanguageLimitation\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/TransactionHandlerTest.php + path: tests/lib/Limitation/LanguageLimitation/ContentDeleteEvaluatorTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\TransactionHandlerTest\:\:\$contentTypeHandlerMock \(Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LanguageLimitation\\ContentDeleteEvaluatorTest\:\:getTergetVersion\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/TransactionHandlerTest.php + path: tests/lib/Limitation/LanguageLimitation/ContentDeleteEvaluatorTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\TransactionHandlerTest\:\:\$languageHandlerMock \(Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\:\:\$id\.$#' + identifier: property.notFound count: 1 - path: tests/lib/Persistence/Legacy/TransactionHandlerTest.php + path: tests/lib/Limitation/LocationLimitationTypeTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\TransactionHandlerTest\:\:\$transactionHandler \(Ibexa\\Core\\Persistence\\Legacy\\TransactionHandler\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/TransactionHandlerTest.php + path: tests/lib/Limitation/LocationLimitationTypeTest.php - - message: '#^Parameter \#1 \$url of method Ibexa\\Core\\Persistence\\Legacy\\URL\\Gateway\\DoctrineDatabase\:\:loadUrlDataByUrl\(\) expects int, string given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/Gateway/DoctrineDatabaseTest.php + path: tests/lib/Limitation/LocationLimitationTypeTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Gateway\\DoctrineDatabaseTest\:\:\$fixtureData type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/Gateway/DoctrineDatabaseTest.php + path: tests/lib/Limitation/LocationLimitationTypeTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Gateway\\DoctrineDatabaseTest\:\:\$gateway \(Ibexa\\Core\\Persistence\\Legacy\\URL\\Gateway\\DoctrineDatabase\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:providerForTestEvaluateInvalidArgument\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/Gateway/DoctrineDatabaseTest.php + path: tests/lib/Limitation/LocationLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\HandlerTest\:\:getUrl\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:providerForTestValidateError\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/HandlerTest.php + path: tests/lib/Limitation/LocationLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\HandlerTest\:\:getUrl\(\) has parameter \$id with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:providerForTestValidatePass\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/HandlerTest.php + path: tests/lib/Limitation/LocationLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\HandlerTest\:\:getUrl\(\) has parameter \$urlAddr with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testEvaluate\(\) has parameter \$expected with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/URL/HandlerTest.php + path: tests/lib/Limitation/LocationLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\HandlerTest\:\:testFind\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testEvaluate\(\) has parameter \$persistenceLocations with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/HandlerTest.php + path: tests/lib/Limitation/LocationLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\HandlerTest\:\:testFindUsages\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testEvaluate\(\) has parameter \$targets with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/URL/HandlerTest.php + path: tests/lib/Limitation/LocationLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\HandlerTest\:\:testLoadByIdWithUrlData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$persistenceLocations with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/HandlerTest.php + path: tests/lib/Limitation/LocationLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\HandlerTest\:\:testLoadByIdWithoutUrlData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\LocationLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$targets with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/URL/HandlerTest.php + path: tests/lib/Limitation/LocationLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\HandlerTest\:\:testLoadByUrlWithUrlData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\MemberOfLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/HandlerTest.php + path: tests/lib/Limitation/MemberOfLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\HandlerTest\:\:testLoadByUrlWithoutUrlData\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\MemberOfLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/HandlerTest.php + path: tests/lib/Limitation/MemberOfLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\HandlerTest\:\:testUpdateUrl\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\MemberOfLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/HandlerTest.php + path: tests/lib/Limitation/MemberOfLimitationTypeTest.php - - message: '#^Property Ibexa\\Contracts\\Core\\Persistence\\URL\\URL\:\:\$url \(string\) does not accept Ibexa\\Contracts\\Core\\Persistence\\URL\\URL\.$#' - identifier: assign.propertyType + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\MemberOfLimitationTypeTest\:\:providerForTestEvaluateSelfGroup\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/HandlerTest.php + path: tests/lib/Limitation/MemberOfLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\MapperTest\:\:testCreateURLFromUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\MemberOfLimitationTypeTest\:\:providerForTestValidateError\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/MapperTest.php + path: tests/lib/Limitation/MemberOfLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\MapperTest\:\:testExtractURLsFromRows\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\MemberOfLimitationTypeTest\:\:testEvaluateSelfGroup\(\) has parameter \$currentUserGroupLocations with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/MapperTest.php + path: tests/lib/Limitation/MemberOfLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\\CriterionHandlerTestCase\:\:assertHandlerAcceptsCriterion\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/CriterionHandlerTestCase.php + path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\\CriterionHandlerTestCase\:\:assertHandlerRejectsCriterion\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/CriterionHandlerTestCase.php + path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\\CriterionHandlerTestCase\:\:testAccept\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/CriterionHandlerTestCase.php + path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\\CriterionHandlerTestCase\:\:testHandle\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:providerForTestEvaluateInvalidArgument\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/CriterionHandlerTestCase.php + path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - message: '#^Parameter \#1 \$criterion of method Ibexa\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\:\:accept\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\Query\\Criterion, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type - count: 2 - path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/CriterionHandlerTestCase.php + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:providerForTestValidateError\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - message: '#^Parameter \#1 \$originalClassName of method PHPUnit\\Framework\\TestCase\:\:createMock\(\) expects class\-string\, string given\.$#' - identifier: argument.type - count: 2 - path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/CriterionHandlerTestCase.php + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:providerForTestValidatePass\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - message: '#^Unable to resolve the template type T in call to method PHPUnit\\Framework\\TestCase\:\:createMock\(\)$#' - identifier: argument.templateType - count: 2 - path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/CriterionHandlerTestCase.php + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:testEvaluate\(\) has parameter \$expected with no type specified\.$#' + identifier: missingType.parameter + count: 1 + path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\\LogicalAndTest\:\:testAccept\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:testEvaluate\(\) has parameter \$targets with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/LogicalAndTest.php + path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\\LogicalNotTest\:\:testAccept\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\NewObjectStateLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$targets with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/LogicalNotTest.php + path: tests/lib/Limitation/NewObjectStateLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\\LogicalOrTest\:\:testAccept\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ObjectStateLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/LogicalOrTest.php + path: tests/lib/Limitation/ObjectStateLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\\MatchAllTest\:\:testAccept\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ObjectStateLimitationTypeTest\:\:testEvaluate\(\) has parameter \$expected with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/MatchAllTest.php + path: tests/lib/Limitation/ObjectStateLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\\MatchAllTest\:\:testHandle\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Limitation\\ObjectStateLimitationTypeTest\:\:\$loadObjectStatesMap type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/MatchAllTest.php + path: tests/lib/Limitation/ObjectStateLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\\MatchNoneTest\:\:testAccept\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:getTestEvaluateContentMock\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/MatchNoneTest.php + path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\\MatchNoneTest\:\:testHandle\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:getTestEvaluateVersionInfoMock\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/MatchNoneTest.php + path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\\PatternTest\:\:testAccept\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/PatternTest.php + path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\\PatternTest\:\:testHandle\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/PatternTest.php + path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\\ValidityTest\:\:testAccept\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/ValidityTest.php + path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\\ValidityTest\:\:testHandle\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:providerForTestEvaluateInvalidArgument\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/ValidityTest.php + path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\Gateway\\DoctrineDatabaseTest\:\:\$databaseGateway \(Ibexa\\Core\\Persistence\\Legacy\\User\\Gateway\\DoctrineDatabase\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:providerForTestValidateError\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/Gateway/DoctrineDatabaseTest.php + path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\Role\\Gateway\\DoctrineDatabaseTest\:\:\$databaseGateway \(Ibexa\\Core\\Persistence\\Legacy\\User\\Role\\Gateway\\DoctrineDatabase\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:providerForTestValidatePass\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/Role/Gateway/DoctrineDatabaseTest.php + path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\Role\\LimitationConverterTest\:\:getLimitationConverter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:testEvaluate\(\) has parameter \$expected with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/User/Role/LimitationConverterTest.php + path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\Role\\LimitationConverterTest\:\:testObjectStateToLegacy\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:testEvaluate\(\) has parameter \$object with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/User/Role/LimitationConverterTest.php + path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\Role\\LimitationConverterTest\:\:testObjectStateToSPI\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:testEvaluate\(\) has parameter \$persistence with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/Role/LimitationConverterTest.php + path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:createRole\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:testEvaluate\(\) has parameter \$targets with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:getDummyUser\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentContentTypeLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$targets with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:getGatewayReturnValue\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\:\:\$id\.$#' + identifier: property.notFound count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:getValidUser\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:getValidUserToken\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:getValidUserToken\(\) has parameter \$time with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testAddPolicyLimitationValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:providerForTestEvaluateInvalidArgument\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testAddPolicyLimitations\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:providerForTestValidatePass\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testAddPolicyPolicyId\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:testEvaluate\(\) has parameter \$expected with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testAddPolicyToRoleLimitations\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:testEvaluate\(\) has parameter \$persistenceLocations with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testAddRoleToUser\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:testEvaluate\(\) has parameter \$targets with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testAddRoleToUserWithComplexLimitation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$persistenceLocations with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testAddRoleToUserWithLimitation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\ParentDepthLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$targets with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/ParentDepthLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testCreateNewRoleRoleId\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Instanceof between Ibexa\\Core\\Repository\\Values\\User\\UserRoleAssignment and Ibexa\\Core\\Repository\\Values\\User\\User will always evaluate to false\.$#' + identifier: instanceof.alwaysFalse count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/RoleLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testCreateNewRoleWithoutPolicies\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\RoleLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/RoleLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testCreateRoleDraftWithoutPolicies\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\RoleLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/RoleLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testCreateUser\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\RoleLimitationTypeTest\:\:testEvaluate\(\) has parameter \$targets with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/RoleLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testDeleteNonExistingUser\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SectionLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testDeletePolicy\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SectionLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testDeletePolicyLimitationValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SectionLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testDeletePolicyLimitations\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:providerForTestEvaluateInvalidArgument\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SectionLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testDeleteRole\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:providerForTestValidateError\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SectionLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testDeleteRoleDraft\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:providerForTestValidatePass\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SectionLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testExpireUserToken\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:testEvaluate\(\) has parameter \$expected with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SectionLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testImplicitlyCreatePolicies\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:testEvaluate\(\) has parameter \$targets with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SectionLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testLoadComplexRoleAssignments\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SectionLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$targets with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SectionLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testLoadMultipleUsersByEmail\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SiteAccessLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SiteAccessLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testLoadMultipleUsersByLogin\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SiteAccessLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SiteAccessLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testLoadRole\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SiteAccessLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SiteAccessLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testLoadRoleAssignmentsByGroupId\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SiteAccessLimitationTypeTest\:\:providerForTestEvaluateInvalidArgument\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SiteAccessLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testLoadRoleAssignmentsByGroupIdInherited\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SiteAccessLimitationTypeTest\:\:providerForTestValidateError\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SiteAccessLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testLoadRoleDraftByRoleId\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SiteAccessLimitationTypeTest\:\:testEvaluate\(\) has parameter \$expected with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SiteAccessLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testLoadRoleWithPolicies\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:getContentMock\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/StatusLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testLoadRoleWithPoliciesAndGroups\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:getContentMock\(\) has parameter \$shouldBeCalled with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/StatusLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testLoadRoleWithPolicyLimitations\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:getVersionInfoMock\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/StatusLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testLoadRoles\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:getVersionInfoMock\(\) has parameter \$shouldBeCalled with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/StatusLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testLoadUnknownUser\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/StatusLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testLoadUser\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/StatusLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testLoadUserByEmail\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/StatusLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testLoadUserByEmailNotFound\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:providerForTestEvaluateInvalidArgument\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/StatusLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testLoadUserByLogin\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:providerForTestValidateError\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/StatusLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testLoadUserByToken\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\StatusLimitationTypeTest\:\:testEvaluate\(\) has parameter \$expected with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/StatusLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testLoadUserByTokenNotFound\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\:\:\$id\.$#' + identifier: property.notFound count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testLoadUsersByEmail\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:providerForTestAcceptValue\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testRemoveUserRoleAssociation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:providerForTestAcceptValueException\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testRoleDraftOnlyHavePolicyDraft\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:providerForTestEvaluate\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testUpdatePolicies\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:providerForTestEvaluateInvalidArgument\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testUpdateRole\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:providerForTestValidateError\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testUpdateUser\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:providerForTestValidatePass\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testUpdateUserSettings\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testEvaluate\(\) has parameter \$expected with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:testUpdateUserToken\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testEvaluate\(\) has parameter \$persistenceLocations with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - message: '#^Parameter \#1 \$handler of method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:createTestRole\(\) expects Ibexa\\Core\\Persistence\\Legacy\\User\\Handler, Ibexa\\Contracts\\Core\\Persistence\\User\\Handler given\.$#' - identifier: argument.type - count: 5 - path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testEvaluate\(\) has parameter \$targets with no type specified\.$#' + identifier: missingType.parameter + count: 1 + path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\UserPreference\\Gateway\\DoctrineDatabaseTest\:\:loadUserPreference\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$persistenceLocations with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/UserPreference/Gateway/DoctrineDatabaseTest.php + path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\UserPreference\\Gateway\\DoctrineDatabaseTest\:\:loadUserPreference\(\) should return array but returns array\\|false\.$#' - identifier: return.type + message: '#^Method Ibexa\\Tests\\Core\\Limitation\\SubtreeLimitationTypeTest\:\:testEvaluateInvalidArgument\(\) has parameter \$targets with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/UserPreference/Gateway/DoctrineDatabaseTest.php + path: tests/lib/Limitation/SubtreeLimitationTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\UserPreference\\Gateway\\DoctrineDatabaseTest\:\:testCountUserPreferences\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Contracts\\Core\\MVC\\View\\VariableProvider@anonymous/tests/lib/MVC/Symfony/EventListener/ContentViewTwigVariablesSubscriberTest\.php\:47\:\:getTwigVariables\(\) has parameter \$options with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/UserPreference/Gateway/DoctrineDatabaseTest.php + path: tests/lib/MVC/Symfony/EventListener/ContentViewTwigVariablesSubscriberTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\UserPreference\\Gateway\\DoctrineDatabaseTest\:\:testInsert\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\EventListener\\ContentViewTwigVariablesSubscriberTest\:\:getRegistry\(\) has parameter \$providers with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/UserPreference/Gateway/DoctrineDatabaseTest.php + path: tests/lib/MVC/Symfony/EventListener/ContentViewTwigVariablesSubscriberTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\UserPreference\\Gateway\\DoctrineDatabaseTest\:\:testLoadUserPreferences\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Contracts\\Core\\MVC\\View\\VariableProvider@anonymous/tests/lib/MVC/Symfony/EventListener/ContentViewTwigVariablesSubscriberTest\.php\:47\:\:\$identifier has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Persistence/Legacy/UserPreference/Gateway/DoctrineDatabaseTest.php + path: tests/lib/MVC/Symfony/EventListener/ContentViewTwigVariablesSubscriberTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\UserPreference\\Gateway\\DoctrineDatabaseTest\:\:testUpdateUserPreference\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/Legacy/UserPreference/Gateway/DoctrineDatabaseTest.php + message: '#^Parameter \#1 \$translationHelper of class Ibexa\\Core\\MVC\\Symfony\\EventListener\\LanguageSwitchListener constructor expects Ibexa\\Core\\Helper\\TranslationHelper, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type + count: 3 + path: tests/lib/MVC/Symfony/EventListener/LanguageSwitchListenerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\UserPreference\\HandlerTest\:\:testCountUserPreferences\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\ImageAsset\\ParameterProviderTest\:\:dataProviderForTestGetViewParameters\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/UserPreference/HandlerTest.php + path: tests/lib/MVC/Symfony/FieldType/ImageAsset/ParameterProviderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\UserPreference\\HandlerTest\:\:testLoadUserPreferences\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\ImageAsset\\ParameterProviderTest\:\:testGetViewParameters\(\) has parameter \$expected with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/UserPreference/HandlerTest.php + path: tests/lib/MVC/Symfony/FieldType/ImageAsset/ParameterProviderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\UserPreference\\HandlerTest\:\:testSetUserPreference\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\ImageAsset\\ParameterProviderTest\:\:testGetViewParameters\(\) has parameter \$status with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Legacy/UserPreference/HandlerTest.php + path: tests/lib/MVC/Symfony/FieldType/ImageAsset/ParameterProviderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\UserPreference\\MapperTest\:\:testExtractUserPreferencesFromRows\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\Relation\\ParameterProviderTest\:\:testGetViewParameters\(\) has parameter \$expected with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Legacy/UserPreference/MapperTest.php + path: tests/lib/MVC/Symfony/FieldType/Relation/ParameterProviderTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Limitation\\\\Target\\\\Builder\\\\VersionBuilder'' and Ibexa\\Contracts\\Core\\Limitation\\Target\\Builder\\VersionBuilder will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\Relation\\ParameterProviderTest\:\:testGetViewParameters\(\) has parameter \$status with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/Limitation/Target/Builder/VersionBuilderTest.php + path: tests/lib/MVC/Symfony/FieldType/Relation/ParameterProviderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Limitation\\Target\\Builder\\VersionBuilderTest\:\:providerForTestBuild\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\RelationList\\ParameterProviderTest\:\:testGetViewParameters\(\) has parameter \$desinationContentIds with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/Limitation/Target/Builder/VersionBuilderTest.php + path: tests/lib/MVC/Symfony/FieldType/RelationList/ParameterProviderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorDefinitionBasedTest\:\:getProcessor\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\RelationList\\ParameterProviderTest\:\:testGetViewParameters\(\) has parameter \$expected with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorDefinitionBasedTest.php + path: tests/lib/MVC/Symfony/FieldType/RelationList/ParameterProviderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorDefinitionBasedTest\:\:testAllNormalizations\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\View\\ParameterProvider\\LocaleParameterProviderTest\:\:getLocaleConverterMock\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorDefinitionBasedTest.php + path: tests/lib/MVC/Symfony/FieldType/View/ParameterProvider/LocaleParameterProviderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorDefinitionBasedTest\:\:testApplyAllLowercaseNormalizations\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\View\\ParameterProvider\\LocaleParameterProviderTest\:\:getRequestStackMock\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorDefinitionBasedTest.php + path: tests/lib/MVC/Symfony/FieldType/View/ParameterProvider/LocaleParameterProviderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorDefinitionBasedTest\:\:testSimpleNormalizationLowercase\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\View\\ParameterProvider\\LocaleParameterProviderTest\:\:getRequestStackMock\(\) has parameter \$hasLocale with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorDefinitionBasedTest.php + path: tests/lib/MVC/Symfony/FieldType/View/ParameterProvider/LocaleParameterProviderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorDefinitionBasedTest\:\:testSimpleNormalizationUppercase\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\View\\ParameterProvider\\LocaleParameterProviderTest\:\:testGetViewParameters\(\) has parameter \$expectedLocale with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorDefinitionBasedTest.php + path: tests/lib/MVC/Symfony/FieldType/View/ParameterProvider/LocaleParameterProviderTest.php - - message: '#^Class Ibexa\\Core\\Persistence\\TransformationProcessor\\DefinitionBased\\Parser constructor invoked with 1 parameter, 0 required\.$#' - identifier: arguments.count - count: 10 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\FieldType\\View\\ParameterProvider\\LocaleParameterProviderTest\:\:testGetViewParameters\(\) has parameter \$hasRequestLocale with no type specified\.$#' + identifier: missingType.parameter + count: 1 + path: tests/lib/MVC/Symfony/FieldType/View/ParameterProvider/LocaleParameterProviderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorPcreCompilerTest\:\:applyTransformations\(\) has parameter \$transformations with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Locale\\LocaleConverterTest\:\:convertToPOSIXProvider\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php + path: tests/lib/MVC/Symfony/Locale/LocaleConverterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorPcreCompilerTest\:\:applyTransformations\(\) should return string but returns string\|null\.$#' - identifier: return.type + message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\Locale\\LocaleConverterTest\:\:\$conversionMap \(array\{array\{string, string\|null\}\}\) does not accept array\{eng\-GB\: ''en_GB'', eng\-US\: ''en_US'', fre\-FR\: ''fr_FR'', ger\-DE\: ''de_DE'', nor\-NO\: ''no_NO'', cro\-HR\: ''hr_HR''\}\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php + path: tests/lib/MVC/Symfony/Locale/LocaleConverterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorPcreCompilerTest\:\:testCompileMap\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\BaseTestCase\:\:getContentInfoMock\(\) has parameter \$properties with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorPcreCompilerTest\:\:testCompileMapAscii\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\BaseTestCase\:\:getLocationMock\(\) has parameter \$properties with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorPcreCompilerTest\:\:testCompileMapKeep\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\BaseTestCase\:\:getPartiallyMockedViewProvider\(\) has parameter \$matchingConfig with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorPcreCompilerTest\:\:testCompileMapRemove\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\BaseTestCase\:\:getPermissionResolverMock\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/BaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorPcreCompilerTest\:\:testCompileMapUnicode\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Depth\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/DepthTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorPcreCompilerTest\:\:testCompileModuloTranspose\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$location of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Depth\:\:matchLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/DepthTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorPcreCompilerTest\:\:testCompileReplace\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$repository of method Ibexa\\Core\\MVC\\RepositoryAware\:\:setRepository\(\) expects Ibexa\\Contracts\\Core\\Repository\\Repository, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/DepthTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorPcreCompilerTest\:\:testCompileTranspose\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\Content\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorPcreCompilerTest\:\:testCompileTransposeAsciiLowercase\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$location of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\Content\:\:matchLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorPcreCompilerTest\:\:testCompileTransposePlus\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ContentTypeGroup\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeGroupTest.php - - message: '#^Parameter \#3 \$subject of function preg_replace_callback expects array\\|string, string\|null given\.$#' + message: '#^Parameter \#1 \$location of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ContentTypeGroup\:\:matchLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' identifier: argument.type count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeGroupTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorPreprocessedBasedTest\:\:getProcessor\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPreprocessedBasedTest.php + message: '#^Parameter \#1 \$repository of method Ibexa\\Core\\MVC\\RepositoryAware\:\:setRepository\(\) expects Ibexa\\Contracts\\Core\\Repository\\Repository, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type + count: 2 + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeGroupTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorPreprocessedBasedTest\:\:testAllNormalizations\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ContentType\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPreprocessedBasedTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorPreprocessedBasedTest\:\:testSimpleNormalizationLowercase\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$location of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ContentType\:\:matchLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPreprocessedBasedTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorPreprocessedBasedTest\:\:testSimpleNormalizationUppercase\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\Location\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPreprocessedBasedTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/LocationTest.php - - message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\AbstractQueryTypeTestCase\:\:dataProviderForGetQuery\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$location of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\Location\:\:matchLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/QueryType/BuiltIn/AbstractQueryTypeTestCase.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/LocationTest.php - - message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\AbstractQueryTypeTestCase\:\:getExpectedSupportedParameters\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ParentContentType\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/QueryType/BuiltIn/AbstractQueryTypeTestCase.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentContentTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\AbstractQueryTypeTestCase\:\:testGetQuery\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$location of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ParentContentType\:\:matchLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/QueryType/BuiltIn/AbstractQueryTypeTestCase.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentContentTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\AncestorsQueryTypeTest\:\:dataProviderForGetQuery\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/QueryType/BuiltIn/AncestorsQueryTypeTest.php + message: '#^Parameter \#1 \$repository of method Ibexa\\Core\\MVC\\RepositoryAware\:\:setRepository\(\) expects Ibexa\\Contracts\\Core\\Repository\\Repository, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type + count: 2 + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentContentTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\AncestorsQueryTypeTest\:\:getExpectedSupportedParameters\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ParentLocation\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/QueryType/BuiltIn/AncestorsQueryTypeTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentLocationTest.php - - message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\ChildrenQueryTypeTest\:\:dataProviderForGetQuery\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$location of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\ParentLocation\:\:matchLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/QueryType/BuiltIn/ChildrenQueryTypeTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentLocationTest.php - - message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\ChildrenQueryTypeTest\:\:getExpectedSupportedParameters\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$repository of method Ibexa\\Core\\MVC\\RepositoryAware\:\:setRepository\(\) expects Ibexa\\Contracts\\Core\\Repository\\Repository, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/QueryType/BuiltIn/ChildrenQueryTypeTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentLocationTest.php - - message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\GeoLocationQueryTypeTest\:\:dataProviderForGetQuery\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\Remote\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/QueryType/BuiltIn/GeoLocationQueryTypeTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/RemoteTest.php - - message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\GeoLocationQueryTypeTest\:\:getExpectedSupportedParameters\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$location of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\Remote\:\:matchLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/QueryType/BuiltIn/GeoLocationQueryTypeTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/RemoteTest.php - - message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\RelatedToContentQueryTypeTest\:\:dataProviderForGetQuery\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\Section\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/QueryType/BuiltIn/RelatedToContentQueryTypeTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/SectionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\RelatedToContentQueryTypeTest\:\:getExpectedSupportedParameters\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$location of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Id\\Section\:\:matchLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/QueryType/BuiltIn/RelatedToContentQueryTypeTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Id/SectionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\SiblingsQueryTypeTest\:\:dataProviderForGetQuery\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\ContentType\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/QueryType/BuiltIn/SiblingsQueryTypeTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ContentTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\SiblingsQueryTypeTest\:\:getExpectedSupportedParameters\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/QueryType/BuiltIn/SiblingsQueryTypeTest.php + message: '#^Parameter \#1 \$contentTypeIdentifier of method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\ContentTypeTest\:\:generateRepositoryMockForContentTypeIdentifier\(\) expects int, string given\.$#' + identifier: argument.type + count: 2 + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ContentTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\SortSpec\\SortSpecLexerStub\:\:__construct\(\) has parameter \$tokens with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$location of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\ContentType\:\:matchLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/QueryType/BuiltIn/SortSpec/SortSpecLexerStub.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ContentTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\SortSpec\\SortSpecLexerTest\:\:dataProviderForTokenize\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$repository of method Ibexa\\Core\\MVC\\RepositoryAware\:\:setRepository\(\) expects Ibexa\\Contracts\\Core\\Repository\\Repository, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type + count: 2 + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ContentTypeTest.php + + - + message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\ParentContentType\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/QueryType/BuiltIn/SortSpec/SortSpecLexerTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ParentContentTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\SortSpec\\SortSpecLexerTest\:\:testTokenize\(\) has parameter \$expectedTokens with no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$location of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\ParentContentType\:\:matchLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/QueryType/BuiltIn/SortSpec/SortSpecLexerTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ParentContentTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\SortSpec\\SortSpecParserTest\:\:dataProviderForParseSortDirection\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$repository of method Ibexa\\Core\\MVC\\RepositoryAware\:\:setRepository\(\) expects Ibexa\\Contracts\\Core\\Repository\\Repository, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type + count: 2 + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ParentContentTypeTest.php + + - + message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\Section\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/QueryType/BuiltIn/SortSpec/SortSpecParserTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/SectionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\SortSpec\\SortSpecParserTest\:\:testParseSortDirection\(\) has parameter \$input with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$location of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\Identifier\\Section\:\:matchLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/QueryType/BuiltIn/SortSpec/SortSpecParserTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/SectionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\SubtreeQueryTest\:\:dataProviderForGetQuery\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$repository of method Ibexa\\Core\\MVC\\RepositoryAware\:\:setRepository\(\) expects Ibexa\\Contracts\\Core\\Repository\\Repository, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type + count: 2 + path: tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/SectionTest.php + + - + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\MultipleValuedTest\:\:getMultipleValuedMatcherMock\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/lib/QueryType/BuiltIn/SubtreeQueryTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/MultipleValuedTest.php - - message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\SubtreeQueryTest\:\:getExpectedSupportedParameters\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\MultipleValuedTest\:\:matchingConfigProvider\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/QueryType/BuiltIn/SubtreeQueryTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/MultipleValuedTest.php - - message: '#^Method Ibexa\\Contracts\\Core\\Repository\\Strategy\\ContentThumbnail\\Field\\FieldTypeBasedThumbnailStrategy@anonymous/tests/lib/Repository/ContentThumbnail/ContentFieldStrategyTest\.php\:24\:\:getThumbnail\(\) never returns null so it can be removed from the return type\.$#' - identifier: return.unusedType + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\MultipleValuedTest\:\:testSetMatchingConfig\(\) has parameter \$matchingConfig with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/ContentThumbnail/ContentFieldStrategyTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/MultipleValuedTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\ContentThumbnail\\StaticStrategyTest\:\:testStaticStrategy\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$contentInfo of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\UrlAlias\:\:matchContentInfo\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentInfo, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/ContentThumbnail/StaticStrategyTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/UrlAliasTest.php - - message: '#^Method Ibexa\\Contracts\\Core\\Repository\\Validator\\ContentValidator@anonymous/tests/lib/Repository/ContentValidator/ContentValidatorStrategyTest\.php\:88\:\:__construct\(\) has parameter \$validationReturn with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$location of method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ContentBased\\UrlAlias\:\:matchLocation\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/ContentValidator/ContentValidatorStrategyTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/UrlAliasTest.php - - message: '#^Method Ibexa\\Contracts\\Core\\Repository\\Validator\\ContentValidator@anonymous/tests/lib/Repository/ContentValidator/ContentValidatorStrategyTest\.php\:88\:\:validate\(\) has parameter \$context with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$repository of method Ibexa\\Core\\MVC\\RepositoryAware\:\:setRepository\(\) expects Ibexa\\Contracts\\Core\\Repository\\Repository, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/ContentValidator/ContentValidatorStrategyTest.php + path: tests/lib/MVC/Symfony/Matcher/ContentBased/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\ContentValidator\\ContentValidatorStrategyTest\:\:buildContentValidator\(\) has parameter \$validationReturn with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Call to an undefined method Ibexa\\Core\\MVC\\Symfony\\Matcher\\ConfigurableMatcherFactoryInterface\:\:expects\(\)\.$#' + identifier: method.notFound count: 1 - path: tests/lib/Repository/ContentValidator/ContentValidatorStrategyTest.php + path: tests/lib/MVC/Symfony/Matcher/DynamicallyConfiguredMatcherFactoryDecoratorTest.php - - message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Validator\\ContentValidator@anonymous/tests/lib/Repository/ContentValidator/ContentValidatorStrategyTest\.php\:88\:\:\$validationReturn type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\DynamicallyConfiguredMatcherFactoryDecoratorTest\:\:matchConfigProvider\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/ContentValidator/ContentValidatorStrategyTest.php + path: tests/lib/MVC/Symfony/Matcher/DynamicallyConfiguredMatcherFactoryDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\BookmarkServiceDecoratorTest\:\:testCreateBookmarkDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\DynamicallyConfiguredMatcherFactoryDecoratorTest\:\:testMatch\(\) has parameter \$matchedConfig with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/BookmarkServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Matcher/DynamicallyConfiguredMatcherFactoryDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\BookmarkServiceDecoratorTest\:\:testDeleteBookmarkDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\DynamicallyConfiguredMatcherFactoryDecoratorTest\:\:testMatch\(\) has parameter \$namespace with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/BookmarkServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Matcher/DynamicallyConfiguredMatcherFactoryDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\BookmarkServiceDecoratorTest\:\:testIsBookmarkedDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\DynamicallyConfiguredMatcherFactoryDecoratorTest\:\:testMatch\(\) has parameter \$parameterName with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/BookmarkServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Matcher/DynamicallyConfiguredMatcherFactoryDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\BookmarkServiceDecoratorTest\:\:testLoadBookmarksDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\DynamicallyConfiguredMatcherFactoryDecoratorTest\:\:testMatch\(\) has parameter \$scope with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/BookmarkServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Matcher/DynamicallyConfiguredMatcherFactoryDecoratorTest.php - - message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\BookmarkServiceDecorator@anonymous/tests/lib/Repository/Decorator/BookmarkServiceDecoratorTest\.php\:21 constructor expects Ibexa\\Contracts\\Core\\Repository\\BookmarkService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Matcher\\DynamicallyConfiguredMatcherFactoryDecoratorTest\:\:testMatch\(\) has parameter \$viewsConfiguration with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/BookmarkServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Matcher/DynamicallyConfiguredMatcherFactoryDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testAddRelationDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\GeneratorTest\:\:testGenerateWithSiteAccessNoReverseMatch\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/GeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testCopyContentDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\GeneratorTest\:\:testGenerateWithSiteAccessNoReverseMatch\(\) has parameter \$referenceType with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/GeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testCreateContentDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\GeneratorTest\:\:testGenerateWithSiteAccessNoReverseMatch\(\) has parameter \$urlResource with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/GeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testCreateContentDraftDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\GeneratorTest\:\:testSimpleGenerate\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/GeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testDeleteContentDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\GeneratorTest\:\:testSimpleGenerate\(\) has parameter \$referenceType with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/GeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testDeleteRelationDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\GeneratorTest\:\:testSimpleGenerate\(\) has parameter \$urlResource with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/GeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testDeleteTranslationDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\RouteReferenceGeneratorTest\:\:testGenerate\(\) has parameter \$params with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/RouteReferenceGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testDeleteTranslationFromDraftDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\RouteReferenceGeneratorTest\:\:testGenerate\(\) has parameter \$resource with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/RouteReferenceGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testDeleteVersionDecorator\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + message: '#^Parameter \#1 \$dispatcher of class Ibexa\\Core\\MVC\\Symfony\\Routing\\Generator\\RouteReferenceGenerator constructor expects Symfony\\Component\\EventDispatcher\\EventDispatcherInterface, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type + count: 4 + path: tests/lib/MVC/Symfony/Routing/RouteReferenceGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testHideContentDecorator\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:getPermissionResolverMock\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testLoadContentByContentInfoDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testDoGenerate\(\) has parameter \$expected with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testLoadContentByRemoteIdDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testDoGenerate\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testLoadContentByVersionInfoDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testDoGenerateRootLocation\(\) has parameter \$expected with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testLoadContentDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testDoGenerateRootLocation\(\) has parameter \$isOutsideAndNotExcluded with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testLoadContentInfoByRemoteIdDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testDoGenerateRootLocation\(\) has parameter \$pathPrefix with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testLoadContentInfoDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testDoGenerateWithSiteAccessParam\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testLoadContentInfoListDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testIsPrefixExcluded\(\) has parameter \$expectedIsExcluded with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testLoadContentListByContentInfoDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasGeneratorTest\:\:testIsPrefixExcluded\(\) has parameter \$uri with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testLoadReverseRelationsDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:getRequestByPathInfo\(\) has parameter \$pathInfo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testLoadVersionInfoByIdDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testSupports\(\) has parameter \$isSupported with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testLoadVersionInfoDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:testSupports\(\) has parameter \$routeReference with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testLoadVersionsDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\Routing\\UrlAliasRouterTest\:\:\$requestContext has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testNewContentCreateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testCheckRequestPath\(\) has parameter \$expected with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testNewContentMetadataUpdateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testCheckRequestPath\(\) has parameter \$path with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testNewContentUpdateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testCheckRequestPath\(\) has parameter \$requestUri with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testPublishVersionDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testCheckRequestPath\(\) has parameter \$siteAccessUri with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testRevealContentDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testGenerateUri\(\) has parameter \$expected with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testUpdateContentDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testGenerateUri\(\) has parameter \$isUriRouteName with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentServiceDecoratorTest\:\:testUpdateContentMetadataDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testGenerateUri\(\) has parameter \$siteAccessUri with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - message: '#^Parameter \#2 \$locationCreateStructs of method Ibexa\\Contracts\\Core\\Repository\\ContentService\:\:createContent\(\) expects array\, array\ given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testGenerateUri\(\) has parameter \$uri with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testAddFieldDefinitionDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testGenerateUriStandard\(\) has parameter \$expected with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testAssignContentTypeGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testGenerateUriStandard\(\) has parameter \$isUriRouteName with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testCopyContentTypeDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\HttpUtilsTest\:\:testGenerateUriStandard\(\) has parameter \$uri with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testCreateContentTypeDecorator\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + message: '#^Property Ibexa\\Core\\MVC\\Symfony\\SiteAccess\:\:\$matcher \(Ibexa\\Core\\MVC\\Symfony\\SiteAccess\\Matcher\) does not accept Ibexa\\Core\\MVC\\Symfony\\SiteAccess\\URILexer&PHPUnit\\Framework\\MockObject\\MockObject\.$#' + identifier: assign.propertyType + count: 2 + path: tests/lib/MVC/Symfony/Security/HttpUtilsTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testCreateContentTypeDraftDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$expirationDate of class Ibexa\\Contracts\\Core\\Repository\\Values\\User\\PasswordInfo constructor expects DateTimeImmutable\|null, DateTimeImmutable\|false given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/UserCheckerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testCreateContentTypeGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\CoreVoterTest\:\:testSupportsAttribute\(\) has parameter \$attribute with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testDeleteContentTypeDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\CoreVoterTest\:\:testSupportsAttribute\(\) has parameter \$expectedResult with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testDeleteContentTypeGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\CoreVoterTest\:\:testSupportsClass\(\) has parameter \$class with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testIsContentTypeUsedDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\CoreVoterTest\:\:testVote\(\) has parameter \$expectedResult with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testLoadContentTypeByIdentifierDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\CoreVoterTest\:\:testVote\(\) has parameter \$repositoryCanUser with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testLoadContentTypeByRemoteIdDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\CoreVoterTest\:\:testVoteInvalidAttribute\(\) has parameter \$attributes with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testLoadContentTypeDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\ValueObjectVoterTest\:\:testSupportsAttribute\(\) has parameter \$attribute with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testLoadContentTypeDraftDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\ValueObjectVoterTest\:\:testSupportsAttribute\(\) has parameter \$expectedResult with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testLoadContentTypeGroupByIdentifierDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\ValueObjectVoterTest\:\:testSupportsClass\(\) has parameter \$class with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testLoadContentTypeGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\ValueObjectVoterTest\:\:testVote\(\) has parameter \$expectedResult with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testLoadContentTypeGroupsDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\ValueObjectVoterTest\:\:testVote\(\) has parameter \$repositoryCanUser with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testLoadContentTypeListDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Security\\Voter\\ValueObjectVoterTest\:\:testVoteInvalidAttribute\(\) has parameter \$attributes with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testLoadContentTypesDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\Compound\\CompoundAndTest\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/Compound/CompoundAndTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testNewContentTypeCreateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\Compound\\CompoundAndTest\:\:testMatch\(\) has parameter \$expectedMatch with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/Compound/CompoundAndTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testNewContentTypeGroupCreateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\Compound\\CompoundOrTest\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/Compound/CompoundOrTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testNewContentTypeGroupUpdateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\Provider\\ChainSiteAccessProviderTest\:\:getExistingSiteProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/Provider/ChainSiteAccessProviderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testNewContentTypeUpdateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\Provider\\ChainSiteAccessProviderTest\:\:siteAccessNamesProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/Provider/ChainSiteAccessProviderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testNewFieldDefinitionCreateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + message: '#^Parameter \#2 \$groupsBySiteAccess of class Ibexa\\Core\\MVC\\Symfony\\SiteAccess\\Provider\\StaticSiteAccessProvider constructor expects array\, array\\> given\.$#' + identifier: argument.type + count: 2 + path: tests/lib/MVC/Symfony/SiteAccess/Provider/ChainSiteAccessProviderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testNewFieldDefinitionUpdateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Core\\MVC\\Symfony\\SiteAccess\:\:\$groups \(array\\) does not accept array\\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/Provider/ChainSiteAccessProviderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testPublishContentTypeDraftDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\Provider\\ChainSiteAccessProviderTest\:\:\$groupsBySiteAccess type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/Provider/ChainSiteAccessProviderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testRemoveContentTypeTranslationDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterBaseTestCase\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterBaseTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testRemoveFieldDefinitionDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Class Ibexa\\Core\\MVC\\Symfony\\SiteAccess\\Matcher\\Map\\Host constructor invoked with 2 parameters, 1 required\.$#' + identifier: arguments.count count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterHostElementTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testUnassignContentTypeGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostElementTest\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterHostElementTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testUpdateContentTypeDraftDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostElementTest\:\:testReverseMatch\(\) has parameter \$elementNumber with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterHostElementTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testUpdateContentTypeGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostElementTest\:\:testReverseMatch\(\) has parameter \$expectedHost with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterHostElementTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ContentTypeServiceDecoratorTest\:\:testUpdateFieldDefinitionDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostElementTest\:\:testReverseMatch\(\) has parameter \$siteAccessName with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterHostElementTest.php - - message: '#^Parameter \#1 \$contentTypeIds of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:loadContentTypeList\(\) expects array\, array\ given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostPortURITest\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterHostPortURITest.php - - message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\ContentTypeServiceDecorator@anonymous/tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest\.php\:31 constructor expects Ibexa\\Contracts\\Core\\Repository\\ContentTypeService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + message: '#^Parameter \#1 \$map of class Ibexa\\Core\\MVC\\Symfony\\SiteAccess\\Matcher\\Map\\Port constructor expects array\, array\ given\.$#' identifier: argument.type - count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + count: 2 + path: tests/lib/MVC/Symfony/SiteAccess/RouterHostPortURITest.php - - message: '#^Parameter \#2 \$contentTypeGroups of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:createContentType\(\) expects array\, array\ given\.$#' - identifier: argument.type + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Core\\\\MVC\\\\Symfony\\\\Routing\\\\SimplifiedRequest'' and Ibexa\\Core\\MVC\\Symfony\\Routing\\SimplifiedRequest will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterHostTextTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\FieldTypeServiceDecoratorTest\:\:testGetFieldTypeDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Class Ibexa\\Core\\MVC\\Symfony\\SiteAccess\\Matcher\\HostText constructor invoked with 2 parameters, 1 required\.$#' + identifier: arguments.count count: 1 - path: tests/lib/Repository/Decorator/FieldTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterHostTextTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\FieldTypeServiceDecoratorTest\:\:testGetFieldTypesDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterHostTextTest\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/FieldTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterHostTextTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\FieldTypeServiceDecoratorTest\:\:testHasFieldTypeDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterMapURITest\:\:testSetGetRequest\(\) has parameter \$config with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/FieldTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterMapURITest.php - - message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\FieldTypeServiceDecorator@anonymous/tests/lib/Repository/Decorator/FieldTypeServiceDecoratorTest\.php\:20 constructor expects Ibexa\\Contracts\\Core\\Repository\\FieldTypeService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterPortHostURITest\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/FieldTypeServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterPortHostURITest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LanguageServiceDecoratorTest\:\:testCreateLanguageDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Class Ibexa\\Core\\MVC\\Symfony\\SiteAccess\\Matcher\\Map\\Port constructor invoked with 2 parameters, 1 required\.$#' + identifier: arguments.count count: 1 - path: tests/lib/Repository/Decorator/LanguageServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterSpecialPortsTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LanguageServiceDecoratorTest\:\:testDeleteLanguageDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterSpecialPortsTest\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/LanguageServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterSpecialPortsTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LanguageServiceDecoratorTest\:\:testDisableLanguageDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterTest\:\:createRouter\(\) has parameter \$debug with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/LanguageServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LanguageServiceDecoratorTest\:\:testEnableLanguageDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterTest\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/LanguageServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LanguageServiceDecoratorTest\:\:testGetDefaultLanguageCodeDecorator\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterTest\:\:testConstructDebug\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Decorator/LanguageServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LanguageServiceDecoratorTest\:\:testLoadLanguageByIdDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterTest\:\:testMatch\(\) has parameter \$siteAccess with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/LanguageServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LanguageServiceDecoratorTest\:\:testLoadLanguageDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElement2Test\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/LanguageServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElement2Test.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LanguageServiceDecoratorTest\:\:testLoadLanguageListByCodeDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElement2Test\:\:testReverseMatch\(\) has parameter \$originalPathinfo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/LanguageServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElement2Test.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LanguageServiceDecoratorTest\:\:testLoadLanguageListByIdDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElement2Test\:\:testReverseMatch\(\) has parameter \$siteAccessName with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/LanguageServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElement2Test.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LanguageServiceDecoratorTest\:\:testLoadLanguagesDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElementTest\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/LanguageServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElementTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LanguageServiceDecoratorTest\:\:testNewLanguageCreateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElementTest\:\:testReverseMatch\(\) has parameter \$originalPathinfo with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/LanguageServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElementTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LanguageServiceDecoratorTest\:\:testUpdateLanguageNameDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURIElementTest\:\:testReverseMatch\(\) has parameter \$siteAccessName with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/LanguageServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterURIElementTest.php - - message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\LanguageServiceDecorator@anonymous/tests/lib/Repository/Decorator/LanguageServiceDecoratorTest\.php\:22 constructor expects Ibexa\\Contracts\\Core\\Repository\\LanguageService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Core\\\\MVC\\\\Symfony\\\\Routing\\\\SimplifiedRequest'' and Ibexa\\Core\\MVC\\Symfony\\Routing\\SimplifiedRequest will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/lib/Repository/Decorator/LanguageServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterURITextTest.php - - message: '#^Parameter \#1 \$languageIds of method Ibexa\\Contracts\\Core\\Repository\\LanguageService\:\:loadLanguageListById\(\) expects array\, array\ given\.$#' - identifier: argument.type + message: '#^Class Ibexa\\Core\\MVC\\Symfony\\SiteAccess\\Matcher\\URIText constructor invoked with 2 parameters, 1 required\.$#' + identifier: arguments.count count: 1 - path: tests/lib/Repository/Decorator/LanguageServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterURITextTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LocationServiceDecoratorTest\:\:testCopySubtreeDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\RouterURITextTest\:\:matchProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/RouterURITextTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LocationServiceDecoratorTest\:\:testCreateLocationDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\SiteAccessServiceTest\:\:getAvailableSitAccesses\(\) return type with generic class ArrayIterator does not specify its types\: TKey, TValue$#' + identifier: missingType.generics count: 1 - path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/SiteAccessServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LocationServiceDecoratorTest\:\:testDeleteLocationDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\SiteAccessServiceTest\:\:getConfigResolverParameters\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/SiteAccessServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LocationServiceDecoratorTest\:\:testGetAllLocationsCountDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#2 \$groupsBySiteAccess of class Ibexa\\Core\\MVC\\Symfony\\SiteAccess\\Provider\\StaticSiteAccessProvider constructor expects array\, array\\> given\.$#' + identifier: argument.type + count: 2 + path: tests/lib/MVC/Symfony/SiteAccess/SiteAccessServiceTest.php + + - + message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\SiteAccessServiceTest\:\:\$availableSiteAccesses with generic class ArrayIterator does not specify its types\: TKey, TValue$#' + identifier: missingType.generics count: 1 - path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/SiteAccessServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LocationServiceDecoratorTest\:\:testGetLocationChildCountDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\SiteAccess\\SiteAccessServiceTest\:\:\$configResolverParameters type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/SiteAccess/SiteAccessServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LocationServiceDecoratorTest\:\:testHideLocationDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Anonymous function has an unused use \$content\.$#' + identifier: closure.unusedUse count: 1 - path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Templating/RenderLocationStrategyTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LocationServiceDecoratorTest\:\:testLoadAllLocationsDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Anonymous function has an unused use \$siteAccess\.$#' + identifier: closure.unusedUse count: 1 - path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Templating/RenderLocationStrategyTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LocationServiceDecoratorTest\:\:testLoadLocationByRemoteIdDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Symfony\\\\Component\\\\HttpKernel\\\\Controller\\\\ControllerReference'' and Symfony\\Component\\HttpKernel\\Controller\\ControllerReference will always evaluate to true\.$#' + identifier: method.alreadyNarrowedType count: 1 - path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Templating/RenderLocationStrategyTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LocationServiceDecoratorTest\:\:testLoadLocationChildrenDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Argument of an invalid type string supplied for foreach, only iterables are supported\.$#' + identifier: foreach.nonIterable count: 1 - path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LocationServiceDecoratorTest\:\:testLoadLocationDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\Twig\\Extension\\FileSizeExtensionTest\:\:getExtensions\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LocationServiceDecoratorTest\:\:testLoadLocationListDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\Twig\\Extension\\FileSizeExtensionTest\:\:getLocale\(\) should return string but returns array\\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LocationServiceDecoratorTest\:\:testLoadLocationsDecorator\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\Twig\\Extension\\FileSizeExtensionTest\:\:setConfigurationLocale\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LocationServiceDecoratorTest\:\:testLoadParentLocationsForDraftContentDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^PHPDoc tag @param has invalid value \(\\Ibexa\\Contracts\\Core\\SiteAccess\\ConfigResolverInterface\|\\PHPUnit\\Framework\\MockObject\\MockObject\)\: Unexpected token "\\n ", expected variable at offset 115 on line 2$#' + identifier: phpDoc.parseError count: 1 - path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LocationServiceDecoratorTest\:\:testMoveSubtreeDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^PHPDoc tag @param has invalid value \(\\Ibexa\\Core\\MVC\\Symfony\\Locale\\LocaleConverterInterface\|\\PHPUnit\\Framework\\MockObject\\MockObject\)\: Unexpected token "\\n ", expected variable at offset 114 on line 2$#' + identifier: phpDoc.parseError count: 1 - path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LocationServiceDecoratorTest\:\:testNewLocationCreateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^PHPDoc tag @param has invalid value \(\\Symfony\\Contracts\\Translation\\TranslatorInterface\|\\PHPUnit\\Framework\\MockObject\\MockObject\)\: Unexpected token "\\n ", expected variable at offset 109 on line 2$#' + identifier: phpDoc.parseError count: 1 - path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LocationServiceDecoratorTest\:\:testNewLocationUpdateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\Twig\\Extension\\FileSizeExtensionTest\:\:\$configResolverInterfaceMock has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LocationServiceDecoratorTest\:\:testSwapLocationDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\Twig\\Extension\\FileSizeExtensionTest\:\:\$locale has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LocationServiceDecoratorTest\:\:testUnhideLocationDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\Twig\\Extension\\FileSizeExtensionTest\:\:\$localeConverterInterfaceMock has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\LocationServiceDecoratorTest\:\:testUpdateLocationDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\Twig\\Extension\\FileSizeExtensionTest\:\:\$suffixes has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\LocationServiceDecorator@anonymous/tests/lib/Repository/Decorator/LocationServiceDecoratorTest\.php\:29 constructor expects Ibexa\\Contracts\\Core\\Repository\\LocationService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type + message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\Twig\\Extension\\FileSizeExtensionTest\:\:\$translatorMock has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\NotificationServiceDecoratorTest\:\:testCreateNotificationDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Anonymous function should return non\-empty\-string but returns non\-empty\-string\|false\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Decorator/NotificationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Templating/Twig/Extension/RoutingExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\NotificationServiceDecoratorTest\:\:testDeleteNotificationDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\Twig\\Extension\\RoutingExtensionTest\:\:getExampleRouteReference\(\) has parameter \$name with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/NotificationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Templating/Twig/Extension/RoutingExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\NotificationServiceDecoratorTest\:\:testGetNotificationCountDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\Templating\\Twig\\Extension\\RoutingExtensionTest\:\:getExampleRouteReference\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/NotificationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/Templating/Twig/Extension/RoutingExtensionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\NotificationServiceDecoratorTest\:\:testGetNotificationDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\AbstractViewTestCase\:\:badTemplateIdentifierProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/NotificationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/AbstractViewTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\NotificationServiceDecoratorTest\:\:testGetPendingNotificationCountDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\AbstractViewTestCase\:\:createViewUnderTest\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/NotificationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/AbstractViewTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\NotificationServiceDecoratorTest\:\:testMarkNotificationAsReadDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\AbstractViewTestCase\:\:createViewUnderTest\(\) has parameter \$template with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/NotificationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/AbstractViewTestCase.php - - message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\NotificationServiceDecorator@anonymous/tests/lib/Repository/Decorator/NotificationServiceDecoratorTest\.php\:24 constructor expects Ibexa\\Contracts\\Core\\Repository\\NotificationService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\AbstractViewTestCase\:\:createViewUnderTest\(\) has parameter \$viewType with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/NotificationServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/AbstractViewTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ObjectStateServiceDecoratorTest\:\:testCreateObjectStateDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\AbstractViewTestCase\:\:getAlwaysAvailableParams\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/AbstractViewTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ObjectStateServiceDecoratorTest\:\:testCreateObjectStateGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\AbstractViewTestCase\:\:goodTemplateIdentifierProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/AbstractViewTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ObjectStateServiceDecoratorTest\:\:testDeleteObjectStateDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$templateIdentifier of method Ibexa\\Core\\MVC\\Symfony\\View\\View\:\:setTemplateIdentifier\(\) expects \(Closure\(array\\)\: string\)\|string, \(callable\(\)\: mixed\)\|string given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/AbstractViewTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ObjectStateServiceDecoratorTest\:\:testDeleteObjectStateGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\Builder\\ContentViewBuilderTest\:\:\$contentViewBuilder \(Ibexa\\Core\\MVC\\Symfony\\View\\Builder\\ContentViewBuilder&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept Ibexa\\Core\\MVC\\Symfony\\View\\Builder\\ContentViewBuilder\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/Builder/ContentViewBuilderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ObjectStateServiceDecoratorTest\:\:testGetContentCountDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ContentViewTest\:\:createViewUnderTest\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/ContentViewTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ObjectStateServiceDecoratorTest\:\:testGetContentStateDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ContentViewTest\:\:createViewUnderTest\(\) has parameter \$template with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/ContentViewTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ObjectStateServiceDecoratorTest\:\:testLoadObjectStateDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ContentViewTest\:\:createViewUnderTest\(\) has parameter \$viewType with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/ContentViewTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ObjectStateServiceDecoratorTest\:\:testLoadObjectStateGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ContentViewTest\:\:getAlwaysAvailableParams\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/ContentViewTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ObjectStateServiceDecoratorTest\:\:testLoadObjectStateGroupsDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ContentViewTest\:\:testConstruct\(\) has parameter \$params with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/ContentViewTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ObjectStateServiceDecoratorTest\:\:testLoadObjectStatesDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ContentViewTest\:\:testConstruct\(\) has parameter \$templateIdentifier with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/ContentViewTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ObjectStateServiceDecoratorTest\:\:testNewObjectStateCreateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ContentViewTest\:\:testConstructFail\(\) has parameter \$templateIdentifier with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/ContentViewTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ObjectStateServiceDecoratorTest\:\:testNewObjectStateGroupCreateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ContentViewTest\:\:\$valueParams type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/ContentViewTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ObjectStateServiceDecoratorTest\:\:testNewObjectStateGroupUpdateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\LoginFormViewTest\:\:createViewUnderTest\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/LoginFormViewTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ObjectStateServiceDecoratorTest\:\:testNewObjectStateUpdateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\LoginFormViewTest\:\:createViewUnderTest\(\) has parameter \$template with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/LoginFormViewTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ObjectStateServiceDecoratorTest\:\:testSetContentStateDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\LoginFormViewTest\:\:createViewUnderTest\(\) has parameter \$viewType with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/LoginFormViewTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ObjectStateServiceDecoratorTest\:\:testSetPriorityOfObjectStateDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\LoginFormViewTest\:\:getAlwaysAvailableParams\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/LoginFormViewTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ObjectStateServiceDecoratorTest\:\:testUpdateObjectStateDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Contracts\\Core\\MVC\\View\\VariableProvider@anonymous/tests/lib/MVC/Symfony/View/VariableProviderRegistryTest\.php\:29\:\:getTwigVariables\(\) has parameter \$options with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/VariableProviderRegistryTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\ObjectStateServiceDecoratorTest\:\:testUpdateObjectStateGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\VariableProviderRegistryTest\:\:getRegistry\(\) has parameter \$providers with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/VariableProviderRegistryTest.php - - message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\ObjectStateServiceDecorator@anonymous/tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest\.php\:27 constructor expects Ibexa\\Contracts\\Core\\Repository\\ObjectStateService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type + message: '#^Property Ibexa\\Contracts\\Core\\MVC\\View\\VariableProvider@anonymous/tests/lib/MVC/Symfony/View/VariableProviderRegistryTest\.php\:29\:\:\$identifier has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/VariableProviderRegistryTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testAddPolicyByRoleDraftDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\MVC\\Symfony\\View\\ViewManagerTest\:\:\$viewBaseLayout has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/MVC/Symfony/View/ViewManagerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testAssignRoleToUserDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Pagination\\AdapterFactory\\SearchHitAdapterFactoryTest\:\:dataProviderForCreateFixedAdapter\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Pagination/AdapterFactory/SearchHitAdapterFactoryTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testAssignRoleToUserGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + message: '#^Parameter \#3 \$languageFilter of class Ibexa\\Core\\Pagination\\Pagerfanta\\ContentFilteringAdapter constructor expects array\\|null, array\\|true\> given\.$#' + identifier: argument.type + count: 2 + path: tests/lib/Pagination/ContentFilteringAdapterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testCreateRoleDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractBaseHandlerTestCase\:\:getCacheItem\(\) has parameter \$key with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractBaseHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testCreateRoleDraftDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractBaseHandlerTestCase\:\:provideAbstractCacheHandlerArguments\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractBaseHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testDeleteRoleDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractBaseHandlerTestCase\:\:provideInMemoryCacheHandlerArguments\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractBaseHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testDeleteRoleDraftDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testGetLimitationTypeDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testGetLimitationTypesByModuleFunctionDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testGetRoleAssignmentsDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$additionalCalls with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testGetRoleAssignmentsForUserDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testGetRoleAssignmentsForUserGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$keyGeneratingArguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testLoadRoleAssignmentDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$keyGeneratingResults with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testLoadRoleByIdentifierDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$tagGeneratingArguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testLoadRoleDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$tagGeneratingResults with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testLoadRoleDraftByRoleIdDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$additionalCalls with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testLoadRoleDraftDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testLoadRolesDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$keyGeneratingArguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testNewPolicyCreateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$keyGeneratingResults with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testNewPolicyUpdateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$tagGeneratingArguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testNewRoleCreateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$tagGeneratingResults with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testNewRoleUpdateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testUnCachedMethods\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testPublishRoleDraftDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testUnCachedMethods\(\) has parameter \$key with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testRemovePolicyByRoleDraftDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testUnCachedMethods\(\) has parameter \$keyGeneratingArguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testRemoveRoleAssignmentDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testUnCachedMethods\(\) has parameter \$tagGeneratingArguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testUpdatePolicyByRoleDraftDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractCacheHandlerTestCase\:\:testUnCachedMethods\(\) has parameter \$tags with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\RoleServiceDecoratorTest\:\:testUpdateRoleDraftDecorator\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + message: '#^Method PHPUnit\\Framework\\MockObject\\Builder\\InvocationMocker\:\:with\(\) invoked with unpacked array with possibly string key, but it''s not allowed because of @no\-named\-arguments\.$#' + identifier: argument.named + count: 2 + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\RoleServiceDecorator@anonymous/tests/lib/Repository/Decorator/RoleServiceDecoratorTest\.php\:34 constructor expects Ibexa\\Contracts\\Core\\Repository\\RoleService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type - count: 1 - path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php + message: '#^Offset int might not exist on array\|null\.$#' + identifier: offsetAccess.notFound + count: 5 + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SearchServiceDecoratorTest\:\:getSearchEngineCapabilities\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Repository/Decorator/SearchServiceDecoratorTest.php + message: '#^Parameter \#1 \$callback of function call_user_func_array expects callable\(\)\: mixed, array\{mixed, string\} given\.$#' + identifier: argument.type + count: 3 + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SearchServiceDecoratorTest\:\:testFindContentDecorator\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Decorator/SearchServiceDecoratorTest.php + message: '#^Parameter \#1 \$originalClassName of method PHPUnit\\Framework\\TestCase\:\:createMock\(\) expects class\-string\, string given\.$#' + identifier: argument.type + count: 2 + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SearchServiceDecoratorTest\:\:testFindContentInfoDecorator\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Decorator/SearchServiceDecoratorTest.php + message: '#^Unable to resolve the template type T in call to method PHPUnit\\Framework\\TestCase\:\:createMock\(\)$#' + identifier: argument.templateType + count: 3 + path: tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SearchServiceDecoratorTest\:\:testFindLocationsDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/SearchServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SearchServiceDecoratorTest\:\:testFindSingleDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/SearchServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SearchServiceDecoratorTest\:\:testSuggestDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/SearchServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\SearchServiceDecorator@anonymous/tests/lib/Repository/Decorator/SearchServiceDecoratorTest\.php\:23 constructor expects Ibexa\\Contracts\\Core\\Repository\\SearchService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$additionalCalls with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/SearchServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SectionServiceDecoratorTest\:\:testAssignSectionDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/SectionServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SectionServiceDecoratorTest\:\:testAssignSectionToSubtreeDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$keyGeneratingArguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/SectionServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SectionServiceDecoratorTest\:\:testCountAssignedContentsDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$keyGeneratingResults with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/SectionServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SectionServiceDecoratorTest\:\:testCreateSectionDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$tagGeneratingArguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/SectionServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SectionServiceDecoratorTest\:\:testDeleteSectionDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheHit\(\) has parameter \$tagGeneratingResults with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/SectionServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SectionServiceDecoratorTest\:\:testIsSectionUsedDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$additionalCalls with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/SectionServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SectionServiceDecoratorTest\:\:testLoadSectionByIdentifierDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/SectionServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SectionServiceDecoratorTest\:\:testLoadSectionDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$keyGeneratingArguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/SectionServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SectionServiceDecoratorTest\:\:testLoadSectionsDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$keyGeneratingResults with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/SectionServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SectionServiceDecoratorTest\:\:testNewSectionCreateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$tagGeneratingArguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/SectionServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SectionServiceDecoratorTest\:\:testNewSectionUpdateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testLoadMethodsCacheMiss\(\) has parameter \$tagGeneratingResults with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/SectionServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SectionServiceDecoratorTest\:\:testUpdateSectionDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testUnCachedMethods\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/SectionServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\SectionServiceDecorator@anonymous/tests/lib/Repository/Decorator/SectionServiceDecoratorTest\.php\:27 constructor expects Ibexa\\Contracts\\Core\\Repository\\SectionService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testUnCachedMethods\(\) has parameter \$key with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/SectionServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SettingServiceDecoratorTest\:\:testCreateSettingDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testUnCachedMethods\(\) has parameter \$keyGeneratingArguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/SettingServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SettingServiceDecoratorTest\:\:testDeleteSettingDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testUnCachedMethods\(\) has parameter \$tagGeneratingArguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/SettingServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SettingServiceDecoratorTest\:\:testLoadSettingDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractInMemoryCacheHandlerTestCase\:\:testUnCachedMethods\(\) has parameter \$tags with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/SettingServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SettingServiceDecoratorTest\:\:testNewSettingCreateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Decorator/SettingServiceDecoratorTest.php + message: '#^Method PHPUnit\\Framework\\MockObject\\Builder\\InvocationMocker\:\:with\(\) invoked with unpacked array with possibly string key, but it''s not allowed because of @no\-named\-arguments\.$#' + identifier: argument.named + count: 2 + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SettingServiceDecoratorTest\:\:testNewSettingUpdateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Decorator/SettingServiceDecoratorTest.php + message: '#^Offset int might not exist on array\|null\.$#' + identifier: offsetAccess.notFound + count: 5 + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SettingServiceDecoratorTest\:\:testUpdateSettingDecorator\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Decorator/SettingServiceDecoratorTest.php + message: '#^Parameter \#1 \$callback of function call_user_func_array expects callable\(\)\: mixed, array\{mixed, string\} given\.$#' + identifier: argument.type + count: 3 + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\SettingServiceDecorator@anonymous/tests/lib/Repository/Decorator/SettingServiceDecoratorTest\.php\:26 constructor expects Ibexa\\Contracts\\Core\\Repository\\SettingService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + message: '#^Parameter \#1 \$originalClassName of method PHPUnit\\Framework\\TestCase\:\:createMock\(\) expects class\-string\, string given\.$#' identifier: argument.type - count: 1 - path: tests/lib/Repository/Decorator/SettingServiceDecoratorTest.php + count: 2 + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\TranslationServiceDecoratorTest\:\:testTranslateDecorator\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Decorator/TranslationServiceDecoratorTest.php + message: '#^Unable to resolve the template type T in call to method PHPUnit\\Framework\\TestCase\:\:createMock\(\)$#' + identifier: argument.templateType + count: 3 + path: tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\TranslationServiceDecoratorTest\:\:testTranslateStringDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Adapter\\InMemoryClearingProxyAdapterTest\:\:arrayAsGenerator\(\) has parameter \$array with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/TranslationServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php - - message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\TranslationServiceDecorator@anonymous/tests/lib/Repository/Decorator/TranslationServiceDecoratorTest\.php\:21 constructor expects Ibexa\\Contracts\\Core\\Repository\\TranslationService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Adapter\\InMemoryClearingProxyAdapterTest\:\:createCacheItem\(\) has parameter \$tags with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/TranslationServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\TrashServiceDecoratorTest\:\:testDeleteTrashItemDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Adapter\\InMemoryClearingProxyAdapterTest\:\:providerForClearAndInvalidation\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/TrashServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\TrashServiceDecoratorTest\:\:testEmptyTrashDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Adapter\\InMemoryClearingProxyAdapterTest\:\:providerForDelete\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/TrashServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\TrashServiceDecoratorTest\:\:testFindTrashItemsDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Adapter\\InMemoryClearingProxyAdapterTest\:\:testClearAndInvalidation\(\) has parameter \$argument with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/TrashServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\TrashServiceDecoratorTest\:\:testLoadTrashItemDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Adapter\\InMemoryClearingProxyAdapterTest\:\:testDelete\(\) has parameter \$argument with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/TrashServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\TrashServiceDecoratorTest\:\:testRecoverDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\BookmarkHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/TrashServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/BookmarkHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\TrashServiceDecoratorTest\:\:testTrashDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\BookmarkHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/TrashServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/BookmarkHandlerTest.php - - message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\TrashServiceDecorator@anonymous/tests/lib/Repository/Decorator/TrashServiceDecoratorTest\.php\:23 constructor expects Ibexa\\Contracts\\Core\\Repository\\TrashService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\BookmarkHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/TrashServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/BookmarkHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLAliasServiceDecoratorTest\:\:testCreateGlobalUrlAliasDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ContentHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/URLAliasServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLAliasServiceDecoratorTest\:\:testCreateUrlAliasDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ContentHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/URLAliasServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLAliasServiceDecoratorTest\:\:testDeleteCorruptedUrlAliasesDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ContentHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/URLAliasServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLAliasServiceDecoratorTest\:\:testListGlobalAliasesDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ContentLanguageHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/URLAliasServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/ContentLanguageHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLAliasServiceDecoratorTest\:\:testListLocationAliasesDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ContentLanguageHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/URLAliasServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/ContentLanguageHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLAliasServiceDecoratorTest\:\:testLoadDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ContentLanguageHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/URLAliasServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/ContentLanguageHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLAliasServiceDecoratorTest\:\:testLookupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ContentTypeHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/URLAliasServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/ContentTypeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLAliasServiceDecoratorTest\:\:testRefreshSystemUrlAliasesForLocationDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ContentTypeHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/URLAliasServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/ContentTypeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLAliasServiceDecoratorTest\:\:testRemoveAliasesDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ContentTypeHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/URLAliasServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/ContentTypeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLAliasServiceDecoratorTest\:\:testReverseLookupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$callback of function call_user_func_array expects callable\(\)\: mixed, array\{mixed, ''publish''\} given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Decorator/URLAliasServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/ContentTypeHandlerTest.php - - message: '#^Parameter \#1 \$aliasList of method Ibexa\\Contracts\\Core\\Repository\\URLAliasService\:\:removeAliases\(\) expects array\, array\ given\.$#' + message: '#^Parameter \#1 \$originalClassName of method PHPUnit\\Framework\\TestCase\:\:createMock\(\) expects class\-string\, string given\.$#' identifier: argument.type count: 1 - path: tests/lib/Repository/Decorator/URLAliasServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/ContentTypeHandlerTest.php - - message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\URLAliasServiceDecorator@anonymous/tests/lib/Repository/Decorator/URLAliasServiceDecoratorTest\.php\:24 constructor expects Ibexa\\Contracts\\Core\\Repository\\URLAliasService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + message: '#^Parameter \#2 \$value of method Ibexa\\Tests\\Core\\Persistence\\Cache\\AbstractBaseHandlerTestCase\:\:getCacheItem\(\) expects null, Ibexa\\Contracts\\Core\\Persistence\\Content\\Type given\.$#' identifier: argument.type count: 1 - path: tests/lib/Repository/Decorator/URLAliasServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/ContentTypeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLServiceDecoratorTest\:\:testCreateUpdateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Unable to resolve the template type T in call to method PHPUnit\\Framework\\TestCase\:\:createMock\(\)$#' + identifier: argument.templateType count: 1 - path: tests/lib/Repository/Decorator/URLServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/ContentTypeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLServiceDecoratorTest\:\:testFindUrlsDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Variable \$tags in empty\(\) always exists and is not falsy\.$#' + identifier: empty.variable count: 1 - path: tests/lib/Repository/Decorator/URLServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/ContentTypeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLServiceDecoratorTest\:\:testFindUsagesDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorTest\:\:providerForTestGenerateKey\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/URLServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/Identifier/CacheIdentifierGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLServiceDecoratorTest\:\:testLoadByIdDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorTest\:\:providerForTestGenerateKeyThrowsInvalidArgumentException\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/URLServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/Identifier/CacheIdentifierGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLServiceDecoratorTest\:\:testLoadByUrlDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorTest\:\:providerForTestGenerateTag\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/URLServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/Identifier/CacheIdentifierGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLServiceDecoratorTest\:\:testUpdateUrlDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorTest\:\:providerForTestGenerateTagThrowsInvalidArgumentException\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/URLServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/Identifier/CacheIdentifierGeneratorTest.php - - message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\URLServiceDecorator@anonymous/tests/lib/Repository/Decorator/URLServiceDecoratorTest\.php\:23 constructor expects Ibexa\\Contracts\\Core\\Repository\\URLService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorTest\:\:testGenerateKey\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/URLServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/Identifier/CacheIdentifierGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLWildcardServiceDecoratorTest\:\:testCreateDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorTest\:\:testGenerateKeyThrowsInvalidArgumentException\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/URLWildcardServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/Identifier/CacheIdentifierGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLWildcardServiceDecoratorTest\:\:testLoadAllDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorTest\:\:testGenerateTag\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/URLWildcardServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/Identifier/CacheIdentifierGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLWildcardServiceDecoratorTest\:\:testLoadDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorTest\:\:testGenerateTagThrowsInvalidArgumentException\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/URLWildcardServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/Identifier/CacheIdentifierGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLWildcardServiceDecoratorTest\:\:testRemoveDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierSanitizerTest\:\:providerForTestEscapeCacheKey\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/URLWildcardServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/Identifier/CacheIdentifierSanitizerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\URLWildcardServiceDecoratorTest\:\:testTranslateDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierSanitizerTest\:\:testEscapeCacheKey\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/URLWildcardServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/Identifier/CacheIdentifierSanitizerTest.php - - message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\URLWildcardServiceDecorator@anonymous/tests/lib/Repository/Decorator/URLWildcardServiceDecoratorTest\.php\:21 constructor expects Ibexa\\Contracts\\Core\\Repository\\URLWildcardService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type + message: '#^Function Ibexa\\Core\\Persistence\\Cache\\InMemory\\microtime\(\) has parameter \$asFloat with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Decorator/URLWildcardServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/InMemory/InMemoryCacheTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserPreferenceServiceDecoratorTest\:\:testGetUserPreferenceCountDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\LocationHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserPreferenceServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/LocationHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserPreferenceServiceDecoratorTest\:\:testGetUserPreferenceDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\LocationHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserPreferenceServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/LocationHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserPreferenceServiceDecoratorTest\:\:testLoadUserPreferencesDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\LocationHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserPreferenceServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/LocationHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserPreferenceServiceDecoratorTest\:\:testSetUserPreferenceDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\LocationPathConverterTest\:\:providerForTestConvertToPathIds\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserPreferenceServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/LocationPathConverterTest.php - - message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\UserPreferenceServiceDecorator@anonymous/tests/lib/Repository/Decorator/UserPreferenceServiceDecoratorTest\.php\:20 constructor expects Ibexa\\Contracts\\Core\\Repository\\UserPreferenceService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\LocationPathConverterTest\:\:testConvertToPathIds\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserPreferenceServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/LocationPathConverterTest.php - - message: '#^Parameter \#1 \$userPreferenceSetStructs of method Ibexa\\Contracts\\Core\\Repository\\UserPreferenceService\:\:setUserPreference\(\) expects array\, array\ given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\LocationPathConverterTest\:\:testConvertToPathIds\(\) has parameter \$resultArray with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserPreferenceServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/LocationPathConverterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testAssignUserToUserGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\NotificationHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/NotificationHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testCheckUserCredentialsDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\NotificationHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/NotificationHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testCreateUserDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\NotificationHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/NotificationHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testCreateUserGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ObjectStateHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/ObjectStateHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testDeleteUserDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ObjectStateHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/ObjectStateHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testDeleteUserGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\ObjectStateHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/ObjectStateHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testExpireUserTokenDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\SectionHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/SectionHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testIsUserDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\SectionHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/SectionHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testIsUserGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\SectionHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/SectionHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testLoadSubUserGroupsDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\SettingHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/SettingHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testLoadUserByLoginDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\SettingHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/SettingHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testLoadUserByTokenDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\SettingHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/SettingHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testLoadUserDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\TransactionHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/TransactionHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testLoadUserGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\TransactionHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/TransactionHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testLoadUserGroupsOfUserDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\TransactionHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/TransactionHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testLoadUsersByEmailDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\TrashHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/TrashHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testLoadUsersOfUserGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\TrashHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/TrashHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testMoveUserGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\TrashHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/TrashHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testNewUserCreateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + message: '#^Parameter \#1 \$originalClassName of method PHPUnit\\Framework\\TestCase\:\:createMock\(\) expects class\-string\, string given\.$#' + identifier: argument.type + count: 3 + path: tests/lib/Persistence/Cache/TrashHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testNewUserGroupCreateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + message: '#^Unable to resolve the template type T in call to method PHPUnit\\Framework\\TestCase\:\:createMock\(\)$#' + identifier: argument.templateType + count: 3 + path: tests/lib/Persistence/Cache/TrashHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testNewUserGroupUpdateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\URLHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/URLHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testNewUserUpdateStructDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\URLHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/URLHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testUnAssignUserFromUserGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\URLHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/URLHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testUpdateUserDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UrlAliasHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testUpdateUserGroupDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UrlAliasHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testUpdateUserTokenDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UrlAliasHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\UserServiceDecoratorTest\:\:testValidatePasswordDecorator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UrlWildcardHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/UrlWildcardHandlerTest.php - - message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\UserServiceDecorator@anonymous/tests/lib/Repository/Decorator/UserServiceDecoratorTest\.php\:37 constructor expects Ibexa\\Contracts\\Core\\Repository\\UserService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UrlWildcardHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php + path: tests/lib/Persistence/Cache/UrlWildcardHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Filtering\\TestContentProvider\:\:createContentDraft\(\) has parameter \$multilingualFields with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UrlWildcardHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Filtering/TestContentProvider.php + path: tests/lib/Persistence/Cache/UrlWildcardHandlerTest.php - - message: '#^Parameter \#2 \$mainLanguageCode of method Ibexa\\Contracts\\Core\\Repository\\ContentService\:\:newContentCreateStruct\(\) expects string, int\|string given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UserHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Filtering/TestContentProvider.php + path: tests/lib/Persistence/Cache/UserHandlerTest.php - - message: '#^Parameter \#2 \$parentLocationId of method Ibexa\\Tests\\Core\\Repository\\Filtering\\TestContentProvider\:\:createArticle\(\) expects int, int\|null given\.$#' - identifier: argument.type - count: 3 - path: tests/lib/Repository/Filtering/TestContentProvider.php + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UserHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/lib/Persistence/Cache/UserHandlerTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\FieldType\\\\FieldType'' and Ibexa\\Contracts\\Core\\FieldType\\FieldType will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UserHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Helper/FieldTypeRegistryTest.php + path: tests/lib/Persistence/Cache/UserHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Helper\\FieldTypeRegistryTest\:\:getFieldTypeMock\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UserPreferenceHandlerTest\:\:providerForCachedLoadMethodsHit\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Helper/FieldTypeRegistryTest.php + path: tests/lib/Persistence/Cache/UserPreferenceHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Helper\\FieldTypeRegistryTest\:\:testConstructor\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UserPreferenceHandlerTest\:\:providerForCachedLoadMethodsMiss\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Helper/FieldTypeRegistryTest.php + path: tests/lib/Persistence/Cache/UserPreferenceHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Helper\\FieldTypeRegistryTest\:\:testGetFieldType\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Cache\\UserPreferenceHandlerTest\:\:providerForUnCachedMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Helper/FieldTypeRegistryTest.php + path: tests/lib/Persistence/Cache/UserPreferenceHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Helper\\FieldTypeRegistryTest\:\:testGetFieldTypeThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Helper/FieldTypeRegistryTest.php + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Persistence\\\\FieldType'' and Ibexa\\Contracts\\Core\\Persistence\\FieldType will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType + count: 3 + path: tests/lib/Persistence/FieldTypeRegistryTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Helper\\FieldTypeRegistryTest\:\:testGetFieldTypeThrowsRuntimeExceptionIncorrectType\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\FieldTypeRegistryTest\:\:getFieldTypeMock\(\) should return Ibexa\\Contracts\\Core\\Persistence\\FieldType but returns Ibexa\\Contracts\\Core\\FieldType\\FieldType&PHPUnit\\Framework\\MockObject\\MockObject\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Helper/FieldTypeRegistryTest.php + path: tests/lib/Persistence/FieldTypeRegistryTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Helper\\FieldTypeRegistryTest\:\:testGetFieldTypes\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$coreFieldTypes of class Ibexa\\Core\\Persistence\\FieldTypeRegistry constructor expects array\, array\ given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Helper/FieldTypeRegistryTest.php + path: tests/lib/Persistence/FieldTypeRegistryTest.php - - message: '#^Parameter \#1 \$fieldTypes of class Ibexa\\Core\\FieldType\\FieldTypeRegistry constructor expects array\, array\ given\.$#' + message: '#^Parameter \#1 \$coreFieldTypes of class Ibexa\\Core\\Persistence\\FieldTypeRegistry constructor expects array\, array\ given\.$#' identifier: argument.type - count: 1 - path: tests/lib/Repository/Helper/FieldTypeRegistryTest.php + count: 2 + path: tests/lib/Persistence/FieldTypeRegistryTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Iterator\\BatchIteratorTestAdapter\:\:__construct\(\) has parameter \$data with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#2 \$fieldType of method Ibexa\\Core\\Persistence\\FieldTypeRegistry\:\:register\(\) expects Ibexa\\Contracts\\Core\\FieldType\\FieldType, Ibexa\\Contracts\\Core\\Persistence\\FieldType given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Iterator/BatchIteratorTestAdapter.php + path: tests/lib/Persistence/FieldTypeRegistryTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Iterator\\BatchIteratorTestAdapter\:\:\$data type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\FieldValue\\Converter\\ImageConverterTest\:\:dataProviderForTestToFieldDefinition\(\) return type has no value type specified in iterable type iterable\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Iterator/BatchIteratorTestAdapter.php - - - - message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:method\(\)\.$#' - identifier: method.notFound - count: 7 - path: tests/lib/Repository/LocationResolver/PermissionAwareLocationResolverTest.php + path: tests/lib/Persistence/FieldValue/Converter/ImageConverterTest.php - - message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:method\(\)\.$#' - identifier: method.notFound - count: 5 - path: tests/lib/Repository/Mapper/ContentLocationMapper/DecoratedLocationServiceTest.php + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\FieldValue\\Converter\\ImageConverterTest\:\:dataProviderForTestToStorageFieldDefinition\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/lib/Persistence/FieldValue/Converter/ImageConverterTest.php - - message: '#^Call to an undefined method Ibexa\\Core\\Repository\\Mapper\\ContentLocationMapper\\ContentLocationMapper\:\:expects\(\)\.$#' + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Bookmark\\Gateway\:\:loadBookmarkDataById\(\)\.$#' identifier: method.notFound - count: 5 - path: tests/lib/Repository/Mapper/ContentLocationMapper/DecoratedLocationServiceTest.php + count: 1 + path: tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php - - message: '#^Cannot access property \$locations on iterable\\.$#' - identifier: property.nonObject - count: 2 - path: tests/lib/Repository/Mapper/ContentLocationMapper/DecoratedLocationServiceTest.php + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\Gateway\\DoctrineDatabaseTest\:\:dataProviderForLoadUserBookmarks\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\PHPUnitConstraint\\ContentItemEquals\:\:compareArrays\(\) has parameter \$actual with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\Gateway\\DoctrineDatabaseTest\:\:loadBookmark\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/PHPUnitConstraint/ContentItemEquals.php + path: tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\PHPUnitConstraint\\ContentItemEquals\:\:compareArrays\(\) has parameter \$expected with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\Gateway\\DoctrineDatabaseTest\:\:testCountUserBookmarks\(\) has parameter \$expected with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/PHPUnitConstraint/ContentItemEquals.php + path: tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\PHPUnitConstraint\\ContentItemEquals\:\:evaluate\(\) has parameter \$content with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Bookmark\\Gateway\\DoctrineDatabaseTest\:\:testLoadUserBookmarks\(\) has parameter \$expected with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/PHPUnitConstraint/ContentItemEquals.php + path: tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php - - message: '#^Class Ibexa\\Tests\\Core\\Repository\\Parallel\\ParallelProcessList implements generic interface IteratorAggregate but does not specify its types\: TKey, TValue$#' - identifier: missingType.generics - count: 1 - path: tests/lib/Repository/Parallel/ParallelProcessList.php + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldHandler\:\:expects\(\)\.$#' + identifier: method.notFound + count: 9 + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:getPermissionCriterionResolverMock\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Handler\:\:expects\(\)\.$#' + identifier: method.notFound + count: 15 + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:getPermissionCriterionResolverMock\(\) has parameter \$methods with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\:\:expects\(\)\.$#' + identifier: method.notFound + count: 8 + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:getPermissionResolverMock\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper\:\:expects\(\)\.$#' + identifier: method.notFound + count: 16 + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:getPermissionResolverMock\(\) has parameter \$methods with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\:\:expects\(\)\.$#' + identifier: method.notFound count: 1 - path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:providerForTestPermissionResolverPassTrough\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\SlugConverter\:\:expects\(\)\.$#' + identifier: method.notFound count: 1 - path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:testGetPermissionsCriterionCaching\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:getContentTypeHandlerMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Handler&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Handler\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:testGetPermissionsCriterionPassTrough\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:getGatewayMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:testPermissionResolverPassTrough\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:getRelationFixture\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:testPermissionResolverPassTrough\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:getTreeHandlerMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\TreeHandler&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\TreeHandler\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:testPermissionResolverPassTrough\(\) has parameter \$expectedReturn with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$methods of method PHPUnit\\Framework\\MockObject\\MockBuilder\\:\:onlyMethods\(\) expects list\, list\ given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:testPermissionResolverPassTrough\(\) has parameter \$method with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:\$contentHandler \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Handler\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:\$permissionCriterionResolverMock has no type specified\.$#' - identifier: missingType.property + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:\$contentTypeHandlerMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Handler\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:\$permissionResolverMock has no type specified\.$#' - identifier: missingType.property + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:\$fieldHandlerMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldHandler\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:getLimitationServiceMock\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:\$gatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:getLimitationServiceMock\(\) has parameter \$methods with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:\$locationGatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:getPermissionResolverMock\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:\$mapperMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:getPermissionResolverMock\(\) has parameter \$methods with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:\$slugConverterMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\SlugConverter\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:mockServices\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:\$treeHandlerMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\TreeHandler\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:mockServices\(\) has parameter \$criterionMock with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:\$typeGatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:mockServices\(\) has parameter \$limitationCount with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ContentHandlerTest\:\:\$urlAliasGatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php + path: tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:mockServices\(\) has parameter \$permissionSets with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:assertCreateExistingFieldsInNewVersion\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:providerForTestGetPermissionsCriterion\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:assertCreateNewFields\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:providerForTestGetPermissionsCriterionBooleanPermissionSets\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:assertCreateNewFieldsForMainLanguage\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:testGetPermissionsCriterion\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:assertUpdateFieldsExistingLanguages\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:testGetPermissionsCriterion\(\) has parameter \$criterionMock with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:assertUpdateFieldsForInitialLanguage\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:testGetPermissionsCriterion\(\) has parameter \$expectedCriterion with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:assertUpdateFieldsWithNewLanguage\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:testGetPermissionsCriterion\(\) has parameter \$limitationCount with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:getContentGatewayMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:testGetPermissionsCriterion\(\) has parameter \$permissionSets with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:getFieldTypeMock\(\) should return Ibexa\\Contracts\\Core\\Persistence\\FieldType&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Contracts\\Core\\FieldType\\FieldType\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:testGetPermissionsCriterionBooleanPermissionSets\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:getFieldTypeRegistryMock\(\) should return Ibexa\\Core\\Persistence\\FieldTypeRegistry&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\FieldTypeRegistry\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:testGetPermissionsCriterionBooleanPermissionSets\(\) has parameter \$permissionSets with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:getMapperMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:\$limitationServiceMock has no type specified\.$#' - identifier: missingType.property + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:getStorageHandlerMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageHandler&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageHandler\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:\$permissionResolverMock has no type specified\.$#' - identifier: missingType.property - count: 1 - path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php + message: '#^Offset int\<\-1, max\> might not exist on array\{\}\|array\{0\: array\{copy\: Ibexa\\Contracts\\Core\\Persistence\\Content\\Field, original\: Ibexa\\Contracts\\Core\\Persistence\\Content\\Field\}, 1\?\: array\{copy\: Ibexa\\Contracts\\Core\\Persistence\\Content\\Field, original\: Ibexa\\Contracts\\Core\\Persistence\\Content\\Field\}\}\.$#' + identifier: offsetAccess.notFound + count: 2 + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:getEventDispatcher\(\) should return PHPUnit\\Framework\\MockObject\\MockObject&Symfony\\Contracts\\EventDispatcher\\EventDispatcherInterface but returns Symfony\\Contracts\\EventDispatcher\\EventDispatcherInterface\.$#' - identifier: return.type + message: '#^Property Ibexa\\Contracts\\Core\\Persistence\\Content\\Field\:\:\$value \(Ibexa\\Contracts\\Core\\Persistence\\Content\\FieldValue\) does not accept null\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Repository/Service/Mock/Base.php + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:getRelationProcessorMock\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:\$contentGatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/Base.php + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:getRepository\(\) has parameter \$serviceSettings with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:\$fieldTypeMock \(Ibexa\\Contracts\\Core\\FieldType\\FieldType\) does not accept Ibexa\\Contracts\\Core\\Persistence\\FieldType&PHPUnit\\Framework\\MockObject\\MockObject\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Repository/Service/Mock/Base.php + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Parameter \#1 \$className of method PHPUnit\\Framework\\TestCase\:\:getMockBuilder\(\) expects class\-string\, string given\.$#' - identifier: argument.type + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:\$fieldTypeMock \(Ibexa\\Contracts\\Core\\FieldType\\FieldType\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/Base.php + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Parameter \#2 \$searchHandler of class Ibexa\\Core\\Repository\\Repository constructor expects Ibexa\\Contracts\\Core\\Search\\Handler, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:\$fieldTypeRegistryMock \(Ibexa\\Core\\Persistence\\FieldTypeRegistry\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/Base.php + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:\$contentDomainMapperMock \(Ibexa\\Core\\Repository\\Mapper\\ContentDomainMapper&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:\$mapperMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper\) in isset\(\) is not nullable\.$#' identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/Base.php + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:\$contentTypeDomainMapperMock \(Ibexa\\Core\\Repository\\Mapper\\ContentTypeDomainMapper&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldHandlerTest\:\:\$storageHandlerMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageHandler\) in isset\(\) is not nullable\.$#' identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/Base.php + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:\$fieldTypeRegistryMock has no type specified\.$#' - identifier: missingType.property - count: 1 - path: tests/lib/Repository/Service/Mock/Base.php + message: '#^Variable \$copyField might not be defined\.$#' + identifier: variable.undefined + count: 2 + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:\$fieldTypeServiceMock has no type specified\.$#' - identifier: missingType.property - count: 1 - path: tests/lib/Repository/Service/Mock/Base.php + message: '#^Variable \$originalField might not be defined\.$#' + identifier: variable.undefined + count: 2 + path: tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:\$permissionServiceMock \(Ibexa\\Contracts\\Core\\Repository\\PermissionService&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Cannot access offset ''email'' on Ibexa\\Core\\FieldType\\Author\\Author\.$#' + identifier: offsetAccess.nonOffsetAccessible count: 1 - path: tests/lib/Repository/Service/Mock/Base.php + path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/AuthorTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:\$persistenceMock \(Ibexa\\Contracts\\Core\\Persistence\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Cannot access offset ''id'' on Ibexa\\Core\\FieldType\\Author\\Author\.$#' + identifier: offsetAccess.nonOffsetAccessible count: 1 - path: tests/lib/Repository/Service/Mock/Base.php + path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/AuthorTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:\$repositoryMock \(Ibexa\\Contracts\\Core\\Repository\\Repository&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Cannot access offset ''name'' on Ibexa\\Core\\FieldType\\Author\\Author\.$#' + identifier: offsetAccess.nonOffsetAccessible count: 1 - path: tests/lib/Repository/Service/Mock/Base.php + path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/AuthorTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:\$thumbnailStrategyMock \(Ibexa\\Contracts\\Core\\Repository\\Strategy\\ContentThumbnail\\ThumbnailStrategy&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\AuthorTest\:\:\$authors \(array\\) does not accept array\\>\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Repository/Service/Mock/Base.php + path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/AuthorTest.php - - message: '#^Unable to resolve the template type T in call to method PHPUnit\\Framework\\TestCase\:\:getMockBuilder\(\)$#' - identifier: argument.templateType + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:testToFieldValue\(\) has parameter \$data with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/Base.php + path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\BookmarkTest\:\:createBookmarkService\(\) has parameter \$methods with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:testToFieldValue\(\) has parameter \$dataText with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/BookmarkTest.php + path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\BookmarkTest\:\:testCreateBookmark\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:testToFieldValue\(\) has parameter \$sortKeyString with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/BookmarkTest.php + path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\BookmarkTest\:\:testCreateBookmarkThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:testToStorageValue\(\) has parameter \$data with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/BookmarkTest.php + path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\BookmarkTest\:\:testCreateBookmarkWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:testToStorageValue\(\) has parameter \$dataText with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/BookmarkTest.php + path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\BookmarkTest\:\:testDeleteBookmarkExisting\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:testToStorageValue\(\) has parameter \$sortKey with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/BookmarkTest.php + path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\BookmarkTest\:\:testDeleteBookmarkNonExisting\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\CountryTest\:\:testToStorageValue\(\) has parameter \$sortKeyString with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/BookmarkTest.php + path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\BookmarkTest\:\:testDeleteBookmarkWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Cannot access offset ''timestring'' on array\|bool\|float\|int\|string\|null\.$#' + identifier: offsetAccess.nonOffsetAccessible + count: 3 + path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateAndTimeTest.php + + - + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\DateAndTimeTest\:\:getXMLToDateIntervalMap\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/BookmarkTest.php + path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateAndTimeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\BookmarkTest\:\:testLoadBookmarks\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\ISBNTest\:\:testToFieldDefinition\(\) has parameter \$dataInt with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/BookmarkTest.php + path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/ISBNTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\BookmarkTest\:\:testLocationShouldBeBookmarked\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\ISBNTest\:\:testToFieldDefinition\(\) has parameter \$excpectedIsbn13Value with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/BookmarkTest.php + path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/ISBNTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\BookmarkTest\:\:testLocationShouldNotBeBookmarked\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\MediaTest\:\:\$converter has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Service/Mock/BookmarkTest.php + path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/MediaTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\BookmarkTest\:\:\$bookmarkHandler \(Ibexa\\Contracts\\Core\\Persistence\\Bookmark\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept PHPUnit\\Framework\\MockObject\\MockObject\.$#' + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\RelationTest\:\:\$converter \(Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\RelationConverter&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\RelationConverter\.$#' identifier: assign.propertyType count: 1 - path: tests/lib/Repository/Service/Mock/BookmarkTest.php + path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/RelationTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Location'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\\TextBlockTest\:\:\$longText has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php + path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TextBlockTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:getContentHandlerMock\(\) should return Ibexa\\Contracts\\Core\\Persistence\\Content\\Handler&PHPUnit\\Framework\\MockObject\\MockObject but returns PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: return.type + message: '#^Property Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageFieldValue\:\:\$sortKeyInt \(int\) does not accept false\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php + path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:getLanguageHandlerMock\(\) should return Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler&PHPUnit\\Framework\\MockObject\\MockObject but returns PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: return.type + message: '#^Property Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageFieldValue\:\:\$sortKeyString \(string\) does not accept false\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php + path: tests/lib/Persistence/Legacy/Content/FieldValue/Converter/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:getTypeHandlerMock\(\) should return Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\Handler&PHPUnit\\Framework\\MockObject\\MockObject but returns PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: return.type + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:assertContentVersionAttributesLanguages\(\) has parameter \$expectation with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php + path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:providerForBuildLocationDomainObjectsOnSearchResult\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:assertValuesInRows\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php + path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:providerForBuildVersionInfo\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:insertRelationFixture\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php + path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:testBuildLocationDomainObjectsOnSearchResult\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:storeFixture\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php + path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:testBuildLocationDomainObjectsOnSearchResult\(\) has parameter \$contentIds with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php + message: '#^Parameter \#2 \$expectedValues of method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:assertValuesInRows\(\) expects array\, array\ given\.$#' + identifier: argument.type + count: 9 + path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:testBuildLocationDomainObjectsOnSearchResult\(\) has parameter \$contentInfoList with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabaseTest\:\:\$databaseGateway \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\\DoctrineDatabase\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php + path: tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:testBuildLocationDomainObjectsOnSearchResult\(\) has parameter \$languageFilter with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:getCacheIdentifierGeneratorMock\(\) should return Ibexa\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorInterface&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorInterface\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php + path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:testBuildLocationDomainObjectsOnSearchResult\(\) has parameter \$locationHits with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:getInnerLanguageHandlerMock\(\) should return Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php + path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:testBuildLocationWithContentForRootLocation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:getLanguageCacheMock\(\) should return Ibexa\\Core\\Persistence\\Cache\\InMemory\\InMemoryCache&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Cache\\InMemory\\InMemoryCache\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php + path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:testBuildLocationWithContentIsAlignedWithBuildLocation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:getLanguageHandler\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\CachingHandler but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Handler\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php + path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:testBuildLocationWithContentThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:\$cacheIdentifierGeneratorMock \(Ibexa\\Core\\Persistence\\Cache\\Identifier\\CacheIdentifierGeneratorInterface\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php + path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:testBuildVersionInfo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:\$innerHandlerMock \(Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php + path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - message: '#^Parameter \#2 \$locationHandler of class Ibexa\\Core\\Repository\\Mapper\\ContentDomainMapper constructor expects Ibexa\\Contracts\\Core\\Persistence\\Content\\Location\\Handler, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' - identifier: argument.type + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:\$languageCacheMock \(Ibexa\\Core\\Persistence\\Cache\\InMemory\\InMemoryCache\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php + path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\FieldType\\Value\:\:\$value\.$#' - identifier: property.notFound + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:\$languageHandler \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Handler\) does not accept Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\CachingHandler\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Persistence\\Content\\Handler\:\:expects\(\)\.$#' - identifier: method.notFound + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\CachingLanguageHandlerTest\:\:\$languageHandler \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Handler\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForCreateContentContentValidationException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\Gateway\\DoctrineDatabaseTest\:\:\$databaseGateway \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Gateway\\DoctrineDatabase\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Language/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForCreateContentContentValidationException\(\) has parameter \$fieldDefinitions with no type specified\.$#' - identifier: missingType.parameter + message: '#^Result of method Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Gateway\\DoctrineDatabase\:\:deleteLanguage\(\) \(void\) is used\.$#' + identifier: method.void count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Language/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForCreateContentContentValidationException\(\) has parameter \$mainLanguageCode with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Gateway\:\:expects\(\)\.$#' + identifier: method.notFound + count: 11 + path: tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForCreateContentContentValidationException\(\) has parameter \$structFields with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Mapper\:\:expects\(\)\.$#' + identifier: method.notFound + count: 6 + path: tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestCreateContentThrowsContentFieldValidationException\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\LanguageHandlerTest\:\:\$gatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Gateway\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentRequiredField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\LanguageHandlerTest\:\:\$languageHandler \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Handler\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentRequiredField\(\) has parameter \$existingFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\LanguageHandlerTest\:\:\$mapperMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Mapper\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentRequiredField\(\) has parameter \$fieldDefinitions with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:getLanguageHandler\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Handler but returns Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentRequiredField\(\) has parameter \$initialLanguageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:getLanguageIndicatorData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentRequiredField\(\) has parameter \$structFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:isAlwaysAvailableProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentThrowsContentFieldValidationException\(\) has parameter \$allFieldErrors with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:languageIdsFromMaskProvider\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentThrowsContentFieldValidationException\(\) has parameter \$existingFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:removeAlwaysAvailableFlagProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentThrowsContentFieldValidationException\(\) has parameter \$fieldDefinitions with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:testExtractLanguageIdsFromMask\(\) has parameter \$expectedResult with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentThrowsContentFieldValidationException\(\) has parameter \$initialLanguageCode with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:testRemoveAlwaysAvailableFlag\(\) has parameter \$expectedResult with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentThrowsContentFieldValidationException\(\) has parameter \$structFields with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGeneratorTest\:\:testRemoveAlwaysAvailableFlag\(\) has parameter \$langMask with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentThrowsContentFieldValidationException\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForUpdateContentContentValidationException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Offset string might not exist on array\{\}\|array\{eng\-US\?\: Ibexa\\Contracts\\Core\\Persistence\\Content\\Language, eng\-GB\?\: Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\}\.$#' + identifier: offsetAccess.notFound count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForUpdateContentContentValidationException\(\) has parameter \$fieldDefinitions with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageAwareTestCase\:\:\$languageHandler \(Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForUpdateContentContentValidationException\(\) has parameter \$initialLanguageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageAwareTestCase\:\:getFullTextSearchConfiguration\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/LanguageAwareTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForUpdateContentContentValidationException\(\) has parameter \$structFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageAwareTestCase\:\:\$fieldNameGeneratorMock \(Ibexa\\Core\\Search\\Common\\FieldNameGenerator&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/LanguageAwareTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:determineValuesForCreate\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageAwareTestCase\:\:\$languageHandler \(Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/LanguageAwareTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:determineValuesForCreate\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageAwareTestCase\:\:\$languageMaskGenerator \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGenerator\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/LanguageAwareTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:determineValuesForUpdate\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageHandlerMock\:\:delete\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/LanguageHandlerMock.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:determineValuesForUpdate\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageHandlerMock\:\:loadList\(\) has parameter \$ids with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:fixturesForTestCreateContentNonRedundantFieldSetComplex\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/LanguageHandlerMock.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:fixturesForTestUpdateContentNonRedundantFieldSetComplex\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageHandlerMock\:\:update\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/LanguageHandlerMock.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:getPartlyMockedContentService\(\) should return Ibexa\\Core\\Repository\\ContentService&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Repository\\ContentService\.$#' - identifier: return.type + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageHandlerMock\:\:\$languages has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/LanguageHandlerMock.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:internalLoadContentProviderById\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:assertLoadLocationProperties\(\) has parameter \$locationData with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:internalLoadContentProviderByRemoteId\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:buildContentTreeSelectContentWithParentQuery\(\) has parameter \$fields with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:mapStructFieldsForCreate\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:buildGenericNodeSelectContentWithParentQuery\(\) has parameter \$fields with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:mapStructFieldsForUpdate\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:buildNodeAssignmentSelectContentWithParentQuery\(\) has parameter \$fields with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:mockBuildContentDomainObject\(\) has parameter \$translations with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:getLoadLocationValues\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:mockGetDefaultObjectStates\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:getLocationGateway\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:mockPublishUrlAliasesForContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testConvertNodeAssignments\(\) has parameter \$field with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:mockSetDefaultObjectStates\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testConvertNodeAssignments\(\) has parameter \$value with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:prepareContentForTestCreateAndUpdateContent\(\) has parameter \$existingFields with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testCreateLocationNodeAssignmentCreation\(\) has parameter \$expectedResult with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:prepareContentForTestCreateAndUpdateContent\(\) has parameter \$existingLanguageCodes with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testCreateLocationReturnValues\(\) has parameter \$field with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:prepareContentForTestCreateAndUpdateContent\(\) has parameter \$fieldDefinitions with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testCreateLocationReturnValues\(\) has parameter \$value with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:provideCommonCreateContentObjects\(\) has parameter \$fieldDefinitions with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testCreateLocationValues\(\) has parameter \$field with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:provideCommonCreateContentObjects\(\) has parameter \$mainLanguageCode with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testCreateLocationValues\(\) has parameter \$value with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:provideCommonCreateContentObjects\(\) has parameter \$structFields with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testUpdateLocation\(\) has parameter \$field with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:provideCommonCreateContentObjects\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testUpdateLocation\(\) has parameter \$value with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestCreateContentNonRedundantFieldSet1\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testUpdatePathIdentificationString\(\) has parameter \$expected with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestCreateContentNonRedundantFieldSet2\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testUpdatePathIdentificationString\(\) has parameter \$locationId with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestCreateContentNonRedundantFieldSetComplex\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testUpdatePathIdentificationString\(\) has parameter \$parentLocationId with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestCreateContentThrowsContentFieldValidationException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTest\:\:testUpdatePathIdentificationString\(\) has parameter \$text with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php + + - + message: '#^Parameter \#2 \$y of method Doctrine\\DBAL\\Query\\Expression\\ExpressionBuilder\:\:in\(\) expects array\\|string, array\ given\.$#' + identifier: argument.type + count: 11 + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestCreateContentThrowsContentValidationExceptionFieldDefinition\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:getLocationGateway\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestCreateContentThrowsContentValidationExceptionRequiredField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testListTrashItem\(\) has parameter \$key with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestCreateContentThrowsContentValidationExceptionTranslation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testListTrashItem\(\) has parameter \$value with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestCreateContentWithInvalidLanguage\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testLoadTrashByLocationId\(\) has parameter \$field with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestUpdateContentNonRedundantFieldSet1\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testLoadTrashByLocationId\(\) has parameter \$value with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestUpdateContentNonRedundantFieldSet2\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testUntrashLocationDefault\(\) has parameter \$property with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestUpdateContentNonRedundantFieldSet3\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:testUntrashLocationDefault\(\) has parameter \$value with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestUpdateContentNonRedundantFieldSet4\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\\DoctrineDatabaseTrashTest\:\:trashSubtree\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestUpdateContentNonRedundantFieldSetComplex\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#2 \$y of method Doctrine\\DBAL\\Query\\Expression\\ExpressionBuilder\:\:in\(\) expects array\\|string, array\ given\.$#' + identifier: argument.type + count: 3 + path: tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php + + - + message: '#^Parameter \#2 \$prefix of method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Mapper\:\:createLocationFromRow\(\) expects string, null given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestUpdateContentRequiredField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\MapperTest\:\:\$locationCreateStructValues type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestUpdateContentThrowsBadStateException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\MapperTest\:\:\$locationRow type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestUpdateContentThrowsContentFieldValidationException\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\MapperTest\:\:\$locationValues type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestUpdateContentThrowsContentValidationExceptionFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\:\:expects\(\)\.$#' + identifier: method.notFound + count: 31 + path: tests/lib/Persistence/Legacy/Content/Location/TrashHandlerTest.php + + - + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Handler\:\:expects\(\)\.$#' + identifier: method.notFound count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/TrashHandlerTest.php + + - + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Mapper\:\:expects\(\)\.$#' + identifier: method.notFound + count: 8 + path: tests/lib/Persistence/Legacy/Content/Location/TrashHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestUpdateContentThrowsContentValidationExceptionTranslation\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Location\\TrashHandlerTest\:\:getTrashHandler\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Location/TrashHandlerTest.php + + - + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Handler\:\:expects\(\)\.$#' + identifier: method.notFound + count: 4 + path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php + + - + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\:\:expects\(\)\.$#' + identifier: method.notFound + count: 19 + path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php + + - + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Handler\:\:expects\(\)\.$#' + identifier: method.notFound + count: 4 + path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php + + - + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Mapper\:\:expects\(\)\.$#' + identifier: method.notFound + count: 4 + path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestUpdateContentWithInvalidLanguage\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LocationHandlerTest\:\:getLocationHandler\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:stubValues\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LocationHandlerTest\:\:loadParentLocationsForDraftContent\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:stubValues\(\) has parameter \$fieldValues with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$methods of method PHPUnit\\Framework\\MockObject\\MockBuilder\\:\:onlyMethods\(\) expects list\, list\ given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCopyContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Argument of an invalid type Ibexa\\Contracts\\Core\\Persistence\\Content\\Relation\\CreateStruct supplied for foreach, only iterables are supported\.$#' + identifier: foreach.nonIterable count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCopyContentThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper\:\:createCreateStructFromContent\(\) invoked with 2 parameters, 1 required\.$#' + identifier: arguments.count count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCopyContentWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:extractContentInfoFromRowProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCopyContentWithVersionInfo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:extractVersionInfoFromRowProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSet1\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:getContentExtractFixture\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSet1\(\) has parameter \$mainLanguageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:getLanguageHandler\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Handler&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSet1\(\) has parameter \$spiFields with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:getMapper\(\) has parameter \$valueConverter with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/MapperTest.php + + - + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:getMultipleVersionsNamesExtractFixture\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/lib/Persistence/Legacy/Content/MapperTest.php + + - + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:getNamesExtractFixture\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSet1\(\) has parameter \$structFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:getRelationExtractFixture\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSet2\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testCreateCreateStructFromContent\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSet2\(\) has parameter \$mainLanguageCode with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testCreateCreateStructFromContentBasicProperties\(\) has parameter \$data with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSet2\(\) has parameter \$spiFields with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testCreateCreateStructFromContentFieldCount\(\) has parameter \$data with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSet2\(\) has parameter \$structFields with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testCreateCreateStructFromContentFieldsNoId\(\) has parameter \$data with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSetComplex\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testCreateCreateStructFromContentParentLocationsEmpty\(\) has parameter \$data with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSetComplex\(\) has parameter \$mainLanguageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:testExtractContentInfoFromRow\(\) has parameter \$fixtures with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSetComplex\(\) has parameter \$spiFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Contracts\\Core\\Persistence\\Content\\CreateStruct\:\:\$name \(array\\) does not accept string\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSetComplex\(\) has parameter \$structFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageAwareTestCase\:\:\$languageHandler \(Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentObjectStates\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\MapperTest\:\:\$valueConverterRegistryMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldValue\\ConverterRegistry\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentRequiredField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabaseTest\:\:\$databaseGateway \(Ibexa\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\\DoctrineDatabase\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentRequiredField\(\) has parameter \$identifier with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\MapperTest\:\:getObjectStateGroupRowsFixture\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/ObjectState/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentRequiredField\(\) has parameter \$languageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\MapperTest\:\:getObjectStateGroupRowsFixture\(\) should return array\\> but returns array\\>\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/ObjectState/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentRequiredField\(\) has parameter \$mainLanguageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\MapperTest\:\:getObjectStateRowsFixture\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/ObjectState/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentRequiredField\(\) has parameter \$structFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\MapperTest\:\:getObjectStateRowsFixture\(\) should return array\\> but returns array\\>\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/ObjectState/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentThrowsContentFieldValidationException\(\) has parameter \$mainLanguageCode with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\:\:expects\(\)\.$#' + identifier: method.notFound + count: 32 + path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentThrowsContentFieldValidationException\(\) has parameter \$structFields with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Mapper\:\:expects\(\)\.$#' + identifier: method.notFound + count: 18 + path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentThrowsContentValidationExceptionFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Match expression does not handle remaining values\: int\\|int\<4, max\>$#' + identifier: match.unhandled count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentThrowsContentValidationExceptionFieldDefinition\(\) has parameter \$mainLanguageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:\$gatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Gateway\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentThrowsContentValidationExceptionFieldDefinition\(\) has parameter \$structFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:\$mapperMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Mapper\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentThrowsContentValidationExceptionTranslation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\ObjectState\\ObjectStateHandlerTest\:\:\$objectStateHandler \(Ibexa\\Core\\Persistence\\Legacy\\Content\\ObjectState\\Handler\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentThrowsContentValidationExceptionTranslation\(\) has parameter \$mainLanguageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\Gateway\\DoctrineDatabaseTest\:\:\$databaseGateway \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Section\\Gateway\\DoctrineDatabase\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Section/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentThrowsContentValidationExceptionTranslation\(\) has parameter \$structFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Result of method Ibexa\\Core\\Persistence\\Legacy\\Content\\Section\\Gateway\\DoctrineDatabase\:\:assignSectionToContent\(\) \(void\) is used\.$#' + identifier: method.void count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Section/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentThrowsInvalidArgumentExceptionDuplicateRemoteId\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Section\\Gateway\:\:expects\(\)\.$#' + identifier: method.notFound + count: 12 + path: tests/lib/Persistence/Legacy/Content/Section/SectionHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\SectionHandlerTest\:\:\$gatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Section\\Gateway\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Section/SectionHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentWithInvalidLanguage\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Section\\SectionHandlerTest\:\:\$sectionHandler \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Section\\Handler\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Section/SectionHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentWithInvalidLanguage\(\) has parameter \$mainLanguageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\TreeHandlerTest\:\:getPartlyMockedTreeHandler\(\) has parameter \$methods with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentWithInvalidLanguage\(\) has parameter \$structFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\TreeHandlerTest\:\:\$contentGatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentWithLocations\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\TreeHandlerTest\:\:\$contentMapper \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentWithLocationsDuplicateUnderParent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\TreeHandlerTest\:\:\$fieldHandlerMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldHandler&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\TreeHandlerTest\:\:\$locationGatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testDeleteContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\TreeHandlerTest\:\:\$locationMapperMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Mapper&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testDeleteContentThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\:\:expects\(\)\.$#' + identifier: method.notFound + count: 35 + path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testDeleteContentWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Handler\:\:expects\(\)\.$#' + identifier: method.notFound + count: 2 + path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testDeleteVersionThrowsBadStateExceptionLastVersion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Mapper\:\:expects\(\)\.$#' + identifier: method.notFound + count: 21 + path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testInternalLoadContentById\(\) has parameter \$languages with no value type specified in iterable type array\.$#' + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Update\\Handler\:\:expects\(\)\.$#' + identifier: method.notFound + count: 6 + path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php + + - + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:getMapperMock\(\) has parameter \$methods with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testInternalLoadContentByRemoteId\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:getPartlyMockedHandler\(\) has parameter \$methods with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testInternalLoadContentByRemoteId\(\) has parameter \$languages with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:\$gatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testLoadContent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:\$mapperMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Mapper\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testLoadContentByContentInfo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:\$storageDispatcherMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\StorageDispatcherInterface&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testLoadContentByVersionInfo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentTypeHandlerTest\:\:\$updateHandlerMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Update\\Handler\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testLoadContentNonPublished\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Core\\\\Persistence\\\\Legacy\\\\Content\\\\Type\\\\ContentUpdater\\\\Action\\\\AddField'' and Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddField will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testLoadContentNotPublishedStatusUnauthorized\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:getContentFixture\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testLoadContentUnauthorized\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:getContentGatewayMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testLoadVersionInfo\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:getContentMapperMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testLoadVersionInfoById\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:getContentStorageHandlerMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageHandler&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageHandler\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testLoadVersionInfoByIdAndVersionNumber\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:getFieldValueConverterMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testLoadVersionInfoByIdNonPublishedVersion\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:getMockedAction\(\) has parameter \$methods with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testLoadVersionInfoByIdPublishedVersion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + message: '#^Parameter \#1 \$id of method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:getFieldReference\(\) expects int, null given\.$#' + identifier: argument.type + count: 6 + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testLoadVersionInfoByIdThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + message: '#^Parameter \#1 \$id of method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:getFieldReference\(\) expects int, string given\.$#' + identifier: argument.type + count: 3 + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testLoadVersionInfoByIdThrowsUnauthorizedExceptionNonPublishedVersion\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + message: '#^Property Ibexa\\Contracts\\Core\\Persistence\\Content\\Field\:\:\$id \(int\) does not accept null\.$#' + identifier: assign.propertyType + count: 2 + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet1\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:\$contentGatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet1\(\) has parameter \$initialLanguageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:\$contentMapperMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet1\(\) has parameter \$spiFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:\$contentStorageHandlerMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageHandler\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet1\(\) has parameter \$structFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\AddFieldTest\:\:\$fieldValueConverterMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldValue\\Converter\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet2\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveFieldTest\:\:getContentFixture\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet2\(\) has parameter \$initialLanguageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveFieldTest\:\:getContentGatewayMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet2\(\) has parameter \$spiFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveFieldTest\:\:getContentMapperMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet2\(\) has parameter \$structFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveFieldTest\:\:getContentStorageHandlerMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageHandler&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageHandler\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet3\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveFieldTest\:\:\$contentGatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet3\(\) has parameter \$initialLanguageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveFieldTest\:\:\$contentMapperMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet3\(\) has parameter \$spiFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveFieldTest\:\:\$contentStorageHandlerMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageHandler\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet3\(\) has parameter \$structFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveFieldTest\:\:\$removeFieldAction \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\\Action\\RemoveField\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet4\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldValue\\ConverterRegistry\:\:expects\(\)\.$#' + identifier: method.notFound count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdaterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet4\(\) has parameter \$initialLanguageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\:\:expects\(\)\.$#' + identifier: method.notFound count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdaterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet4\(\) has parameter \$spiFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdaterTest\:\:\$contentGatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Gateway\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdaterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet4\(\) has parameter \$structFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdaterTest\:\:\$contentMapperMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Mapper\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdaterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSetComplex\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdaterTest\:\:\$contentStorageHandlerMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\StorageHandler\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdaterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSetComplex\(\) has parameter \$initialLanguageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdaterTest\:\:\$contentUpdater \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdaterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSetComplex\(\) has parameter \$spiFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdaterTest\:\:\$converterRegistryMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldValue\\ConverterRegistry\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/ContentUpdaterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSetComplex\(\) has parameter \$structFields with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + message: '#^Method Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabase\:\:countInstancesOfType\(\) invoked with 2 parameters, 1 required\.$#' + identifier: arguments.count + count: 2 + path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentRequiredField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:getTypeCreationContentClassNameExpectations\(\) should return array\\> but returns array\\|string\>\>\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentRequiredField\(\) has parameter \$identifier with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:getTypeCreationExpectations\(\) should return array\\> but returns array\\>\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentRequiredField\(\) has parameter \$initialLanguageCode with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testInsertType\(\) has parameter \$column with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentRequiredField\(\) has parameter \$languageCode with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testInsertType\(\) has parameter \$expectation with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentRequiredField\(\) has parameter \$structFields with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testInsertTypeContentClassName\(\) has parameter \$column with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsBadStateException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testInsertTypeContentClassName\(\) has parameter \$expectation with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsBadStateException\(\) has parameter \$status with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testUpdateType\(\) has parameter \$expectedValue with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsContentFieldValidationException\(\) has parameter \$allFieldErrors with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:testUpdateType\(\) has parameter \$fieldName with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsContentFieldValidationException\(\) has parameter \$initialLanguageCode with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + message: '#^Property Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\:\:\$description \(array\\) does not accept array\\.$#' + identifier: assign.propertyType + count: 2 + path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsContentFieldValidationException\(\) has parameter \$spiField with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\FieldDefinition\:\:\$defaultValue \(Ibexa\\Contracts\\Core\\Persistence\\Content\\FieldValue\) does not accept array\\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsContentFieldValidationException\(\) has parameter \$structFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabaseTest\:\:\$gateway \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabase\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsContentValidationExceptionFieldDefinition\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Result of method Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\\DoctrineDatabase\:\:updateGroup\(\) \(void\) is used\.$#' + identifier: method.void count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsContentValidationExceptionFieldDefinition\(\) has parameter \$initialLanguageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Argument of an invalid type Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\CreateStruct supplied for foreach, only iterables are supported\.$#' + identifier: foreach.nonIterable + count: 2 + path: tests/lib/Persistence/Legacy/Content/Type/MapperTest.php + + - + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\MapperTest\:\:getLoadGroupFixture\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsContentValidationExceptionFieldDefinition\(\) has parameter \$structFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\MapperTest\:\:getLoadTypeFixture\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsContentValidationExceptionTranslation\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\MapperTest\:\:getMaskGeneratorMock\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/MapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsContentValidationExceptionTranslation\(\) has parameter \$initialLanguageCode with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\:\:expects\(\)\.$#' + identifier: method.notFound + count: 2 + path: tests/lib/Persistence/Legacy/Content/Type/Update/Handler/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsContentValidationExceptionTranslation\(\) has parameter \$structFields with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + message: '#^Call to an undefined method Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\:\:expects\(\)\.$#' + identifier: method.notFound + count: 2 + path: tests/lib/Persistence/Legacy/Content/Type/Update/Handler/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Update\\Handler\\DoctrineDatabase\:\:deleteOldType\(\) invoked with 2 parameters, 1 required\.$#' + identifier: arguments.count count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/Update/Handler/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentTransactionRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Update\\Handler\\DoctrineDatabaseTest\:\:\$contentUpdaterMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\ContentUpdater\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/Update/Handler/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentWithInvalidLanguage\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\Type\\Update\\Handler\\DoctrineDatabaseTest\:\:\$gatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Gateway\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/Type/Update/Handler/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentWithInvalidLanguage\(\) has parameter \$initialLanguageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:getGateway\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabase but returns Ibexa\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentWithInvalidLanguage\(\) has parameter \$structFields with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:providerForTestArchiveUrlAliasesForDeletedTranslations\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - message: '#^Parameter \#1 \$languageHandlerMock of method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:loadByLanguageCodeMock\(\) expects PHPUnit\\Framework\\MockObject\\MockObject, Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:providerForTestCleanupAfterPublishHistorize\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - message: '#^Parameter \#1 \$singular of class Ibexa\\Core\\FieldType\\ValidationError constructor expects string, int given\.$#' - identifier: argument.type - count: 2 - path: tests/lib/Repository/Service/Mock/ContentTest.php + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:providerForTestCleanupAfterPublishRemovesLanguage\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - message: '#^Property Ibexa\\Contracts\\Core\\Persistence\\Content\\MetadataUpdateStruct\:\:\$publicationDate \(int\) does not accept int\|null\.$#' - identifier: assign.propertyType + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:providerForTestLoadPathData\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:\$contentTypeServiceMock has no type specified\.$#' - identifier: missingType.property + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:providerForTestLoadPathDataMultipleLanguages\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:\$locationServiceMock has no type specified\.$#' - identifier: missingType.property + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testCleanupAfterPublishHistorize\(\) has parameter \$action with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:\$partlyMockedContentService \(Ibexa\\Core\\Repository\\ContentService\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testCleanupAfterPublishHistorize\(\) has parameter \$languageId with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:\$relationProcessorMock has no type specified\.$#' - identifier: missingType.property + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testCleanupAfterPublishHistorize\(\) has parameter \$parentId with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/ContentTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Persistence\\User\\Handler\:\:expects\(\)\.$#' - identifier: method.notFound - count: 11 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testCleanupAfterPublishHistorize\(\) has parameter \$textMD5 with no type specified\.$#' + identifier: missingType.parameter + count: 1 + path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Repository\\PermissionResolver&PHPUnit\\Framework\\MockObject\\MockObject\:\:sudo\(\)\.$#' - identifier: method.notFound + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testCleanupAfterPublishRemovesLanguage\(\) has parameter \$action with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:createRole\(\) has parameter \$policiesData with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testCleanupAfterPublishRemovesLanguage\(\) has parameter \$languageId with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:getPermissionResolverMock\(\) has parameter \$methods with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testCleanupAfterPublishRemovesLanguage\(\) has parameter \$parentId with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:getPermissionSetsMock\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testCleanupAfterPublishRemovesLanguage\(\) has parameter \$textMD5 with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:getUserReferenceMock\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testLoadPathData\(\) has parameter \$id with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:providerForTestCanUserComplex\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testLoadPathData\(\) has parameter \$pathData with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:providerForTestCanUserSimple\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testLoadPathDataMultipleLanguages\(\) has parameter \$id with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:providerForTestHasAccessReturnsFalse\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:testLoadPathDataMultipleLanguages\(\) has parameter \$pathData with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:providerForTestHasAccessReturnsInvalidArgumentValueException\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\\DoctrineDatabaseTest\:\:\$gateway \(Ibexa\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\Gateway\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:providerForTestHasAccessReturnsLimitationNotFoundException\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$methods of method PHPUnit\\Framework\\MockObject\\MockBuilder\\:\:onlyMethods\(\) expects list\, list\ given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/SlugConverterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:providerForTestHasAccessReturnsPermissionSets\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + message: '#^Argument of an invalid type Ibexa\\Contracts\\Core\\Persistence\\Content\\UrlAlias supplied for foreach, only iterables are supported\.$#' + identifier: foreach.nonIterable + count: 4 + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:providerForTestHasAccessReturnsPermissionSetsWithRoleLimitation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Persistence\\\\Content\\\\UrlAlias'' and Ibexa\\Contracts\\Core\\Persistence\\Content\\UrlAlias will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:providerForTestHasAccessReturnsTrue\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:assertVirtualUrlAliasValid\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testCanUserComplex\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:assertVirtualUrlAliasValid\(\) has parameter \$id with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testCanUserComplex\(\) has parameter \$policyLimitationEvaluations with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:getHistoryAlias\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testCanUserComplex\(\) has parameter \$roleLimitationEvaluations with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:getPartlyMockedHandler\(\) has parameter \$methods with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testCanUserComplex\(\) has parameter \$userCan with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:providerForArchiveUrlAliasesForDeletedTranslations\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testCanUserSimple\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:providerForTestPublishUrlAliasForLocationComplex\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testCanUserSimple\(\) has parameter \$permissionSets with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadAutogeneratedUrlAlias\(\) has parameter \$alwaysAvailable with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testCanUserSimple\(\) has parameter \$result with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadAutogeneratedUrlAlias\(\) has parameter \$id with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testCanUserWithoutLimitations\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testGetCurrentUserReferenceReturnsAnonymousUser\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsFalse\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadAutogeneratedUrlAlias\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsFalse\(\) has parameter \$roleAssignments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadAutogeneratedUrlAlias\(\) has parameter \$locationId with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsFalse\(\) has parameter \$roles with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadAutogeneratedUrlAlias\(\) has parameter \$pathData with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsFalseButSudoSoTrue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadAutogeneratedUrlAlias\(\) has parameter \$url with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsInvalidArgumentValueException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadResourceUrlAlias\(\) has parameter \$alwaysAvailable with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsInvalidArgumentValueException\(\) has parameter \$roleAssignments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadResourceUrlAlias\(\) has parameter \$destination with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsInvalidArgumentValueException\(\) has parameter \$roles with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadResourceUrlAlias\(\) has parameter \$forward with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsLimitationNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadResourceUrlAlias\(\) has parameter \$id with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsLimitationNotFoundException\(\) has parameter \$roleAssignments with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadResourceUrlAlias\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsLimitationNotFoundException\(\) has parameter \$roles with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadResourceUrlAlias\(\) has parameter \$pathData with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsPermissionSets\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadResourceUrlAlias\(\) has parameter \$url with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsPermissionSets\(\) has parameter \$roleAssignments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadVirtualUrlAlias\(\) has parameter \$id with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsPermissionSets\(\) has parameter \$roles with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLoadVirtualUrlAlias\(\) has parameter \$url with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsPermissionSetsWithRoleLimitation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAlias\(\) has parameter \$alwaysAvailable with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsPermissionSetsWithRoleLimitation\(\) has parameter \$roleAssignments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAlias\(\) has parameter \$destination with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsPermissionSetsWithRoleLimitation\(\) has parameter \$roles with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAlias\(\) has parameter \$forward with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsTrue\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAlias\(\) has parameter \$id with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsTrue\(\) has parameter \$roleAssignments with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAlias\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsTrue\(\) has parameter \$roles with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAlias\(\) has parameter \$pathData with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testSetAndGetCurrentUserReference\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAlias\(\) has parameter \$url with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^PHPDoc tag @var has invalid value \(\$limitationsPass\)\: Unexpected token "\$limitationsPass", expected type at offset 9 on line 1$#' - identifier: phpDoc.parseError + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAliasCaseCorrection\(\) has parameter \$alwaysAvailable with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^PHPDoc tag @var has invalid value \(\$policy \\Ibexa\\Contracts\\Core\\Persistence\\User\\Policy\)\: Unexpected token "\$policy", expected type at offset 9 on line 1$#' - identifier: phpDoc.parseError + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAliasCaseCorrection\(\) has parameter \$destination with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^PHPDoc tag @var has invalid value \(\$policy \\Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy\)\: Unexpected token "\$policy", expected type at offset 9 on line 1$#' - identifier: phpDoc.parseError + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAliasCaseCorrection\(\) has parameter \$forward with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^PHPDoc tag @var has invalid value \(\$role \\Ibexa\\Contracts\\Core\\Persistence\\User\\Role\)\: Unexpected token "\$role", expected type at offset 9 on line 1$#' - identifier: phpDoc.parseError + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAliasCaseCorrection\(\) has parameter \$id with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^PHPDoc tag @var has invalid value \(\$roleAssignments \\Ibexa\\Contracts\\Core\\Persistence\\User\\RoleAssignment\[\]\)\: Unexpected token "\$roleAssignments", expected type at offset 9 on line 1$#' - identifier: phpDoc.parseError + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAliasCaseCorrection\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php - - - - message: '#^PHPDoc tag @var has invalid value \(\$userHandlerMock \\PHPUnit\\Framework\\MockObject\\MockObject\)\: Unexpected token "\$userHandlerMock", expected type at offset 9 on line 1$#' - identifier: phpDoc.parseError - count: 6 - path: tests/lib/Repository/Service/Mock/PermissionTest.php - - - - message: '#^PHPDoc tag @var has invalid value \(\$valueObject \\Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\)\: Unexpected token "\$valueObject", expected type at offset 9 on line 1$#' - identifier: phpDoc.parseError - count: 3 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:\$permissionResolverMock has no type specified\.$#' - identifier: missingType.property + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAliasCaseCorrection\(\) has parameter \$pathData with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:\$repositoryMock has no type specified\.$#' - identifier: missingType.property + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupCustomLocationUrlAliasCaseCorrection\(\) has parameter \$url with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:\$userReferenceMock has no type specified\.$#' - identifier: missingType.property + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationCaseCorrection\(\) has parameter \$alwaysAvailable with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Variable \$limitationsPass might not be defined\.$#' - identifier: variable.undefined + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationCaseCorrection\(\) has parameter \$id with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/PermissionTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Persistence\\Content\\Location\\Handler\:\:expects\(\)\.$#' - identifier: method.notFound - count: 2 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationCaseCorrection\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:assertLocationHandlerExpectation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationCaseCorrection\(\) has parameter \$locationId with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:assertLocationHandlerExpectation\(\) has parameter \$callCounter with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationCaseCorrection\(\) has parameter \$pathData with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:assertLocationHandlerExpectation\(\) has parameter \$fieldRelations with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationCaseCorrection\(\) has parameter \$url with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:assertLocationHandlerExpectation\(\) has parameter \$locationHandlerMock with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationMultipleLanguages\(\) has parameter \$alwaysAvailable with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:assertLocationHandlerExpectation\(\) has parameter \$type with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationMultipleLanguages\(\) has parameter \$id with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:getStubbedRelation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationMultipleLanguages\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:getStubbedRelation\(\) has parameter \$contentId with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationMultipleLanguages\(\) has parameter \$locationId with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:getStubbedRelation\(\) has parameter \$fieldDefinitionId with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationMultipleLanguages\(\) has parameter \$pathData with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:getStubbedRelation\(\) has parameter \$id with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationMultipleLanguages\(\) has parameter \$url with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:getStubbedRelation\(\) has parameter \$type with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationUrlAlias\(\) has parameter \$alwaysAvailable with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:providerForTestAppendRelations\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationUrlAlias\(\) has parameter \$id with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:testAppendFieldRelations\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationUrlAlias\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:testAppendFieldRelations\(\) has parameter \$expected with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationUrlAlias\(\) has parameter \$locationId with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:testAppendFieldRelations\(\) has parameter \$fieldRelations with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationUrlAlias\(\) has parameter \$pathData with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:testAppendFieldRelationsLocationMappingWorks\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupLocationUrlAlias\(\) has parameter \$url with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:testAppendFieldRelationsLogsMissingLocations\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAlias\(\) has parameter \$alwaysAvailable with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:testProcessFieldRelationsAddsRelations\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAlias\(\) has parameter \$destination with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:testProcessFieldRelationsNoChanges\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAlias\(\) has parameter \$forward with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:testProcessFieldRelationsRemovesRelations\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAlias\(\) has parameter \$id with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:testProcessFieldRelationsWhenRelationFieldNoLongerExists\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAlias\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php - - - - message: '#^Parameter \#5 \$fieldDefinitionId of method Ibexa\\Core\\Repository\\Helper\\RelationProcessor\:\:appendFieldRelations\(\) expects string, int given\.$#' - identifier: argument.type - count: 3 - path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RepositoryTest\:\:testBeginTransaction\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAlias\(\) has parameter \$pathData with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RepositoryTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RepositoryTest\:\:testCommit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAlias\(\) has parameter \$url with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RepositoryTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RepositoryTest\:\:testCommitThrowsRuntimeException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAliasCaseInsensitive\(\) has parameter \$alwaysAvailable with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RepositoryTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RepositoryTest\:\:testRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAliasCaseInsensitive\(\) has parameter \$destination with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RepositoryTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RepositoryTest\:\:testRollbackThrowsRuntimeException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAliasCaseInsensitive\(\) has parameter \$forward with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RepositoryTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Repository\\Values\\User\\RoleCreateStruct\:\:expects\(\)\.$#' - identifier: method.notFound + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAliasCaseInsensitive\(\) has parameter \$id with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:getPartlyMockedRoleService\(\) has parameter \$settings with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAliasCaseInsensitive\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:getPartlyMockedRoleService\(\) should return Ibexa\\Core\\Repository\\RoleService&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Repository\\RoleService\.$#' - identifier: return.type - count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:testAddPolicyThrowsLimitationValidationException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAliasCaseInsensitive\(\) has parameter \$pathData with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:testAssignRoleGroupToUserThrowsBadStateException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupResourceUrlAliasCaseInsensitive\(\) has parameter \$url with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:testAssignRoleToUser\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupVirtualUrlAlias\(\) has parameter \$id with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:testAssignRoleToUserGroup\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testLookupVirtualUrlAlias\(\) has parameter \$url with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:testAssignRoleToUserGroupThrowsLimitationValidationException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationComplex\(\) has parameter \$alwaysAvailable with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:testAssignRoleToUserGroupThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationComplex\(\) has parameter \$id with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:testAssignRoleToUserGroupWithNullLimitation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationComplex\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:testAssignRoleToUserGroupWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationComplex\(\) has parameter \$locationId with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:testAssignRoleToUserThrowsBadStateException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationComplex\(\) has parameter \$pathData with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:testAssignRoleToUserThrowsLimitationValidationException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationComplex\(\) has parameter \$url with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:testAssignRoleToUserThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationSkipsReservedWord\(\) has parameter \$alias with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:testAssignRoleToUserWithNullLimitation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:testPublishUrlAliasForLocationSkipsReservedWord\(\) has parameter \$text with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:testAssignRoleToUserWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:\$languageHandler \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\Handler\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:testCreateRoleThrowsLimitationValidationException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:\$languageMaskGenerator \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\MaskGenerator\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:testRemovePolicyByRoleDraft\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasHandlerTest\:\:\$locationGateway \(Ibexa\\Core\\Persistence\\Legacy\\Content\\Location\\Gateway\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:testRemovePolicyByRoleDraftThrowsUnauthorizedException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasMapperTest\:\:getExpectation\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasMapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:testRemovePolicyByRoleDraftWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasMapperTest\:\:testExtractUrlAliasFromData\(\) has parameter \$index with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasMapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:testUpdatePolicyThrowsLimitationValidationException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlAlias\\UrlAliasMapperTest\:\:\$fixture has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasMapperTest.php - - message: '#^PHPDoc tag @var with type Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Role is not subtype of native type PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: varTag.nativeType - count: 6 - path: tests/lib/Repository/Service/Mock/RoleTest.php + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\Gateway\\DoctrineDatabaseTest\:\:\$fixtureData has no type specified\.$#' + identifier: missingType.property + count: 1 + path: tests/lib/Persistence/Legacy/Content/UrlWildcard/Gateway/DoctrineDatabaseTest.php - - message: '#^PHPDoc tag @var with type Ibexa\\Contracts\\Core\\Repository\\Values\\User\\RoleCreateStruct is not subtype of native type PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: varTag.nativeType + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\Gateway\\DoctrineDatabaseTest\:\:\$gateway \(Ibexa\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\Gateway\\DoctrineDatabase\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/Content/UrlWildcard/Gateway/DoctrineDatabaseTest.php - - message: '#^PHPDoc tag @var with type Ibexa\\Contracts\\Core\\Repository\\Values\\User\\User is not subtype of native type PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: varTag.nativeType - count: 3 - path: tests/lib/Repository/Service/Mock/RoleTest.php + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\UrlWildcardHandlerTest\:\:\$fixtureData has no type specified\.$#' + identifier: missingType.property + count: 1 + path: tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardHandlerTest.php - - message: '#^PHPDoc tag @var with type Ibexa\\Contracts\\Core\\Repository\\Values\\User\\UserGroup is not subtype of native type PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: varTag.nativeType - count: 3 - path: tests/lib/Repository/Service/Mock/RoleTest.php + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\UrlWildcard\\UrlWildcardHandlerTest\:\:\$urlWildcardHandler \(Ibexa\\Contracts\\Core\\Persistence\\Content\\UrlWildcard\\Handler\) in isset\(\) is not nullable\.$#' + identifier: isset.property + count: 1 + path: tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardHandlerTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:\$partlyMockedRoleService \(Ibexa\\Core\\Repository\\RoleService\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\FieldValue\\Converter\\ImageConverterTest\:\:fieldValueToXmlProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/RoleTest.php + path: tests/lib/Persistence/Legacy/FieldValue/Converter/ImageConverterTest.php - - message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Search\\Handler\:\:expects\(\)\.$#' - identifier: method.notFound - count: 7 - path: tests/lib/Repository/Service/Mock/SearchTest.php + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\FieldValue\\Converter\\ImageConverterTest\:\:xmlToFieldValueProvider\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/lib/Persistence/Legacy/FieldValue/Converter/ImageConverterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:providerForFindContentValidatesLocationCriteriaAndSortClauses\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Filter\\BaseCriterionVisitorQueryBuilderTestCase\:\:getBaseCriterionQueryBuilders\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/Filter/BaseCriterionVisitorQueryBuilderTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:providerForFindSingleValidatesLocationCriteria\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Filter\\BaseCriterionVisitorQueryBuilderTestCase\:\:getFilteringCriteriaQueryData\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/Filter/BaseCriterionVisitorQueryBuilderTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testConstructor\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Filter\\BaseCriterionVisitorQueryBuilderTestCase\:\:testVisitCriteriaProducesQuery\(\) has parameter \$expectedParameterValues with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/Filter/BaseCriterionVisitorQueryBuilderTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindContentNoPermissionsFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \.\.\.\$arrays of function array_merge expects array, iterable given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/Filter/BaseCriterionVisitorQueryBuilderTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindContentThrowsHandlerException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#2 \.\.\.\$arrays of function array_merge expects array, iterable\ given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/Filter/BaseCriterionVisitorQueryBuilderTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindContentValidatesLocationCriteriaAndSortClauses\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Filter\\CriterionQueryBuilder\\Content\\LanguageCodeQueryBuilderQueryBuilderTest\:\:getFilteringCriteriaQueryData\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Content/LanguageCodeQueryBuilderQueryBuilderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindContentValidatesLocationCriteriaAndSortClauses\(\) has parameter \$exceptionMessage with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Filter\\CriterionQueryBuilder\\Content\\Type\\ContentTypeGroupIdQueryBuilderTest\:\:getFilteringCriteriaQueryData\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Content/Type/ContentTypeGroupIdQueryBuilderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindContentValidatesLocationCriteriaAndSortClauses\(\) has parameter \$query with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Filter\\CriterionQueryBuilder\\Content\\Type\\ContentTypeQueryBuildersTest\:\:getFilteringCriteriaQueryData\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Content/Type/ContentTypeQueryBuildersTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindContentWhenDomainMapperThrowsException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Filter\\CriterionQueryBuilder\\Location\\AncestorQueryBuilderTest\:\:getFilteringCriteriaQueryData\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/AncestorQueryBuilderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindContentWithDefaultQueryValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Filter\\CriterionQueryBuilder\\Location\\LocationIdQueryBuilderTest\:\:getFilteringCriteriaQueryData\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/LocationIdQueryBuilderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindContentWithNoPermission\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Filter\\CriterionQueryBuilder\\Location\\ParentLocationQueryBuilderTest\:\:getFilteringCriteriaQueryData\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/ParentLocationQueryBuilderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindContentWithPermission\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Filter\\CriterionQueryBuilder\\LogicalOperatorQueryBuilderQueryBuilderTest\:\:getFilteringCriteriaQueryData\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/LogicalOperatorQueryBuilderQueryBuilderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindLocationsBackgroundIndexerWhenDomainMapperThrowsException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Container\:\:get\(\)\.$#' + identifier: method.notFound count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/HandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindLocationsThrowsHandlerException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Setting\\SettingHandlerTest\:\:getGatewayMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Setting\\Gateway&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Persistence\\Legacy\\Setting\\Gateway\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/Setting/SettingHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindLocationsWithDefaultQueryValues\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Setting\\SettingHandlerTest\:\:\$gatewayMock \(Ibexa\\Core\\Persistence\\Legacy\\Setting\\Gateway\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/Setting/SettingHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindLocationsWithNoPermissionsFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\Setting\\SettingHandlerTest\:\:\$settingHandler \(Ibexa\\Core\\Persistence\\Legacy\\Setting\\Handler\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/Setting/SettingHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindLocationsWithPermission\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Generator expects value type Doctrine\\DBAL\\Connection\|PHPUnit\\Framework\\MockObject\\MockObject, array\ given\.$#' + identifier: generator.valueType count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/SharedGateway/GatewayFactoryTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindSingleThrowsHandlerException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$expected of static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) expects class\-string\, string given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/SharedGateway/GatewayFactoryTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindSingleThrowsNotFoundException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TestCase\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/TestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindSingleValidatesLocationCriteria\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TestCase\:\:assertPropertiesCorrect\(\) has parameter \$properties with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/TestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindSingleValidatesLocationCriteria\(\) has parameter \$criterion with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TestCase\:\:assertQueryResult\(\) has parameter \$expectation with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/TestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindSingleValidatesLocationCriteria\(\) has parameter \$exceptionMessage with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TestCase\:\:assertStructsEqual\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/TestCase.php - - message: '#^PHPDoc tag @var with type Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\Criterion is not subtype of native type PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: varTag.nativeType - count: 5 - path: tests/lib/Repository/Service/Mock/SearchTest.php + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TestCase\:\:assertStructsEqual\(\) has parameter \$propertyNames with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/lib/Persistence/Legacy/TestCase.php - - message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Search\\SearchResult\\:\:\$searchHits \(list\\>\) does not accept array\, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Search\\SearchHit\\>\.$#' - identifier: assign.propertyType - count: 2 - path: tests/lib/Repository/Service/Mock/SearchTest.php + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TestCase\:\:getPublicPropertyNames\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/lib/Persistence/Legacy/TestCase.php - - message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Search\\SearchResult\\:\:\$totalCount \(int\<0, max\>\|null\) does not accept int\<\-1, max\>\.$#' - identifier: assign.propertyType - count: 2 - path: tests/lib/Repository/Service/Mock/SearchTest.php + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TestCase\:\:getResultTextRepresentation\(\) has parameter \$result with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/lib/Persistence/Legacy/TestCase.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:\$contentDomainMapperMock has no type specified\.$#' - identifier: missingType.property + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\TestCase\:\:\$db \(string\) does not accept string\|null\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/TestCase.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:\$permissionsCriterionResolverMock has no type specified\.$#' - identifier: missingType.property + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\TestCase\:\:\$dsn \(string\) does not accept string\|false\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/TestCase.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:\$repositoryMock has no type specified\.$#' - identifier: missingType.property + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TransactionHandlerTest\:\:getContentTypeHandlerMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\MemoryCachingHandler&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/SearchTest.php + path: tests/lib/Persistence/Legacy/TransactionHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:getPartlyMockedURLAliasServiceService\(\) has parameter \$prioritizedLanguages with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\TransactionHandlerTest\:\:getLanguageHandlerMock\(\) should return Ibexa\\Core\\Persistence\\Legacy\\Content\\Language\\CachingHandler&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/TransactionHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:getSpiUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\TransactionHandlerTest\:\:\$connectionMock \(Doctrine\\DBAL\\Connection&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/TransactionHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:providerForTestListAutogeneratedLocationAliasesAlwaysAvailablePath\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\TransactionHandlerTest\:\:\$contentTypeHandlerMock \(Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/TransactionHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:providerForTestListAutogeneratedLocationAliasesEmpty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\TransactionHandlerTest\:\:\$languageHandlerMock \(Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/TransactionHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:providerForTestListAutogeneratedLocationAliasesMultipleLanguagesEmpty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\TransactionHandlerTest\:\:\$transactionHandler \(Ibexa\\Core\\Persistence\\Legacy\\TransactionHandler\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/TransactionHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:providerForTestListAutogeneratedLocationAliasesMultipleLanguagesPath\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$url of method Ibexa\\Core\\Persistence\\Legacy\\URL\\Gateway\\DoctrineDatabase\:\:loadUrlDataByUrl\(\) expects int, string given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/URL/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:providerForTestListAutogeneratedLocationAliasesPath\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Gateway\\DoctrineDatabaseTest\:\:\$fixtureData type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/URL/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:providerForTestListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmpty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Gateway\\DoctrineDatabaseTest\:\:\$gateway \(Ibexa\\Core\\Persistence\\Legacy\\URL\\Gateway\\DoctrineDatabase\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/URL/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:providerForTestListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePath\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\HandlerTest\:\:getUrl\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/URL/HandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:providerForTestListAutogeneratedLocationAliasesWithLanguageCodeEmpty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\HandlerTest\:\:getUrl\(\) has parameter \$id with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/URL/HandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:providerForTestListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmpty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\HandlerTest\:\:getUrl\(\) has parameter \$urlAddr with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/URL/HandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:providerForTestListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPath\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Contracts\\Core\\Persistence\\URL\\URL\:\:\$url \(string\) does not accept Ibexa\\Contracts\\Core\\Persistence\\URL\\URL\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/URL/HandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:providerForTestListAutogeneratedLocationAliasesWithLanguageCodePath\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\\CriterionHandlerTestCase\:\:assertHandlerAcceptsCriterion\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/CriterionHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:providerForTestLookup\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\\CriterionHandlerTestCase\:\:assertHandlerRejectsCriterion\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/CriterionHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:providerForTestLookupThrowsNotFoundExceptionPath\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + message: '#^Parameter \#1 \$criterion of method Ibexa\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\:\:accept\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\Query\\Criterion, PHPUnit\\Framework\\MockObject\\Stub given\.$#' + identifier: argument.type + count: 2 + path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/CriterionHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:providerForTestLookupWithSharedTranslation\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + message: '#^Parameter \#1 \$originalClassName of static method PHPUnit\\Framework\\TestCase\:\:createStub\(\) expects class\-string\, string given\.$#' + identifier: argument.type + count: 2 + path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/CriterionHandlerTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:providerForTestReverseLookup\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Unable to resolve the template type T in call to static method PHPUnit\\Framework\\TestCase\:\:createStub\(\)$#' + identifier: argument.templateType + count: 2 + path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/CriterionHandlerTestCase.php + + - + message: '#^Parameter \#2 \$queryBuilder of method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\\CriterionHandlerTestCase\:\:mockConverterForLogicalOperator\(\) expects Doctrine\\DBAL\\Query\\QueryBuilder&PHPUnit\\Framework\\MockObject\\MockObject, Doctrine\\DBAL\\Query\\QueryBuilder&PHPUnit\\Framework\\MockObject\\Stub given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/LogicalAndTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:providerForTestReverseLookupAlwaysAvailablePath\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#2 \$queryBuilder of method Ibexa\\Tests\\Core\\Persistence\\Legacy\\URL\\Query\\CriterionHandler\\CriterionHandlerTestCase\:\:mockConverterForLogicalOperator\(\) expects Doctrine\\DBAL\\Query\\QueryBuilder&PHPUnit\\Framework\\MockObject\\MockObject, Doctrine\\DBAL\\Query\\QueryBuilder&PHPUnit\\Framework\\MockObject\\Stub given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/LogicalOrTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:setConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\Gateway\\DoctrineDatabaseTest\:\:\$databaseGateway \(Ibexa\\Core\\Persistence\\Legacy\\User\\Gateway\\DoctrineDatabase\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/User/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:setConfiguration\(\) has parameter \$configuration with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Property Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\Role\\Gateway\\DoctrineDatabaseTest\:\:\$databaseGateway \(Ibexa\\Core\\Persistence\\Legacy\\User\\Role\\Gateway\\DoctrineDatabase\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/User/Role/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testConstructor\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\Role\\LimitationConverterTest\:\:getLimitationConverter\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/User/Role/LimitationConverterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testCreateGlobalUrlAlias\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:createRole\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testCreateGlobalUrlAliasForLocation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:getDummyUser\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testCreateGlobalUrlAliasThrowsInvalidArgumentExceptionPath\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:getGatewayReturnValue\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testCreateGlobalUrlAliasThrowsInvalidArgumentExceptionResource\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:getValidUser\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testCreateGlobalUrlAliasThrowsUnauthorizedException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:getValidUserToken\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testCreateGlobalUrlAliasWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:getValidUserToken\(\) has parameter \$time with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testCreateUrlAlias\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$handler of method Ibexa\\Tests\\Core\\Persistence\\Legacy\\User\\UserHandlerTest\:\:createTestRole\(\) expects Ibexa\\Core\\Persistence\\Legacy\\User\\Handler, Ibexa\\Contracts\\Core\\Persistence\\User\\Handler given\.$#' + identifier: argument.type + count: 5 + path: tests/lib/Persistence/Legacy/User/UserHandlerTest.php + + - + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\UserPreference\\Gateway\\DoctrineDatabaseTest\:\:loadUserPreference\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/UserPreference/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testCreateUrlAliasThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Legacy\\UserPreference\\Gateway\\DoctrineDatabaseTest\:\:loadUserPreference\(\) should return array but returns array\\|false\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Legacy/UserPreference/Gateway/DoctrineDatabaseTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testCreateUrlAliasThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Limitation\\\\Target\\\\Builder\\\\VersionBuilder'' and Ibexa\\Contracts\\Core\\Limitation\\Target\\Builder\\VersionBuilder will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Limitation/Target/Builder/VersionBuilderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testCreateUrlAliasWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\Limitation\\Target\\Builder\\VersionBuilderTest\:\:providerForTestBuild\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/Limitation/Target/Builder/VersionBuilderTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesAlwaysAvailablePath\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorDefinitionBasedTest\:\:getProcessor\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorDefinitionBasedTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesAlwaysAvailablePath\(\) has parameter \$paths with no type specified\.$#' - identifier: missingType.parameter + message: '#^Class Ibexa\\Core\\Persistence\\TransformationProcessor\\DefinitionBased\\Parser constructor invoked with 1 parameter, 0 required\.$#' + identifier: arguments.count + count: 10 + path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php + + - + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorPcreCompilerTest\:\:applyTransformations\(\) has parameter \$transformations with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesAlwaysAvailablePath\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorPcreCompilerTest\:\:applyTransformations\(\) should return string but returns string\|null\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesAlwaysAvailablePath\(\) has parameter \$spiUrlAliases with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#3 \$subject of function preg_replace_callback expects array\\|string, string\|null given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesAlwaysAvailablePathCustomConfiguration\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Persistence\\TransformationProcessor\\TransformationProcessorPreprocessedBasedTest\:\:getProcessor\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Persistence/TransformationProcessor/TransformationProcessorPreprocessedBasedTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesAlwaysAvailablePathCustomConfiguration\(\) has parameter \$paths with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\AbstractQueryTypeTestCase\:\:dataProviderForGetQuery\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/QueryType/BuiltIn/AbstractQueryTypeTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesAlwaysAvailablePathCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\AbstractQueryTypeTestCase\:\:getExpectedSupportedParameters\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/QueryType/BuiltIn/AbstractQueryTypeTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesAlwaysAvailablePathCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\AbstractQueryTypeTestCase\:\:testGetQuery\(\) has parameter \$parameters with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/QueryType/BuiltIn/AbstractQueryTypeTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesEmpty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\AncestorsQueryTypeTest\:\:dataProviderForGetQuery\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/QueryType/BuiltIn/AncestorsQueryTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesEmpty\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\AncestorsQueryTypeTest\:\:getExpectedSupportedParameters\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/QueryType/BuiltIn/AncestorsQueryTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesEmpty\(\) has parameter \$spiUrlAliases with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\ChildrenQueryTypeTest\:\:dataProviderForGetQuery\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/QueryType/BuiltIn/ChildrenQueryTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesEmptyCustomConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\ChildrenQueryTypeTest\:\:getExpectedSupportedParameters\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/QueryType/BuiltIn/ChildrenQueryTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesEmptyCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\GeoLocationQueryTypeTest\:\:dataProviderForGetQuery\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/QueryType/BuiltIn/GeoLocationQueryTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesEmptyCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\GeoLocationQueryTypeTest\:\:getExpectedSupportedParameters\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/QueryType/BuiltIn/GeoLocationQueryTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesEmpty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\RelatedToContentQueryTypeTest\:\:dataProviderForGetQuery\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/QueryType/BuiltIn/RelatedToContentQueryTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesEmpty\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\RelatedToContentQueryTypeTest\:\:getExpectedSupportedParameters\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/QueryType/BuiltIn/RelatedToContentQueryTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesEmpty\(\) has parameter \$spiUrlAliases with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\SiblingsQueryTypeTest\:\:dataProviderForGetQuery\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/QueryType/BuiltIn/SiblingsQueryTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesEmptyCustomConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\SiblingsQueryTypeTest\:\:getExpectedSupportedParameters\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/QueryType/BuiltIn/SiblingsQueryTypeTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesEmptyCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\SortSpec\\SortSpecLexerStub\:\:__construct\(\) has parameter \$tokens with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/QueryType/BuiltIn/SortSpec/SortSpecLexerStub.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesEmptyCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\SortSpec\\SortSpecLexerTest\:\:dataProviderForTokenize\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/QueryType/BuiltIn/SortSpec/SortSpecLexerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesPath\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\SortSpec\\SortSpecLexerTest\:\:testTokenize\(\) has parameter \$expectedTokens with no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/QueryType/BuiltIn/SortSpec/SortSpecLexerTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesPath\(\) has parameter \$paths with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\SortSpec\\SortSpecParserTest\:\:dataProviderForParseSortDirection\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/QueryType/BuiltIn/SortSpec/SortSpecParserTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesPath\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\SortSpec\\SortSpecParserTest\:\:testParseSortDirection\(\) has parameter \$input with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/QueryType/BuiltIn/SortSpec/SortSpecParserTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesPath\(\) has parameter \$spiUrlAliases with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\SubtreeQueryTest\:\:dataProviderForGetQuery\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/QueryType/BuiltIn/SubtreeQueryTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesPathCustomConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\QueryType\\BuiltIn\\SubtreeQueryTest\:\:getExpectedSupportedParameters\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/QueryType/BuiltIn/SubtreeQueryTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesPathCustomConfiguration\(\) has parameter \$paths with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Contracts\\Core\\Repository\\Strategy\\ContentThumbnail\\Field\\FieldTypeBasedThumbnailStrategy@anonymous/tests/lib/Repository/ContentThumbnail/ContentFieldStrategyTest\.php\:24\:\:getThumbnail\(\) never returns null so it can be removed from the return type\.$#' + identifier: return.unusedType count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/ContentThumbnail/ContentFieldStrategyTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesPathCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Contracts\\Core\\Repository\\Validator\\ContentValidator@anonymous/tests/lib/Repository/ContentValidator/ContentValidatorStrategyTest\.php\:88\:\:__construct\(\) has parameter \$validationReturn with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/ContentValidator/ContentValidatorStrategyTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesPathCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Contracts\\Core\\Repository\\Validator\\ContentValidator@anonymous/tests/lib/Repository/ContentValidator/ContentValidatorStrategyTest\.php\:88\:\:validate\(\) has parameter \$context with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/ContentValidator/ContentValidatorStrategyTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesPath\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\ContentValidator\\ContentValidatorStrategyTest\:\:buildContentValidator\(\) has parameter \$validationReturn with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/ContentValidator/ContentValidatorStrategyTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesPath\(\) has parameter \$paths with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Validator\\ContentValidator@anonymous/tests/lib/Repository/ContentValidator/ContentValidatorStrategyTest\.php\:88\:\:\$validationReturn type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/ContentValidator/ContentValidatorStrategyTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesPath\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\BookmarkServiceDecorator@anonymous/tests/lib/Repository/Decorator/BookmarkServiceDecoratorTest\.php\:21 constructor expects Ibexa\\Contracts\\Core\\Repository\\BookmarkService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/BookmarkServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesPath\(\) has parameter \$spiUrlAliases with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#2 \$locationCreateStructs of method Ibexa\\Contracts\\Core\\Repository\\ContentService\:\:createContent\(\) expects array\, array\ given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesPathCustomConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$contentTypeIds of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:loadContentTypeList\(\) expects array\, array\ given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesPathCustomConfiguration\(\) has parameter \$paths with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\ContentTypeServiceDecorator@anonymous/tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest\.php\:31 constructor expects Ibexa\\Contracts\\Core\\Repository\\ContentTypeService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesPathCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#2 \$contentTypeGroups of method Ibexa\\Contracts\\Core\\Repository\\ContentTypeService\:\:createContentType\(\) expects array\, array\ given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesPathCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\FieldTypeServiceDecorator@anonymous/tests/lib/Repository/Decorator/FieldTypeServiceDecoratorTest\.php\:20 constructor expects Ibexa\\Contracts\\Core\\Repository\\FieldTypeService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/FieldTypeServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmpty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\LanguageServiceDecorator@anonymous/tests/lib/Repository/Decorator/LanguageServiceDecoratorTest\.php\:22 constructor expects Ibexa\\Contracts\\Core\\Repository\\LanguageService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/LanguageServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmpty\(\) has parameter \$languageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$languageIds of method Ibexa\\Contracts\\Core\\Repository\\LanguageService\:\:loadLanguageListById\(\) expects array\, array\ given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/LanguageServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmpty\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\LocationServiceDecorator@anonymous/tests/lib/Repository/Decorator/LocationServiceDecoratorTest\.php\:29 constructor expects Ibexa\\Contracts\\Core\\Repository\\LocationService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmpty\(\) has parameter \$spiUrlAliases with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\NotificationServiceDecorator@anonymous/tests/lib/Repository/Decorator/NotificationServiceDecoratorTest\.php\:24 constructor expects Ibexa\\Contracts\\Core\\Repository\\NotificationService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/NotificationServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmptyCustomConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\ObjectStateServiceDecorator@anonymous/tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest\.php\:27 constructor expects Ibexa\\Contracts\\Core\\Repository\\ObjectStateService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmptyCustomConfiguration\(\) has parameter \$languageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\RoleServiceDecorator@anonymous/tests/lib/Repository/Decorator/RoleServiceDecoratorTest\.php\:34 constructor expects Ibexa\\Contracts\\Core\\Repository\\RoleService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmptyCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Decorator\\SearchServiceDecoratorTest\:\:getSearchEngineCapabilities\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/SearchServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmptyCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\SearchServiceDecorator@anonymous/tests/lib/Repository/Decorator/SearchServiceDecoratorTest\.php\:24 constructor expects Ibexa\\Contracts\\Core\\Repository\\SearchService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/SearchServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePath\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\SectionServiceDecorator@anonymous/tests/lib/Repository/Decorator/SectionServiceDecoratorTest\.php\:27 constructor expects Ibexa\\Contracts\\Core\\Repository\\SectionService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/SectionServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePath\(\) has parameter \$languageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\SettingServiceDecorator@anonymous/tests/lib/Repository/Decorator/SettingServiceDecoratorTest\.php\:26 constructor expects Ibexa\\Contracts\\Core\\Repository\\SettingService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/SettingServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePath\(\) has parameter \$paths with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\TranslationServiceDecorator@anonymous/tests/lib/Repository/Decorator/TranslationServiceDecoratorTest\.php\:21 constructor expects Ibexa\\Contracts\\Core\\Repository\\TranslationService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/TranslationServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePath\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\TrashServiceDecorator@anonymous/tests/lib/Repository/Decorator/TrashServiceDecoratorTest\.php\:23 constructor expects Ibexa\\Contracts\\Core\\Repository\\TrashService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/TrashServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePath\(\) has parameter \$spiUrlAliases with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$aliasList of method Ibexa\\Contracts\\Core\\Repository\\URLAliasService\:\:removeAliases\(\) expects array\, array\ given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/URLAliasServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePathCustomConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\URLAliasServiceDecorator@anonymous/tests/lib/Repository/Decorator/URLAliasServiceDecoratorTest\.php\:24 constructor expects Ibexa\\Contracts\\Core\\Repository\\URLAliasService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/URLAliasServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePathCustomConfiguration\(\) has parameter \$languageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\URLServiceDecorator@anonymous/tests/lib/Repository/Decorator/URLServiceDecoratorTest\.php\:23 constructor expects Ibexa\\Contracts\\Core\\Repository\\URLService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/URLServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePathCustomConfiguration\(\) has parameter \$paths with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\URLWildcardServiceDecorator@anonymous/tests/lib/Repository/Decorator/URLWildcardServiceDecoratorTest\.php\:21 constructor expects Ibexa\\Contracts\\Core\\Repository\\URLWildcardService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/URLWildcardServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePathCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\UserPreferenceServiceDecorator@anonymous/tests/lib/Repository/Decorator/UserPreferenceServiceDecoratorTest\.php\:20 constructor expects Ibexa\\Contracts\\Core\\Repository\\UserPreferenceService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/UserPreferenceServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePathCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$userPreferenceSetStructs of method Ibexa\\Contracts\\Core\\Repository\\UserPreferenceService\:\:setUserPreference\(\) expects array\, array\ given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/UserPreferenceServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeEmpty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$innerService of class Ibexa\\Contracts\\Core\\Repository\\Decorator\\UserServiceDecorator@anonymous/tests/lib/Repository/Decorator/UserServiceDecoratorTest\.php\:37 constructor expects Ibexa\\Contracts\\Core\\Repository\\UserService, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Decorator/UserServiceDecoratorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeEmpty\(\) has parameter \$languageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Filtering\\TestContentProvider\:\:createContentDraft\(\) has parameter \$multilingualFields with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Filtering/TestContentProvider.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeEmpty\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#2 \$mainLanguageCode of method Ibexa\\Contracts\\Core\\Repository\\ContentService\:\:newContentCreateStruct\(\) expects string, int\|string given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Filtering/TestContentProvider.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeEmpty\(\) has parameter \$spiUrlAliases with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#2 \$parentLocationId of method Ibexa\\Tests\\Core\\Repository\\Filtering\\TestContentProvider\:\:createArticle\(\) expects int, int\|null given\.$#' + identifier: argument.type + count: 3 + path: tests/lib/Repository/Filtering/TestContentProvider.php + + - + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\FieldType\\\\FieldType'' and Ibexa\\Contracts\\Core\\FieldType\\FieldType will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Helper/FieldTypeRegistryTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeEmptyCustomConfiguration\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Helper\\FieldTypeRegistryTest\:\:getFieldTypeMock\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Helper/FieldTypeRegistryTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeEmptyCustomConfiguration\(\) has parameter \$languageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$fieldTypes of class Ibexa\\Core\\FieldType\\FieldTypeRegistry constructor expects array\, array\ given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Helper/FieldTypeRegistryTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeEmptyCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Iterator\\BatchIteratorTestAdapter\:\:__construct\(\) has parameter \$data with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Iterator/BatchIteratorTestAdapter.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeEmptyCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Iterator\\BatchIteratorTestAdapter\:\:\$data type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Iterator/BatchIteratorTestAdapter.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmpty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:method\(\)\.$#' + identifier: method.notFound + count: 7 + path: tests/lib/Repository/LocationResolver/PermissionAwareLocationResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmpty\(\) has parameter \$languageCode with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Repository\\LocationService\:\:method\(\)\.$#' + identifier: method.notFound + count: 5 + path: tests/lib/Repository/Mapper/ContentLocationMapper/DecoratedLocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmpty\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + message: '#^Call to an undefined method Ibexa\\Core\\Repository\\Mapper\\ContentLocationMapper\\ContentLocationMapper\:\:expects\(\)\.$#' + identifier: method.notFound + count: 5 + path: tests/lib/Repository/Mapper/ContentLocationMapper/DecoratedLocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmpty\(\) has parameter \$spiUrlAliases with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + message: '#^Cannot access property \$locations on iterable\\.$#' + identifier: property.nonObject + count: 2 + path: tests/lib/Repository/Mapper/ContentLocationMapper/DecoratedLocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmptyCustomConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\PHPUnitConstraint\\ContentItemEquals\:\:compareArrays\(\) has parameter \$actual with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/PHPUnitConstraint/ContentItemEquals.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmptyCustomConfiguration\(\) has parameter \$languageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Repository\\PHPUnitConstraint\\ContentItemEquals\:\:compareArrays\(\) has parameter \$expected with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/PHPUnitConstraint/ContentItemEquals.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmptyCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\PHPUnitConstraint\\ContentItemEquals\:\:evaluate\(\) has parameter \$content with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/PHPUnitConstraint/ContentItemEquals.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmptyCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\PHPUnitConstraint\\ContentItemEquals\:\:failureDescription\(\) has parameter \$content with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/PHPUnitConstraint/ContentItemEquals.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPath\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Class Ibexa\\Tests\\Core\\Repository\\Parallel\\ParallelProcessList implements generic interface IteratorAggregate but does not specify its types\: TKey, TValue$#' + identifier: missingType.generics count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Parallel/ParallelProcessList.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPath\(\) has parameter \$languageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:getPermissionCriterionResolverMock\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPath\(\) has parameter \$paths with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:getPermissionCriterionResolverMock\(\) has parameter \$methods with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPath\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:getPermissionResolverMock\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPath\(\) has parameter \$spiUrlAliases with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:getPermissionResolverMock\(\) has parameter \$methods with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPathCustomConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:testPermissionResolverPassTrough\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPathCustomConfiguration\(\) has parameter \$languageCode with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:testPermissionResolverPassTrough\(\) has parameter \$expectedReturn with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPathCustomConfiguration\(\) has parameter \$paths with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:testPermissionResolverPassTrough\(\) has parameter \$method with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPathCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:\$permissionCriterionResolverMock has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPathCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Permission\\CachedPermissionServiceTest\:\:\$permissionResolverMock has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/CachedPermissionServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodePath\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:getLimitationServiceMock\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodePath\(\) has parameter \$languageCode with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodePath\(\) has parameter \$paths with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:getLimitationServiceMock\(\) has parameter \$methods with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodePath\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:getPermissionResolverMock\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodePath\(\) has parameter \$spiUrlAliases with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:getPermissionResolverMock\(\) has parameter \$methods with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodePathCustomConfiguration\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:mockServices\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodePathCustomConfiguration\(\) has parameter \$languageCode with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:mockServices\(\) has parameter \$criterionMock with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodePathCustomConfiguration\(\) has parameter \$paths with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:mockServices\(\) has parameter \$limitationCount with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodePathCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:mockServices\(\) has parameter \$permissionSets with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodePathCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:testGetPermissionsCriterion\(\) has parameter \$criterionMock with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListGlobalAliases\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:testGetPermissionsCriterion\(\) has parameter \$expectedCriterion with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListGlobalAliasesEmpty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:testGetPermissionsCriterion\(\) has parameter \$limitationCount with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListGlobalAliasesWithParameters\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:testGetPermissionsCriterion\(\) has parameter \$permissionSets with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListLocationAliasesWithShowAllTranslations\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:testGetPermissionsCriterionBooleanPermissionSets\(\) has parameter \$permissionSets with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListLocationAliasesWithShowAllTranslationsCustomConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$methods of method PHPUnit\\Framework\\MockObject\\MockBuilder\\:\:onlyMethods\(\) expects list\, non\-empty\-list\ given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLoad\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:\$limitationServiceMock has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLoadThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Permission\\PermissionCriterionResolverTest\:\:\$permissionResolverMock has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Permission/PermissionCriterionResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLoadThrowsNotFoundExceptionPath\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:getEventDispatcher\(\) should return PHPUnit\\Framework\\MockObject\\MockObject&Symfony\\Contracts\\EventDispatcher\\EventDispatcherInterface but returns Symfony\\Contracts\\EventDispatcher\\EventDispatcherInterface\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/Base.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookup\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:getRelationProcessorMock\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookup\(\) has parameter \$alwaysAvailable with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookup\(\) has parameter \$languageCode with no type specified\.$#' - identifier: missingType.parameter - count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/Base.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookup\(\) has parameter \$prioritizedLanguageList with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:getRepository\(\) has parameter \$serviceSettings with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/Base.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookup\(\) has parameter \$showAllTranslations with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#1 \$className of method PHPUnit\\Framework\\TestCase\:\:getMockBuilder\(\) expects class\-string\, string given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/Base.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookupThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$methods of method PHPUnit\\Framework\\MockObject\\MockBuilder\\:\:onlyMethods\(\) expects list\, non\-empty\-list\ given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/Base.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookupThrowsNotFoundExceptionPathNotMatchedOrNotLoadable\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#2 \$searchHandler of class Ibexa\\Core\\Repository\\Repository constructor expects Ibexa\\Contracts\\Core\\Search\\Handler, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/Base.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookupThrowsNotFoundExceptionPathNotMatchedOrNotLoadable\(\) has parameter \$languageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:\$contentDomainMapperMock \(Ibexa\\Core\\Repository\\Mapper\\ContentDomainMapper&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/Base.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookupThrowsNotFoundExceptionPathNotMatchedOrNotLoadable\(\) has parameter \$prioritizedLanguageList with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:\$contentTypeDomainMapperMock \(Ibexa\\Core\\Repository\\Mapper\\ContentTypeDomainMapper&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/Base.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookupThrowsNotFoundExceptionPathNotMatchedOrNotLoadable\(\) has parameter \$url with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:\$fieldTypeRegistryMock has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/Base.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookupWithSharedTranslation\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:\$fieldTypeServiceMock has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/Base.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookupWithSharedTranslation\(\) has parameter \$alwaysAvailable with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:\$permissionServiceMock \(Ibexa\\Contracts\\Core\\Repository\\PermissionService&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/Base.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookupWithSharedTranslation\(\) has parameter \$languageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:\$persistenceMock \(Ibexa\\Contracts\\Core\\Persistence\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/Base.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookupWithSharedTranslation\(\) has parameter \$prioritizedLanguageList with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:\$repositoryMock \(Ibexa\\Contracts\\Core\\Repository\\Repository&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/Base.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookupWithSharedTranslation\(\) has parameter \$showAllTranslations with no type specified\.$#' - identifier: missingType.parameter + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\Base\:\:\$thumbnailStrategyMock \(Ibexa\\Contracts\\Core\\Repository\\Strategy\\ContentThumbnail\\ThumbnailStrategy&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/Base.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testRemoveAliases\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Unable to resolve the template type T in call to method PHPUnit\\Framework\\TestCase\:\:getMockBuilder\(\)$#' + identifier: argument.templateType count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/Base.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testRemoveAliasesThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\BookmarkTest\:\:createBookmarkService\(\) has parameter \$methods with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/BookmarkTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testRemoveAliasesThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\BookmarkTest\:\:\$bookmarkHandler \(Ibexa\\Contracts\\Core\\Persistence\\Bookmark\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept PHPUnit\\Framework\\MockObject\\MockObject\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/BookmarkTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testRemoveAliasesWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertInstanceOf\(\) with ''Ibexa\\\\Contracts\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Location'' and Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testReverseLookupAlwaysAvailablePath\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:getContentHandlerMock\(\) should return Ibexa\\Contracts\\Core\\Persistence\\Content\\Handler&PHPUnit\\Framework\\MockObject\\MockObject but returns PHPUnit\\Framework\\MockObject\\MockObject\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testReverseLookupAlwaysAvailablePath\(\) has parameter \$paths with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:getLanguageHandlerMock\(\) should return Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler&PHPUnit\\Framework\\MockObject\\MockObject but returns PHPUnit\\Framework\\MockObject\\MockObject\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testReverseLookupAlwaysAvailablePath\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:getTypeHandlerMock\(\) should return Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\Handler&PHPUnit\\Framework\\MockObject\\MockObject but returns PHPUnit\\Framework\\MockObject\\MockObject\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testReverseLookupAlwaysAvailablePath\(\) has parameter \$spiUrlAliases with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:testBuildLocationDomainObjectsOnSearchResult\(\) has parameter \$contentIds with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testReverseLookupCustomConfiguration\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:testBuildLocationDomainObjectsOnSearchResult\(\) has parameter \$contentInfoList with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testReverseLookupPath\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:testBuildLocationDomainObjectsOnSearchResult\(\) has parameter \$languageFilter with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testReverseLookupPath\(\) has parameter \$paths with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentDomainMapperTest\:\:testBuildLocationDomainObjectsOnSearchResult\(\) has parameter \$locationHits with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testReverseLookupPath\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' - identifier: missingType.parameter + message: '#^Parameter \#2 \$locationHandler of class Ibexa\\Core\\Repository\\Mapper\\ContentDomainMapper constructor expects Ibexa\\Contracts\\Core\\Persistence\\Content\\Location\\Handler, PHPUnit\\Framework\\MockObject\\MockObject given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testReverseLookupPath\(\) has parameter \$reverseLookupLanguageCode with no type specified\.$#' - identifier: missingType.parameter + message: '#^Access to an undefined property Ibexa\\Contracts\\Core\\FieldType\\Value\:\:\$value\.$#' + identifier: property.notFound count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testReverseLookupPath\(\) has parameter \$spiUrlAliases with no type specified\.$#' - identifier: missingType.parameter + message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Persistence\\Content\\Handler\:\:expects\(\)\.$#' + identifier: method.notFound count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testReverseLookupThrowsNotFoundException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForCreateContentContentValidationException\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testReverseLookupWithShowAllTranslations\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForCreateContentContentValidationException\(\) has parameter \$fieldDefinitions with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Parameter \#1 \$value of function count expects array\|Countable, iterable\ given\.$#' - identifier: argument.type - count: 12 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForCreateContentContentValidationException\(\) has parameter \$mainLanguageCode with no type specified\.$#' + identifier: missingType.parameter + count: 1 + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:\$urlAliasHandler \(Ibexa\\Contracts\\Core\\Persistence\\Content\\UrlAlias\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: assign.propertyType + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForCreateContentContentValidationException\(\) has parameter \$structFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlAliasTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Cannot call method getTimestamp\(\) on DateTimeInterface\|null\.$#' - identifier: method.nonObject - count: 2 - path: tests/lib/Repository/Service/Mock/UrlTest.php + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestCreateContentThrowsContentFieldValidationException\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:configurePermissions\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentRequiredField\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:configurePermissions\(\) has parameter \$permissions with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentRequiredField\(\) has parameter \$existingFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:configureUrlUpdatePermission\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentRequiredField\(\) has parameter \$fieldDefinitions with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:configureUrlUpdatePermission\(\) has parameter \$hasAccess with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentRequiredField\(\) has parameter \$initialLanguageCode with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:configureUrlUpdatePermission\(\) has parameter \$object with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentRequiredField\(\) has parameter \$structFields with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:configureUrlViewPermission\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentThrowsContentFieldValidationException\(\) has parameter \$allFieldErrors with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:configureUrlViewPermission\(\) has parameter \$hasAccess with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentThrowsContentFieldValidationException\(\) has parameter \$existingFields with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:configureUrlViewPermission\(\) has parameter \$object with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentThrowsContentFieldValidationException\(\) has parameter \$fieldDefinitions with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:configureUrlViewPermissionForHasAccess\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentThrowsContentFieldValidationException\(\) has parameter \$initialLanguageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:configureUrlViewPermissionForHasAccess\(\) has parameter \$hasAccess with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentThrowsContentFieldValidationException\(\) has parameter \$structFields with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:createUrlService\(\) has parameter \$methods with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForTestUpdateContentThrowsContentFieldValidationException\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:dateProviderForFindUsages\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForUpdateContentContentValidationException\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:getApiUrl\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForUpdateContentContentValidationException\(\) has parameter \$fieldDefinitions with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:getApiUrl\(\) has parameter \$id with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForUpdateContentContentValidationException\(\) has parameter \$initialLanguageCode with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:getApiUrl\(\) has parameter \$url with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:assertForUpdateContentContentValidationException\(\) has parameter \$structFields with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:testCreateUpdateStruct\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:determineValuesForCreate\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:testFindUrls\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:determineValuesForCreate\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:testFindUrlsNonNumericLimit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:determineValuesForUpdate\(\) has parameter \$languageCodes with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:testFindUrlsNonNumericOffset\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:determineValuesForUpdate\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:testFindUrlsUnauthorized\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:fixturesForTestCreateContentNonRedundantFieldSetComplex\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:testFindUsages\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:fixturesForTestUpdateContentNonRedundantFieldSetComplex\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:testFindUsages\(\) has parameter \$limit with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:getPartlyMockedContentService\(\) should return Ibexa\\Core\\Repository\\ContentService&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Repository\\ContentService\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:testFindUsages\(\) has parameter \$offset with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:internalLoadContentProviderById\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php + + - + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:internalLoadContentProviderByRemoteId\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/lib/Repository/Service/Mock/ContentTest.php + + - + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:mapStructFieldsForCreate\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:testFindUsages\(\) has parameter \$usages with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:mapStructFieldsForUpdate\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:testLoadById\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:mockBuildContentDomainObject\(\) has parameter \$translations with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:testLoadByIdUnauthorized\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:mockGetDefaultObjectStates\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:testLoadByUrl\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:mockPublishUrlAliasesForContent\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:testLoadByUrlUnauthorized\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:mockSetDefaultObjectStates\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:testUpdateUrl\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:prepareContentForTestCreateAndUpdateContent\(\) has parameter \$existingFields with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:testUpdateUrlNonUnique\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:prepareContentForTestCreateAndUpdateContent\(\) has parameter \$existingLanguageCodes with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:testUpdateUrlStatus\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:prepareContentForTestCreateAndUpdateContent\(\) has parameter \$fieldDefinitions with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:testUpdateUrlUnauthorized\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:provideCommonCreateContentObjects\(\) has parameter \$fieldDefinitions with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method PHPUnit\\Framework\\MockObject\\Builder\\InvocationMocker\:\:withConsecutive\(\) invoked with unpacked array with possibly string key, but it''s not allowed because of @no\-named\-arguments\.$#' - identifier: argument.named + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:provideCommonCreateContentObjects\(\) has parameter \$mainLanguageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\URLQuery\:\:\$limit \(int\) does not accept string\.$#' - identifier: assign.propertyType + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:provideCommonCreateContentObjects\(\) has parameter \$structFields with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\URLQuery\:\:\$offset \(int\) does not accept string\.$#' - identifier: assign.propertyType + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:provideCommonCreateContentObjects\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:\$urlHandler \(Ibexa\\Contracts\\Core\\Repository\\URLService&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: assign.propertyType + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestUpdateContentNonRedundantFieldSetComplex\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:providerForTestCreate\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:providerForTestUpdateContentThrowsContentFieldValidationException\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:providerForTestCreateThrowsContentValidationException\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:stubValues\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:providerForTestTranslate\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:stubValues\(\) has parameter \$fieldValues with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:providerForTestTranslateThrowsNotFoundException\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSet1\(\) has parameter \$mainLanguageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testCreate\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSet1\(\) has parameter \$spiFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testCreate\(\) has parameter \$destinationUrl with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSet1\(\) has parameter \$structFields with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testCreate\(\) has parameter \$forward with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSet2\(\) has parameter \$mainLanguageCode with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testCreate\(\) has parameter \$sourceUrl with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSet2\(\) has parameter \$spiFields with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testCreateThrowsContentValidationException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSet2\(\) has parameter \$structFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testCreateThrowsContentValidationException\(\) has parameter \$destinationUrl with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSetComplex\(\) has parameter \$mainLanguageCode with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testCreateThrowsContentValidationException\(\) has parameter \$forward with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSetComplex\(\) has parameter \$spiFields with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testCreateThrowsContentValidationException\(\) has parameter \$sourceUrl with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentNonRedundantFieldSetComplex\(\) has parameter \$structFields with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testCreateThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentRequiredField\(\) has parameter \$identifier with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testCreateThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentRequiredField\(\) has parameter \$languageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testCreateWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentRequiredField\(\) has parameter \$mainLanguageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testLoad\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentRequiredField\(\) has parameter \$structFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testLoadAll\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentThrowsContentFieldValidationException\(\) has parameter \$mainLanguageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testLoadAllWithLimitAndOffset\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentThrowsContentFieldValidationException\(\) has parameter \$structFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testLoadThrowsException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentThrowsContentValidationExceptionFieldDefinition\(\) has parameter \$mainLanguageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testRemove\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentThrowsContentValidationExceptionFieldDefinition\(\) has parameter \$structFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testRemoveThrowsUnauthorizedException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentThrowsContentValidationExceptionTranslation\(\) has parameter \$mainLanguageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testRemoveWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentThrowsContentValidationExceptionTranslation\(\) has parameter \$structFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testTranslate\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentWithInvalidLanguage\(\) has parameter \$mainLanguageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testTranslate\(\) has parameter \$createArray with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testCreateContentWithInvalidLanguage\(\) has parameter \$structFields with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testTranslate\(\) has parameter \$uri with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testInternalLoadContentById\(\) has parameter \$languages with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testTranslate\(\) has parameter \$url with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testInternalLoadContentByRemoteId\(\) has parameter \$languages with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue + count: 1 + path: tests/lib/Repository/Service/Mock/ContentTest.php + + - + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet1\(\) has parameter \$initialLanguageCode with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testTranslateThrowsNotFoundException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet1\(\) has parameter \$spiFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testTranslateThrowsNotFoundException\(\) has parameter \$createArray with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet1\(\) has parameter \$structFields with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testTranslateThrowsNotFoundException\(\) has parameter \$url with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet2\(\) has parameter \$initialLanguageCode with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testTranslateUsesLongestMatchingWildcard\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet2\(\) has parameter \$spiFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:\$urlWildcardHandler \(Ibexa\\Contracts\\Core\\Persistence\\Content\\UrlWildcard\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: assign.propertyType + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet2\(\) has parameter \$structFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UserPasswordValidatorTest\:\:dateProviderForValidate\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet3\(\) has parameter \$initialLanguageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UserPasswordValidatorTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UserPasswordValidatorTest\:\:testValidate\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet3\(\) has parameter \$spiFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UserPasswordValidatorTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UserPasswordValidatorTest\:\:testValidate\(\) has parameter \$constraints with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet3\(\) has parameter \$structFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UserPasswordValidatorTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UserPasswordValidatorTest\:\:testValidate\(\) has parameter \$expectedErrors with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet4\(\) has parameter \$initialLanguageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UserPasswordValidatorTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UserPreferenceTest\:\:createAPIUserPreferenceService\(\) has parameter \$methods with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet4\(\) has parameter \$spiFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UserPreferenceTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UserPreferenceTest\:\:testGetUserPreference\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSet4\(\) has parameter \$structFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UserPreferenceTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UserPreferenceTest\:\:testGetUserPreferenceCount\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSetComplex\(\) has parameter \$initialLanguageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UserPreferenceTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UserPreferenceTest\:\:testLoadUserPreferences\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSetComplex\(\) has parameter \$spiFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UserPreferenceTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UserPreferenceTest\:\:testSetUserPreference\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentNonRedundantFieldSetComplex\(\) has parameter \$structFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UserPreferenceTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UserPreferenceTest\:\:testSetUserPreferenceThrowsInvalidArgumentException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentRequiredField\(\) has parameter \$identifier with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UserPreferenceTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UserPreferenceTest\:\:testSetUserPreferenceWithRollback\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentRequiredField\(\) has parameter \$initialLanguageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UserPreferenceTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UserPreferenceTest\:\:\$userSPIPreferenceHandler \(Ibexa\\Contracts\\Core\\Persistence\\UserPreference\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: assign.propertyType + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentRequiredField\(\) has parameter \$languageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UserPreferenceTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Persistence\\User\\Handler\:\:expects\(\)\.$#' - identifier: method.notFound + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentRequiredField\(\) has parameter \$structFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UserTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Parameter \#1 \$methods of method PHPUnit\\Framework\\MockObject\\MockBuilder\\:\:onlyMethods\(\) expects array\, array\\|null given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsBadStateException\(\) has parameter \$status with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Service/Mock/UserTest.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Parameter \#6 \$userHandler of method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UserTest\:\:mockDeleteUserFlow\(\) expects Ibexa\\Contracts\\Core\\Persistence\\User\\Handler&PHPUnit\\Framework\\MockObject\\MockObject, Ibexa\\Contracts\\Core\\Persistence\\User\\Handler given\.$#' - identifier: argument.type - count: 2 - path: tests/lib/Repository/Service/Mock/UserTest.php + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsContentFieldValidationException\(\) has parameter \$allFieldErrors with no type specified\.$#' + identifier: missingType.parameter + count: 1 + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Call to method expects\(\) on an unknown class object\.$#' - identifier: class.notFound - count: 4 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsContentFieldValidationException\(\) has parameter \$initialLanguageCode with no type specified\.$#' + identifier: missingType.parameter + count: 1 + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:getAPIServiceClassName\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsContentFieldValidationException\(\) has parameter \$spiField with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:getSiteAccessAwareServiceClassName\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsContentFieldValidationException\(\) has parameter \$structFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:providerForLanguagesLookupMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsContentValidationExceptionFieldDefinition\(\) has parameter \$initialLanguageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:providerForPassTroughMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsContentValidationExceptionFieldDefinition\(\) has parameter \$structFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:setLanguagesLookupArguments\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsContentValidationExceptionTranslation\(\) has parameter \$initialLanguageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:setLanguagesLookupArguments\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentThrowsContentValidationExceptionTranslation\(\) has parameter \$structFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:setLanguagesLookupExpectedArguments\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentWithInvalidLanguage\(\) has parameter \$initialLanguageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:setLanguagesLookupExpectedArguments\(\) has parameter \$languages with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:testUpdateContentWithInvalidLanguage\(\) has parameter \$structFields with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:setLanguagesLookupExpectedArguments\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$languageHandlerMock of method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:loadByLanguageCodeMock\(\) expects PHPUnit\\Framework\\MockObject\\MockObject, Ibexa\\Contracts\\Core\\Persistence\\Content\\Language\\Handler given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:setLanguagesPassTroughArguments\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$methods of method PHPUnit\\Framework\\MockObject\\MockBuilder\\:\:addMethods\(\) expects list\, non\-empty\-list\ given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:setLanguagesPassTroughArguments\(\) has parameter \$languages with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Parameter \#1 \$methods of method PHPUnit\\Framework\\MockObject\\MockBuilder\\:\:onlyMethods\(\) expects list\, non\-empty\-list\ given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:setLanguagesPassTroughArguments\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + message: '#^Parameter \#1 \$singular of class Ibexa\\Core\\FieldType\\ValidationError constructor expects string, int given\.$#' + identifier: argument.type + count: 2 + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:testForLanguagesLookup\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Contracts\\Core\\Persistence\\Content\\MetadataUpdateStruct\:\:\$publicationDate \(int\) does not accept int\|null\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:testForLanguagesPassTrough\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:\$contentTypeServiceMock has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:testForPassTrough\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:\$locationServiceMock has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:testForPassTrough\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:\$partlyMockedContentService \(Ibexa\\Core\\Repository\\ContentService\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Method PHPUnit\\Framework\\MockObject\\Builder\\InvocationMocker\:\:with\(\) invoked with unpacked array with possibly string key, but it''s not allowed because of @no\-named\-arguments\.$#' - identifier: argument.named - count: 4 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\ContentTest\:\:\$relationProcessorMock has no type specified\.$#' + identifier: missingType.property + count: 1 + path: tests/lib/Repository/Service/Mock/ContentTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:\$innerApiServiceMock \(object&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: assign.propertyType - count: 1 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Persistence\\User\\Handler\:\:expects\(\)\.$#' + identifier: method.notFound + count: 6 + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:\$innerApiServiceMock has unknown class object as its type\.$#' - identifier: class.notFound + message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Repository\\PermissionResolver&PHPUnit\\Framework\\MockObject\\MockObject\:\:sudo\(\)\.$#' + identifier: method.notFound count: 1 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Unable to resolve the template type T in call to method PHPUnit\\Framework\\TestCase\:\:getMockBuilder\(\)$#' - identifier: argument.templateType + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:createRole\(\) has parameter \$policiesData with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\ContentServiceTest\:\:providerForLanguagesLookupMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:getPermissionResolverMock\(\) has parameter \$methods with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/SiteAccessAware/ContentServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\ContentServiceTest\:\:providerForPassTroughMethods\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:getPermissionSetsMock\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/ContentServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\ContentTypeServiceTest\:\:providerForLanguagesLookupMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:getUserReferenceMock\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/lib/Repository/SiteAccessAware/ContentTypeServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\ContentTypeServiceTest\:\:providerForPassTroughMethods\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:providerForTestCanUserComplex\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/ContentTypeServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\Language\\LanguageResolverTest\:\:getDataForTestGetPrioritizedLanguages\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:providerForTestHasAccessReturnsInvalidArgumentValueException\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/Language/LanguageResolverTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\Language\\LanguageResolverTest\:\:testGetPrioritizedLanguages\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:providerForTestHasAccessReturnsLimitationNotFoundException\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/Language/LanguageResolverTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\Language\\LanguageResolverTest\:\:testGetPrioritizedLanguages\(\) has parameter \$configLanguages with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:providerForTestHasAccessReturnsPermissionSets\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/Language/LanguageResolverTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\Language\\LanguageResolverTest\:\:testGetPrioritizedLanguages\(\) has parameter \$expectedPrioritizedLanguagesList with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testCanUserComplex\(\) has parameter \$policyLimitationEvaluations with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/Language/LanguageResolverTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\Language\\LanguageResolverTest\:\:testGetPrioritizedLanguages\(\) has parameter \$forcedLanguages with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testCanUserComplex\(\) has parameter \$roleLimitationEvaluations with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/Language/LanguageResolverTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\LanguageServiceTest\:\:providerForLanguagesLookupMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testCanUserComplex\(\) has parameter \$userCan with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/SiteAccessAware/LanguageServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\LanguageServiceTest\:\:providerForPassTroughMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testCanUserSimple\(\) has parameter \$permissionSets with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/SiteAccessAware/LanguageServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\LocationServiceTest\:\:providerForLanguagesLookupMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testCanUserSimple\(\) has parameter \$result with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/SiteAccessAware/LocationServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\LocationServiceTest\:\:providerForPassTroughMethods\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsFalse\(\) has parameter \$roleAssignments with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/LocationServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\ObjectStateServiceTest\:\:providerForLanguagesLookupMethods\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsFalse\(\) has parameter \$roles with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/ObjectStateServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\ObjectStateServiceTest\:\:providerForPassTroughMethods\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsInvalidArgumentValueException\(\) has parameter \$roleAssignments with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/ObjectStateServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\SearchServiceTest\:\:providerForLanguagesLookupMethods\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsInvalidArgumentValueException\(\) has parameter \$roles with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\SearchServiceTest\:\:providerForPassTroughMethods\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsLimitationNotFoundException\(\) has parameter \$roleAssignments with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\SearchServiceTest\:\:setLanguagesLookupArguments\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsLimitationNotFoundException\(\) has parameter \$roles with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\SearchServiceTest\:\:setLanguagesLookupArguments\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsPermissionSets\(\) has parameter \$roleAssignments with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\SearchServiceTest\:\:setLanguagesLookupExpectedArguments\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsPermissionSets\(\) has parameter \$roles with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\SearchServiceTest\:\:setLanguagesLookupExpectedArguments\(\) has parameter \$languages with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsPermissionSetsWithRoleLimitation\(\) has parameter \$roleAssignments with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\SearchServiceTest\:\:setLanguagesLookupExpectedArguments\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsPermissionSetsWithRoleLimitation\(\) has parameter \$roles with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\SearchServiceTest\:\:setLanguagesPassTroughArguments\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsTrue\(\) has parameter \$roleAssignments with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\SearchServiceTest\:\:setLanguagesPassTroughArguments\(\) has parameter \$languages with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:testHasAccessReturnsTrue\(\) has parameter \$roles with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\SearchServiceTest\:\:setLanguagesPassTroughArguments\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^PHPDoc tag @var has invalid value \(\$limitationsPass\)\: Unexpected token "\$limitationsPass", expected type at offset 9 on line 1$#' + identifier: phpDoc.parseError count: 1 - path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\TrashServiceTest\:\:providerForLanguagesLookupMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^PHPDoc tag @var has invalid value \(\$policy \\Ibexa\\Contracts\\Core\\Persistence\\User\\Policy\)\: Unexpected token "\$policy", expected type at offset 9 on line 1$#' + identifier: phpDoc.parseError count: 1 - path: tests/lib/Repository/SiteAccessAware/TrashServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\TrashServiceTest\:\:providerForPassTroughMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^PHPDoc tag @var has invalid value \(\$policy \\Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy\)\: Unexpected token "\$policy", expected type at offset 9 on line 1$#' + identifier: phpDoc.parseError count: 1 - path: tests/lib/Repository/SiteAccessAware/TrashServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\UrlAliasServiceTest\:\:providerForLanguagesLookupMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^PHPDoc tag @var has invalid value \(\$role \\Ibexa\\Contracts\\Core\\Persistence\\User\\Role\)\: Unexpected token "\$role", expected type at offset 9 on line 1$#' + identifier: phpDoc.parseError count: 1 - path: tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\UrlAliasServiceTest\:\:providerForPassTroughMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^PHPDoc tag @var has invalid value \(\$roleAssignments \\Ibexa\\Contracts\\Core\\Persistence\\User\\RoleAssignment\[\]\)\: Unexpected token "\$roleAssignments", expected type at offset 9 on line 1$#' + identifier: phpDoc.parseError count: 1 - path: tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\UrlAliasServiceTest\:\:setLanguagesLookupExpectedArguments\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^PHPDoc tag @var has invalid value \(\$userHandlerMock \\PHPUnit\\Framework\\MockObject\\MockObject\)\: Unexpected token "\$userHandlerMock", expected type at offset 9 on line 1$#' + identifier: phpDoc.parseError + count: 6 + path: tests/lib/Repository/Service/Mock/PermissionTest.php + + - + message: '#^PHPDoc tag @var has invalid value \(\$valueObject \\Ibexa\\Contracts\\Core\\Repository\\Values\\ValueObject\)\: Unexpected token "\$valueObject", expected type at offset 9 on line 1$#' + identifier: phpDoc.parseError + count: 3 + path: tests/lib/Repository/Service/Mock/PermissionTest.php + + - + message: '#^Parameter \#1 \$userHandlerMock of method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:mockLoadRoleSequence\(\) expects PHPUnit\\Framework\\MockObject\\MockObject, Ibexa\\Contracts\\Core\\Persistence\\User\\Handler given\.$#' + identifier: argument.type + count: 5 + path: tests/lib/Repository/Service/Mock/PermissionTest.php + + - + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:\$permissionResolverMock has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\UrlAliasServiceTest\:\:setLanguagesLookupExpectedArguments\(\) has parameter \$languages with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:\$repositoryMock has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\UrlAliasServiceTest\:\:setLanguagesLookupExpectedArguments\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\PermissionTest\:\:\$userReferenceMock has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\UrlAliasServiceTest\:\:setLanguagesPassTroughArguments\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Variable \$limitationsPass might not be defined\.$#' + identifier: variable.undefined count: 1 - path: tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php + path: tests/lib/Repository/Service/Mock/PermissionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\UrlAliasServiceTest\:\:setLanguagesPassTroughArguments\(\) has parameter \$languages with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Persistence\\Content\\Location\\Handler\:\:expects\(\)\.$#' + identifier: method.notFound + count: 3 + path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + + - + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:assertLocationHandlerExpectation\(\) has no return type specified\.$#' + identifier: missingType.return count: 1 - path: tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php + path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\UrlAliasServiceTest\:\:setLanguagesPassTroughArguments\(\) return type has no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:assertLocationHandlerExpectation\(\) has parameter \$expectedLocationIds with no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php + path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\UserServiceTest\:\:providerForLanguagesLookupMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:assertLocationHandlerExpectation\(\) has parameter \$fieldRelations with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/SiteAccessAware/UserServiceTest.php + path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\UserServiceTest\:\:providerForPassTroughMethods\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:assertLocationHandlerExpectation\(\) has parameter \$type with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/SiteAccessAware/UserServiceTest.php + path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php - - message: '#^Call to method expects\(\) on an unknown class PHPUnit_Framework_MockObject_MockObject\.$#' - identifier: class.notFound - count: 2 - path: tests/lib/Repository/Validator/TargetContentValidatorTest.php + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:getStubbedRelation\(\) has no return type specified\.$#' + identifier: missingType.return + count: 1 + path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php - - message: '#^Call to method method\(\) on an unknown class PHPUnit_Framework_MockObject_MockObject\.$#' - identifier: class.notFound + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:getStubbedRelation\(\) has parameter \$contentId with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Validator/TargetContentValidatorTest.php + path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Validator\\TargetContentValidatorTest\:\:\$contentHandler \(Ibexa\\Contracts\\Core\\Persistence\\Content\\Handler&PHPUnit_Framework_MockObject_MockObject\) does not accept Ibexa\\Contracts\\Core\\Persistence\\Content\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: assign.propertyType + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:getStubbedRelation\(\) has parameter \$fieldDefinitionId with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Validator/TargetContentValidatorTest.php + path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Validator\\TargetContentValidatorTest\:\:\$contentHandler has unknown class PHPUnit_Framework_MockObject_MockObject as its type\.$#' - identifier: class.notFound + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:getStubbedRelation\(\) has parameter \$id with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Validator/TargetContentValidatorTest.php + path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Validator\\TargetContentValidatorTest\:\:\$contentTypeHandler \(Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\Handler&PHPUnit_Framework_MockObject_MockObject\) does not accept Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\.$#' - identifier: assign.propertyType + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:getStubbedRelation\(\) has parameter \$type with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Validator/TargetContentValidatorTest.php + path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Repository\\Validator\\TargetContentValidatorTest\:\:\$contentTypeHandler has unknown class PHPUnit_Framework_MockObject_MockObject as its type\.$#' - identifier: class.notFound + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:testAppendFieldRelations\(\) has parameter \$expected with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Validator/TargetContentValidatorTest.php + path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\LanguageTest\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RelationProcessorTest\:\:testAppendFieldRelations\(\) has parameter \$fieldRelations with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Values/Content/LanguageTest.php + path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\LanguageTest\:\:testIsPropertySet\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$methods of method PHPUnit\\Framework\\MockObject\\MockBuilder\\:\:onlyMethods\(\) expects list\, list\ given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Values/Content/LanguageTest.php + path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\LanguageTest\:\:testMissingProperty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#5 \$fieldDefinitionId of method Ibexa\\Core\\Repository\\Helper\\RelationProcessor\:\:appendFieldRelations\(\) expects string, int given\.$#' + identifier: argument.type + count: 3 + path: tests/lib/Repository/Service/Mock/RelationProcessorTest.php + + - + message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Repository\\Values\\User\\RoleCreateStruct\:\:expects\(\)\.$#' + identifier: method.notFound count: 1 - path: tests/lib/Repository/Values/Content/LanguageTest.php + path: tests/lib/Repository/Service/Mock/RoleTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\LanguageTest\:\:testReadOnlyProperty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:getPartlyMockedRoleService\(\) has parameter \$settings with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Values/Content/LanguageTest.php + path: tests/lib/Repository/Service/Mock/RoleTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\LanguageTest\:\:testUnsetProperty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:getPartlyMockedRoleService\(\) should return Ibexa\\Core\\Repository\\RoleService&PHPUnit\\Framework\\MockObject\\MockObject but returns Ibexa\\Core\\Repository\\RoleService\.$#' + identifier: return.type count: 1 - path: tests/lib/Repository/Values/Content/LanguageTest.php + path: tests/lib/Repository/Service/Mock/RoleTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertTrue\(\) with true will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType + message: '#^PHPDoc tag @var with type Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Role is not subtype of native type PHPUnit\\Framework\\MockObject\\Stub\.$#' + identifier: varTag.nativeType + count: 6 + path: tests/lib/Repository/Service/Mock/RoleTest.php + + - + message: '#^PHPDoc tag @var with type Ibexa\\Contracts\\Core\\Repository\\Values\\User\\RoleCreateStruct is not subtype of native type PHPUnit\\Framework\\MockObject\\MockObject\.$#' + identifier: varTag.nativeType count: 1 - path: tests/lib/Repository/Values/Content/LocationTest.php + path: tests/lib/Repository/Service/Mock/RoleTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\LocationTest\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^PHPDoc tag @var with type Ibexa\\Contracts\\Core\\Repository\\Values\\User\\User is not subtype of native type PHPUnit\\Framework\\MockObject\\Stub\.$#' + identifier: varTag.nativeType + count: 3 + path: tests/lib/Repository/Service/Mock/RoleTest.php + + - + message: '#^PHPDoc tag @var with type Ibexa\\Contracts\\Core\\Repository\\Values\\User\\UserGroup is not subtype of native type PHPUnit\\Framework\\MockObject\\Stub\.$#' + identifier: varTag.nativeType + count: 3 + path: tests/lib/Repository/Service/Mock/RoleTest.php + + - + message: '#^Parameter \#1 \$methods of method PHPUnit\\Framework\\MockObject\\MockBuilder\\:\:onlyMethods\(\) expects list\, list\ given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Repository/Values/Content/LocationTest.php + path: tests/lib/Repository/Service/Mock/RoleTest.php - - message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\:\:\$id \(int\) in isset\(\) is not nullable\.$#' + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\RoleTest\:\:\$partlyMockedRoleService \(Ibexa\\Core\\Repository\\RoleService\) in isset\(\) is not nullable\.$#' identifier: isset.property count: 1 - path: tests/lib/Repository/Values/Content/LocationTest.php + path: tests/lib/Repository/Service/Mock/RoleTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\Query\\Criterion\\DateMetadataTest\:\:testConstruction\(\) has parameter \$value with no type specified\.$#' + message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Search\\Handler\:\:expects\(\)\.$#' + identifier: method.notFound + count: 7 + path: tests/lib/Repository/Service/Mock/SearchTest.php + + - + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindContentValidatesLocationCriteriaAndSortClauses\(\) has parameter \$exceptionMessage with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/Content/Query/Criterion/DateMetadataTest.php + path: tests/lib/Repository/Service/Mock/SearchTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertTrue\(\) with true will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindContentValidatesLocationCriteriaAndSortClauses\(\) has parameter \$query with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/Content/SectionTest.php + path: tests/lib/Repository/Service/Mock/SearchTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\SectionTest\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindSingleValidatesLocationCriteria\(\) has parameter \$criterion with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/Content/SectionTest.php + path: tests/lib/Repository/Service/Mock/SearchTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\SectionTest\:\:testIsPropertySet\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:testFindSingleValidatesLocationCriteria\(\) has parameter \$exceptionMessage with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/Content/SectionTest.php + path: tests/lib/Repository/Service/Mock/SearchTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\SectionTest\:\:testMissingProperty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Values/Content/SectionTest.php + message: '#^PHPDoc tag @var with type Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\Criterion is not subtype of native type PHPUnit\\Framework\\MockObject\\MockObject\.$#' + identifier: varTag.nativeType + count: 5 + path: tests/lib/Repository/Service/Mock/SearchTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\SectionTest\:\:testReadOnlyProperty\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Repository/Values/Content/SectionTest.php + message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Search\\SearchResult\\:\:\$searchHits \(list\\>\) does not accept array\, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Search\\SearchHit\\>\.$#' + identifier: assign.propertyType + count: 2 + path: tests/lib/Repository/Service/Mock/SearchTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\SectionTest\:\:testUnsetProperty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Search\\SearchResult\\:\:\$totalCount \(int\<0, max\>\|null\) does not accept int\<\-1, max\>\.$#' + identifier: assign.propertyType + count: 2 + path: tests/lib/Repository/Service/Mock/SearchTest.php + + - + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:\$contentDomainMapperMock has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Values/Content/SectionTest.php + path: tests/lib/Repository/Service/Mock/SearchTest.php - - message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Section\:\:\$id \(int\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:\$permissionsCriterionResolverMock has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Values/Content/SectionTest.php + path: tests/lib/Repository/Service/Mock/SearchTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertTrue\(\) with true will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\SearchTest\:\:\$repositoryMock has no type specified\.$#' + identifier: missingType.property count: 1 - path: tests/lib/Repository/Values/Content/TrashItemTest.php + path: tests/lib/Repository/Service/Mock/SearchTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\TrashItemTest\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:getPartlyMockedURLAliasServiceService\(\) has parameter \$prioritizedLanguages with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Values/Content/TrashItemTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\TrashItemTest\:\:testIsPropertySet\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:getSpiUrlAlias\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Values/Content/TrashItemTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\TrashItemTest\:\:testMissingProperty\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:setConfiguration\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Repository/Values/Content/TrashItemTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\TrashItemTest\:\:testReadOnlyProperty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:setConfiguration\(\) has parameter \$configuration with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Repository/Values/Content/TrashItemTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\TrashItemTest\:\:testUnsetProperty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesAlwaysAvailablePath\(\) has parameter \$paths with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/Content/TrashItemTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\:\:\$id \(int\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesAlwaysAvailablePath\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/Content/TrashItemTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ContentType\\FieldDefinitionCollectionTest\:\:createFieldDefinitions\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesAlwaysAvailablePath\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ContentType/FieldDefinitionCollectionTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ContentType\\FieldDefinitionCollectionTest\:\:createFieldDefinitionsWith\(\) has parameter \$values with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesAlwaysAvailablePathCustomConfiguration\(\) has parameter \$paths with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ContentType/FieldDefinitionCollectionTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ContentType\\FieldDefinitionCollectionTest\:\:createFieldDefinitionsWith\(\) return type has no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesAlwaysAvailablePathCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ContentType/FieldDefinitionCollectionTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Filter\\FilterTest\:\:getComplexFilterTestData\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesAlwaysAvailablePathCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/Filter/FilterTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Filter\\FilterTest\:\:getFilters\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesEmpty\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/Filter/FilterTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Filter\\FilterTest\:\:getFiltersWithInvalidSliceData\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesEmpty\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/Filter/FilterTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Filter\\FilterTest\:\:getInvalidSortClausesData\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesEmptyCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/Filter/FilterTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Filter\\FilterTest\:\:testConstructorThrowsBadStateException\(\) has parameter \$sortClauses with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesEmptyCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/Filter/FilterTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertTrue\(\) with true will always evaluate to true\.$#' - identifier: staticMethod.alreadyNarrowedType + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesEmpty\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateGroupTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateGroupTest\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesEmpty\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateGroupTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateGroupTest\:\:testGetMultiLanguageDefaultDescription\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesEmptyCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateGroupTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateGroupTest\:\:testGetMultiLanguageDefaultName\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesEmptyCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateGroupTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateGroupTest\:\:testGetMultiLanguagePrioritizedDescription\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesPath\(\) has parameter \$paths with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateGroupTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateGroupTest\:\:testGetMultiLanguagePrioritizedName\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesPath\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateGroupTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateGroupTest\:\:testIsPropertySet\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesPath\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateGroupTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateGroupTest\:\:testMissingProperty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesPathCustomConfiguration\(\) has parameter \$paths with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateGroupTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateGroupTest\:\:testNewClass\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesPathCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateGroupTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateGroupTest\:\:testReadOnlyProperty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesMultipleLanguagesPathCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateGroupTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateGroupTest\:\:testUnsetProperty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesPath\(\) has parameter \$paths with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateGroupTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Property Ibexa\\Core\\Repository\\Values\\ObjectState\\ObjectStateGroup\:\:\$defaultLanguageCode \(string\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesPath\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateGroupTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateTest\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesPath\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateTest\:\:testGetMultiLanguageDefaultDescription\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesPathCustomConfiguration\(\) has parameter \$paths with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateTest\:\:testGetMultiLanguageDefaultName\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesPathCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateTest\:\:testGetMultiLanguagePrioritizedDescription\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesPathCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateTest\:\:testGetMultiLanguagePrioritizedName\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmpty\(\) has parameter \$languageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateTest\:\:testIsPropertySet\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmpty\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateTest\:\:testMissingProperty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmpty\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateTest\:\:testNewClass\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmptyCustomConfiguration\(\) has parameter \$languageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateTest\:\:testReadOnlyProperty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmptyCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateTest\:\:testUnsetProperty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmptyCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/ObjectState/ObjectStateTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\User\\PolicyTest\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePath\(\) has parameter \$languageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/User/PolicyTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\User\\PolicyTest\:\:testIsPropertySet\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePath\(\) has parameter \$paths with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/User/PolicyTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\User\\PolicyTest\:\:testMissingProperty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePath\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/User/PolicyTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\User\\PolicyTest\:\:testNewClass\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePath\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/User/PolicyTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\User\\PolicyTest\:\:testReadOnlyProperty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePathCustomConfiguration\(\) has parameter \$languageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/User/PolicyTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\User\\PolicyTest\:\:testUnsetProperty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePathCustomConfiguration\(\) has parameter \$paths with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/User/PolicyTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\User\\RoleTest\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePathCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/User/RoleTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\User\\UserGroupTest\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePathCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/User/UserGroupTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\User\\UserGroupTest\:\:testGetName\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeEmpty\(\) has parameter \$languageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/User/UserGroupTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\User\\UserGroupTest\:\:testIsPropertySet\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeEmpty\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/User/UserGroupTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\User\\UserGroupTest\:\:testMissingProperty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeEmpty\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/User/UserGroupTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\User\\UserGroupTest\:\:testNewClass\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeEmptyCustomConfiguration\(\) has parameter \$languageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/User/UserGroupTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\User\\UserGroupTest\:\:testObjectProperties\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeEmptyCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/User/UserGroupTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\User\\UserGroupTest\:\:testReadOnlyProperty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeEmptyCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/User/UserGroupTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\User\\UserGroupTest\:\:testUnsetProperty\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmpty\(\) has parameter \$languageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/User/UserGroupTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\User\\UserTest\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmpty\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Repository/Values/User/UserTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Common\\FieldValueMapper\\RemoteIdentifierMapperTest\:\:getDataForTestCanMap\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmpty\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Common/FieldValueMapper/RemoteIdentifierMapperTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Common\\FieldValueMapper\\RemoteIdentifierMapperTest\:\:getDataForTestMap\(\) return type has no value type specified in iterable type iterable\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmptyCustomConfiguration\(\) has parameter \$languageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Common/FieldValueMapper/RemoteIdentifierMapperTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:getMockedFieldNameResolver\(\) has parameter \$methods with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmptyCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/FieldNameResolverTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:testGetFieldNames\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmptyCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/FieldNameResolverTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:testGetFieldNamesReturnsEmptyArray\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPath\(\) has parameter \$languageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/FieldNameResolverTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:testGetFieldNamesWithNamedField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPath\(\) has parameter \$paths with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/FieldNameResolverTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:testGetFieldNamesWithTypedAndNamedField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPath\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/FieldNameResolverTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:testGetFieldNamesWithTypedField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPath\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/FieldNameResolverTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:testGetIndexFieldNameCustomField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPathCustomConfiguration\(\) has parameter \$languageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/FieldNameResolverTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:testGetIndexFieldNameDefaultMatchField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPathCustomConfiguration\(\) has parameter \$paths with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/FieldNameResolverTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:testGetIndexFieldNameDefaultMatchFieldThrowsRuntimeException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPathCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/FieldNameResolverTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:testGetIndexFieldNameDefaultSortField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPathCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/FieldNameResolverTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:testGetIndexFieldNameDefaultSortFieldThrowsRuntimeException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodePath\(\) has parameter \$languageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/FieldNameResolverTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:testGetIndexFieldNameNamedField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodePath\(\) has parameter \$paths with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/FieldNameResolverTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:testGetIndexFieldNameNamedFieldThrowsRuntimeException\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodePath\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/FieldNameResolverTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:testGetSortFieldName\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodePath\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/FieldNameResolverTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:testGetSortFieldNameReturnsNull\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodePathCustomConfiguration\(\) has parameter \$languageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/FieldNameResolverTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:\$contentTypeHandlerMock \(Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodePathCustomConfiguration\(\) has parameter \$paths with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/FieldNameResolverTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:\$fieldNameGeneratorMock \(Ibexa\\Core\\Search\\Common\\FieldNameGenerator&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodePathCustomConfiguration\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/FieldNameResolverTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:\$fieldRegistryMock \(Ibexa\\Core\\Search\\Common\\FieldRegistry&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testListAutogeneratedLocationAliasesWithLanguageCodePathCustomConfiguration\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/FieldNameResolverTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\AbstractTestCase\:\:assertSearchResults\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookup\(\) has parameter \$alwaysAvailable with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/AbstractTestCase.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\AbstractTestCase\:\:assertSearchResults\(\) has parameter \$expectedIds with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookup\(\) has parameter \$languageCode with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/AbstractTestCase.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\AbstractTestCase\:\:assertSearchResults\(\) has parameter \$searchResult with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookup\(\) has parameter \$prioritizedLanguageList with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/AbstractTestCase.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\AbstractTestCase\:\:getConverterRegistry\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookup\(\) has parameter \$showAllTranslations with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/AbstractTestCase.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\AbstractTestCase\:\:getIds\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookupThrowsNotFoundExceptionPathNotMatchedOrNotLoadable\(\) has parameter \$languageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/AbstractTestCase.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\AbstractTestCase\:\:getIds\(\) has parameter \$searchResult with no type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookupThrowsNotFoundExceptionPathNotMatchedOrNotLoadable\(\) has parameter \$prioritizedLanguageList with no type specified\.$#' identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/AbstractTestCase.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\AbstractTestCase\:\:\$contentTypeHandler \(Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\Handler\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookupThrowsNotFoundExceptionPathNotMatchedOrNotLoadable\(\) has parameter \$url with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/AbstractTestCase.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\AbstractTestCase\:\:\$converterRegistry \(Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldValue\\ConverterRegistry\) in isset\(\) is not nullable\.$#' - identifier: isset.property + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookupWithSharedTranslation\(\) has parameter \$alwaysAvailable with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/AbstractTestCase.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Class Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\SortClause\\Field constructor invoked with 4 parameters, 2\-3 required\.$#' - identifier: arguments.count + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookupWithSharedTranslation\(\) has parameter \$languageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentSortTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentSortTest\:\:getContentSearchHandler\(\) has parameter \$fullTextSearchConfiguration with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookupWithSharedTranslation\(\) has parameter \$prioritizedLanguageList with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentSortTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentSortTest\:\:testNoSorting\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testLookupWithSharedTranslation\(\) has parameter \$showAllTranslations with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentSortTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentSortTest\:\:testSortContentName\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testReverseLookupAlwaysAvailablePath\(\) has parameter \$paths with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentSortTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentSortTest\:\:testSortDateModified\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testReverseLookupAlwaysAvailablePath\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentSortTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentSortTest\:\:testSortDatePublished\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testReverseLookupAlwaysAvailablePath\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentSortTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentSortTest\:\:testSortFieldNumeric\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testReverseLookupPath\(\) has parameter \$paths with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentSortTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentSortTest\:\:testSortFieldText\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testReverseLookupPath\(\) has parameter \$prioritizedLanguageCodes with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentSortTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentSortTest\:\:testSortSectionIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testReverseLookupPath\(\) has parameter \$reverseLookupLanguageCode with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentSortTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentSortTest\:\:testSortSectionName\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:testReverseLookupPath\(\) has parameter \$spiUrlAliases with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentSortTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Parameter \#1 \$contentTypeHandler of method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageAwareTestCase\:\:getFullTextMapper\(\) expects Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Handler, Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\Handler given\.$#' + message: '#^Parameter \#1 \$methods of method PHPUnit\\Framework\\MockObject\\MockBuilder\\:\:onlyMethods\(\) expects list\, list\ given\.$#' identifier: argument.type count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentSortTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Property Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentSortTest\:\:\$fieldRegistry \(Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldValue\\ConverterRegistry\) in isset\(\) is not nullable\.$#' - identifier: isset.property - count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentSortTest.php + message: '#^Parameter \#1 \$value of function count expects array\|Countable, iterable\ given\.$#' + identifier: argument.type + count: 12 + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlAliasTest\:\:\$urlAliasHandler \(Ibexa\\Contracts\\Core\\Persistence\\Content\\UrlAlias\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept PHPUnit\\Framework\\MockObject\\MockObject\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentSortTest.php + path: tests/lib/Repository/Service/Mock/UrlAliasTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:getContentSearchHandler\(\) has parameter \$fullTextSearchConfiguration with no value type specified in iterable type array\.$#' - identifier: missingType.iterableValue - count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + message: '#^Cannot call method getTimestamp\(\) on DateTimeInterface\|null\.$#' + identifier: method.nonObject + count: 2 + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testContentAndCombinatorFilter\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:configurePermissions\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testContentIdFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:configurePermissions\(\) has parameter \$permissions with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testContentIdFilterCount\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:configureUrlUpdatePermission\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testContentNotCombinatorFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:configureUrlUpdatePermission\(\) has parameter \$hasAccess with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testContentOrCombinatorFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:configureUrlUpdatePermission\(\) has parameter \$object with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testContentSubtreeFilterEq\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:configureUrlViewPermission\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testContentSubtreeFilterIn\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:configureUrlViewPermission\(\) has parameter \$hasAccess with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testContentTypeGroupFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:configureUrlViewPermission\(\) has parameter \$object with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testContentTypeIdFilter\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:configureUrlViewPermissionForHasAccess\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testContentTypeIdentifierFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:configureUrlViewPermissionForHasAccess\(\) has parameter \$hasAccess with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testDateMetadataFilterCreatedBetween\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:createUrlService\(\) has parameter \$methods with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testDateMetadataFilterModifiedBetween\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:getApiUrl\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testDateMetadataFilterModifiedGreater\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:getApiUrl\(\) has parameter \$id with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testDateMetadataFilterModifiedGreaterOrEqual\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:getApiUrl\(\) has parameter \$url with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testDateMetadataFilterModifiedIn\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:testFindUsages\(\) has parameter \$limit with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFieldFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:testFindUsages\(\) has parameter \$offset with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFieldFilterBetween\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:testFindUsages\(\) has parameter \$usages with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFieldFilterContainsPartial\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\URLQuery\:\:\$limit \(int\) does not accept string\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFieldFilterContainsSimple\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Values\\URL\\URLQuery\:\:\$offset \(int\) does not accept string\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFieldFilterContainsSimpleNoMatch\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlTest\:\:\$urlHandler \(Ibexa\\Contracts\\Core\\Repository\\URLService&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept PHPUnit\\Framework\\MockObject\\MockObject\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFieldFilterIn\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:providerForTestTranslate\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFieldFilterOr\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:providerForTestTranslateThrowsNotFoundException\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFieldRelationFilterContainsArray\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testCreate\(\) has parameter \$destinationUrl with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFieldRelationFilterContainsArrayNotMatch\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testCreate\(\) has parameter \$forward with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFieldRelationFilterContainsSingle\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testCreate\(\) has parameter \$sourceUrl with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFieldRelationFilterContainsSingleNoMatch\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testCreateThrowsContentValidationException\(\) has parameter \$destinationUrl with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFieldRelationFilterInArray\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testCreateThrowsContentValidationException\(\) has parameter \$forward with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFieldRelationFilterInArrayNotMatch\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testCreateThrowsContentValidationException\(\) has parameter \$sourceUrl with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFindContentWithNonSearchableField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testTranslate\(\) has parameter \$createArray with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFindSingle\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testTranslate\(\) has parameter \$uri with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFindSingleTooMany\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testTranslate\(\) has parameter \$url with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFindSingleWithNonSearchableField\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testTranslateThrowsNotFoundException\(\) has parameter \$createArray with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFindSingleZero\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:testTranslateThrowsNotFoundException\(\) has parameter \$url with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFindWithOffsetToNonexistent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$methods of method PHPUnit\\Framework\\MockObject\\MockBuilder\\:\:onlyMethods\(\) expects list\, list\ given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFindWithZeroLimit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UrlWildcardTest\:\:\$urlWildcardHandler \(Ibexa\\Contracts\\Core\\Persistence\\Content\\UrlWildcard\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept PHPUnit\\Framework\\MockObject\\MockObject\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UrlWildcardTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFindWithoutOffsetLimit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UserPasswordValidatorTest\:\:dateProviderForValidate\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UserPasswordValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFullTextDisabledWildcardFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UserPasswordValidatorTest\:\:testValidate\(\) has parameter \$constraints with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UserPasswordValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFullTextFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UserPasswordValidatorTest\:\:testValidate\(\) has parameter \$expectedErrors with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UserPasswordValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFullTextFilterInvalidStopwordThreshold\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UserPreferenceTest\:\:createAPIUserPreferenceService\(\) has parameter \$methods with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UserPreferenceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFullTextFilterNoStopwordRemoval\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UserPreferenceTest\:\:\$userSPIPreferenceHandler \(Ibexa\\Contracts\\Core\\Persistence\\UserPreference\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept PHPUnit\\Framework\\MockObject\\MockObject\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UserPreferenceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFullTextFilterStopwordRemoval\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to an undefined method Ibexa\\Contracts\\Core\\Persistence\\User\\Handler\:\:expects\(\)\.$#' + identifier: method.notFound count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UserTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testFullTextWildcardFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$array of function array_values expects array\, array\\|null given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/Service/Mock/UserTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testLanguageCodeFilter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + message: '#^Parameter \#6 \$userHandler of method Ibexa\\Tests\\Core\\Repository\\Service\\Mock\\UserTest\:\:mockDeleteUserFlow\(\) expects Ibexa\\Contracts\\Core\\Persistence\\User\\Handler&PHPUnit\\Framework\\MockObject\\MockObject, Ibexa\\Contracts\\Core\\Persistence\\User\\Handler given\.$#' + identifier: argument.type + count: 2 + path: tests/lib/Repository/Service/Mock/UserTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testLanguageCodeFilterIn\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to an undefined method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:addWarning\(\)\.$#' + identifier: method.notFound count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testLanguageCodeFilterWithAlwaysAvailable\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + message: '#^Call to method expects\(\) on an unknown class object\.$#' + identifier: class.notFound + count: 4 + path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testLocationIdFilter\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:getAPIServiceClassName\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testLocationRemoteIdFilter\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:getSiteAccessAwareServiceClassName\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testObjectStateIdFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:providerForLanguagesLookupMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testObjectStateIdFilterIn\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:providerForPassTroughMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testParentLocationIdFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:setLanguagesLookupArguments\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testRemoteIdFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:setLanguagesLookupArguments\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testSectionFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:setLanguagesLookupExpectedArguments\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testStatusFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:setLanguagesLookupExpectedArguments\(\) has parameter \$languages with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testUserMetadataFilterCreatorEqAMember\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:setLanguagesLookupExpectedArguments\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testUserMetadataFilterCreatorInAMember\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:setLanguagesPassTroughArguments\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testUserMetadataFilterEqGroupMember\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:setLanguagesPassTroughArguments\(\) has parameter \$languages with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testUserMetadataFilterEqGroupMemberNoMatch\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:setLanguagesPassTroughArguments\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testUserMetadataFilterInGroupMember\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:testForPassTrough\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testUserMetadataFilterInGroupMemberNoMatch\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + message: '#^Method PHPUnit\\Framework\\MockObject\\Builder\\InvocationMocker\:\:with\(\) invoked with unpacked array with possibly string key, but it''s not allowed because of @no\-named\-arguments\.$#' + identifier: argument.named + count: 4 + path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testUserMetadataFilterOwnerAdministrator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:\$innerApiServiceMock \(object&PHPUnit\\Framework\\MockObject\\MockObject\) does not accept PHPUnit\\Framework\\MockObject\\MockObject\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testUserMetadataFilterOwnerEqAMember\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\AbstractServiceTestCase\:\:\$innerApiServiceMock has unknown class object as its type\.$#' + identifier: class.notFound count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testUserMetadataFilterOwnerInAMember\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Unable to resolve the template type T in call to method PHPUnit\\Framework\\TestCase\:\:getMockBuilder\(\)$#' + identifier: argument.templateType count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testUserMetadataFilterOwnerWrongUserId\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\ContentServiceTest\:\:providerForLanguagesLookupMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/SiteAccessAware/ContentServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:testVisibilityFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\ContentServiceTest\:\:providerForPassTroughMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/SiteAccessAware/ContentServiceTest.php - - message: '#^Parameter \#1 \$contentTypeHandler of method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageAwareTestCase\:\:getFullTextMapper\(\) expects Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Handler, Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\Handler given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\ContentTypeServiceTest\:\:providerForLanguagesLookupMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerContentTest.php + path: tests/lib/Repository/SiteAccessAware/ContentTypeServiceTest.php - - message: '#^Class Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\SortClause\\Field constructor invoked with 4 parameters, 2\-3 required\.$#' - identifier: arguments.count + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\ContentTypeServiceTest\:\:providerForPassTroughMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/ContentTypeServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:getIds\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\Language\\LanguageResolverTest\:\:getDataForTestGetPrioritizedLanguages\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/Language/LanguageResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:getIds\(\) has parameter \$searchResult with no type specified\.$#' - identifier: missingType.parameter + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\Language\\LanguageResolverTest\:\:testGetPrioritizedLanguages\(\) has parameter \$configLanguages with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/Language/LanguageResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:testNoSorting\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\Language\\LanguageResolverTest\:\:testGetPrioritizedLanguages\(\) has parameter \$expectedPrioritizedLanguagesList with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/Language/LanguageResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:testSortContentId\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\Language\\LanguageResolverTest\:\:testGetPrioritizedLanguages\(\) has parameter \$forcedLanguages with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/Language/LanguageResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:testSortContentName\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\LanguageServiceTest\:\:providerForPassTroughMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/LanguageServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:testSortDateModified\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\LocationServiceTest\:\:providerForLanguagesLookupMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:testSortDatePublished\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\LocationServiceTest\:\:providerForPassTroughMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/LocationServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:testSortFieldNumeric\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\ObjectStateServiceTest\:\:providerForLanguagesLookupMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:testSortFieldText\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\ObjectStateServiceTest\:\:providerForPassTroughMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/ObjectStateServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:testSortIsMainLocationAscending\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\SearchServiceTest\:\:providerForLanguagesLookupMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:testSortIsMainLocationDescending\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\SearchServiceTest\:\:providerForPassTroughMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:testSortLocationDepth\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\SearchServiceTest\:\:setLanguagesLookupArguments\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:testSortLocationDepthAndPath\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\SearchServiceTest\:\:setLanguagesLookupArguments\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:testSortLocationId\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\SearchServiceTest\:\:setLanguagesLookupExpectedArguments\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:testSortLocationPath\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\SearchServiceTest\:\:setLanguagesLookupExpectedArguments\(\) has parameter \$languages with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:testSortLocationPriority\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\SearchServiceTest\:\:setLanguagesLookupExpectedArguments\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:testSortLocationVisibilityAscending\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\SearchServiceTest\:\:setLanguagesPassTroughArguments\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:testSortLocationVisibilityDescending\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\SearchServiceTest\:\:setLanguagesPassTroughArguments\(\) has parameter \$languages with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:testSortSectionIdentifier\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\SearchServiceTest\:\:setLanguagesPassTroughArguments\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:testSortSectionName\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + message: '#^Undefined variable\: \$this$#' + identifier: variable.undefined + count: 2 + path: tests/lib/Repository/SiteAccessAware/SearchServiceTest.php - - message: '#^Parameter \#1 \$contentTypeHandler of method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageAwareTestCase\:\:getFullTextMapper\(\) expects Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Handler, Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\Handler given\.$#' - identifier: argument.type + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\TrashServiceTest\:\:providerForPassTroughMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/TrashServiceTest.php - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\UrlAliasServiceTest\:\:providerForLanguagesLookupMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php + path: tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:getContentSearchHandler\(\) has parameter \$fullTextSearchConfiguration with no value type specified in iterable type array\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\UrlAliasServiceTest\:\:providerForPassTroughMethods\(\) return type has no value type specified in iterable type array\.$#' identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testContentDepthFilterBetween\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\UrlAliasServiceTest\:\:setLanguagesLookupExpectedArguments\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testContentDepthFilterEq\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\UrlAliasServiceTest\:\:setLanguagesLookupExpectedArguments\(\) has parameter \$languages with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testContentDepthFilterGreaterThan\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\UrlAliasServiceTest\:\:setLanguagesLookupExpectedArguments\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testContentDepthFilterGreaterThanOrEqual\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\UrlAliasServiceTest\:\:setLanguagesPassTroughArguments\(\) has parameter \$arguments with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testContentDepthFilterIn\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\UrlAliasServiceTest\:\:setLanguagesPassTroughArguments\(\) has parameter \$languages with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testContentDepthFilterLessThan\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\UrlAliasServiceTest\:\:setLanguagesPassTroughArguments\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testContentDepthFilterLessThanOrEqual\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + message: '#^Undefined variable\: \$this$#' + identifier: variable.undefined + count: 2 + path: tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testContentIdFilterEquals\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\UserServiceTest\:\:providerForLanguagesLookupMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/SiteAccessAware/UserServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testContentIdFilterIn\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\SiteAccessAware\\UserServiceTest\:\:providerForPassTroughMethods\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/SiteAccessAware/UserServiceTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testContentTypeGroupFilter\(\) has no return type specified\.$#' - identifier: missingType.return - count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + message: '#^Call to method expects\(\) on an unknown class PHPUnit_Framework_MockObject_MockObject\.$#' + identifier: class.notFound + count: 2 + path: tests/lib/Repository/Validator/TargetContentValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testContentTypeIdFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to method method\(\) on an unknown class PHPUnit_Framework_MockObject_MockObject\.$#' + identifier: class.notFound count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Validator/TargetContentValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testContentTypeIdentifierFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Validator\\TargetContentValidatorTest\:\:\$contentHandler \(Ibexa\\Contracts\\Core\\Persistence\\Content\\Handler&PHPUnit_Framework_MockObject_MockObject\) does not accept Ibexa\\Contracts\\Core\\Persistence\\Content\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Validator/TargetContentValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testDateMetadataFilterCreatedBetween\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Validator\\TargetContentValidatorTest\:\:\$contentHandler has unknown class PHPUnit_Framework_MockObject_MockObject as its type\.$#' + identifier: class.notFound count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Validator/TargetContentValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testDateMetadataFilterModifiedBetween\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Validator\\TargetContentValidatorTest\:\:\$contentTypeHandler \(Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\Handler&PHPUnit_Framework_MockObject_MockObject\) does not accept Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\.$#' + identifier: assign.propertyType count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Validator/TargetContentValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testDateMetadataFilterModifiedGreater\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Repository\\Validator\\TargetContentValidatorTest\:\:\$contentTypeHandler has unknown class PHPUnit_Framework_MockObject_MockObject as its type\.$#' + identifier: class.notFound count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Validator/TargetContentValidatorTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testDateMetadataFilterModifiedGreaterOrEqual\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\LanguageTest\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/Content/LanguageTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testDateMetadataFilterModifiedIn\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertTrue\(\) with true will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/Content/LocationTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFieldFilter\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\LocationTest\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/Content/LocationTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFieldFilterBetween\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\:\:\$id \(int\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/Content/LocationTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFieldFilterContainsPartial\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\Query\\Criterion\\DateMetadataTest\:\:testConstruction\(\) has parameter \$value with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/Content/Query/Criterion/DateMetadataTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFieldFilterContainsSimple\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertTrue\(\) with true will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/Content/SectionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFieldFilterContainsSimpleNoMatch\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\SectionTest\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/Content/SectionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFieldFilterIn\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Section\:\:\$id \(int\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/Content/SectionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFieldFilterOr\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertTrue\(\) with true will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/Content/TrashItemTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFieldRelationFilterContainsArray\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Content\\TrashItemTest\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/Content/TrashItemTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFieldRelationFilterContainsArrayNotMatch\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Location\:\:\$id \(int\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/Content/TrashItemTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFieldRelationFilterContainsSingle\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ContentType\\FieldDefinitionCollectionTest\:\:createFieldDefinitions\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/ContentType/FieldDefinitionCollectionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFieldRelationFilterContainsSingleNoMatch\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ContentType\\FieldDefinitionCollectionTest\:\:createFieldDefinitionsWith\(\) has parameter \$values with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/ContentType/FieldDefinitionCollectionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFieldRelationFilterInArray\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ContentType\\FieldDefinitionCollectionTest\:\:createFieldDefinitionsWith\(\) return type has no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/ContentType/FieldDefinitionCollectionTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFieldRelationFilterInArrayNotMatch\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Filter\\FilterTest\:\:getComplexFilterTestData\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/Filter/FilterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFindWithOffsetToNonexistent\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Filter\\FilterTest\:\:getFilters\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/Filter/FilterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFindWithZeroLimit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Filter\\FilterTest\:\:getFiltersWithInvalidSliceData\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/Filter/FilterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFindWithoutOffsetLimit\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Filter\\FilterTest\:\:getInvalidSortClausesData\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/Filter/FilterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFullTextDisabledWildcardFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\Filter\\FilterTest\:\:testConstructorThrowsBadStateException\(\) has parameter \$sortClauses with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/Filter/FilterTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFullTextFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Call to static method PHPUnit\\Framework\\Assert\:\:assertTrue\(\) with true will always evaluate to true\.$#' + identifier: staticMethod.alreadyNarrowedType count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/ObjectState/ObjectStateGroupTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFullTextFilterInvalidStopwordThreshold\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateGroupTest\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/ObjectState/ObjectStateGroupTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFullTextFilterNoStopwordRemoval\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Core\\Repository\\Values\\ObjectState\\ObjectStateGroup\:\:\$defaultLanguageCode \(string\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/ObjectState/ObjectStateGroupTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFullTextFilterStopwordRemoval\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\ObjectState\\ObjectStateTest\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/ObjectState/ObjectStateTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testFullTextWildcardFilter\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\User\\PolicyTest\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/User/PolicyTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testIsMainLocationFilter\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\User\\RoleTest\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/User/RoleTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testIsNotMainLocationFilter\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\User\\UserGroupTest\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/User/UserGroupTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testLanguageCodeFilter\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Repository\\Values\\User\\UserTest\:\:assertPropertiesCorrect\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Repository/Values/User/UserTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testLanguageCodeFilterIn\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Search\\Common\\FieldValueMapper\\RemoteIdentifierMapperTest\:\:getDataForTestCanMap\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Common/FieldValueMapper/RemoteIdentifierMapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testLanguageCodeFilterWithAlwaysAvailable\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Search\\Common\\FieldValueMapper\\RemoteIdentifierMapperTest\:\:getDataForTestMap\(\) return type has no value type specified in iterable type iterable\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Common/FieldValueMapper/RemoteIdentifierMapperTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testLocationIdAndCombinatorFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:getMockedFieldNameResolver\(\) has parameter \$methods with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/FieldNameResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testLocationIdFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:\$contentTypeHandlerMock \(Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\Handler&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/FieldNameResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testLocationIdParentLocationIdAndCombinatorFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:\$fieldNameGeneratorMock \(Ibexa\\Core\\Search\\Common\\FieldNameGenerator&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/FieldNameResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testLocationNotCombinatorFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Search\\FieldNameResolverTest\:\:\$fieldRegistryMock \(Ibexa\\Core\\Search\\Common\\FieldRegistry&PHPUnit\\Framework\\MockObject\\MockObject\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/FieldNameResolverTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testLocationOrCombinatorFilter\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\AbstractTestCase\:\:assertSearchResults\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Legacy/Content/AbstractTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testLocationPriorityFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\AbstractTestCase\:\:assertSearchResults\(\) has parameter \$expectedIds with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Legacy/Content/AbstractTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testLocationRemoteIdFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\AbstractTestCase\:\:assertSearchResults\(\) has parameter \$searchResult with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Legacy/Content/AbstractTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testMatchAllFilter\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\AbstractTestCase\:\:getConverterRegistry\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Legacy/Content/AbstractTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testObjectStateIdFilter\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\AbstractTestCase\:\:getIds\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Legacy/Content/AbstractTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testObjectStateIdFilterIn\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\AbstractTestCase\:\:getIds\(\) has parameter \$searchResult with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Legacy/Content/AbstractTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testParentLocationIdFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\AbstractTestCase\:\:\$contentTypeHandler \(Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\Handler\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Legacy/Content/AbstractTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testRemoteIdFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\AbstractTestCase\:\:\$converterRegistry \(Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldValue\\ConverterRegistry\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Legacy/Content/AbstractTestCase.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testSectionFilter\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Class Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\SortClause\\Field constructor invoked with 4 parameters, 2\-3 required\.$#' + identifier: arguments.count count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Legacy/Content/HandlerContentSortTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testUserMetadataFilterCreatorEqAMember\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentSortTest\:\:getContentSearchHandler\(\) has parameter \$fullTextSearchConfiguration with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Legacy/Content/HandlerContentSortTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testUserMetadataFilterCreatorInAMember\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$contentTypeHandler of method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageAwareTestCase\:\:getFullTextMapper\(\) expects Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Handler, Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\Handler given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Legacy/Content/HandlerContentSortTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testUserMetadataFilterEqGroupMember\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Property Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentSortTest\:\:\$fieldRegistry \(Ibexa\\Core\\Persistence\\Legacy\\Content\\FieldValue\\ConverterRegistry\) in isset\(\) is not nullable\.$#' + identifier: isset.property count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Legacy/Content/HandlerContentSortTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testUserMetadataFilterEqGroupMemberNoMatch\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Unreachable statement \- code above always terminates\.$#' + identifier: deadCode.unreachable count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Legacy/Content/HandlerContentSortTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testUserMetadataFilterInGroupMember\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerContentTest\:\:getContentSearchHandler\(\) has parameter \$fullTextSearchConfiguration with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Legacy/Content/HandlerContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testUserMetadataFilterInGroupMemberNoMatch\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$contentTypeHandler of method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageAwareTestCase\:\:getFullTextMapper\(\) expects Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Handler, Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\Handler given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Legacy/Content/HandlerContentTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testUserMetadataFilterOwnerAdministrator\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Class Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\SortClause\\Field constructor invoked with 4 parameters, 2\-3 required\.$#' + identifier: arguments.count count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testUserMetadataFilterOwnerEqAMember\(\) has no return type specified\.$#' + message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:getIds\(\) has no return type specified\.$#' identifier: missingType.return count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testUserMetadataFilterOwnerInAMember\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationSortTest\:\:getIds\(\) has parameter \$searchResult with no type specified\.$#' + identifier: missingType.parameter count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testUserMetadataFilterOwnerWrongUserId\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Parameter \#1 \$contentTypeHandler of method Ibexa\\Tests\\Core\\Persistence\\Legacy\\Content\\LanguageAwareTestCase\:\:getFullTextMapper\(\) expects Ibexa\\Core\\Persistence\\Legacy\\Content\\Type\\Handler, Ibexa\\Contracts\\Core\\Persistence\\Content\\Type\\Handler given\.$#' + identifier: argument.type count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testVisibilityFilterHidden\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Unreachable statement \- code above always terminates\.$#' + identifier: deadCode.unreachable count: 1 - path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php + path: tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php - - message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:testVisibilityFilterVisible\(\) has no return type specified\.$#' - identifier: missingType.return + message: '#^Method Ibexa\\Tests\\Core\\Search\\Legacy\\Content\\HandlerLocationTest\:\:getContentSearchHandler\(\) has parameter \$fullTextSearchConfiguration with no value type specified in iterable type array\.$#' + identifier: missingType.iterableValue count: 1 path: tests/lib/Search/Legacy/Content/HandlerLocationTest.php diff --git a/phpunit-integration-legacy-solr.xml b/phpunit-integration-legacy-solr.xml index fd22dd1b03..750f1b1199 100644 --- a/phpunit-integration-legacy-solr.xml +++ b/phpunit-integration-legacy-solr.xml @@ -1,10 +1,5 @@ - - - - tests/integration - - + @@ -43,4 +38,9 @@ tests/integration/Core/Repository/KeywordFieldCriterionTest.php + + + tests/integration + + diff --git a/phpunit-integration-legacy.xml b/phpunit-integration-legacy.xml index e90e63df74..15e6394eb9 100644 --- a/phpunit-integration-legacy.xml +++ b/phpunit-integration-legacy.xml @@ -1,10 +1,5 @@ - - - - tests/integration - - + @@ -53,4 +48,9 @@ tests/integration/RepositoryInstaller + + + tests/integration + + diff --git a/phpunit-integration.xml b/phpunit-integration.xml index 5f8c3cc801..6da6168244 100644 --- a/phpunit-integration.xml +++ b/phpunit-integration.xml @@ -1,46 +1,37 @@ - - - - - - - - - - - - tests/integration/Core/BasicKernelTest.php - tests/integration/Core/Repository/SerializationTest.php - tests/integration/Core/Repository/ContentTypeService/FindContentTypesTest.php - tests/integration/Core/Repository/ContentService/CopyNonTranslatableFieldsFromPublishedVersionTest.php - tests/integration/Core/Persistence/Legacy/BookmarkHandlerTest.php - tests/integration/Core/Repository/ContentService/CopyTranslationsFromPublishedVersionTest.php - tests/integration/Core/Repository/ContentService/CreateContentInNonContainerTest.php - tests/integration/Core/Repository/URLAliasService/UrlAliasLookupTest.php - tests/integration/Core/Repository/ContentService/ContentUpdateAfterAddingFieldDefinitionTest.php - tests/integration/Core/Repository/ContentService/UpdateContentTest.php - tests/integration/Core/Repository/ContentService/ImageAssetTest.php - tests/integration/Core/Repository/ContentService/LoadVersionInfoTest.php - tests/integration/Core/Repository/ContentService/DeleteContentTest.php - tests/integration/Core/Repository/ContentService/MaxLanguagesContentServiceTest.php - tests/integration/Core/Repository/SearchServiceBookmarkTest.php - tests/integration/Core/Repository/SearchServiceContentNameTest.php - tests/integration/Core/Repository/SearchServiceImageTest.php - tests/integration/Core/Repository/Filtering/LegacyContentFilteringTest.php - tests/integration/Core/Repository/KeywordFieldCriterionTest.php - - - - - + + + + + + + + + + + + tests/integration/Core/BasicKernelTest.php + tests/integration/Core/Repository/SerializationTest.php + tests/integration/Core/Repository/ContentTypeService/FindContentTypesTest.php + tests/integration/Core/Repository/ContentService/CopyNonTranslatableFieldsFromPublishedVersionTest.php + tests/integration/Core/Persistence/Legacy/BookmarkHandlerTest.php + tests/integration/Core/Repository/ContentService/CopyTranslationsFromPublishedVersionTest.php + tests/integration/Core/Repository/ContentService/CreateContentInNonContainerTest.php + tests/integration/Core/Repository/URLAliasService/UrlAliasLookupTest.php + tests/integration/Core/Repository/ContentService/ContentUpdateAfterAddingFieldDefinitionTest.php + tests/integration/Core/Repository/ContentService/UpdateContentTest.php + tests/integration/Core/Repository/ContentService/ImageAssetTest.php + tests/integration/Core/Repository/ContentService/LoadVersionInfoTest.php + tests/integration/Core/Repository/ContentService/DeleteContentTest.php + tests/integration/Core/Repository/ContentService/MaxLanguagesContentServiceTest.php + tests/integration/Core/Repository/SearchServiceBookmarkTest.php + tests/integration/Core/Repository/SearchServiceContentNameTest.php + tests/integration/Core/Repository/SearchServiceImageTest.php + tests/integration/Core/Repository/Filtering/LegacyContentFilteringTest.php + tests/integration/Core/Repository/KeywordFieldCriterionTest.php + + + + + + diff --git a/phpunit.xml b/phpunit.xml index 9bbf6c9b6d..8d982c6a79 100644 --- a/phpunit.xml +++ b/phpunit.xml @@ -1,15 +1,7 @@ - + + - + @@ -32,7 +24,7 @@ tests/bundle/LegacySearchEngine - - - + + + diff --git a/tests/bundle/Core/ApiLoader/CacheFactoryTest.php b/tests/bundle/Core/ApiLoader/CacheFactoryTest.php index 40918937fb..42c6145662 100644 --- a/tests/bundle/Core/ApiLoader/CacheFactoryTest.php +++ b/tests/bundle/Core/ApiLoader/CacheFactoryTest.php @@ -10,6 +10,7 @@ use Ibexa\Bundle\Core\ApiLoader\CacheFactory; use Ibexa\Contracts\Core\SiteAccess\ConfigResolverInterface; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; use Symfony\Component\Cache\Adapter\AdapterInterface; @@ -32,7 +33,7 @@ protected function setUp(): void /** * @return array */ - public function providerGetService(): array + public static function providerGetService(): array { return [ ['default', 'default'], @@ -41,9 +42,7 @@ public function providerGetService(): array ]; } - /** - * @dataProvider providerGetService - */ + #[DataProvider('providerGetService')] public function testGetService($name, $expected): void { $this->configResolver @@ -56,7 +55,7 @@ public function testGetService($name, $expected): void ->expects(self::once()) ->method('get') ->with($expected) - ->will(self::returnValue($this->createMock(AdapterInterface::class))); + ->will(self::returnValue(self::createStub(AdapterInterface::class))); $factory = new CacheFactory($this->container); diff --git a/tests/bundle/Core/ApiLoader/RepositoryConfigurationProviderTest.php b/tests/bundle/Core/ApiLoader/RepositoryConfigurationProviderTest.php index 29377eea48..305f9ecf09 100644 --- a/tests/bundle/Core/ApiLoader/RepositoryConfigurationProviderTest.php +++ b/tests/bundle/Core/ApiLoader/RepositoryConfigurationProviderTest.php @@ -11,13 +11,14 @@ use Ibexa\Bundle\Core\ApiLoader\Exception\InvalidRepositoryException; use Ibexa\Contracts\Core\SiteAccess\ConfigResolverInterface; use Ibexa\Core\Base\Container\ApiLoader\RepositoryConfigurationProvider; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\MockObject\MockObject; /** - * @covers \Ibexa\Core\Base\Container\ApiLoader\RepositoryConfigurationProvider - * * @phpstan-import-type TRepositoryListConfiguration from \Ibexa\Core\Base\Container\ApiLoader\RepositoryConfigurationProvider */ +#[CoversClass(RepositoryConfigurationProvider::class)] final class RepositoryConfigurationProviderTest extends BaseRepositoryConfigurationProviderTestCase { /** @@ -61,12 +62,11 @@ public function testGetRepositoryConfigNotSpecifiedRepository(): void } /** - * @dataProvider providerForRepositories - * * @phpstan-param TRepositoryListConfiguration $repositories * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ + #[DataProvider('providerForRepositories')] public function testGetRepositoryConfigUndefinedRepository(array $repositories): void { $this->expectException(InvalidRepositoryException::class); @@ -83,12 +83,11 @@ public function testGetRepositoryConfigUndefinedRepository(array $repositories): } /** - * @dataProvider providerForRepositories - * * @phpstan-param TRepositoryListConfiguration $repositories * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ + #[DataProvider('providerForRepositories')] public function testGetDefaultRepositoryAlias(array $repositories): void { $configResolver = $this->getConfigResolverMock(); @@ -100,10 +99,9 @@ public function testGetDefaultRepositoryAlias(array $repositories): void } /** - * @dataProvider providerForRepositories - * * @phpstan-param TRepositoryListConfiguration $repositories */ + #[DataProvider('providerForRepositories')] public function testGetCurrentRepositoryAlias(array $repositories): void { $configResolver = $this->getConfigResolverMock(); @@ -117,7 +115,7 @@ public function testGetCurrentRepositoryAlias(array $repositories): void /** * @phpstan-return list> $repositories */ - public function providerForRepositories(): array + public static function providerForRepositories(): array { return [ [self::REPOSITORIES_CONFIG], diff --git a/tests/bundle/Core/ApiLoader/StorageConnectionFactoryTest.php b/tests/bundle/Core/ApiLoader/StorageConnectionFactoryTest.php index b3b14a61a3..4bd6db85f9 100644 --- a/tests/bundle/Core/ApiLoader/StorageConnectionFactoryTest.php +++ b/tests/bundle/Core/ApiLoader/StorageConnectionFactoryTest.php @@ -14,15 +14,14 @@ use Ibexa\Contracts\Core\Container\ApiLoader\RepositoryConfigurationProviderInterface; use Ibexa\Contracts\Core\SiteAccess\ConfigResolverInterface; use Ibexa\Core\Base\Container\ApiLoader\RepositoryConfigurationProvider; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\MockObject\MockObject; use Symfony\Component\DependencyInjection\ContainerInterface; use Symfony\Component\DependencyInjection\ServiceLocator; final class StorageConnectionFactoryTest extends BaseRepositoryConfigurationProviderTestCase { - /** - * @dataProvider getConnectionProvider - */ + #[DataProvider('getConnectionProvider')] public function testGetConnection(string $repositoryAlias, string $doctrineConnection): void { $repositories = [ @@ -143,7 +142,7 @@ private function buildStorageConnectionFactory( ; $serviceLocatorMock->method('getProvidedServices')->willReturn($doctrineConnections); if (isset($doctrineConnections[$connectionName])) { - $serviceLocatorMock->method('get')->with($connectionName)->willReturn($this->createMock(Connection::class)); + $serviceLocatorMock->method('get')->with($connectionName)->willReturn(self::createStub(Connection::class)); } else { $serviceLocatorMock->expects(self::never())->method('get'); } diff --git a/tests/bundle/Core/ApiLoader/StorageEngineFactoryTest.php b/tests/bundle/Core/ApiLoader/StorageEngineFactoryTest.php index cdc606e79a..5a8dcd9a0e 100644 --- a/tests/bundle/Core/ApiLoader/StorageEngineFactoryTest.php +++ b/tests/bundle/Core/ApiLoader/StorageEngineFactoryTest.php @@ -19,7 +19,7 @@ final class StorageEngineFactoryTest extends BaseRepositoryConfigurationProvider { public function testRegisterStorageEngine(): void { - $repositoryConfigurationProvider = $this->createMock(RepositoryConfigurationProviderInterface::class); + $repositoryConfigurationProvider = self::createStub(RepositoryConfigurationProviderInterface::class); $factory = new StorageEngineFactory($repositoryConfigurationProvider); $storageEngines = [ diff --git a/tests/bundle/Core/ChainConfigResolverTest.php b/tests/bundle/Core/ChainConfigResolverTest.php index 0c46cedae0..70a99fff10 100644 --- a/tests/bundle/Core/ChainConfigResolverTest.php +++ b/tests/bundle/Core/ChainConfigResolverTest.php @@ -10,11 +10,11 @@ use Ibexa\Bundle\Core\DependencyInjection\Configuration\ChainConfigResolver; use Ibexa\Contracts\Core\SiteAccess\ConfigResolverInterface; use Ibexa\Core\MVC\Exception\ParameterNotFoundException; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Bundle\Core\DependencyInjection\Configuration\ChainConfigResolver - */ +#[CoversClass(ChainConfigResolver::class)] class ChainConfigResolverTest extends TestCase { /** @var \Ibexa\Bundle\Core\DependencyInjection\Configuration\ChainConfigResolver */ @@ -25,7 +25,7 @@ protected function setUp(): void $this->chainResolver = new ChainConfigResolver(); } - public function testPriority() + public function testPriority(): void { self::assertEquals([], $this->chainResolver->getAllResolvers()); @@ -47,7 +47,7 @@ public function testPriority() * Resolvers are supposed to be sorted only once. * This test will check that by trying to get all resolvers several times. */ - public function testSortResolvers() + public function testSortResolvers(): void { list($low, $medium, $high) = $this->createResolverMocks(); // We're using a mock here and not $this->chainResolver because we need to ensure that the sorting operation is done only once. @@ -77,7 +77,7 @@ public function testSortResolvers() /** * This test ensures that if a resolver is being added on the fly, the sorting is reset. */ - public function testReSortResolvers() + public function testReSortResolvers(): void { list($low, $medium, $high) = $this->createResolverMocks(); $highest = clone $high; @@ -86,22 +86,13 @@ public function testReSortResolvers() ChainConfigResolver::class, ['sortResolvers'] ); - $resolver - ->expects(self::at(0)) - ->method('sortResolvers') - ->will( - self::returnValue( - [$high, $medium, $low] - ) - ); // The second time sortResolvers() is called, we're supposed to get the newly added router ($highest) $resolver - ->expects(self::at(1)) + ->expects(self::exactly(2)) ->method('sortResolvers') - ->will( - self::returnValue( - [$highest, $high, $medium, $low] - ) + ->willReturnOnConsecutiveCalls( + [$high, $medium, $low], + [$highest, $high, $medium, $low] ); $resolver->addResolver($low, 10); @@ -120,14 +111,14 @@ public function testReSortResolvers() ); } - public function testGetDefaultNamespace() + public function testGetDefaultNamespace(): void { $this->expectException(\LogicException::class); $this->chainResolver->getDefaultNamespace(); } - public function testSetDefaultNamespace() + public function testSetDefaultNamespace(): void { $namespace = 'foo'; foreach ($this->createResolverMocks() as $i => $resolver) { @@ -141,7 +132,7 @@ public function testSetDefaultNamespace() $this->chainResolver->setDefaultNamespace($namespace); } - public function testGetParameterInvalid() + public function testGetParameterInvalid(): void { $this->expectException(ParameterNotFoundException::class); @@ -161,14 +152,13 @@ public function testGetParameterInvalid() } /** - * @dataProvider getParameterProvider - * * @param string $paramName * @param string $namespace * @param string $scope * @param mixed $expectedValue */ - public function testGetParameter($paramName, $namespace, $scope, $expectedValue) + #[DataProvider('getParameterProvider')] + public function testGetParameter($paramName, $namespace, $scope, $expectedValue): void { $resolver = $this->createMock(ConfigResolverInterface::class); $resolver @@ -181,7 +171,10 @@ public function testGetParameter($paramName, $namespace, $scope, $expectedValue) self::assertSame($expectedValue, $this->chainResolver->getParameter($paramName, $namespace, $scope)); } - public function getParameterProvider() + /** + * @return array + */ + public static function getParameterProvider(): array { return [ ['foo', 'namespace', 'scope', 'someValue'], @@ -191,7 +184,7 @@ public function getParameterProvider() ]; } - public function testHasParameterTrue() + public function testHasParameterTrue(): void { $paramName = 'foo'; $namespace = 'yetAnotherNamespace'; @@ -222,7 +215,7 @@ public function testHasParameterTrue() self::assertTrue($this->chainResolver->hasParameter($paramName, $namespace, $scope)); } - public function testHasParameterFalse() + public function testHasParameterFalse(): void { $paramName = 'foo'; $namespace = 'yetAnotherNamespace'; @@ -245,18 +238,21 @@ public function testHasParameterFalse() private function createResolverMocks() { return [ - $this->createMock(ConfigResolverInterface::class), - $this->createMock(ConfigResolverInterface::class), - $this->createMock(ConfigResolverInterface::class), + self::createStub(ConfigResolverInterface::class), + self::createStub(ConfigResolverInterface::class), + self::createStub(ConfigResolverInterface::class), ]; } private function buildMock($class, array $methods = []) { - return $this + $builder = $this ->getMockBuilder($class) - ->disableOriginalConstructor() - ->setMethods($methods) - ->getMock(); + ->disableOriginalConstructor(); + if ($methods !== []) { + $builder->onlyMethods(array_values($methods)); + } + + return $builder->getMock(); } } diff --git a/tests/bundle/Core/Command/Indexer/ContentIdList/ContentTypeInputGeneratorStrategyTest.php b/tests/bundle/Core/Command/Indexer/ContentIdList/ContentTypeInputGeneratorStrategyTest.php index 9bb6c7a39f..59b02f676d 100644 --- a/tests/bundle/Core/Command/Indexer/ContentIdList/ContentTypeInputGeneratorStrategyTest.php +++ b/tests/bundle/Core/Command/Indexer/ContentIdList/ContentTypeInputGeneratorStrategyTest.php @@ -13,21 +13,20 @@ use Ibexa\Contracts\Core\Repository\Repository; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; use Ibexa\Contracts\Core\Repository\Values\Content\ContentList; -use Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo; use Ibexa\Core\Repository\Values\Content\Content; +use Ibexa\Core\Repository\Values\Content\VersionInfo as CoreVersionInfo; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\Console\Input\InputInterface; -/** - * @covers \Ibexa\Bundle\Core\Command\Indexer\ContentIdList\ContentTypeInputGeneratorStrategy - */ +#[CoversClass(ContentTypeInputGeneratorStrategy::class)] final class ContentTypeInputGeneratorStrategyTest extends TestCase { /** - * @dataProvider getDataForTestGetGenerator - * * @param array $expectedBatches */ + #[DataProvider('getDataForTestGetGenerator')] public function testGetGenerator(ContentList $contentList, int $batchSize, array $expectedBatches): void { $contentServiceMock = $this->createMock(ContentService::class); @@ -57,10 +56,10 @@ public function testGetGenerator(ContentList $contentList, int $batchSize, array /** * @return iterable}> */ - public function getDataForTestGetGenerator(): iterable + public static function getDataForTestGetGenerator(): iterable { yield 'iteration count = 3, items = 10' => [ - $this->generateContentList(10), + self::generateContentList(10), 3, [ [1, 2, 3], @@ -71,7 +70,7 @@ public function getDataForTestGetGenerator(): iterable ]; yield 'iteration count = 6, items = 6' => [ - $this->generateContentList(6), + self::generateContentList(6), 6, [ [1, 2, 3, 4, 5, 6], @@ -79,7 +78,7 @@ public function getDataForTestGetGenerator(): iterable ]; yield 'iteration count = 2, items = 4' => [ - $this->generateContentList(4), + self::generateContentList(4), 2, [ [1, 2], @@ -88,7 +87,7 @@ public function getDataForTestGetGenerator(): iterable ]; yield 'iteration count = 10, items = 5' => [ - $this->generateContentList(5), + self::generateContentList(5), 10, [ [1, 2, 3, 4, 5], @@ -96,31 +95,28 @@ public function getDataForTestGetGenerator(): iterable ]; yield 'iteration count = 5, items = 0' => [ - $this->generateContentList(0), + self::generateContentList(0), 5, [], ]; } - private function generateContentList(int $totalCount): ContentList + private static function generateContentList(int $totalCount): ContentList { $contentItems = []; for ($i = 0; $i < $totalCount; ++$i) { - $contentItems[] = $this->createContentItemWithIdMock($i + 1); + $contentItems[] = self::createContentItemWithId($i + 1); } return new ContentList($totalCount, $contentItems); } - private function createContentItemWithIdMock(int $id): Content + private static function createContentItemWithId(int $id): Content { - $contentItem = $this->createMock(Content::class); - $contentInfoMock = $this->createMock(ContentInfo::class); - $contentInfoMock->method('getId')->willReturn($id); - $versionInfoMock = $this->createMock(VersionInfo::class); - $versionInfoMock->method('getContentInfo')->willReturn($contentInfoMock); - $contentItem->method('getVersionInfo')->willReturn($versionInfoMock); - - return $contentItem; + return new Content([ + 'versionInfo' => new CoreVersionInfo([ + 'contentInfo' => new ContentInfo(['id' => $id]), + ]), + ]); } } diff --git a/tests/bundle/Core/ControllerArgumentResolver/LocationArgumentResolverTest.php b/tests/bundle/Core/ControllerArgumentResolver/LocationArgumentResolverTest.php index d6ce209d2d..a2e3b8e319 100644 --- a/tests/bundle/Core/ControllerArgumentResolver/LocationArgumentResolverTest.php +++ b/tests/bundle/Core/ControllerArgumentResolver/LocationArgumentResolverTest.php @@ -13,13 +13,13 @@ use Ibexa\Contracts\Core\Exception\InvalidArgumentException; use Ibexa\Contracts\Core\Repository\LocationService; use Ibexa\Contracts\Core\Repository\Values\Content\Location; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpKernel\ControllerMetadata\ArgumentMetadata; -/** - * @covers \Ibexa\Bundle\Core\Converter\LocationArgumentResolver - */ +#[CoversClass(LocationArgumentResolver::class)] final class LocationArgumentResolverTest extends TestCase { private const PARAMETER_LOCATION_ID = 'locationId'; @@ -28,13 +28,10 @@ final class LocationArgumentResolverTest extends TestCase protected function setUp(): void { - $locationService = $this->createMock(LocationService::class); - $this->locationArgumentResolver = new LocationArgumentResolver($locationService); + $this->locationArgumentResolver = new LocationArgumentResolver(self::createStub(LocationService::class)); } - /** - * @dataProvider dataProviderForTestResolverForUnsupportedRequest - */ + #[DataProvider('dataProviderForTestResolverForUnsupportedRequest')] public function testResolveForUnsupportedRequest( Request $request, ArgumentMetadata $argumentMetadata @@ -58,7 +55,7 @@ public function testResolveThrowsInvalidArgumentException(): void 'locationId' => 'foo', ] ), - $this->createArgumentMetadata(Location::class) + self::createArgumentMetadata(Location::class) ); self::assertInstanceOf(Generator::class, $generator); @@ -69,8 +66,8 @@ public function testResolveThrowsInvalidArgumentException(): void public function testResolve(): void { $resolvedArgumentsGenerator = $this->locationArgumentResolver->resolve( - $this->createRequest(true, false, 1), - $this->createArgumentMetadata(Location::class) + self::createRequest(true, false, 1), + self::createArgumentMetadata(Location::class) ); self::assertInstanceOf(Generator::class, $resolvedArgumentsGenerator); @@ -91,37 +88,32 @@ public function testResolve(): void * \Symfony\Component\HttpKernel\ControllerMetadata\ArgumentMetadata * }> */ - public function dataProviderForTestResolverForUnsupportedRequest(): iterable + public static function dataProviderForTestResolverForUnsupportedRequest(): iterable { - $locationBasedArgumentMetadata = $this->createArgumentMetadata(Location::class); + $locationBasedArgumentMetadata = self::createArgumentMetadata(Location::class); yield 'Not supported - type different than Ibexa\Contracts\Core\Repository\Values\Content\Location' => [ - $this->createRequest(true, false, 1), - $this->createArgumentMetadata('foo'), + self::createRequest(true, false, 1), + self::createArgumentMetadata('foo'), ]; yield 'Not supported - locationId passed to request attributes' => [ - $this->createRequest(false, true, 1), + self::createRequest(false, true, 1), $locationBasedArgumentMetadata, ]; yield 'Not supported - locationId passed to request attributes and query' => [ - $this->createRequest(true, true, 1), + self::createRequest(true, true, 1), $locationBasedArgumentMetadata, ]; } - private function createArgumentMetadata(string $type): ArgumentMetadata + private static function createArgumentMetadata(string $type): ArgumentMetadata { - $argumentMetadata = $this->createMock(ArgumentMetadata::class); - $argumentMetadata - ->method('getType') - ->willReturn($type); - - return $argumentMetadata; + return new ArgumentMetadata('locationId', $type, false, false, null); } - private function createRequest( + private static function createRequest( bool $addToQuery, bool $addToAttributes, ?int $locationId = null diff --git a/tests/bundle/Core/DependencyInjection/Compiler/ChainConfigResolverPassTest.php b/tests/bundle/Core/DependencyInjection/Compiler/ChainConfigResolverPassTest.php index 5d79973cdd..44dfc3d7c2 100644 --- a/tests/bundle/Core/DependencyInjection/Compiler/ChainConfigResolverPassTest.php +++ b/tests/bundle/Core/DependencyInjection/Compiler/ChainConfigResolverPassTest.php @@ -10,13 +10,13 @@ use Ibexa\Bundle\Core\DependencyInjection\Compiler\ChainConfigResolverPass; use Ibexa\Bundle\Core\DependencyInjection\Configuration\ChainConfigResolver; use Matthias\SymfonyDependencyInjectionTest\PhpUnit\AbstractCompilerPassTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Definition; use Symfony\Component\DependencyInjection\Reference; -/** - * @covers \Ibexa\Bundle\Core\DependencyInjection\Compiler\ChainConfigResolverPass - */ +#[CoversClass(ChainConfigResolverPass::class)] class ChainConfigResolverPassTest extends AbstractCompilerPassTestCase { protected function setUp(): void @@ -39,10 +39,9 @@ protected function registerCompilerPass(ContainerBuilder $container): void /** * @param int|null $declaredPriority * @param int $expectedPriority - * - * @dataProvider addResolverProvider */ - public function testAddResolver($declaredPriority, $expectedPriority) + #[DataProvider('addResolverProvider')] + public function testAddResolver($declaredPriority, $expectedPriority): void { $resolverDef = new Definition(); $serviceId = 'some_service_id'; @@ -63,7 +62,10 @@ public function testAddResolver($declaredPriority, $expectedPriority) ); } - public function addResolverProvider() + /** + * @return array + */ + public static function addResolverProvider(): array { return [ [null, 0], diff --git a/tests/bundle/Core/DependencyInjection/Compiler/ChainRoutingPassTest.php b/tests/bundle/Core/DependencyInjection/Compiler/ChainRoutingPassTest.php index c557e62eb7..5116a841ce 100644 --- a/tests/bundle/Core/DependencyInjection/Compiler/ChainRoutingPassTest.php +++ b/tests/bundle/Core/DependencyInjection/Compiler/ChainRoutingPassTest.php @@ -10,13 +10,13 @@ use Ibexa\Bundle\Core\DependencyInjection\Compiler\ChainRoutingPass; use Ibexa\Core\MVC\Symfony\Routing\ChainRouter; use Matthias\SymfonyDependencyInjectionTest\PhpUnit\AbstractCompilerPassTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Definition; use Symfony\Component\DependencyInjection\Reference; -/** - * @covers \Ibexa\Bundle\Core\DependencyInjection\Compiler\ChainRoutingPass - */ +#[CoversClass(ChainRoutingPass::class)] class ChainRoutingPassTest extends AbstractCompilerPassTestCase { protected function setUp(): void @@ -39,10 +39,9 @@ protected function registerCompilerPass(ContainerBuilder $container): void /** * @param int|null $declaredPriority * @param int $expectedPriority - * - * @dataProvider addRouterProvider */ - public function testAddRouter($declaredPriority, $expectedPriority) + #[DataProvider('addRouterProvider')] + public function testAddRouter($declaredPriority, $expectedPriority): void { $resolverDef = new Definition(); $serviceId = 'some_service_id'; @@ -65,10 +64,9 @@ public function testAddRouter($declaredPriority, $expectedPriority) /** * @param int|null $declaredPriority * @param int $expectedPriority - * - * @dataProvider addRouterProvider */ - public function testAddRouterWithDefaultRouter($declaredPriority, $expectedPriority) + #[DataProvider('addRouterProvider')] + public function testAddRouterWithDefaultRouter($declaredPriority, $expectedPriority): void { $defaultRouter = new Definition(); $this->setDefinition('router.default', $defaultRouter); @@ -100,7 +98,10 @@ public function testAddRouterWithDefaultRouter($declaredPriority, $expectedPrior ); } - public function addRouterProvider() + /** + * @return array + */ + public static function addRouterProvider(): array { return [ [null, 0], diff --git a/tests/bundle/Core/DependencyInjection/Compiler/FieldTypeParameterProviderRegistryPassTest.php b/tests/bundle/Core/DependencyInjection/Compiler/FieldTypeParameterProviderRegistryPassTest.php index 9e19239e81..a85c7f1324 100644 --- a/tests/bundle/Core/DependencyInjection/Compiler/FieldTypeParameterProviderRegistryPassTest.php +++ b/tests/bundle/Core/DependencyInjection/Compiler/FieldTypeParameterProviderRegistryPassTest.php @@ -10,6 +10,7 @@ use Ibexa\Bundle\Core\DependencyInjection\Compiler\FieldTypeParameterProviderRegistryPass; use Ibexa\Core\MVC\Symfony\FieldType\View\ParameterProviderRegistry; use Matthias\SymfonyDependencyInjectionTest\PhpUnit\AbstractCompilerPassTestCase; +use PHPUnit\Framework\Attributes\DataProvider; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Definition; use Symfony\Component\DependencyInjection\Reference; @@ -33,10 +34,8 @@ protected function registerCompilerPass(ContainerBuilder $container): void $container->addCompilerPass(new FieldTypeParameterProviderRegistryPass()); } - /** - * @dataProvider tagsProvider - */ - public function testRegisterFieldType(string $tag) + #[DataProvider('tagsProvider')] + public function testRegisterFieldType(string $tag): void { $fieldTypeIdentifier = 'field_type_identifier'; $serviceId = 'service_id'; @@ -54,11 +53,10 @@ public function testRegisterFieldType(string $tag) } /** - * @dataProvider tagsProvider - * * @param string $tag */ - public function testRegisterFieldTypeNoAlias(string $tag) + #[DataProvider('tagsProvider')] + public function testRegisterFieldTypeNoAlias(string $tag): void { $this->expectException(\LogicException::class); @@ -77,7 +75,7 @@ public function testRegisterFieldTypeNoAlias(string $tag) ); } - public function tagsProvider(): array + public static function tagsProvider(): array { return [ [FieldTypeParameterProviderRegistryPass::FIELD_TYPE_PARAMETER_PROVIDER_SERVICE_TAG], diff --git a/tests/bundle/Core/DependencyInjection/Compiler/FragmentPassTest.php b/tests/bundle/Core/DependencyInjection/Compiler/FragmentPassTest.php index 6616520948..72c78331d0 100644 --- a/tests/bundle/Core/DependencyInjection/Compiler/FragmentPassTest.php +++ b/tests/bundle/Core/DependencyInjection/Compiler/FragmentPassTest.php @@ -24,7 +24,7 @@ protected function registerCompilerPass(ContainerBuilder $container): void $container->addCompilerPass(new FragmentPass()); } - public function testProcess() + public function testProcess(): void { $inlineRendererDef = new Definition(InlineFragmentRenderer::class); $inlineRendererDef->addTag('kernel.fragment_renderer'); diff --git a/tests/bundle/Core/DependencyInjection/Compiler/NotificationRendererPassTest.php b/tests/bundle/Core/DependencyInjection/Compiler/NotificationRendererPassTest.php index eb87e94e90..a230b50584 100644 --- a/tests/bundle/Core/DependencyInjection/Compiler/NotificationRendererPassTest.php +++ b/tests/bundle/Core/DependencyInjection/Compiler/NotificationRendererPassTest.php @@ -31,7 +31,7 @@ protected function registerCompilerPass(ContainerBuilder $container): void $container->addCompilerPass(new NotificationRendererPass()); } - public function testAddRenderer() + public function testAddRenderer(): void { $definition = new Definition(); $definition->addTag(NotificationRendererPass::TAG_NAME, [ @@ -48,7 +48,7 @@ public function testAddRenderer() ); } - public function testAddRendererWithoutAliasThrowsLogicException() + public function testAddRendererWithoutAliasThrowsLogicException(): void { $this->expectException(\LogicException::class); diff --git a/tests/bundle/Core/DependencyInjection/Compiler/PlaceholderProviderPassTest.php b/tests/bundle/Core/DependencyInjection/Compiler/PlaceholderProviderPassTest.php index 9c174c56bd..fad1abddc1 100644 --- a/tests/bundle/Core/DependencyInjection/Compiler/PlaceholderProviderPassTest.php +++ b/tests/bundle/Core/DependencyInjection/Compiler/PlaceholderProviderPassTest.php @@ -30,7 +30,7 @@ protected function registerCompilerPass(ContainerBuilder $container): void $container->addCompilerPass(new PlaceholderProviderPass()); } - public function testAddProvider() + public function testAddProvider(): void { $definition = new Definition(); $definition->addTag(PlaceholderProviderPass::TAG_NAME, ['type' => self::PROVIDER_TYPE]); @@ -45,7 +45,7 @@ public function testAddProvider() ); } - public function testAddProviderWithoutType() + public function testAddProviderWithoutType(): void { $this->expectException(\LogicException::class); diff --git a/tests/bundle/Core/DependencyInjection/Compiler/QueryTypePassTest.php b/tests/bundle/Core/DependencyInjection/Compiler/QueryTypePassTest.php index 3fede95012..924eacf3ed 100644 --- a/tests/bundle/Core/DependencyInjection/Compiler/QueryTypePassTest.php +++ b/tests/bundle/Core/DependencyInjection/Compiler/QueryTypePassTest.php @@ -13,6 +13,7 @@ use Ibexa\Tests\Bundle\Core\DependencyInjection\Stub\QueryTypeBundle\QueryType\TestQueryType; use Ibexa\Tests\Bundle\Core\DependencyInjection\Stub\QueryTypeBundle\QueryTypeBundle; use Matthias\SymfonyDependencyInjectionTest\PhpUnit\AbstractCompilerPassTestCase; +use PHPUnit\Framework\Attributes\DataProvider; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Definition; use Symfony\Component\DependencyInjection\Reference; @@ -31,9 +32,7 @@ protected function registerCompilerPass(ContainerBuilder $container): void $container->addCompilerPass(new QueryTypePass()); } - /** - * @dataProvider tagsProvider - */ + #[DataProvider('tagsProvider')] public function testRegisterTaggedQueryType(string $tag): void { $def = new Definition(); @@ -50,9 +49,7 @@ public function testRegisterTaggedQueryType(string $tag): void ); } - /** - * @dataProvider tagsProvider - */ + #[DataProvider('tagsProvider')] public function testRegisterTaggedQueryTypeWithClassAsParameter(string $tag): void { $this->setParameter('query_type_class', TestQueryType::class); @@ -75,9 +72,8 @@ public function testRegisterTaggedQueryTypeWithClassAsParameter(string $tag): vo * * The QueryType class will still be registered, as the aliases are different from the * built-in alias of the class. - * - * @dataProvider tagsProvider */ + #[DataProvider('tagsProvider')] public function testTaggedOverride(string $tag): void { $this->setParameter('kernel.bundles', ['QueryTypeBundle' => QueryTypeBundle::class]); @@ -107,7 +103,7 @@ public function testTaggedOverride(string $tag): void ); } - public function tagsProvider(): iterable + public static function tagsProvider(): iterable { return [ [QueryTypePass::QUERY_TYPE_SERVICE_TAG], diff --git a/tests/bundle/Core/DependencyInjection/Compiler/RegisterSearchEngineIndexerPassTest.php b/tests/bundle/Core/DependencyInjection/Compiler/RegisterSearchEngineIndexerPassTest.php index 400f175656..be53b7eb63 100644 --- a/tests/bundle/Core/DependencyInjection/Compiler/RegisterSearchEngineIndexerPassTest.php +++ b/tests/bundle/Core/DependencyInjection/Compiler/RegisterSearchEngineIndexerPassTest.php @@ -12,6 +12,7 @@ use Ibexa\Bundle\Core\DependencyInjection\Compiler\RegisterSearchEngineIndexerPass; use LogicException; use Matthias\SymfonyDependencyInjectionTest\PhpUnit\AbstractCompilerPassTestCase; +use PHPUnit\Framework\Attributes\DataProvider; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Definition; use Symfony\Component\DependencyInjection\Reference; @@ -33,9 +34,7 @@ protected function registerCompilerPass(ContainerBuilder $container): void $container->addCompilerPass(new RegisterSearchEngineIndexerPass()); } - /** - * @dataProvider tagsProvider - */ + #[DataProvider('tagsProvider')] public function testRegisterSearchEngineIndexer(string $tag): void { $definition = new Definition(); @@ -56,9 +55,7 @@ public function testRegisterSearchEngineIndexer(string $tag): void ); } - /** - * @dataProvider tagsProvider - */ + #[DataProvider('tagsProvider')] public function testRegisterSearchEngineIndexerWithoutAliasThrowsLogicException(string $tag): void { $this->expectException(LogicException::class); @@ -70,7 +67,7 @@ public function testRegisterSearchEngineIndexerWithoutAliasThrowsLogicException( $this->compile(); } - public function tagsProvider(): iterable + public static function tagsProvider(): iterable { return [ [RegisterSearchEngineIndexerPass::SEARCH_ENGINE_INDEXER_SERVICE_TAG], diff --git a/tests/bundle/Core/DependencyInjection/Compiler/RegisterSearchEnginePassTest.php b/tests/bundle/Core/DependencyInjection/Compiler/RegisterSearchEnginePassTest.php index 1b6a2a3692..160b316607 100644 --- a/tests/bundle/Core/DependencyInjection/Compiler/RegisterSearchEnginePassTest.php +++ b/tests/bundle/Core/DependencyInjection/Compiler/RegisterSearchEnginePassTest.php @@ -12,6 +12,7 @@ use Ibexa\Bundle\Core\DependencyInjection\Compiler\RegisterSearchEnginePass; use LogicException; use Matthias\SymfonyDependencyInjectionTest\PhpUnit\AbstractCompilerPassTestCase; +use PHPUnit\Framework\Attributes\DataProvider; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Definition; use Symfony\Component\DependencyInjection\Reference; @@ -33,9 +34,7 @@ protected function registerCompilerPass(ContainerBuilder $container): void $container->addCompilerPass(new RegisterSearchEnginePass()); } - /** - * @dataProvider tagsProvider - */ + #[DataProvider('tagsProvider')] public function testRegisterSearchEngine(string $tag): void { $definition = new Definition(); @@ -56,9 +55,7 @@ public function testRegisterSearchEngine(string $tag): void ); } - /** - * @dataProvider tagsProvider - */ + #[DataProvider('tagsProvider')] public function testRegisterSearchEngineWithoutAliasThrowsLogicException(string $tag): void { $this->expectException(LogicException::class); @@ -70,7 +67,7 @@ public function testRegisterSearchEngineWithoutAliasThrowsLogicException(string $this->compile(); } - public function tagsProvider(): iterable + public static function tagsProvider(): iterable { return [ [RegisterSearchEnginePass::SEARCH_ENGINE_SERVICE_TAG], diff --git a/tests/bundle/Core/DependencyInjection/Compiler/RegisterStorageEnginePassTest.php b/tests/bundle/Core/DependencyInjection/Compiler/RegisterStorageEnginePassTest.php index 2b298c9b24..be60023985 100644 --- a/tests/bundle/Core/DependencyInjection/Compiler/RegisterStorageEnginePassTest.php +++ b/tests/bundle/Core/DependencyInjection/Compiler/RegisterStorageEnginePassTest.php @@ -34,7 +34,7 @@ protected function registerCompilerPass(ContainerBuilder $container): void $container->addCompilerPass(new RegisterStorageEnginePass()); } - public function testRegisterStorageEngine() + public function testRegisterStorageEngine(): void { $storageEngineDef = new Definition(); $storageEngineIdentifier = 'i_am_a_storage_engine'; @@ -51,7 +51,7 @@ public function testRegisterStorageEngine() ); } - public function testRegisterDefaultStorageEngine() + public function testRegisterDefaultStorageEngine(): void { $storageEngineDef = new Definition(); $storageEngineIdentifier = 'i_am_a_storage_engine'; @@ -70,7 +70,7 @@ public function testRegisterDefaultStorageEngine() ); } - public function testRegisterStorageEngineNoAlias() + public function testRegisterStorageEngineNoAlias(): void { $this->expectException(\LogicException::class); diff --git a/tests/bundle/Core/DependencyInjection/Compiler/SlugConverterConfigurationPassTest.php b/tests/bundle/Core/DependencyInjection/Compiler/SlugConverterConfigurationPassTest.php index b679a7aa2c..7533614880 100644 --- a/tests/bundle/Core/DependencyInjection/Compiler/SlugConverterConfigurationPassTest.php +++ b/tests/bundle/Core/DependencyInjection/Compiler/SlugConverterConfigurationPassTest.php @@ -11,6 +11,7 @@ use Ibexa\Core\Persistence\Legacy\Content\UrlAlias\SlugConverter; use Ibexa\Core\Persistence\TransformationProcessor; use Matthias\SymfonyDependencyInjectionTest\PhpUnit\AbstractCompilerPassTestCase; +use PHPUnit\Framework\Attributes\DataProvider; use ReflectionClass; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Definition; @@ -26,21 +27,20 @@ protected function registerCompilerPass(ContainerBuilder $container): void } /** - * @dataProvider configurationProvider - * * @param array $commandsToAdd * @param array $existingOldParameters * @param array $expectedCommands * * @throws \ReflectionException */ + #[DataProvider('configurationProvider')] public function testMergeConfigurations( array $commandsToAdd, array $existingOldParameters, array $expectedCommands - ) { + ): void { $definition = new Definition(SlugConverter::class); - $definition->setArgument(0, $this->createMock(TransformationProcessor::class)); + $definition->setArgument(0, self::createStub(TransformationProcessor::class)); $definition->setArgument(1, $existingOldParameters); $definition->setPublic(true); @@ -70,7 +70,10 @@ public function testMergeConfigurations( self::assertEquals('url_cleanup', $configuration['transformationGroups']['urlalias']['cleanupMethod']); } - public function configurationProvider() + /** + * @return array + */ + public static function configurationProvider(): array { $injectedBySemanticCommands = [ 'new_command_to_add', diff --git a/tests/bundle/Core/DependencyInjection/Compiler/StorageConnectionFactoryPassTest.php b/tests/bundle/Core/DependencyInjection/Compiler/StorageConnectionFactoryPassTest.php index 1d06c290ba..75214a756d 100644 --- a/tests/bundle/Core/DependencyInjection/Compiler/StorageConnectionFactoryPassTest.php +++ b/tests/bundle/Core/DependencyInjection/Compiler/StorageConnectionFactoryPassTest.php @@ -11,13 +11,12 @@ use Ibexa\Bundle\Core\ApiLoader\StorageConnectionFactory; use Ibexa\Bundle\Core\DependencyInjection\Compiler\StorageConnectionFactoryPass; use Matthias\SymfonyDependencyInjectionTest\PhpUnit\AbstractCompilerPassTestCase; +use PHPUnit\Framework\Attributes\CoversClass; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Definition; use Symfony\Component\DependencyInjection\Reference; -/** - * @covers \Ibexa\Bundle\Core\DependencyInjection\Compiler\StorageConnectionFactoryPass - */ +#[CoversClass(StorageConnectionFactoryPass::class)] final class StorageConnectionFactoryPassTest extends AbstractCompilerPassTestCase { protected function setUp(): void diff --git a/tests/bundle/Core/DependencyInjection/Compiler/TranslationCollectorPassTest.php b/tests/bundle/Core/DependencyInjection/Compiler/TranslationCollectorPassTest.php index 89ccd8aff1..b377c19cf3 100644 --- a/tests/bundle/Core/DependencyInjection/Compiler/TranslationCollectorPassTest.php +++ b/tests/bundle/Core/DependencyInjection/Compiler/TranslationCollectorPassTest.php @@ -9,6 +9,7 @@ use Ibexa\Bundle\Core\DependencyInjection\Compiler\TranslationCollectorPass; use Matthias\SymfonyDependencyInjectionTest\PhpUnit\AbstractCompilerPassTestCase; +use PHPUnit\Framework\Attributes\DataProvider; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Definition; @@ -19,9 +20,7 @@ protected function registerCompilerPass(ContainerBuilder $container): void $container->addCompilerPass(new TranslationCollectorPass()); } - /** - * @dataProvider translationCollectorProvider - */ + #[DataProvider('translationCollectorProvider')] public function testTranslationCollector( bool $translationsEnabled, array $availableTranslations @@ -43,7 +42,7 @@ private function normalizePath(string $path): string /** * @return iterable */ - public function translationCollectorProvider(): iterable + public static function translationCollectorProvider(): iterable { yield 'translations enabled' => [ true, diff --git a/tests/bundle/Core/DependencyInjection/Compiler/URLHandlerPassTest.php b/tests/bundle/Core/DependencyInjection/Compiler/URLHandlerPassTest.php index 50a459809a..1ec5924d83 100644 --- a/tests/bundle/Core/DependencyInjection/Compiler/URLHandlerPassTest.php +++ b/tests/bundle/Core/DependencyInjection/Compiler/URLHandlerPassTest.php @@ -27,7 +27,7 @@ protected function registerCompilerPass(ContainerBuilder $container): void $container->addCompilerPass(new URLHandlerPass()); } - public function testRegisterURLHandler() + public function testRegisterURLHandler(): void { $serviceId = 'service_id'; $scheme = 'http'; @@ -44,7 +44,7 @@ public function testRegisterURLHandler() ); } - public function testRegisterURLHandlerNoScheme() + public function testRegisterURLHandlerNoScheme(): void { $this->expectException(\LogicException::class); diff --git a/tests/bundle/Core/DependencyInjection/Compiler/ViewProvidersPassTest.php b/tests/bundle/Core/DependencyInjection/Compiler/ViewProvidersPassTest.php index 8cfa5c4418..fe5bcbcb80 100644 --- a/tests/bundle/Core/DependencyInjection/Compiler/ViewProvidersPassTest.php +++ b/tests/bundle/Core/DependencyInjection/Compiler/ViewProvidersPassTest.php @@ -10,6 +10,7 @@ use Ibexa\Bundle\Core\DependencyInjection\Compiler\ViewProvidersPass; use Ibexa\Core\MVC\Symfony\View\Provider\Registry; use Matthias\SymfonyDependencyInjectionTest\PhpUnit\AbstractCompilerPassTestCase; +use PHPUnit\Framework\Attributes\DataProvider; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Definition; use Symfony\Component\DependencyInjection\Reference; @@ -33,10 +34,8 @@ protected function registerCompilerPass(ContainerBuilder $container): void $container->addCompilerPass(new ViewProvidersPass()); } - /** - * @dataProvider addViewProviderProvider - */ - public function testAddViewProvider($declaredPriority, $expectedPriority) + #[DataProvider('addViewProviderProvider')] + public function testAddViewProvider($declaredPriority, $expectedPriority): void { $def = new Definition(); @@ -58,7 +57,10 @@ public function testAddViewProvider($declaredPriority, $expectedPriority) ); } - public function addViewProviderProvider() + /** + * @return array + */ + public static function addViewProviderProvider(): array { return [ [null, 0], diff --git a/tests/bundle/Core/DependencyInjection/Configuration/ComplexSettings/ComplexSettingParserTest.php b/tests/bundle/Core/DependencyInjection/Configuration/ComplexSettings/ComplexSettingParserTest.php index a2c60061cf..533c126b58 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/ComplexSettings/ComplexSettingParserTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/ComplexSettings/ComplexSettingParserTest.php @@ -8,6 +8,7 @@ namespace Ibexa\Tests\Bundle\Core\DependencyInjection\Configuration\ComplexSettings; use Ibexa\Bundle\Core\DependencyInjection\Configuration\ComplexSettings\ComplexSettingParser; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; class ComplexSettingParserTest extends TestCase @@ -20,23 +21,22 @@ protected function setUp(): void $this->parser = new ComplexSettingParser(); } - /** - * @dataProvider provideSettings - */ - public function testContainsDynamicSettings($setting, $expected) + #[DataProvider('provideSettings')] + public function testContainsDynamicSettings($setting, $expected): void { self::assertEquals($expected[0], $this->parser->containsDynamicSettings($setting), 'string'); } - /** - * @dataProvider provideSettings - */ - public function testParseComplexSetting($setting, $expected) + #[DataProvider('provideSettings')] + public function testParseComplexSetting($setting, $expected): void { self::assertEquals($expected[1], $this->parser->parseComplexSetting($setting), 'string'); } - public function provideSettings() + /** + * @return array + */ + public static function provideSettings(): array { // array( setting, array( isDynamicSetting, containsDynamicSettings ) ) return [ diff --git a/tests/bundle/Core/DependencyInjection/Configuration/ComplexSettings/ComplexSettingValueResolverTest.php b/tests/bundle/Core/DependencyInjection/Configuration/ComplexSettings/ComplexSettingValueResolverTest.php index 4afa862ff5..effa5c4085 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/ComplexSettings/ComplexSettingValueResolverTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/ComplexSettings/ComplexSettingValueResolverTest.php @@ -12,7 +12,7 @@ class ComplexSettingValueResolverTest extends TestCase { - public function testGetArgumentValue() + public function testGetArgumentValue(): void { $resolver = new ComplexSettingValueResolver(); self::assertEquals( diff --git a/tests/bundle/Core/DependencyInjection/Configuration/ConfigParserTest.php b/tests/bundle/Core/DependencyInjection/Configuration/ConfigParserTest.php index 0838525084..acf3457bd5 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/ConfigParserTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/ConfigParserTest.php @@ -82,7 +82,7 @@ public function testMapConfig(): void 'some' => 'thing', ]; $currentScope = 'the_current_scope'; - $contextualizer = $this->createMock(ContextualizerInterface::class); + $contextualizer = self::createStub(ContextualizerInterface::class); foreach ($parsers as $parser) { /* @var \PHPUnit\Framework\MockObject\MockObject $parser */ @@ -110,7 +110,7 @@ public function testPrePostMap(): void 'foo' => 'bar', 'some' => 'thing', ]; - $contextualizer = $this->createMock(ContextualizerInterface::class); + $contextualizer = self::createStub(ContextualizerInterface::class); foreach ($parsers as $parser) { /* @var \PHPUnit\Framework\MockObject\MockObject $parser */ diff --git a/tests/bundle/Core/DependencyInjection/Configuration/ConfigResolver/ChainConfigResolverTest.php b/tests/bundle/Core/DependencyInjection/Configuration/ConfigResolver/ChainConfigResolverTest.php index 727ece69e9..a9ce439ea0 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/ConfigResolver/ChainConfigResolverTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/ConfigResolver/ChainConfigResolverTest.php @@ -17,6 +17,7 @@ use Ibexa\Core\MVC\Symfony\SiteAccess; use Ibexa\Core\MVC\Symfony\SiteAccess\Provider\StaticSiteAccessProvider; use Ibexa\Core\MVC\Symfony\SiteAccessGroup; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use function sprintf; use Symfony\Component\DependencyInjection\ContainerInterface; @@ -46,9 +47,7 @@ protected function setUp(): void $this->containerMock = $this->createMock(ContainerInterface::class); } - /** - * @dataProvider parameterProvider - */ + #[DataProvider('parameterProvider')] public function testGetParameterDefaultScope(string $paramName, $expectedValue): void { $globalScopeParameter = $this->getParameter($paramName, self::SCOPE_GLOBAL); @@ -77,9 +76,7 @@ public function testGetParameterDefaultScope(string $paramName, $expectedValue): self::assertSame($expectedValue, $this->getChainConfigResolver()->getParameter($paramName)); } - /** - * @dataProvider parameterProvider - */ + #[DataProvider('parameterProvider')] public function testGetParameterRelativeScope(string $paramName, $expectedValue): void { $globalScopeParameter = $this->getParameter($paramName, self::SCOPE_GLOBAL); @@ -104,9 +101,7 @@ public function testGetParameterRelativeScope(string $paramName, $expectedValue) self::assertSame($expectedValue, $this->getChainConfigResolver()->getParameter($paramName)); } - /** - * @dataProvider parameterProvider - */ + #[DataProvider('parameterProvider')] public function testGetParameterSpecificScope(string $paramName, $expectedValue): void { $specificScopeParameter = $this->getParameter($paramName, self::FIRST_SA_NAME); @@ -133,9 +128,7 @@ public function testGetParameterSpecificScope(string $paramName, $expectedValue) ); } - /** - * @dataProvider parameterProvider - */ + #[DataProvider('parameterProvider')] public function testGetParameterGlobalScope(string $paramName, $expectedValue): void { $globalScopeParameter = $this->getParameter($paramName, self::SCOPE_GLOBAL); @@ -153,9 +146,7 @@ public function testGetParameterGlobalScope(string $paramName, $expectedValue): self::assertSame($expectedValue, $this->getChainConfigResolver()->getParameter($paramName)); } - /** - * @dataProvider hasParameterProvider - */ + #[DataProvider('hasParameterProvider')] public function testHasParameterNoNamespace( bool $defaultMatch, bool $groupMatch, @@ -182,9 +173,7 @@ public function testHasParameterNoNamespace( self::assertSame($expectedResult, $chainConfigResolver->hasParameter($paramName)); } - /** - * @dataProvider hasParameterProvider - */ + #[DataProvider('hasParameterProvider')] public function testHasParameterWithNamespaceAndScope( bool $defaultMatch, bool $groupMatch, @@ -274,7 +263,7 @@ private function getStaticSiteAccessProvider(): StaticSiteAccessProvider ); } - public function parameterProvider(): array + public static function parameterProvider(): array { return [ ['foo', 'bar'], @@ -301,7 +290,7 @@ public function parameterProvider(): array ]; } - public function hasParameterProvider(): array + public static function hasParameterProvider(): array { return [ [true, true, true, true, true], diff --git a/tests/bundle/Core/DependencyInjection/Configuration/ConfigResolver/ConfigResolverTestCase.php b/tests/bundle/Core/DependencyInjection/Configuration/ConfigResolver/ConfigResolverTestCase.php index b89c3ba152..ef0a6354c7 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/ConfigResolver/ConfigResolverTestCase.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/ConfigResolver/ConfigResolverTestCase.php @@ -11,6 +11,7 @@ use Ibexa\Contracts\Core\SiteAccess\ConfigResolverInterface; use Ibexa\Core\MVC\Exception\ParameterNotFoundException; use Ibexa\Core\MVC\Symfony\SiteAccess; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\DependencyInjection\ContainerInterface; @@ -58,9 +59,7 @@ public function testGetParameterFailedWithException(): void $resolver->getParameter('undefined'); } - /** - * @dataProvider parameterProvider - */ + #[DataProvider('parameterProvider')] public function testGetParameterGlobalScope(string $paramName, $expectedValue): void { $globalScopeParameter = sprintf('%s.%s.%s', $this->getNamespace(), $this->getScope(), $paramName); @@ -78,7 +77,7 @@ public function testGetParameterGlobalScope(string $paramName, $expectedValue): self::assertSame($expectedValue, $this->getResolver()->getParameter($paramName)); } - public function parameterProvider(): array + public static function parameterProvider(): array { return [ ['foo', 'bar'], diff --git a/tests/bundle/Core/DependencyInjection/Configuration/ConfigResolver/SiteAccessGroupConfigResolverTest.php b/tests/bundle/Core/DependencyInjection/Configuration/ConfigResolver/SiteAccessGroupConfigResolverTest.php index 1f863f0794..eae024585f 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/ConfigResolver/SiteAccessGroupConfigResolverTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/ConfigResolver/SiteAccessGroupConfigResolverTest.php @@ -25,7 +25,7 @@ protected function getResolver(string $defaultNamespace = self::DEFAULT_NAMESPAC $siteAccess = new SiteAccess( self::EXISTING_SA_NAME, 'default', - $this->createMock(Matcher::class) + self::createStub(Matcher::class) ); $configResolver = new SiteAccessGroupConfigResolver( $this->containerMock, diff --git a/tests/bundle/Core/DependencyInjection/Configuration/ConfigResolver/StaticSiteAccessConfigResolverTest.php b/tests/bundle/Core/DependencyInjection/Configuration/ConfigResolver/StaticSiteAccessConfigResolverTest.php index 854bf8a46b..e38a7f1fed 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/ConfigResolver/StaticSiteAccessConfigResolverTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/ConfigResolver/StaticSiteAccessConfigResolverTest.php @@ -25,7 +25,7 @@ protected function getResolver(string $defaultNamespace = self::DEFAULT_NAMESPAC $siteAccess = new SiteAccess( self::EXISTING_SA_NAME, 'default', - $this->createMock(Matcher::class) + self::createStub(Matcher::class) ); $configResolver = new StaticSiteAccessConfigResolver( $this->containerMock, diff --git a/tests/bundle/Core/DependencyInjection/Configuration/Parser/CommonTest.php b/tests/bundle/Core/DependencyInjection/Configuration/Parser/CommonTest.php index 057b5da634..36ea0859fa 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/Parser/CommonTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/Parser/CommonTest.php @@ -9,6 +9,7 @@ use Ibexa\Bundle\Core\DependencyInjection\Configuration\Parser\Common; use Ibexa\Bundle\Core\DependencyInjection\IbexaCoreExtension; +use PHPUnit\Framework\Attributes\DataProvider; use Symfony\Component\Yaml\Yaml; class CommonTest extends AbstractParserTestCase @@ -25,7 +26,7 @@ protected function getMinimalConfiguration(): array return $this->minimalConfig = Yaml::parse(file_get_contents(__DIR__ . '/../../Fixtures/ezpublish_minimal.yml')); } - public function testIndexPage() + public function testIndexPage(): void { $indexPage1 = '/Getting-Started'; $indexPage2 = '/Contact-Us'; @@ -42,7 +43,7 @@ public function testIndexPage() $this->assertConfigResolverParameterValue('index_page', null, self::EMPTY_SA_GROUP); } - public function testDefaultPage() + public function testDefaultPage(): void { $defaultPage1 = '/Getting-Started'; $defaultPage2 = '/Foo/bar'; @@ -62,7 +63,7 @@ public function testDefaultPage() /** * Test defaults. */ - public function testNonExistentSettings() + public function testNonExistentSettings(): void { $this->load(); $this->assertConfigResolverParameterValue('url_alias_router', true, 'ibexa_demo_site'); @@ -75,7 +76,7 @@ public function testNonExistentSettings() $this->assertConfigResolverParameterValue('index_page', null, 'ibexa_demo_site'); } - public function testMiscSettings() + public function testMiscSettings(): void { $cachePoolName = 'cache_foo'; $varDir = 'var/foo/bar'; @@ -116,7 +117,7 @@ public function testMiscSettings() $this->assertConfigResolverParameterValue('anonymous_user_id', $anonymousUserId, 'ibexa_demo_site'); } - public function testApiKeysSettings() + public function testApiKeysSettings(): void { $key = 'my_key'; $this->load( @@ -135,7 +136,7 @@ public function testApiKeysSettings() $this->assertConfigResolverParameterValue('api_keys.google_maps', $key, 'ibexa_demo_site'); } - public function testUserSettings() + public function testUserSettings(): void { $layout = 'somelayout.html.twig'; $loginTemplate = 'login_template.html.twig'; @@ -156,7 +157,7 @@ public function testUserSettings() $this->assertConfigResolverParameterValue('security.login_template', $loginTemplate, 'ibexa_demo_site'); } - public function testNoUserSettings() + public function testNoUserSettings(): void { $this->load(); $this->assertConfigResolverParameterValue( @@ -171,10 +172,8 @@ public function testNoUserSettings() ); } - /** - * @dataProvider sessionSettingsProvider - */ - public function testSessionSettings(array $inputParams, array $expected) + #[DataProvider('sessionSettingsProvider')] + public function testSessionSettings(array $inputParams, array $expected): void { $this->load( [ @@ -187,7 +186,10 @@ public function testSessionSettings(array $inputParams, array $expected) $this->assertConfigResolverParameterValue('session', $expected['session'], 'ibexa_demo_site'); } - public function sessionSettingsProvider() + /** + * @return array + */ + public static function sessionSettingsProvider(): array { return [ [ diff --git a/tests/bundle/Core/DependencyInjection/Configuration/Parser/ContentTest.php b/tests/bundle/Core/DependencyInjection/Configuration/Parser/ContentTest.php index c38e81bf37..d2540dd7cc 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/Parser/ContentTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/Parser/ContentTest.php @@ -9,6 +9,7 @@ use Ibexa\Bundle\Core\DependencyInjection\Configuration\Parser\Content as ContentConfigParser; use Ibexa\Bundle\Core\DependencyInjection\IbexaCoreExtension; +use PHPUnit\Framework\Attributes\DataProvider; use Symfony\Component\Yaml\Yaml; class ContentTest extends AbstractParserTestCase @@ -25,7 +26,7 @@ protected function getMinimalConfiguration(): array return Yaml::parse(file_get_contents(__DIR__ . '/../../Fixtures/ezpublish_minimal.yml')); } - public function testDefaultContentSettings() + public function testDefaultContentSettings(): void { $this->load(); @@ -34,10 +35,8 @@ public function testDefaultContentSettings() $this->assertConfigResolverParameterValue('content.default_ttl', 60, 'ibexa_demo_site'); } - /** - * @dataProvider contentSettingsProvider - */ - public function testContentSettings(array $config, array $expected) + #[DataProvider('contentSettingsProvider')] + public function testContentSettings(array $config, array $expected): void { $this->load( [ @@ -52,7 +51,10 @@ public function testContentSettings(array $config, array $expected) } } - public function contentSettingsProvider() + /** + * @return array + */ + public static function contentSettingsProvider(): array { return [ [ diff --git a/tests/bundle/Core/DependencyInjection/Configuration/Parser/EmbeddingsTest.php b/tests/bundle/Core/DependencyInjection/Configuration/Parser/EmbeddingsTest.php index 3b02a39d17..52300e9eb4 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/Parser/EmbeddingsTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/Parser/EmbeddingsTest.php @@ -10,6 +10,7 @@ use Ibexa\Bundle\Core\DependencyInjection\Configuration\Parser\Embeddings as EmbeddingsConfigParser; use Ibexa\Bundle\Core\DependencyInjection\IbexaCoreExtension; +use PHPUnit\Framework\Attributes\DataProvider; use Symfony\Component\Yaml\Yaml; final class EmbeddingsTest extends AbstractParserTestCase @@ -74,9 +75,8 @@ public function testDefaultEmbeddingModelSetInDefaultScopeIsNotMaterializedToOth /** * @param array $config * @param array $expected - * - * @dataProvider embeddingsSettingsProvider */ + #[DataProvider('embeddingsSettingsProvider')] public function testEmbeddingsSettings(array $config, array $expected): void { $this->load( @@ -114,7 +114,7 @@ public function testEmbeddingsSettings(array $config, array $expected): void * } * }> */ - public function embeddingsSettingsProvider(): array + public static function embeddingsSettingsProvider(): array { return [ [ diff --git a/tests/bundle/Core/DependencyInjection/Configuration/Parser/FieldType/ImageAssetTest.php b/tests/bundle/Core/DependencyInjection/Configuration/Parser/FieldType/ImageAssetTest.php index 3697ea88b6..efcb76a35d 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/Parser/FieldType/ImageAssetTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/Parser/FieldType/ImageAssetTest.php @@ -11,6 +11,7 @@ use Ibexa\Bundle\Core\DependencyInjection\Configuration\Parser\FieldType\ImageAsset as ImageAssetConfigParser; use Ibexa\Bundle\Core\DependencyInjection\IbexaCoreExtension; use Ibexa\Tests\Bundle\Core\DependencyInjection\Configuration\Parser\AbstractParserTestCase; +use PHPUnit\Framework\Attributes\DataProvider; class ImageAssetTest extends AbstractParserTestCase { @@ -24,7 +25,7 @@ protected function getContainerExtensions(): array ]; } - public function testDefaultImageAssetSettings() + public function testDefaultImageAssetSettings(): void { $this->load(); @@ -40,10 +41,8 @@ public function testDefaultImageAssetSettings() ); } - /** - * @dataProvider imageAssetSettingsProvider - */ - public function testImageAssetSettings(array $config, array $expected) + #[DataProvider('imageAssetSettingsProvider')] + public function testImageAssetSettings(array $config, array $expected): void { $this->load( [ @@ -58,7 +57,7 @@ public function testImageAssetSettings(array $config, array $expected) } } - public function imageAssetSettingsProvider(): array + public static function imageAssetSettingsProvider(): array { return [ [ diff --git a/tests/bundle/Core/DependencyInjection/Configuration/Parser/IOTest.php b/tests/bundle/Core/DependencyInjection/Configuration/Parser/IOTest.php index 2b2ea2a995..2c2992e897 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/Parser/IOTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/Parser/IOTest.php @@ -36,7 +36,7 @@ protected function getMinimalConfiguration(): array return $this->minimalConfig = Yaml::parse(file_get_contents(__DIR__ . '/../../Fixtures/ezpublish_minimal.yml')); } - public function testHandlersConfig() + public function testHandlersConfig(): void { $config = [ 'system' => [ diff --git a/tests/bundle/Core/DependencyInjection/Configuration/Parser/ImageTest.php b/tests/bundle/Core/DependencyInjection/Configuration/Parser/ImageTest.php index 22bf92734c..ba06a2f6bb 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/Parser/ImageTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/Parser/ImageTest.php @@ -44,7 +44,7 @@ protected function getContainerExtensions(): array ]; } - public function testVariations() + public function testVariations(): void { $this->load(); @@ -72,7 +72,7 @@ public function testVariations() ); } - public function testPrePostParameters() + public function testPrePostParameters(): void { $this->expectException(\InvalidArgumentException::class); diff --git a/tests/bundle/Core/DependencyInjection/Configuration/Parser/LanguagesTest.php b/tests/bundle/Core/DependencyInjection/Configuration/Parser/LanguagesTest.php index 6a4508862e..bd3b753fa7 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/Parser/LanguagesTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/Parser/LanguagesTest.php @@ -23,7 +23,7 @@ protected function getMinimalConfiguration(): array return Yaml::parse(file_get_contents(__DIR__ . '/../../Fixtures/ezpublish_minimal.yml')); } - public function testLanguagesSingleSiteaccess() + public function testLanguagesSingleSiteaccess(): void { $langDemoSite = ['eng-GB']; $langFre = ['fre-FR', 'eng-GB']; @@ -58,7 +58,7 @@ public function testLanguagesSingleSiteaccess() $this->assertConfigResolverParameterValue('languages', [], 'ibexa_demo_site_admin'); } - public function testLanguagesSiteaccessGroup() + public function testLanguagesSiteaccessGroup(): void { $langDemoSite = ['eng-US', 'eng-GB']; $config = [ @@ -83,7 +83,7 @@ public function testLanguagesSiteaccessGroup() $this->assertConfigResolverParameterValue('languages', [], 'ibexa_demo_site_admin'); } - public function testTranslationSiteAccesses() + public function testTranslationSiteAccesses(): void { $translationSAsDemoSite = ['foo', 'bar']; $translationSAsFre = ['foo2', 'bar2']; @@ -101,7 +101,7 @@ public function testTranslationSiteAccesses() $this->assertConfigResolverParameterValue('translation_siteaccesses', [], self::EMPTY_SA_GROUP); } - public function testTranslationSiteAccessesWithGroup() + public function testTranslationSiteAccessesWithGroup(): void { $translationSAsDemoSite = ['ibexa_demo_site', 'fre']; $config = [ diff --git a/tests/bundle/Core/DependencyInjection/Configuration/Parser/TemplatesTest.php b/tests/bundle/Core/DependencyInjection/Configuration/Parser/TemplatesTest.php index 2907e3398b..e84c71cd6d 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/Parser/TemplatesTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/Parser/TemplatesTest.php @@ -32,7 +32,7 @@ protected function getMinimalConfiguration(): array return $this->config = Yaml::parse(file_get_contents(__DIR__ . '/../../Fixtures/ezpublish_templates.yml')); } - public function testFieldTemplates() + public function testFieldTemplates(): void { $this->load(); $fixedUpConfig = $this->getExpectedConfigFieldTemplates($this->config); @@ -106,7 +106,7 @@ private function getExpectedConfigFieldTemplates(array $config) return $config; } - public function testFieldDefinitionSettingsTemplates() + public function testFieldDefinitionSettingsTemplates(): void { $this->load(); $fixedUpConfig = $this->getExpectedConfigFieldDefinitionSettingsTemplates($this->config); diff --git a/tests/bundle/Core/DependencyInjection/Configuration/Parser/ViewTest.php b/tests/bundle/Core/DependencyInjection/Configuration/Parser/ViewTest.php index be7546142f..ee795a6f86 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/Parser/ViewTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/Parser/ViewTest.php @@ -28,7 +28,7 @@ protected function getMinimalConfiguration(): array return $this->config = Yaml::parse(file_get_contents(__DIR__ . '/../../Fixtures/ezpublish_view.yml')); } - public function testLocationView() + public function testLocationView(): void { $this->load(); $expectedLocationView = $this->config['system']['ibexa_demo_frontend_group']['location_view']; @@ -50,7 +50,7 @@ public function testLocationView() $this->assertConfigResolverParameterValue('location_view', [], 'ibexa_demo_site_admin', false); } - public function testContentView() + public function testContentView(): void { $this->load(); $expectedContentView = $this->config['system']['ibexa_demo_frontend_group']['content_view']; diff --git a/tests/bundle/Core/DependencyInjection/Configuration/RepositoryConfigParserTest.php b/tests/bundle/Core/DependencyInjection/Configuration/RepositoryConfigParserTest.php index fdfb5d5ca2..ca11c2710b 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/RepositoryConfigParserTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/RepositoryConfigParserTest.php @@ -26,7 +26,7 @@ final class RepositoryConfigParserTest extends TestCase public function testAddSemanticConfig(): void { /** @phpstan-var NodeBuilder & MockObject $nodeBuilder */ - $nodeBuilder = $this->createMock(NodeBuilder::class); + $nodeBuilder = self::createStub(NodeBuilder::class); $repositoryConfigParser = new RepositoryConfigParser([ $this->createRepositoryConfigParserMock($nodeBuilder), diff --git a/tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ConfigurationProcessorTest.php b/tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ConfigurationProcessorTest.php index ec7b4af269..7e5fc8f2d2 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ConfigurationProcessorTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ConfigurationProcessorTest.php @@ -16,7 +16,7 @@ class ConfigurationProcessorTest extends TestCase { - public function testConstruct() + public function testConstruct(): void { $namespace = 'ibexa_test'; $siteAccessNodeName = 'foo'; @@ -42,7 +42,7 @@ public function testConstruct() self::assertSame($groupsBySa, $contextualizer->getGroupsBySiteAccess()); } - public function testGetSetContextualizer() + public function testGetSetContextualizer(): void { $namespace = 'ibexa_test'; $siteAccessNodeName = 'foo'; @@ -59,7 +59,7 @@ public function testGetSetContextualizer() self::assertSame($newContextualizer, $processor->getContextualizer()); } - public function testMapConfigClosure() + public function testMapConfigClosure(): void { $namespace = 'ibexa_test'; $saNodeName = 'foo'; @@ -98,7 +98,7 @@ public function testMapConfigClosure() $processor->mapConfig($config, $mapperClosure); } - public function testMapConfigMapperObject() + public function testMapConfigMapperObject(): void { $namespace = 'ibexa_test'; $saNodeName = 'foo'; @@ -144,7 +144,7 @@ public function testMapConfigMapperObject() $processor->mapConfig($config, $mapper); } - public function testMapConfigHookableMapperObject() + public function testMapConfigHookableMapperObject(): void { $namespace = 'ibexa_test'; $saNodeName = 'foo'; @@ -198,7 +198,7 @@ public function testMapConfigHookableMapperObject() $processor->mapConfig($config, $mapper); } - public function testMapSetting() + public function testMapSetting(): void { $namespace = 'ibexa_test'; $saNodeName = 'foo'; @@ -234,7 +234,7 @@ public function testMapSetting() $processor->mapSetting('foo', $config); } - public function testMapConfigArray() + public function testMapConfigArray(): void { $namespace = 'ibexa_test'; $saNodeName = 'foo'; diff --git a/tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php b/tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php index f0e9f38e36..8593181b87 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/ContextualizerTest.php @@ -10,12 +10,15 @@ use Ibexa\Bundle\Core\DependencyInjection\Configuration\SiteAccessAware\Contextualizer; use Ibexa\Bundle\Core\DependencyInjection\Configuration\SiteAccessAware\ContextualizerInterface; use Ibexa\Contracts\Core\SiteAccess\ConfigResolverInterface; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\ContainerInterface; class ContextualizerTest extends TestCase { + private const string SA_NODE_NAME = 'heyho'; + /** @var \PHPUnit\Framework\MockObject\MockObject */ private $container; @@ -23,7 +26,7 @@ class ContextualizerTest extends TestCase private $namespace = 'ibexa_test'; /** @var string */ - private $saNodeName = 'heyho'; + private $saNodeName = self::SA_NODE_NAME; /** @var array */ private $availableSAs = ['sa1', 'sa2', 'sa3']; @@ -58,10 +61,8 @@ protected function setUp(): void ); } - /** - * @dataProvider setContextualParameterProvider - */ - public function testSetContextualParameter($parameterName, $scope, $value) + #[DataProvider('setContextualParameterProvider')] + public function testSetContextualParameter($parameterName, $scope, $value): void { $this->container ->expects(self::once()) @@ -71,7 +72,10 @@ public function testSetContextualParameter($parameterName, $scope, $value) $this->contextualizer->setContextualParameter($parameterName, $scope, $value); } - public function setContextualParameterProvider() + /** + * @return array + */ + public static function setContextualParameterProvider(): array { return [ ['my_parameter', 'sa1', 'foobar'], @@ -83,7 +87,7 @@ public function setContextualParameterProvider() ]; } - public function testMapSetting() + public function testMapSetting(): void { $fooSa1 = 'bar'; $planetsSa1 = ['Earth']; @@ -131,7 +135,7 @@ public function testMapSetting() self::assertSame($boolSa2, $container->getParameter("$this->namespace.sa2.a_bool")); } - public function testMapConfigArray() + public function testMapConfigArray(): void { $containerBuilder = new ContainerBuilder(); $this->contextualizer->setContainer($containerBuilder); @@ -233,7 +237,7 @@ public function testMapConfigArray() ); } - public function testMapConfigArraySecondLevel() + public function testMapConfigArraySecondLevel(): void { $containerBuilder = new ContainerBuilder(); $this->contextualizer->setContainer($containerBuilder); @@ -343,7 +347,7 @@ public function testMapConfigArraySecondLevel() ); } - public function testMapConfigArrayUnique() + public function testMapConfigArrayUnique(): void { $containerBuilder = new ContainerBuilder(); $this->contextualizer->setContainer($containerBuilder); @@ -396,7 +400,7 @@ public function testMapConfigArrayUnique() ); } - public function testGetSetContainer() + public function testGetSetContainer(): void { self::assertSame($this->container, $this->contextualizer->getContainer()); $containerBuilder = new ContainerBuilder(); @@ -404,7 +408,7 @@ public function testGetSetContainer() self::assertSame($containerBuilder, $this->contextualizer->getContainer()); } - public function testGetSetSANodeName() + public function testGetSetSANodeName(): void { $nodeName = 'foobarbaz'; self::assertSame($this->saNodeName, $this->contextualizer->getSiteAccessNodeName()); @@ -412,7 +416,7 @@ public function testGetSetSANodeName() self::assertSame($nodeName, $this->contextualizer->getSiteAccessNodeName()); } - public function testGetSetNamespace() + public function testGetSetNamespace(): void { $ns = 'ibexa'; self::assertSame($this->namespace, $this->contextualizer->getNamespace()); @@ -420,7 +424,7 @@ public function testGetSetNamespace() self::assertSame($ns, $this->contextualizer->getNamespace()); } - public function testGetSetAvailableSiteAccesses() + public function testGetSetAvailableSiteAccesses(): void { self::assertSame($this->availableSAs, $this->contextualizer->getAvailableSiteAccesses()); $sa = ['foo', 'bar', 'baz']; @@ -428,7 +432,7 @@ public function testGetSetAvailableSiteAccesses() self::assertSame($sa, $this->contextualizer->getAvailableSiteAccesses()); } - public function testGetSetGroupsBySA() + public function testGetSetGroupsBySA(): void { self::assertSame($this->groupsBySA, $this->contextualizer->getGroupsBySiteAccess()); $groups = ['foo' => ['bar', 'baz'], 'group2' => ['some', 'thing']]; @@ -439,9 +443,8 @@ public function testGetSetGroupsBySA() /** * Test that settings array a properly merged when defined in several * scopes. - * - * @dataProvider fullMapConfigArrayProvider */ + #[DataProvider('fullMapConfigArrayProvider')] public function testFullMapConfigArray( $testId, $siteaccess, @@ -452,7 +455,7 @@ public function testFullMapConfigArray( $options, array $expected, $customSANodeKey = null - ) { + ): void { $this->contextualizer->setAvailableSiteAccesses($config['siteaccess']['list']); $this->contextualizer->setGroupsBySiteAccess([$siteaccess => $groups]); @@ -502,7 +505,10 @@ public function testFullMapConfigArray( $this->contextualizer->mapConfigArray($testId, $config, $options); } - public function fullMapConfigArrayProvider() + /** + * @return array + */ + public static function fullMapConfigArrayProvider(): array { $testId = 'wizards'; $siteaccess = 'krondor'; @@ -638,7 +644,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [], + self::SA_NODE_NAME => [], ], 0, $all, @@ -652,7 +658,7 @@ public function fullMapConfigArrayProvider() $all, [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [], + self::SA_NODE_NAME => [], ], 0, $all, @@ -666,7 +672,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group2 => [$testId => $all], ], ], @@ -682,7 +688,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $siteaccess => [$testId => $all], ], ], @@ -698,7 +704,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testId => ['Pug', 'Rogen', 'William']], ], ], @@ -714,7 +720,7 @@ public function fullMapConfigArrayProvider() ['Pug', 'Rogen', 'William'], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testId => ['Kulgan', 'Macros the Black']], ], ], @@ -730,7 +736,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testId => ['Pug', 'Rogen']], $group2 => [$testId => ['William']], ], @@ -747,7 +753,7 @@ public function fullMapConfigArrayProvider() ['Kulgan', 'Macros the Black'], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testId => ['Pug', 'Rogen']], $group2 => [$testId => ['William']], ], @@ -764,7 +770,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testId => ['Pug']], $group2 => [$testId => ['Rogen']], $siteaccess => [$testId => ['William']], @@ -782,7 +788,7 @@ public function fullMapConfigArrayProvider() ['Kulgan', 'Macros the Black'], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testId => ['Pug']], $group2 => [$testId => ['Rogen']], $siteaccess => [$testId => ['William']], @@ -800,7 +806,7 @@ public function fullMapConfigArrayProvider() ['William'], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testId => ['Pug']], $group2 => [$testId => ['Rogen']], ], @@ -817,7 +823,7 @@ public function fullMapConfigArrayProvider() ['William'], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testId => ['Macros the Black']], $group2 => [$testId => ['Pug']], $siteaccess => [$testId => ['Rogen']], @@ -837,7 +843,7 @@ public function fullMapConfigArrayProvider() ['William'], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testId => ['Macros the Black']], $group2 => [$testId => ['Pug']], $siteaccess => [$testId => ['Rogen', 'Pug']], @@ -854,7 +860,7 @@ public function fullMapConfigArrayProvider() ['William', 'Kulgan', 'Pug'], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testId => ['Macros the Black']], $group2 => [$testId => ['Pug', 'William', 'Kulgan']], $siteaccess => [$testId => ['Rogen', 'Pug', 'Rogen', 'Macros the Black']], @@ -875,7 +881,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [], + self::SA_NODE_NAME => [], ], ContextualizerInterface::MERGE_FROM_SECOND_LEVEL, $locationView1, @@ -889,7 +895,7 @@ public function fullMapConfigArrayProvider() $locationView1, [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [], + self::SA_NODE_NAME => [], ], ContextualizerInterface::MERGE_FROM_SECOND_LEVEL, $locationView1, @@ -903,7 +909,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testIdHash => $locationView1], ], ], @@ -919,7 +925,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $siteaccess => [$testIdHash => $locationView1], ], ], @@ -936,7 +942,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testIdHash => $locationView2], ], ], @@ -952,7 +958,7 @@ public function fullMapConfigArrayProvider() $locationView1, [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testIdHash => $locationView2], ], ], @@ -968,7 +974,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testIdHash => $locationView2], $group2 => [$testIdHash => $locationView3], ], @@ -985,7 +991,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testIdHash => $locationView2], $group2 => [$testIdHash => $locationView3], $siteaccess => [$testIdHash => $locationView4], @@ -1003,7 +1009,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testIdHash => $locationView1], $group2 => [$testIdHash => $locationView2], ], @@ -1020,7 +1026,7 @@ public function fullMapConfigArrayProvider() $locationView3, [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testIdHash => $locationView1], $group2 => [$testIdHash => $locationView2], ], @@ -1037,7 +1043,7 @@ public function fullMapConfigArrayProvider() $locationView4, [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testIdHash => $locationView1], $group2 => [$testIdHash => $locationView2], $siteaccess => [$testIdHash => $locationView3], @@ -1056,7 +1062,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $siteaccess => [$testIdHash => $locationView3], $group1 => [$testIdHash => $locationView1], $group2 => [$testIdHash => $locationView2], @@ -1074,7 +1080,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testIdHash => $locationView2], $siteaccess => [$testIdHash => $locationView3], ], @@ -1091,7 +1097,7 @@ public function fullMapConfigArrayProvider() $locationView4, [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testIdHash => $locationView2], $siteaccess => [$testIdHash => $locationView3], ], @@ -1108,7 +1114,7 @@ public function fullMapConfigArrayProvider() $locationView3, [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group2 => [$testIdHash => $locationView1], $siteaccess => [$testIdHash => $locationView2], ], @@ -1125,7 +1131,7 @@ public function fullMapConfigArrayProvider() $locationView3, [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group2 => [$testIdHash => $locationView2], ], ], @@ -1145,7 +1151,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [], + self::SA_NODE_NAME => [], ], 0, $locationView1, @@ -1159,7 +1165,7 @@ public function fullMapConfigArrayProvider() $locationView1, [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [], + self::SA_NODE_NAME => [], ], 0, $locationView1, @@ -1173,7 +1179,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testIdHash => $locationView1], ], ], @@ -1189,7 +1195,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $siteaccess => [$testIdHash => $locationView1], ], ], @@ -1205,7 +1211,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testIdHash => $locationView2], ], ], @@ -1221,7 +1227,7 @@ public function fullMapConfigArrayProvider() $locationView1, [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testIdHash => $locationView2], ], ], @@ -1237,7 +1243,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testIdHash => $locationView2], $group2 => [$testIdHash => $locationView3], ], @@ -1254,7 +1260,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testIdHash => $locationView2], $group2 => [$testIdHash => $locationView3], $siteaccess => [$testIdHash => $locationView4], @@ -1272,7 +1278,7 @@ public function fullMapConfigArrayProvider() $locationView4, [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testIdHash => $locationView2], $group2 => [$testIdHash => $locationView3], ], @@ -1289,7 +1295,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testIdHash => $locationView1], $group2 => [$testIdHash => $locationView2], ], @@ -1306,7 +1312,7 @@ public function fullMapConfigArrayProvider() $locationView3, [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testIdHash => $locationView1], $group2 => [$testIdHash => $locationView2], ], @@ -1323,7 +1329,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $siteaccess => [$testIdHash => $locationView3], $group1 => [$testIdHash => $locationView1], $group2 => [$testIdHash => $locationView2], @@ -1341,7 +1347,7 @@ public function fullMapConfigArrayProvider() $locationView4, [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $siteaccess => [$testIdHash => $locationView3], $group1 => [$testIdHash => $locationView1], $group2 => [$testIdHash => $locationView2], @@ -1359,7 +1365,7 @@ public function fullMapConfigArrayProvider() [], [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group1 => [$testIdHash => $locationView2], $siteaccess => [$testIdHash => $locationView3], ], @@ -1376,7 +1382,7 @@ public function fullMapConfigArrayProvider() $locationView3, [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group2 => [$testIdHash => $locationView1], $siteaccess => [$testIdHash => $locationView2], ], @@ -1393,7 +1399,7 @@ public function fullMapConfigArrayProvider() $locationView3, [ 'siteaccess' => $siteaccessConfig, - $this->saNodeName => [ + self::SA_NODE_NAME => [ $group2 => [$testIdHash => $locationView2], ], ], @@ -1404,9 +1410,9 @@ public function fullMapConfigArrayProvider() foreach ($cases as $k => $newcase) { // run the same tests with another baseKey than the default one - if (isset($newcase[5][$this->saNodeName])) { - $newcase[5]['customBaseKey'] = $newcase[5][$this->saNodeName]; - unset($newcase[5][$this->saNodeName]); + if (isset($newcase[5][self::SA_NODE_NAME])) { + $newcase[5]['customBaseKey'] = $newcase[5][self::SA_NODE_NAME]; + unset($newcase[5][self::SA_NODE_NAME]); $newcase[] = 'customBaseKey'; $cases[] = $newcase; } diff --git a/tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/DynamicSettingParserTest.php b/tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/DynamicSettingParserTest.php index ebd5991120..78977edef3 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/DynamicSettingParserTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/SiteAccessAware/DynamicSettingParserTest.php @@ -8,20 +8,22 @@ namespace Ibexa\Tests\Bundle\Core\DependencyInjection\Configuration\SiteAccessAware; use Ibexa\Bundle\Core\DependencyInjection\Configuration\SiteAccessAware\DynamicSettingParser; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; class DynamicSettingParserTest extends TestCase { - /** - * @dataProvider isDynamicSettingProvider - */ - public function testIsDynamicSetting($setting, $expected) + #[DataProvider('isDynamicSettingProvider')] + public function testIsDynamicSetting($setting, $expected): void { $parser = new DynamicSettingParser(); self::assertSame($expected, $parser->isDynamicSetting($setting)); } - public function isDynamicSettingProvider() + /** + * @return array + */ + public static function isDynamicSettingProvider(): array { return [ ['foo', false], @@ -40,7 +42,7 @@ public function isDynamicSettingProvider() ]; } - public function testParseDynamicSettingFail() + public function testParseDynamicSettingFail(): void { $this->expectException(\OutOfBoundsException::class); @@ -48,16 +50,17 @@ public function testParseDynamicSettingFail() $parser->parseDynamicSetting('$foo;bar;baz;biz$'); } - /** - * @dataProvider parseDynamicSettingProvider - */ - public function testParseDynamicSetting($setting, array $expected) + #[DataProvider('parseDynamicSettingProvider')] + public function testParseDynamicSetting($setting, array $expected): void { $parser = new DynamicSettingParser(); self::assertSame($expected, $parser->parseDynamicSetting($setting)); } - public function parseDynamicSettingProvider() + /** + * @return array + */ + public static function parseDynamicSettingProvider(): array { return [ [ diff --git a/tests/bundle/Core/DependencyInjection/Configuration/Suggestion/Collector/SuggestionCollectorTest.php b/tests/bundle/Core/DependencyInjection/Configuration/Suggestion/Collector/SuggestionCollectorTest.php index abfdf4e7a8..97cbc9233c 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/Suggestion/Collector/SuggestionCollectorTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/Suggestion/Collector/SuggestionCollectorTest.php @@ -13,7 +13,7 @@ class SuggestionCollectorTest extends TestCase { - public function testAddHasGetSuggestions() + public function testAddHasGetSuggestions(): void { $collector = new SuggestionCollector(); $suggestions = [new ConfigSuggestion(), new ConfigSuggestion(), new ConfigSuggestion()]; diff --git a/tests/bundle/Core/DependencyInjection/Configuration/Suggestion/ConfigSuggestionTest.php b/tests/bundle/Core/DependencyInjection/Configuration/Suggestion/ConfigSuggestionTest.php index b16db5268a..591f4c60f6 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/Suggestion/ConfigSuggestionTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/Suggestion/ConfigSuggestionTest.php @@ -12,7 +12,7 @@ class ConfigSuggestionTest extends TestCase { - public function testEmptyConstructor() + public function testEmptyConstructor(): void { $suggestion = new ConfigSuggestion(); self::assertNull($suggestion->getMessage()); @@ -20,7 +20,7 @@ public function testEmptyConstructor() self::assertFalse($suggestion->isMandatory()); } - public function testConfigSuggestion() + public function testConfigSuggestion(): void { $message = 'some message'; $configArray = ['foo' => 'bar']; diff --git a/tests/bundle/Core/DependencyInjection/Configuration/Suggestion/Formatter/YamlSuggestionFormatterTest.php b/tests/bundle/Core/DependencyInjection/Configuration/Suggestion/Formatter/YamlSuggestionFormatterTest.php index c818e73bda..cf4b1ce7a7 100644 --- a/tests/bundle/Core/DependencyInjection/Configuration/Suggestion/Formatter/YamlSuggestionFormatterTest.php +++ b/tests/bundle/Core/DependencyInjection/Configuration/Suggestion/Formatter/YamlSuggestionFormatterTest.php @@ -13,7 +13,7 @@ class YamlSuggestionFormatterTest extends TestCase { - public function testFormat() + public function testFormat(): void { $message = <<format($suggestion))); } - public function testFormatNoSuggestion() + public function testFormatNoSuggestion(): void { $message = 'This is a message'; $suggestion = new ConfigSuggestion($message); diff --git a/tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php b/tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php index 6035fcac94..612ea53716 100644 --- a/tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php +++ b/tests/bundle/Core/DependencyInjection/IbexaCoreExtensionTest.php @@ -24,6 +24,7 @@ use Ibexa\Tests\Bundle\Core\DependencyInjection\Stub\QueryTypeBundle\QueryType\TestQueryType; use Ibexa\Tests\Bundle\Core\DependencyInjection\Stub\StubPolicyProvider; use Matthias\SymfonyDependencyInjectionTest\PhpUnit\AbstractExtensionTestCase; +use PHPUnit\Framework\Attributes\DataProvider; use Symfony\Component\Config\Definition\Exception\InvalidConfigurationException; use Symfony\Component\Config\FileLocator; use Symfony\Component\DependencyInjection\Compiler\CheckExceptionOnInvalidReferenceBehaviorPass; @@ -88,7 +89,7 @@ protected function getMinimalConfiguration(): array return $this->minimalConfig = Yaml::parse(file_get_contents(__DIR__ . '/Fixtures/ezpublish_minimal_no_siteaccess.yml')); } - public function testSiteAccessConfiguration() + public function testSiteAccessConfiguration(): void { $this->load($this->siteaccessConfig); $this->assertContainerBuilderHasParameter( @@ -121,7 +122,7 @@ public function testSiteAccessConfiguration() } } - public function testSiteAccessNoConfiguration() + public function testSiteAccessNoConfiguration(): void { $this->load(); $this->assertContainerBuilderHasParameter('ibexa.site_access.list', ['setup']); @@ -131,7 +132,7 @@ public function testSiteAccessNoConfiguration() $this->assertContainerBuilderHasParameter('ibexa.site_access.match_config', null); } - public function testImageMagickConfigurationBasic() + public function testImageMagickConfigurationBasic(): void { if (!isset($_ENV['imagemagickConvertPath']) || !is_executable($_ENV['imagemagickConvertPath'])) { self::markTestSkipped('Missing or mis-configured Imagemagick convert path.'); @@ -150,9 +151,7 @@ public function testImageMagickConfigurationBasic() $this->assertContainerBuilderHasParameter('ibexa.image.imagemagick.executable', basename($_ENV['imagemagickConvertPath'])); } - /** - * @dataProvider translationsConfigurationProvider - */ + #[DataProvider('translationsConfigurationProvider')] public function testUITranslationsConfiguration( bool $enabled, bool $expectedParameterValue @@ -175,7 +174,7 @@ public function testUITranslationsConfiguration( /** * @return iterable */ - public function translationsConfigurationProvider(): iterable + public static function translationsConfigurationProvider(): iterable { yield 'translations enabled' => [ true, @@ -188,7 +187,7 @@ public function translationsConfigurationProvider(): iterable ]; } - public function testImageMagickConfigurationFilters() + public function testImageMagickConfigurationFilters(): void { if (!isset($_ENV['imagemagickConvertPath']) || !is_executable($_ENV['imagemagickConvertPath'])) { self::markTestSkipped('Missing or mis-configured Imagemagick convert path.'); @@ -215,7 +214,7 @@ public function testImageMagickConfigurationFilters() self::assertSame($customFilters['wow'], $filters['wow']); } - public function testImagePlaceholderConfiguration() + public function testImagePlaceholderConfiguration(): void { $this->load([ 'image_placeholder' => [ @@ -250,7 +249,7 @@ public function testImagePlaceholderConfiguration() ], $this->container->getParameter('ibexa.io.images.alias.placeholder_provider')); } - public function testRoutingConfiguration() + public function testRoutingConfiguration(): void { $this->load(); $this->assertContainerBuilderHasAlias('router', ChainRouter::class); @@ -263,19 +262,21 @@ public function testRoutingConfiguration() } /** - * @dataProvider cacheConfigurationProvider - * * @param array $customCacheConfig * @param string $expectedPurgeType */ - public function testCacheConfiguration(array $customCacheConfig, $expectedPurgeType) + #[DataProvider('cacheConfigurationProvider')] + public function testCacheConfiguration(array $customCacheConfig, $expectedPurgeType): void { $this->load($customCacheConfig); $this->assertContainerBuilderHasParameter('ibexa.http_cache.purge_type', $expectedPurgeType); } - public function cacheConfigurationProvider() + /** + * @return array + */ + public static function cacheConfigurationProvider(): array { return [ [[], 'local'], @@ -312,7 +313,7 @@ public function cacheConfigurationProvider() ]; } - public function testCacheConfigurationCustomPurgeService() + public function testCacheConfigurationCustomPurgeService(): void { $serviceId = 'foobar'; $this->setDefinition($serviceId, new Definition()); @@ -325,7 +326,7 @@ public function testCacheConfigurationCustomPurgeService() $this->assertContainerBuilderHasParameter('ibexa.http_cache.purge_type', 'foobar'); } - public function testLocaleConfiguration() + public function testLocaleConfiguration(): void { $this->load(['locale_conversion' => ['foo' => 'bar']]); $conversionMap = $this->container->getParameter('ibexa.locale.conversion_map'); @@ -333,7 +334,7 @@ public function testLocaleConfiguration() self::assertSame('bar', $conversionMap['foo']); } - public function testRepositoriesConfiguration() + public function testRepositoriesConfiguration(): void { $repositories = [ 'main' => [ @@ -383,10 +384,8 @@ public function testRepositoriesConfiguration() self::assertSame($repositories, $this->container->getParameter('ibexa.repositories')); } - /** - * @dataProvider repositoriesConfigurationFieldGroupsProvider - */ - public function testRepositoriesConfigurationFieldGroups($repositories, $expectedRepositories) + #[DataProvider('repositoriesConfigurationFieldGroupsProvider')] + public function testRepositoriesConfigurationFieldGroups($repositories, $expectedRepositories): void { $this->load(['repositories' => $repositories]); self::assertTrue($this->container->hasParameter('ibexa.repositories')); @@ -401,7 +400,10 @@ public function testRepositoriesConfigurationFieldGroups($repositories, $expecte } } - public function repositoriesConfigurationFieldGroupsProvider() + /** + * @return array + */ + public static function repositoriesConfigurationFieldGroupsProvider(): array { return [ //empty config @@ -521,7 +523,7 @@ public function repositoriesConfigurationFieldGroupsProvider() ]; } - public function testRepositoriesConfigurationEmpty() + public function testRepositoriesConfigurationEmpty(): void { $repositories = [ 'main' => null, @@ -557,7 +559,7 @@ public function testRepositoriesConfigurationEmpty() ); } - public function testRepositoriesConfigurationStorageEmpty() + public function testRepositoriesConfigurationStorageEmpty(): void { $repositories = [ 'main' => [ @@ -598,7 +600,7 @@ public function testRepositoriesConfigurationStorageEmpty() ); } - public function testRepositoriesConfigurationSearchEmpty() + public function testRepositoriesConfigurationSearchEmpty(): void { $repositories = [ 'main' => [ @@ -639,7 +641,7 @@ public function testRepositoriesConfigurationSearchEmpty() ); } - public function testRepositoriesConfigurationCompatibility() + public function testRepositoriesConfigurationCompatibility(): void { $repositories = [ 'main' => [ @@ -710,7 +712,7 @@ public function testRepositoriesConfigurationCompatibility() ); } - public function testRepositoriesConfigurationCompatibility2() + public function testRepositoriesConfigurationCompatibility2(): void { $repositories = [ 'main' => [ @@ -749,7 +751,7 @@ public function testRepositoriesConfigurationCompatibility2() ); } - public function testRegisteredPolicies() + public function testRegisteredPolicies(): void { $this->load(); $this->assertContainerBuilderHasParameter('ibexa.api.role.policy_map'); @@ -801,7 +803,7 @@ public function testRegisteredPolicies() self::assertEquals($expectedPolicies, $this->container->getParameter('ibexa.api.role.policy_map')); } - public function testUrlAliasConfiguration() + public function testUrlAliasConfiguration(): void { $configuration = [ 'transformation' => 'urlalias_lowercase', @@ -860,11 +862,11 @@ public function testQueryTypeAutomaticConfiguration(): void * Test automatic configuration of services implementing Criterion & SortClause Filtering Query * Builders. * - * @dataProvider getFilteringQueryBuilderData * * @see \Ibexa\Contracts\Core\Repository\Values\Filter\CriterionQueryBuilder * @see \Ibexa\Contracts\Core\Repository\Values\Filter\SortClauseQueryBuilder */ + #[DataProvider('getFilteringQueryBuilderData')] public function testFilteringQueryBuildersAutomaticConfiguration( string $classFQCN, string $tagName @@ -886,7 +888,7 @@ public function testFilteringQueryBuildersAutomaticConfiguration( /** * Data provider for {@see testFilteringQueryBuildersAutomaticConfiguration}. */ - public function getFilteringQueryBuilderData(): iterable + public static function getFilteringQueryBuilderData(): iterable { yield Filter\CriterionQueryBuilder::class => [ CustomCriterionQueryBuilder::class, diff --git a/tests/bundle/Core/DependencyInjection/Security/PolicyProvider/PoliciesConfigBuilderTest.php b/tests/bundle/Core/DependencyInjection/Security/PolicyProvider/PoliciesConfigBuilderTest.php index 4914843b4c..b86e1f1574 100644 --- a/tests/bundle/Core/DependencyInjection/Security/PolicyProvider/PoliciesConfigBuilderTest.php +++ b/tests/bundle/Core/DependencyInjection/Security/PolicyProvider/PoliciesConfigBuilderTest.php @@ -8,6 +8,7 @@ namespace Ibexa\Tests\Bundle\Core\DependencyInjection\Security\PolicyProvider; use Ibexa\Bundle\Core\DependencyInjection\Security\PolicyProvider\PoliciesConfigBuilder; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\Config\Resource\DirectoryResource; use Symfony\Component\Config\Resource\FileResource; @@ -15,9 +16,7 @@ class PoliciesConfigBuilderTest extends TestCase { - /** - * @dataProvider policiesConfigProvider - */ + #[DataProvider('policiesConfigProvider')] public function testAddConfig(array $configOne, array $configTwo, array $expectedConfig): void { $containerBuilder = new ContainerBuilder(); @@ -29,7 +28,7 @@ public function testAddConfig(array $configOne, array $configTwo, array $expecte self::assertSame($expectedConfig, $containerBuilder->getParameter('ibexa.api.role.policy_map')); } - public function policiesConfigProvider(): array + public static function policiesConfigProvider(): array { return [ 'add' => [ @@ -57,7 +56,7 @@ public function policiesConfigProvider(): array ]; } - public function testAddResource() + public function testAddResource(): void { $containerBuilder = new ContainerBuilder(); $configBuilder = new PoliciesConfigBuilder($containerBuilder); diff --git a/tests/bundle/Core/DependencyInjection/Security/PolicyProvider/YamlPolicyProviderTest.php b/tests/bundle/Core/DependencyInjection/Security/PolicyProvider/YamlPolicyProviderTest.php index 74285ddb49..cfc0a9fefd 100644 --- a/tests/bundle/Core/DependencyInjection/Security/PolicyProvider/YamlPolicyProviderTest.php +++ b/tests/bundle/Core/DependencyInjection/Security/PolicyProvider/YamlPolicyProviderTest.php @@ -14,7 +14,7 @@ class YamlPolicyProviderTest extends TestCase { - public function testSingleYaml() + public function testSingleYaml(): void { $files = [__DIR__ . '/../../Fixtures/policies1.yml']; $provider = new StubYamlPolicyProvider($files); @@ -44,7 +44,7 @@ public function testSingleYaml() $provider->addPolicies($configBuilder); } - public function testMultipleYaml() + public function testMultipleYaml(): void { $file1 = __DIR__ . '/../../Fixtures/policies1.yml'; $file2 = __DIR__ . '/../../Fixtures/policies2.yml'; diff --git a/tests/bundle/Core/Doctrine/ManagedTablesSchemaAssetFilterTest.php b/tests/bundle/Core/Doctrine/ManagedTablesSchemaAssetFilterTest.php index edf01ba496..d0dcf0ab97 100644 --- a/tests/bundle/Core/Doctrine/ManagedTablesSchemaAssetFilterTest.php +++ b/tests/bundle/Core/Doctrine/ManagedTablesSchemaAssetFilterTest.php @@ -25,8 +25,8 @@ final class ManagedTablesSchemaAssetFilterTest extends TestCase private function createFilter(array $entityTableNames): ManagedTablesSchemaAssetFilter { $classMetadataList = array_map( - function (string $tableName): ClassMetadata { - $classMetadata = $this->createStub(ClassMetadata::class); + static function (string $tableName): ClassMetadata { + $classMetadata = self::createStub(ClassMetadata::class); $classMetadata->method('getTableName')->willReturn($tableName); return $classMetadata; @@ -34,15 +34,15 @@ function (string $tableName): ClassMetadata { $entityTableNames ); - $metadataFactory = $this->createStub(ClassMetadataFactory::class); + $metadataFactory = self::createStub(ClassMetadataFactory::class); $metadataFactory->method('getAllMetadata')->willReturn($classMetadataList); - $entityManager = $this->createStub(EntityManagerInterface::class); + $entityManager = self::createStub(EntityManagerInterface::class); $entityManager->method('getMetadataFactory')->willReturn($metadataFactory); - $nonEntityManager = $this->createStub(ObjectManager::class); + $nonEntityManager = self::createStub(ObjectManager::class); - $managerRegistry = $this->createStub(ManagerRegistry::class); + $managerRegistry = self::createStub(ManagerRegistry::class); $managerRegistry->method('getManagers')->willReturn([$entityManager, $nonEntityManager]); return new ManagedTablesSchemaAssetFilter($managerRegistry); diff --git a/tests/bundle/Core/Entity/EntityManagerFactoryTest.php b/tests/bundle/Core/Entity/EntityManagerFactoryTest.php index 98292fa89b..5494a13f7a 100644 --- a/tests/bundle/Core/Entity/EntityManagerFactoryTest.php +++ b/tests/bundle/Core/Entity/EntityManagerFactoryTest.php @@ -12,13 +12,12 @@ use Ibexa\Bundle\Core\Entity\EntityManagerFactory; use Ibexa\Contracts\Core\Container\ApiLoader\RepositoryConfigurationProviderInterface; use InvalidArgumentException; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; use Symfony\Component\DependencyInjection\ServiceLocator; -/** - * @covers \Ibexa\Bundle\Core\Entity\EntityManagerFactory - */ +#[CoversClass(EntityManagerFactory::class)] final class EntityManagerFactoryTest extends TestCase { private const string DEFAULT_ENTITY_MANAGER = 'doctrine.orm.ibexa_default_entity_manager'; diff --git a/tests/bundle/Core/EventListener/BackgroundIndexingTerminateListenerTest.php b/tests/bundle/Core/EventListener/BackgroundIndexingTerminateListenerTest.php index 441bf638c1..db49415e91 100644 --- a/tests/bundle/Core/EventListener/BackgroundIndexingTerminateListenerTest.php +++ b/tests/bundle/Core/EventListener/BackgroundIndexingTerminateListenerTest.php @@ -14,6 +14,7 @@ use Ibexa\Contracts\Core\Persistence\Handler as PersistenceHandler; use Ibexa\Contracts\Core\Search\Handler as SearchHandler; use Ibexa\Core\Base\Exceptions\NotFoundException; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Psr\Log\LoggerInterface; use Symfony\Component\Console\ConsoleEvents; @@ -47,7 +48,7 @@ protected function tearDown(): void parent::tearDown(); } - public function testGetSubscribedEvents() + public function testGetSubscribedEvents(): void { self::assertSame( [ @@ -59,30 +60,32 @@ public function testGetSubscribedEvents() ); } - public function indexingProvider() + /** + * @return array + */ + public static function indexingProvider(): array { $info = new ContentInfo(['id' => 33]); $location = new Location(['id' => 44, 'contentId' => 33]); return [ [[$location]], - [[$location], $this->createMock(LoggerInterface::class)], + [[$location], self::createStub(LoggerInterface::class)], [[$info]], - [[$info], $this->createMock(LoggerInterface::class)], + [[$info], self::createStub(LoggerInterface::class)], [null], - [null, $this->createMock(LoggerInterface::class)], + [null, self::createStub(LoggerInterface::class)], [[$location, $info]], - [[$info, $location], $this->createMock(LoggerInterface::class)], + [[$info, $location], self::createStub(LoggerInterface::class)], ]; } /** - * @dataProvider indexingProvider - * * @param array|null $value * @param \Psr\Log\LoggerInterface|\PHPUnit\Framework\MockObject\MockObject|null $logger */ - public function testIndexing(?array $values = null, $logger = null) + #[DataProvider('indexingProvider')] + public function testIndexing(?array $values = null, $logger = null): void { $contentHandlerMock = $this->createMock(Content\Handler::class); $this->persistenceMock @@ -130,7 +133,7 @@ public function testIndexing(?array $values = null, $logger = null) if ($values) { $logger->expects(self::once()) ->method('warning') - ->with(self::isType('string')); + ->with(self::isString()); } else { $logger->expects(self::never()) ->method('warning'); @@ -140,14 +143,17 @@ public function testIndexing(?array $values = null, $logger = null) $this->listener->reindex(); } - public function indexDeleteProvider() + /** + * @return array + */ + public static function indexDeleteProvider(): array { $location = new Location(['id' => 44, 'contentId' => 33]); $info = new ContentInfo(['id' => 33, 'currentVersionNo' => 2, 'status' => ContentInfo::STATUS_PUBLISHED]); - $infoReturn = self::returnValue($info); - $infoReturnUnPublished = self::returnValue(new ContentInfo(['id' => 33, 'currentVersionNo' => 2])); - $returnThrow = self::throwException(new NotFoundException('content', '33')); + $infoReturn = $info; + $infoReturnUnPublished = new ContentInfo(['id' => 33, 'currentVersionNo' => 2]); + $returnThrow = new NotFoundException('content', '33'); return [ [$location, $infoReturn, $returnThrow], @@ -160,14 +166,8 @@ public function indexDeleteProvider() ]; } - /** - * @dataProvider indexDeleteProvider - * - * @param \Ibexa\Contracts\Core\Persistence\Content\ContentInfo|\Ibexa\Contracts\Core\Persistence\Content\Location $value - * @param \PHPUnit\Framework\MockObject\Stub $infoReturn - * @param \PHPUnit\Framework\MockObject\Stub|null $contentReturn - */ - public function testIndexDelete($value, $infoReturn, $contentReturn = null) + #[DataProvider('indexDeleteProvider')] + public function testIndexDelete(ContentInfo|Location $value, ContentInfo|\Throwable $infoReturn, Content|\Throwable|null $contentReturn = null): void { $contentHandlerMock = $this->createMock(Content\Handler::class); $this->persistenceMock @@ -175,18 +175,26 @@ public function testIndexDelete($value, $infoReturn, $contentReturn = null) ->method('contentHandler') ->willReturn($contentHandlerMock); - $contentHandlerMock + $loadContentInfoExpectation = $contentHandlerMock ->expects(self::once()) ->method('loadContentInfo') - ->with(33) - ->will($infoReturn); + ->with(33); + if ($infoReturn instanceof \Throwable) { + $loadContentInfoExpectation->willThrowException($infoReturn); + } else { + $loadContentInfoExpectation->willReturn($infoReturn); + } if ($contentReturn) { - $contentHandlerMock + $loadExpectation = $contentHandlerMock ->expects(self::once()) ->method('load') - ->with(33, 2) - ->will($contentReturn); + ->with(33, 2); + if ($contentReturn instanceof \Throwable) { + $loadExpectation->willThrowException($contentReturn); + } else { + $loadExpectation->willReturn($contentReturn); + } } else { $contentHandlerMock ->expects(self::never()) diff --git a/tests/bundle/Core/EventListener/ConfigScopeListenerTest.php b/tests/bundle/Core/EventListener/ConfigScopeListenerTest.php index 868d52185a..04d148d940 100644 --- a/tests/bundle/Core/EventListener/ConfigScopeListenerTest.php +++ b/tests/bundle/Core/EventListener/ConfigScopeListenerTest.php @@ -33,12 +33,12 @@ protected function setUp(): void $this->configResolver = $this->createMock(VersatileScopeInterface::class); $this->viewManager = $this->createMock(ViewManager::class); $this->viewProviders = [ - $this->createMock(ViewProvider::class), - $this->createMock(ViewProvider::class), + self::createStub(ViewProvider::class), + self::createStub(ViewProvider::class), ]; } - public function testGetSubscribedEvents() + public function testGetSubscribedEvents(): void { self::assertSame( [ @@ -49,7 +49,7 @@ public function testGetSubscribedEvents() ); } - public function testOnConfigScopeChange() + public function testOnConfigScopeChange(): void { $siteAccess = new SiteAccess('test'); $event = new ScopeChangeEvent($siteAccess); diff --git a/tests/bundle/Core/EventListener/ConsoleCommandListenerTest.php b/tests/bundle/Core/EventListener/ConsoleCommandListenerTest.php index 511a6547db..8da45863df 100644 --- a/tests/bundle/Core/EventListener/ConsoleCommandListenerTest.php +++ b/tests/bundle/Core/EventListener/ConsoleCommandListenerTest.php @@ -11,6 +11,7 @@ use Ibexa\Core\MVC\Exception\InvalidSiteAccessException; use Ibexa\Core\MVC\Symfony\SiteAccess; use Ibexa\Tests\Bundle\Core\EventListener\Stubs\TestOutput; +use PHPUnit\Framework\MockObject\Stub; use PHPUnit\Framework\TestCase; use Symfony\Component\Console\Command\Command; use Symfony\Component\Console\ConsoleEvents; @@ -40,8 +41,7 @@ class ConsoleCommandListenerTest extends TestCase /** @var \Symfony\Component\Console\Output\Output */ private $testOutput; - /** @var \Symfony\Component\Console\Command\Command|\PHPUnit\Framework\MockObject\MockObject */ - private $command; + private Command&Stub $command; protected function setUp(): void { @@ -53,10 +53,10 @@ protected function setUp(): void $this->dispatcher->addSubscriber($this->listener); $this->inputDefinition = new InputDefinition([new InputOption('siteaccess', null, InputOption::VALUE_OPTIONAL)]); $this->testOutput = new TestOutput(Output::VERBOSITY_QUIET, true); - $this->command = $this->createMock(Command::class); + $this->command = self::createStub(Command::class); } - public function testGetSubscribedEvents() + public function testGetSubscribedEvents(): void { self::assertSame( [ @@ -66,7 +66,7 @@ public function testGetSubscribedEvents() ); } - public function testInvalidSiteAccessDev() + public function testInvalidSiteAccessDev(): void { $this->expectException(InvalidSiteAccessException::class); $this->expectExceptionMessageMatches('/^Invalid SiteAccess \'foo\', matched by .+\\. Valid SiteAccesses are/'); @@ -79,7 +79,7 @@ public function testInvalidSiteAccessDev() $this->listener->onConsoleCommand($event); } - public function testInvalidSiteAccessProd() + public function testInvalidSiteAccessProd(): void { $this->expectException(InvalidSiteAccessException::class); $this->expectExceptionMessageMatches('/^Invalid SiteAccess \'foo\', matched by .+\\.$/'); @@ -92,7 +92,7 @@ public function testInvalidSiteAccessProd() $this->listener->onConsoleCommand($event); } - public function testValidSiteAccess() + public function testValidSiteAccess(): void { $this->dispatcher->expects(self::once()) ->method('dispatch'); @@ -102,7 +102,7 @@ public function testValidSiteAccess() self::assertEquals(new SiteAccess('site1', 'cli'), $this->siteAccess); } - public function testDefaultSiteAccess() + public function testDefaultSiteAccess(): void { $this->dispatcher->expects(self::once()) ->method('dispatch'); diff --git a/tests/bundle/Core/EventListener/ContentDownloadRouteReferenceListenerTest.php b/tests/bundle/Core/EventListener/ContentDownloadRouteReferenceListenerTest.php index d33fa227d8..ff5528a4a2 100644 --- a/tests/bundle/Core/EventListener/ContentDownloadRouteReferenceListenerTest.php +++ b/tests/bundle/Core/EventListener/ContentDownloadRouteReferenceListenerTest.php @@ -30,7 +30,7 @@ protected function setUp(): void $this->translationHelperMock = $this->createMock(TranslationHelper::class); } - public function testIgnoresOtherRoutes() + public function testIgnoresOtherRoutes(): void { $routeReference = new RouteReference('some_route'); $event = new RouteReferenceGenerationEvent($routeReference, new Request()); @@ -41,7 +41,7 @@ public function testIgnoresOtherRoutes() self::assertEquals('some_route', $routeReference->getRoute()); } - public function testThrowsExceptionOnBadContentParameter() + public function testThrowsExceptionOnBadContentParameter(): void { $this->expectException(\InvalidArgumentException::class); @@ -58,7 +58,7 @@ public function testThrowsExceptionOnBadContentParameter() $eventListener->onRouteReferenceGeneration($event); } - public function testThrowsExceptionOnBadFieldIdentifier() + public function testThrowsExceptionOnBadFieldIdentifier(): void { $this->expectException(\InvalidArgumentException::class); @@ -86,7 +86,7 @@ public function testThrowsExceptionOnBadFieldIdentifier() $eventListener->onRouteReferenceGeneration($event); } - public function testGeneratesCorrectRouteReference() + public function testGeneratesCorrectRouteReference(): void { $content = $this->getCompleteContent(); @@ -112,7 +112,7 @@ public function testGeneratesCorrectRouteReference() self::assertEquals('Test-file.pdf', $routeReference->get(ContentDownloadRouteReferenceListener::OPT_DOWNLOAD_NAME)); } - public function testDownloadNameOverrideWorks() + public function testDownloadNameOverrideWorks(): void { $content = $this->getCompleteContent(); diff --git a/tests/bundle/Core/EventListener/ExceptionListenerTest.php b/tests/bundle/Core/EventListener/ExceptionListenerTest.php index 3d403783a5..b5489972d2 100644 --- a/tests/bundle/Core/EventListener/ExceptionListenerTest.php +++ b/tests/bundle/Core/EventListener/ExceptionListenerTest.php @@ -24,6 +24,8 @@ use Ibexa\Core\Base\Exceptions\NotFound\LimitationNotFoundException; use Ibexa\Core\Base\Exceptions\NotFoundException; use Ibexa\Core\Base\Exceptions\UnauthorizedException; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; use RuntimeException; use Symfony\Component\HttpFoundation\Request; @@ -40,8 +42,7 @@ class ExceptionListenerTest extends TestCase { - /** @var \PHPUnit\Framework\MockObject\MockObject&\Symfony\Contracts\Translation\TranslatorInterface */ - private TranslatorInterface $translator; + private TranslatorInterface&MockObject $translator; private ExceptionListener $listener; @@ -66,7 +67,7 @@ public function testGetSubscribedEvents(): void private function generateExceptionEvent(Exception $exception): ExceptionEvent { return new ExceptionEvent( - $this->createMock(HttpKernelInterface::class), + self::createStub(HttpKernelInterface::class), new Request(), HttpKernelInterface::MAIN_REQUEST, $exception @@ -114,10 +115,9 @@ public function testUnauthorizedException(): void } /** - * @dataProvider badRequestExceptionProvider - * * @param \Exception&\Ibexa\Core\Base\Translatable $exception */ + #[DataProvider('badRequestExceptionProvider')] public function testBadRequestException(Exception $exception): void { $messageTemplate = 'some message template'; @@ -138,10 +138,9 @@ public function testBadRequestException(Exception $exception): void } /** - * @dataProvider provideDataForTestForbiddenException - * * @param \Exception&\Ibexa\Core\Base\Translatable $exception */ + #[DataProvider('provideDataForTestForbiddenException')] public function testForbiddenException(Exception $exception): void { $messageTemplate = 'some message template'; @@ -174,10 +173,9 @@ public function testUntouchedException(): void } /** - * @dataProvider otherExceptionProvider - * * @param \Exception&\Ibexa\Core\Base\Translatable $exception */ + #[DataProvider('otherExceptionProvider')] public function testOtherRepositoryException(Exception $exception): void { $messageTemplate = 'some message template'; @@ -200,7 +198,7 @@ public function testOtherRepositoryException(Exception $exception): void /** * @return iterable */ - public function badRequestExceptionProvider(): iterable + public static function badRequestExceptionProvider(): iterable { return [ [new BadStateException('foo', 'bar')], @@ -213,7 +211,7 @@ public function badRequestExceptionProvider(): iterable /** * @return iterable */ - public function provideDataForTestForbiddenException(): iterable + public static function provideDataForTestForbiddenException(): iterable { return [ [new ForbiddenException('foo "%param%"', ['%param%' => 'bar'])], @@ -228,7 +226,7 @@ public function provideDataForTestForbiddenException(): iterable /** * @return iterable */ - public function otherExceptionProvider(): iterable + public static function otherExceptionProvider(): iterable { return [ [new MissingClass('foo')], diff --git a/tests/bundle/Core/EventListener/IndexRequestListenerTest.php b/tests/bundle/Core/EventListener/IndexRequestListenerTest.php index 854bcc1947..071fcb85e4 100644 --- a/tests/bundle/Core/EventListener/IndexRequestListenerTest.php +++ b/tests/bundle/Core/EventListener/IndexRequestListenerTest.php @@ -9,6 +9,8 @@ use Ibexa\Bundle\Core\EventListener\IndexRequestListener; use Ibexa\Contracts\Core\SiteAccess\ConfigResolverInterface; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\MockObject\Stub; use PHPUnit\Framework\TestCase; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpKernel\Event\RequestEvent; @@ -29,8 +31,7 @@ class IndexRequestListenerTest extends TestCase /** @var \Symfony\Component\HttpKernel\Event\RequestEvent */ private $event; - /** @var \Symfony\Component\HttpKernel\HttpKernelInterface|\PHPUnit\Framework\MockObject\MockObject */ - private $httpKernel; + private HttpKernelInterface&Stub $httpKernel; protected function setUp(): void { @@ -42,10 +43,10 @@ protected function setUp(): void $this->request = $this ->getMockBuilder(Request::class) - ->setMethods(['getSession', 'hasSession']) + ->onlyMethods(['getSession', 'hasSession']) ->getMock(); - $this->httpKernel = $this->createMock(HttpKernelInterface::class); + $this->httpKernel = self::createStub(HttpKernelInterface::class); $this->event = new RequestEvent( $this->httpKernel, $this->request, @@ -53,7 +54,7 @@ protected function setUp(): void ); } - public function testSubscribedEvents() + public function testSubscribedEvents(): void { self::assertSame( [ @@ -65,10 +66,8 @@ public function testSubscribedEvents() ); } - /** - * @dataProvider indexPageProvider - */ - public function testOnKernelRequestIndexOnIndexPage($requestPath, $configuredIndexPath, $expectedIndexPath) + #[DataProvider('indexPageProvider')] + public function testOnKernelRequestIndexOnIndexPage($requestPath, $configuredIndexPath, $expectedIndexPath): void { $this->configResolver ->expects(self::once()) @@ -81,7 +80,10 @@ public function testOnKernelRequestIndexOnIndexPage($requestPath, $configuredInd self::assertTrue($this->request->attributes->get('needsRedirect')); } - public function indexPageProvider() + /** + * @return array + */ + public static function indexPageProvider(): array { return [ ['/', '/foo', '/foo'], @@ -94,7 +96,7 @@ public function indexPageProvider() ]; } - public function testOnKernelRequestIndexNotOnIndexPage() + public function testOnKernelRequestIndexNotOnIndexPage(): void { $this->request->attributes->set('semanticPathinfo', '/anyContent'); $this->indexRequestEventListener->onKernelRequestIndex($this->event); diff --git a/tests/bundle/Core/EventListener/LocaleListenerTest.php b/tests/bundle/Core/EventListener/LocaleListenerTest.php index 8f25e9f67b..8456a42309 100644 --- a/tests/bundle/Core/EventListener/LocaleListenerTest.php +++ b/tests/bundle/Core/EventListener/LocaleListenerTest.php @@ -10,6 +10,7 @@ use Ibexa\Bundle\Core\EventListener\LocaleListener; use Ibexa\Contracts\Core\SiteAccess\ConfigResolverInterface; use Ibexa\Core\MVC\Symfony\Locale\LocaleConverterInterface; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\HttpFoundation\ParameterBag; use Symfony\Component\HttpFoundation\Request; @@ -42,9 +43,7 @@ protected function setUp(): void $this->requestStack = new RequestStack([$requestMock]); } - /** - * @dataProvider onKernelRequestProvider - */ + #[DataProvider('onKernelRequestProvider')] public function testOnKernelRequest(array $configuredLanguages, array $convertedLocalesValueMap, $expectedLocale): void { $this->configResolver @@ -67,7 +66,7 @@ public function testOnKernelRequest(array $configuredLanguages, array $converted $request = new Request(); $localeListener->onKernelRequest( new RequestEvent( - $this->createMock(HttpKernelInterface::class), + self::createStub(HttpKernelInterface::class), $request, HttpKernelInterface::MAIN_REQUEST ) @@ -75,7 +74,7 @@ public function testOnKernelRequest(array $configuredLanguages, array $converted self::assertSame($expectedLocale, $request->attributes->get('_locale')); } - public function onKernelRequestProvider(): array + public static function onKernelRequestProvider(): array { return [ [ diff --git a/tests/bundle/Core/EventListener/OriginalRequestListenerTest.php b/tests/bundle/Core/EventListener/OriginalRequestListenerTest.php index 049931a944..db61740c8f 100644 --- a/tests/bundle/Core/EventListener/OriginalRequestListenerTest.php +++ b/tests/bundle/Core/EventListener/OriginalRequestListenerTest.php @@ -17,7 +17,7 @@ class OriginalRequestListenerTest extends TestCase { - public function testGetSubscribedEvents() + public function testGetSubscribedEvents(): void { self::assertSame( [ @@ -27,11 +27,11 @@ public function testGetSubscribedEvents() ); } - public function testOnKernelRequestNotMaster() + public function testOnKernelRequestNotMaster(): void { $request = new Request(); $event = new RequestEvent( - $this->createMock(HttpKernelInterface::class), + self::createStub(HttpKernelInterface::class), $request, HttpKernelInterface::SUB_REQUEST ); @@ -41,11 +41,11 @@ public function testOnKernelRequestNotMaster() self::assertFalse($request->attributes->has('_ez_original_request')); } - public function testOnKernelRequestNoOriginalRequest() + public function testOnKernelRequestNoOriginalRequest(): void { $request = new Request(); $event = new RequestEvent( - $this->createMock(HttpKernelInterface::class), + self::createStub(HttpKernelInterface::class), $request, HttpKernelInterface::MAIN_REQUEST ); @@ -55,7 +55,7 @@ public function testOnKernelRequestNoOriginalRequest() self::assertFalse($request->attributes->has('_ez_original_request')); } - public function testOnKernelRequestWithOriginalRequest() + public function testOnKernelRequestWithOriginalRequest(): void { ClockMock::withClockMock(true); @@ -73,7 +73,7 @@ public function testOnKernelRequestWithOriginalRequest() $request->headers->set('x-fos-original-url', $originalUri); $request->headers->set('x-fos-original-accept', $originalAccept); $event = new RequestEvent( - $this->createMock(HttpKernelInterface::class), + self::createStub(HttpKernelInterface::class), $request, HttpKernelInterface::MAIN_REQUEST ); diff --git a/tests/bundle/Core/EventListener/RejectExplicitFrontControllerRequestsListenerTest.php b/tests/bundle/Core/EventListener/RejectExplicitFrontControllerRequestsListenerTest.php index 21e5ffc075..b6bd3aa2c4 100644 --- a/tests/bundle/Core/EventListener/RejectExplicitFrontControllerRequestsListenerTest.php +++ b/tests/bundle/Core/EventListener/RejectExplicitFrontControllerRequestsListenerTest.php @@ -9,6 +9,9 @@ namespace Ibexa\Tests\Bundle\Core\EventListener; use Ibexa\Bundle\Core\EventListener\RejectExplicitFrontControllerRequestsListener; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\DoesNotPerformAssertions; +use PHPUnit\Framework\MockObject\Stub; use PHPUnit\Framework\TestCase; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpKernel\Event\RequestEvent; @@ -21,15 +24,14 @@ class RejectExplicitFrontControllerRequestsListenerTest extends TestCase /** @var \Ibexa\Bundle\Core\EventListener\RejectExplicitFrontControllerRequestsListener */ private $eventListener; - /** @var \Symfony\Component\HttpKernel\HttpKernelInterface|\PHPUnit\Framework\MockObject\MockObject */ - private $httpKernel; + private HttpKernelInterface&Stub $httpKernel; protected function setUp(): void { parent::setUp(); $this->eventListener = new RejectExplicitFrontControllerRequestsListener(); - $this->httpKernel = $this->createMock(HttpKernelInterface::class); + $this->httpKernel = self::createStub(HttpKernelInterface::class); } public function testSubscribedEvents(): void @@ -44,11 +46,8 @@ public function testSubscribedEvents(): void ); } - /** - * @dataProvider validRequestDataProvider - * - * @doesNotPerformAssertions - */ + #[DataProvider('validRequestDataProvider')] + #[DoesNotPerformAssertions] public function testOnKernelRequest(Request $request): void { $event = new RequestEvent( @@ -60,9 +59,7 @@ public function testOnKernelRequest(Request $request): void $this->eventListener->onKernelRequest($event); } - /** - * @dataProvider prohibitedRequestDataProvider - */ + #[DataProvider('prohibitedRequestDataProvider')] public function testOnKernelRequestThrowsException(Request $request): void { $this->expectException(NotFoundHttpException::class); @@ -76,7 +73,7 @@ public function testOnKernelRequestThrowsException(Request $request): void $this->eventListener->onKernelRequest($event); } - public function validRequestDataProvider(): array + public static function validRequestDataProvider(): array { return [ [ @@ -212,7 +209,7 @@ public function validRequestDataProvider(): array ]; } - public function prohibitedRequestDataProvider(): array + public static function prohibitedRequestDataProvider(): array { return [ [ diff --git a/tests/bundle/Core/EventListener/RequestEventListenerTest.php b/tests/bundle/Core/EventListener/RequestEventListenerTest.php index f3bbd9d5d7..6edce24604 100644 --- a/tests/bundle/Core/EventListener/RequestEventListenerTest.php +++ b/tests/bundle/Core/EventListener/RequestEventListenerTest.php @@ -10,6 +10,7 @@ use Ibexa\Bundle\Core\EventListener\RequestEventListener; use Ibexa\Contracts\Core\SiteAccess\ConfigResolverInterface; use Ibexa\Core\MVC\Symfony\SiteAccess; +use PHPUnit\Framework\MockObject\Stub; use PHPUnit\Framework\TestCase; use Psr\Log\LoggerInterface; use Symfony\Bridge\PhpUnit\ClockMock; @@ -23,14 +24,11 @@ class RequestEventListenerTest extends TestCase { - /** @var \PHPUnit\Framework\MockObject\MockObject */ - private $configResolver; + private ConfigResolverInterface&Stub $configResolver; - /** @var \PHPUnit\Framework\MockObject\MockObject */ - private $router; + private RouterInterface&Stub $router; - /** @var \PHPUnit\Framework\MockObject\MockObject|\Psr\Log\LoggerInterface */ - private $logger; + private LoggerInterface&Stub $logger; /** @var \Ibexa\Bundle\Core\EventListener\RequestEventListener */ private $requestEventListener; @@ -48,15 +46,15 @@ protected function setUp(): void { parent::setUp(); - $this->configResolver = $this->createMock(ConfigResolverInterface::class); - $this->router = $this->createMock(RouterInterface::class); - $this->logger = $this->createMock(LoggerInterface::class); + $this->configResolver = self::createStub(ConfigResolverInterface::class); + $this->router = self::createStub(RouterInterface::class); + $this->logger = self::createStub(LoggerInterface::class); $this->requestEventListener = new RequestEventListener($this->configResolver, $this->router, 'foobar', $this->logger); $this->request = $this ->getMockBuilder(Request::class) - ->setMethods(['getSession', 'hasSession']) + ->onlyMethods(['getSession', 'hasSession']) ->getMock(); $this->httpKernel = $this->createMock(HttpKernelInterface::class); @@ -67,7 +65,7 @@ protected function setUp(): void ); } - public function testSubscribedEvents() + public function testSubscribedEvents(): void { self::assertSame( [ @@ -80,7 +78,7 @@ public function testSubscribedEvents() ); } - public function testOnKernelRequestForwardSubRequest() + public function testOnKernelRequestForwardSubRequest(): void { $this->httpKernel ->expects(self::never()) @@ -90,7 +88,7 @@ public function testOnKernelRequestForwardSubRequest() $this->requestEventListener->onKernelRequestForward($event); } - public function testOnKernelRequestForward() + public function testOnKernelRequestForward(): void { ClockMock::withClockMock(true); @@ -121,14 +119,14 @@ public function testOnKernelRequestForward() ClockMock::withClockMock(false); } - public function testOnKernelRequestRedirectSubRequest() + public function testOnKernelRequestRedirectSubRequest(): void { $event = new RequestEvent($this->httpKernel, new Request(), HttpKernelInterface::SUB_REQUEST); $this->requestEventListener->onKernelRequestRedirect($event); self::assertFalse($event->hasResponse()); } - public function testOnKernelRequestRedirect() + public function testOnKernelRequestRedirect(): void { $queryParameters = ['some' => 'thing']; $cookieParameters = ['cookie' => 'value']; @@ -149,7 +147,7 @@ public function testOnKernelRequestRedirect() self::assertTrue($event->isPropagationStopped()); } - public function testOnKernelRequestRedirectWithLocationId() + public function testOnKernelRequestRedirectWithLocationId(): void { $queryParameters = ['some' => 'thing']; $cookieParameters = ['cookie' => 'value']; @@ -172,7 +170,7 @@ public function testOnKernelRequestRedirectWithLocationId() self::assertTrue($event->isPropagationStopped()); } - public function testOnKernelRequestRedirectPrependSiteaccess() + public function testOnKernelRequestRedirectPrependSiteaccess(): void { $queryParameters = ['some' => 'thing']; $cookieParameters = ['cookie' => 'value']; diff --git a/tests/bundle/Core/EventListener/RoutingListenerTest.php b/tests/bundle/Core/EventListener/RoutingListenerTest.php index 76663ac22f..9252ac101e 100644 --- a/tests/bundle/Core/EventListener/RoutingListenerTest.php +++ b/tests/bundle/Core/EventListener/RoutingListenerTest.php @@ -37,7 +37,7 @@ protected function setUp(): void $this->urlAliasGenerator = $this->createMock(UrlAliasGenerator::class); } - public function testGetSubscribedEvents() + public function testGetSubscribedEvents(): void { $listener = new RoutingListener($this->configResolver, $this->urlAliasRouter, $this->urlAliasGenerator); self::assertSame( @@ -48,7 +48,7 @@ public function testGetSubscribedEvents() ); } - public function testOnSiteAccessMatch() + public function testOnSiteAccessMatch(): void { $rootLocationId = 123; $excludedUriPrefixes = ['/foo/bar', '/baz']; diff --git a/tests/bundle/Core/EventListener/SessionSetDynamicNameListenerTest.php b/tests/bundle/Core/EventListener/SessionSetDynamicNameListenerTest.php index 618a167d3c..c013c5a931 100644 --- a/tests/bundle/Core/EventListener/SessionSetDynamicNameListenerTest.php +++ b/tests/bundle/Core/EventListener/SessionSetDynamicNameListenerTest.php @@ -13,6 +13,7 @@ use Ibexa\Core\MVC\Symfony\Event\PostSiteAccessMatchEvent; use Ibexa\Core\MVC\Symfony\MVCEvents; use Ibexa\Core\MVC\Symfony\SiteAccess; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\Session\Session; @@ -92,14 +93,12 @@ public function testOnSiteAccessMatchNonNativeSessionStorage(): void ->method('getParameter'); $listener = new SessionSetDynamicNameListener( $this->configResolver, - $this->createMock(SessionStorageFactoryInterface::class) + self::createStub(SessionStorageFactoryInterface::class) ); $listener->onSiteAccessMatch(new PostSiteAccessMatchEvent(new SiteAccess('test'), new Request(), HttpKernelInterface::SUB_REQUEST)); } - /** - * @dataProvider onSiteAccessMatchProvider - */ + #[DataProvider('onSiteAccessMatchProvider')] public function testOnSiteAccessMatch(SiteAccess $siteAccess, $configuredSessionStorageOptions, array $expectedSessionStorageOptions): void { $request = new Request(); @@ -122,7 +121,7 @@ public function testOnSiteAccessMatch(SiteAccess $siteAccess, $configuredSession /** * @return array{array{\Ibexa\Core\MVC\Symfony\SiteAccess, array, array}} */ - public function onSiteAccessMatchProvider(): array + public static function onSiteAccessMatchProvider(): array { return [ [new SiteAccess('foo'), ['name' => 'IBX_SESSION_ID'], ['name' => 'IBX_SESSION_ID']], diff --git a/tests/bundle/Core/EventListener/SiteAccessListenerTest.php b/tests/bundle/Core/EventListener/SiteAccessListenerTest.php index 164d6dbfec..254949578c 100644 --- a/tests/bundle/Core/EventListener/SiteAccessListenerTest.php +++ b/tests/bundle/Core/EventListener/SiteAccessListenerTest.php @@ -12,6 +12,7 @@ use Ibexa\Core\MVC\Symfony\MVCEvents; use Ibexa\Core\MVC\Symfony\SiteAccess; use Ibexa\Core\MVC\Symfony\SiteAccessGroup; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpKernel\HttpKernelInterface; @@ -32,7 +33,7 @@ protected function setUp(): void $this->listener = new SiteAccessListener($this->defaultSiteaccess); } - public function testGetSubscribedEvents() + public function testGetSubscribedEvents(): void { self::assertSame( [ @@ -42,7 +43,10 @@ public function testGetSubscribedEvents() ); } - public function siteAccessMatchProvider() + /** + * @return array + */ + public static function siteAccessMatchProvider(): array { return [ ['/foo/bar', '/foo/bar', '', []], @@ -60,15 +64,13 @@ public function siteAccessMatchProvider() ]; } - /** - * @dataProvider siteAccessMatchProvider - */ + #[DataProvider('siteAccessMatchProvider')] public function testOnSiteAccessMatchMasterRequest( $uri, $expectedSemanticPathinfo, $expectedVPString, array $expectedVPArray - ) { + ): void { $uri = rawurldecode($uri); $semanticPathinfoPos = strpos($uri, $expectedSemanticPathinfo); if ($semanticPathinfoPos !== 0) { @@ -97,12 +99,10 @@ public function testOnSiteAccessMatchMasterRequest( self::assertSame($this->defaultSiteaccess->groups, $siteAccess->groups); } - /** - * @dataProvider siteAccessMatchProvider - */ - public function testOnSiteAccessMatchSubRequest($uri, $semanticPathinfo, $vpString, $expectedViewParameters) + #[DataProvider('siteAccessMatchProvider')] + public function testOnSiteAccessMatchSubRequest($uri, $semanticPathinfo, $vpString, $expectedViewParameters): void { - $siteAccess = new SiteAccess('test', 'test', $this->createMock(SiteAccess\Matcher::class)); + $siteAccess = new SiteAccess('test', 'test', self::createStub(SiteAccess\Matcher::class)); $request = Request::create($uri); $request->attributes->set('semanticPathinfo', $semanticPathinfo); if (!empty($vpString)) { diff --git a/tests/bundle/Core/EventListener/ViewControllerListenerTest.php b/tests/bundle/Core/EventListener/ViewControllerListenerTest.php index f9744862d4..d9d752e36e 100644 --- a/tests/bundle/Core/EventListener/ViewControllerListenerTest.php +++ b/tests/bundle/Core/EventListener/ViewControllerListenerTest.php @@ -15,6 +15,7 @@ use Ibexa\Core\MVC\Symfony\View\ContentView; use Ibexa\Core\MVC\Symfony\View\Event\FilterViewBuilderParametersEvent; use Ibexa\Core\MVC\Symfony\View\ViewEvents; +use PHPUnit\Framework\MockObject\Stub; use PHPUnit\Framework\TestCase; use Psr\Log\LoggerInterface; use Symfony\Component\EventDispatcher\EventDispatcherInterface; @@ -30,8 +31,7 @@ class ViewControllerListenerTest extends TestCase /** @var \Symfony\Component\HttpKernel\Controller\ControllerResolver|\PHPUnit\Framework\MockObject\MockObject */ private $controllerResolver; - /** @var \Psr\Log\LoggerInterface|\PHPUnit\Framework\MockObject\MockObject */ - private $logger; + private LoggerInterface&Stub $logger; /** @var \Ibexa\Bundle\Core\EventListener\ViewControllerListener */ private $controllerListener; @@ -60,7 +60,7 @@ protected function setUp(): void $this->controllerResolver = $this->createMock(ControllerResolverInterface::class); $this->viewBuilderRegistry = $this->createMock(ViewBuilderRegistry::class); $this->eventDispatcher = $this->createMock(EventDispatcherInterface::class); - $this->logger = $this->createMock(LoggerInterface::class); + $this->logger = self::createStub(LoggerInterface::class); $this->controllerListener = new ViewControllerListener( $this->controllerResolver, $this->viewBuilderRegistry, @@ -74,7 +74,7 @@ protected function setUp(): void $this->viewBuilderMock = $this->createMock(ViewBuilder::class); } - public function testGetSubscribedEvents() + public function testGetSubscribedEvents(): void { self::assertSame( [KernelEvents::CONTROLLER => ['getController', 10]], @@ -82,7 +82,7 @@ public function testGetSubscribedEvents() ); } - public function testGetControllerNoBuilder() + public function testGetControllerNoBuilder(): void { $initialController = 'Foo::bar'; $this->request->attributes->set('_controller', $initialController); @@ -96,7 +96,7 @@ public function testGetControllerNoBuilder() $this->controllerListener->getController($this->event); } - public function testGetControllerWithClosure() + public function testGetControllerWithClosure(): void { $initialController = static function () {}; $this->request->attributes->set('_controller', $initialController); @@ -110,7 +110,7 @@ public function testGetControllerWithClosure() $this->controllerListener->getController($this->event); } - public function testGetControllerMatchedView() + public function testGetControllerMatchedView(): void { $contentId = 12; $locationId = 123; @@ -170,21 +170,22 @@ public function testGetControllerEmitsProperEvents(): void ->expects(self::once()) ->method('buildView') ->willReturn($viewObject); + $matcher = self::exactly(2); $this->eventDispatcher - ->expects(self::exactly(2)) - ->method('dispatch') - ->withConsecutive( - [ - self::isInstanceOf(FilterViewBuilderParametersEvent::class), - self::identicalTo(ViewEvents::FILTER_BUILDER_PARAMETERS), - ], - [ - self::isInstanceOf(PostBuildViewEvent::class), - self::isNull(), - ] - ) - ->willReturnArgument(0); + ->expects($matcher) + ->method('dispatch')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertInstanceOf(FilterViewBuilderParametersEvent::class, $parameters[0]); + $this->assertSame(ViewEvents::FILTER_BUILDER_PARAMETERS, $parameters[1]); + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertInstanceOf(PostBuildViewEvent::class, $parameters[0]); + $this->assertNull($parameters[1]); + } + + return $parameters[0]; + }); $this->controllerListener->getController($this->event); } @@ -195,7 +196,7 @@ public function testGetControllerEmitsProperEvents(): void protected function createEvent() { return new ControllerEvent( - $this->createMock(HttpKernelInterface::class), + self::createStub(HttpKernelInterface::class), static function () {}, $this->request, HttpKernelInterface::MAIN_REQUEST diff --git a/tests/bundle/Core/EventSubscriber/CrowdinRequestLocaleSubscriberTest.php b/tests/bundle/Core/EventSubscriber/CrowdinRequestLocaleSubscriberTest.php index 2a6e88ab9a..a412c60df8 100644 --- a/tests/bundle/Core/EventSubscriber/CrowdinRequestLocaleSubscriberTest.php +++ b/tests/bundle/Core/EventSubscriber/CrowdinRequestLocaleSubscriberTest.php @@ -8,6 +8,7 @@ namespace Ibexa\Tests\Bundle\Core\EventSubscriber; use Ibexa\Bundle\Core\EventSubscriber\CrowdinRequestLocaleSubscriber; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpKernel\Event\RequestEvent; @@ -15,10 +16,8 @@ class CrowdinRequestLocaleSubscriberTest extends TestCase { - /** - * @dataProvider testSetRequestsProvider - */ - public function testSetLocale(Request $request, $shouldHaveCustomLocale) + #[DataProvider('provideSetRequests')] + public function testSetLocale(Request $request, $shouldHaveCustomLocale): void { $event = new RequestEvent( $this->getMockBuilder(HttpKernelInterface::class)->getMock(), @@ -36,7 +35,10 @@ public function testSetLocale(Request $request, $shouldHaveCustomLocale) ); } - public function testSetRequestsProvider() + /** + * @return array + */ + public static function provideSetRequests(): array { return [ 'with_ez_in_context_translation_cookie' => [ diff --git a/tests/bundle/Core/EventSubscriber/TrustedHeaderClientIpEventSubscriberTest.php b/tests/bundle/Core/EventSubscriber/TrustedHeaderClientIpEventSubscriberTest.php index d30e172a87..a0c86ff0e0 100644 --- a/tests/bundle/Core/EventSubscriber/TrustedHeaderClientIpEventSubscriberTest.php +++ b/tests/bundle/Core/EventSubscriber/TrustedHeaderClientIpEventSubscriberTest.php @@ -9,6 +9,7 @@ namespace Ibexa\Tests\Bundle\Core\EventSubscriber; use Ibexa\Bundle\Core\EventSubscriber\TrustedHeaderClientIpEventSubscriber; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\EventDispatcher\EventDispatcher; use Symfony\Component\HttpFoundation\Request; @@ -37,7 +38,7 @@ protected function tearDown(): void $_SERVER['REMOTE_ADDR'] = $this->originalRemoteAddr; } - public function getTrustedHeaderEventSubscriberTestData(): array + public static function getTrustedHeaderEventSubscriberTestData(): array { return [ 'default behaviour' => [ @@ -90,9 +91,7 @@ public function testTrustedHeaderEventSubscriberWithoutTrustedProxy(): void self::assertEquals(self::PROXY_IP, $request->getClientIp()); } - /** - * @dataProvider getTrustedHeaderEventSubscriberTestData - */ + #[DataProvider('getTrustedHeaderEventSubscriberTestData')] public function testTrustedHeaderEventSubscriberWithTrustedProxy( string $expectedIp, string $remoteAddrIp, diff --git a/tests/bundle/Core/Fragment/DecoratedFragmentRendererTest.php b/tests/bundle/Core/Fragment/DecoratedFragmentRendererTest.php index eda709b056..3867ebe41e 100644 --- a/tests/bundle/Core/Fragment/DecoratedFragmentRendererTest.php +++ b/tests/bundle/Core/Fragment/DecoratedFragmentRendererTest.php @@ -10,6 +10,7 @@ use Ibexa\Bundle\Core\Fragment\DecoratedFragmentRenderer; use Ibexa\Bundle\Core\Fragment\SiteAccessSerializer; use Ibexa\Core\MVC\Symfony\SiteAccess; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\MockObject\MockObject; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\Response; @@ -18,9 +19,7 @@ use Symfony\Component\HttpKernel\Fragment\RoutableFragmentRenderer; use Symfony\Component\Serializer\Normalizer\AbstractNormalizer; -/** - * @covers \Ibexa\Bundle\Core\Fragment\DecoratedFragmentRenderer - */ +#[CoversClass(DecoratedFragmentRenderer::class)] class DecoratedFragmentRendererTest extends FragmentRendererBaseTestCase { protected FragmentRendererInterface & MockObject $innerRenderer; diff --git a/tests/bundle/Core/Fragment/DirectFragmentRendererTest.php b/tests/bundle/Core/Fragment/DirectFragmentRendererTest.php index 49e1981f89..2094ba5311 100644 --- a/tests/bundle/Core/Fragment/DirectFragmentRendererTest.php +++ b/tests/bundle/Core/Fragment/DirectFragmentRendererTest.php @@ -169,9 +169,9 @@ private function getDirectFragmentRenderer( ?TemplateRenderer $templateRenderer = null ): DirectFragmentRenderer { return new DirectFragmentRenderer( - $this->createMock(FragmentRendererInterface::class), - $this->createMock(KernelInterface::class), - $this->createMock(ViewControllerListener::class), + self::createStub(FragmentRendererInterface::class), + self::createStub(KernelInterface::class), + self::createStub(ViewControllerListener::class), $controllerResolver, new ArgumentMetadataFactory(), new RequestAttributeValueResolver(), diff --git a/tests/bundle/Core/Fragment/FragmentListenerFactoryTest.php b/tests/bundle/Core/Fragment/FragmentListenerFactoryTest.php index 434b72b45b..de3ac52692 100644 --- a/tests/bundle/Core/Fragment/FragmentListenerFactoryTest.php +++ b/tests/bundle/Core/Fragment/FragmentListenerFactoryTest.php @@ -8,6 +8,7 @@ namespace Ibexa\Tests\Bundle\Core\Fragment; use Ibexa\Bundle\Core\Fragment\FragmentListenerFactory; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use ReflectionObject; use Symfony\Component\HttpFoundation\Request; @@ -17,10 +18,8 @@ class FragmentListenerFactoryTest extends TestCase { - /** - * @dataProvider buildFragmentListenerProvider - */ - public function testBuildFragmentListener($requestUri, $isFragmentCandidate) + #[DataProvider('buildFragmentListenerProvider')] + public function testBuildFragmentListener($requestUri, $isFragmentCandidate): void { $listenerClass = FragmentListener::class; $uriSigner = new UriSigner('my_precious_secret'); @@ -43,7 +42,10 @@ public function testBuildFragmentListener($requestUri, $isFragmentCandidate) } } - public function buildFragmentListenerProvider() + /** + * @return array + */ + public static function buildFragmentListenerProvider(): array { return [ ['/foo/bar', false], @@ -55,7 +57,7 @@ public function buildFragmentListenerProvider() ]; } - public function testBuildFragmentListenerNoRequest() + public function testBuildFragmentListenerNoRequest(): void { $factory = new FragmentListenerFactory(); $factory->setRequestStack(new RequestStack()); diff --git a/tests/bundle/Core/Fragment/InlineFragmentRendererTest.php b/tests/bundle/Core/Fragment/InlineFragmentRendererTest.php index 1a2a6d71e9..a5d0cfc7f0 100644 --- a/tests/bundle/Core/Fragment/InlineFragmentRendererTest.php +++ b/tests/bundle/Core/Fragment/InlineFragmentRendererTest.php @@ -10,15 +10,14 @@ use Ibexa\Bundle\Core\Fragment\InlineFragmentRenderer; use Ibexa\Bundle\Core\Fragment\SiteAccessSerializer; use Ibexa\Core\MVC\Symfony\SiteAccess; +use PHPUnit\Framework\Attributes\CoversClass; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\Response; use Symfony\Component\HttpKernel\Controller\ControllerReference; use Symfony\Component\HttpKernel\Fragment\FragmentRendererInterface; use Symfony\Component\Serializer\Normalizer\AbstractNormalizer; -/** - * @covers \Ibexa\Bundle\Core\Fragment\InlineFragmentRenderer - */ +#[CoversClass(InlineFragmentRenderer::class)] class InlineFragmentRendererTest extends DecoratedFragmentRendererTest { private const string FOO_BAR_SEMANTIC_PATH = '/foo/bar'; diff --git a/tests/bundle/Core/Fragment/SiteAccessSerializerTest.php b/tests/bundle/Core/Fragment/SiteAccessSerializerTest.php index e40df471ea..11893d6537 100644 --- a/tests/bundle/Core/Fragment/SiteAccessSerializerTest.php +++ b/tests/bundle/Core/Fragment/SiteAccessSerializerTest.php @@ -10,20 +10,19 @@ use Ibexa\Bundle\Core\Fragment\SiteAccessSerializer; use Ibexa\Core\MVC\Symfony\SiteAccess; use Ibexa\Tests\Core\MVC\Symfony\Component\Serializer\Stubs\CompoundStub; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\HttpKernel\Controller\ControllerReference; use Symfony\Component\Serializer\SerializerInterface; -/** - * @covers \Ibexa\Bundle\Core\Fragment\SiteAccessSerializer - */ +#[CoversClass(SiteAccessSerializer::class)] final class SiteAccessSerializerTest extends TestCase { /** - * @dataProvider getDataForTestSerializeSiteAccessAsControllerAttributes - * * @throws \JsonException */ + #[DataProvider('getDataForTestSerializeSiteAccessAsControllerAttributes')] public function testSerializeSiteAccessAsControllerAttributes(SiteAccess $siteAccess): void { $serializerMock = $this->createMock(SerializerInterface::class); @@ -35,7 +34,7 @@ public function testSerializeSiteAccessAsControllerAttributes(SiteAccess $siteAc ->with( self::isInstanceOf(SiteAccess\Matcher::class), 'json', - self::isType('array') + self::isArray() )->willReturn('{"foo":"bar"}') ; diff --git a/tests/bundle/Core/IbexaCoreBundleTest.php b/tests/bundle/Core/IbexaCoreBundleTest.php index b03be75e04..5888d48844 100644 --- a/tests/bundle/Core/IbexaCoreBundleTest.php +++ b/tests/bundle/Core/IbexaCoreBundleTest.php @@ -9,14 +9,13 @@ namespace Ibexa\Tests\Bundle\Core; use Ibexa\Bundle\Core\IbexaCoreBundle; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; use RuntimeException; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Extension\Extension; -/** - * @covers \Ibexa\Bundle\Core\IbexaCoreBundle - */ +#[CoversClass(IbexaCoreBundle::class)] final class IbexaCoreBundleTest extends TestCase { private IbexaCoreBundle $bundle; diff --git a/tests/bundle/Core/Imagine/AliasCleanerTest.php b/tests/bundle/Core/Imagine/AliasCleanerTest.php index 596e2381f2..6b281c7cbe 100644 --- a/tests/bundle/Core/Imagine/AliasCleanerTest.php +++ b/tests/bundle/Core/Imagine/AliasCleanerTest.php @@ -26,7 +26,7 @@ protected function setUp(): void $this->aliasCleaner = new AliasCleaner($this->resolver); } - public function testRemoveAliases() + public function testRemoveAliases(): void { $originalPath = 'foo/bar/test.jpg'; $this->resolver diff --git a/tests/bundle/Core/Imagine/AliasGeneratorTest.php b/tests/bundle/Core/Imagine/AliasGeneratorTest.php index d701acb302..9a6c793b85 100644 --- a/tests/bundle/Core/Imagine/AliasGeneratorTest.php +++ b/tests/bundle/Core/Imagine/AliasGeneratorTest.php @@ -34,6 +34,7 @@ use Liip\ImagineBundle\Imagine\Cache\Resolver\ResolverInterface; use Liip\ImagineBundle\Imagine\Filter\FilterConfiguration; use Liip\ImagineBundle\Imagine\Filter\FilterManager; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; use Psr\Log\LoggerInterface; @@ -95,9 +96,7 @@ protected function setUp(): void ); } - /** - * @dataProvider supportsValueProvider - */ + #[DataProvider('supportsValueProvider')] public function testSupportsValue(Value $value, bool $isSupported): void { self::assertSame($isSupported, $this->aliasGenerator->supportsValue($value)); @@ -112,13 +111,13 @@ public function testSupportsValue(Value $value, bool $isSupported): void * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ - public function supportsValueProvider(): array + public static function supportsValueProvider(): array { return [ - [$this->createMock(FieldTypeValue::class), false], + [self::createStub(FieldTypeValue::class), false], [new TextLineValue(), false], [new ImageValue(), true], - [$this->createMock(ImageValue::class), true], + [self::createStub(ImageValue::class), true], ]; } @@ -127,7 +126,7 @@ public function testGetVariationWrongValue(): void $this->expectException(\InvalidArgumentException::class); $field = new Field([ - 'value' => $this->createMock(FieldTypeValue::class), + 'value' => self::createStub(FieldTypeValue::class), 'fieldDefIdentifier' => 'image_field', ]); $this->aliasGenerator->getVariation($field, new VersionInfo(), 'foo'); @@ -158,7 +157,7 @@ public function testGetVariationNotStored(): void ->expects(self::once()) ->method('debug'); - $binary = $this->createMock(BinaryInterface::class); + $binary = self::createStub(BinaryInterface::class); $this->dataLoader ->expects(self::once()) ->method('find') @@ -330,7 +329,7 @@ public function testGetVariationNotStoredHavingReferences(): void ->expects(self::once()) ->method('debug'); - $binary = $this->createMock(BinaryInterface::class); + $binary = self::createStub(BinaryInterface::class); $this->dataLoader ->expects(self::once()) ->method('find') @@ -338,21 +337,20 @@ public function testGetVariationNotStoredHavingReferences(): void ->will(self::returnValue($binary)); // Filter manager is supposed to be called 3 times to generate references, and then passed variation. + $expectedApplyFilterCalls = [ + [$binary, $reference2, []], + [$binary, $reference1, []], + [$binary, $variationName, []], + ]; + $matcher = self::exactly(3); $this->filterManager - ->expects(self::at(0)) - ->method('applyFilter') - ->with($binary, $reference2) - ->will(self::returnValue($binary)); - $this->filterManager - ->expects(self::at(1)) - ->method('applyFilter') - ->with($binary, $reference1) - ->will(self::returnValue($binary)); - $this->filterManager - ->expects(self::at(2)) + ->expects($matcher) ->method('applyFilter') - ->with($binary, $variationName) - ->will(self::returnValue($binary)); + ->willReturnCallback(function (...$parameters) use ($matcher, $expectedApplyFilterCalls, $binary) { + $this->assertSame($expectedApplyFilterCalls[$matcher->numberOfInvocations() - 1], $parameters); + + return $binary; + }); $this->ioResolver ->expects(self::once()) diff --git a/tests/bundle/Core/Imagine/BinaryLoaderTest.php b/tests/bundle/Core/Imagine/BinaryLoaderTest.php index feddb12766..bde37f2ce2 100644 --- a/tests/bundle/Core/Imagine/BinaryLoaderTest.php +++ b/tests/bundle/Core/Imagine/BinaryLoaderTest.php @@ -33,7 +33,7 @@ protected function setUp(): void $this->binaryLoader = new BinaryLoader($this->ioService, new MimeTypes()); } - public function testFindNotFound() + public function testFindNotFound(): void { $this->expectException(\Liip\ImagineBundle\Exception\Binary\Loader\NotLoadableException::class); @@ -47,7 +47,7 @@ public function testFindNotFound() $this->binaryLoader->find($path); } - public function testFindMissing() + public function testFindMissing(): void { $this->expectException(\Liip\ImagineBundle\Exception\Binary\Loader\NotLoadableException::class); @@ -61,7 +61,7 @@ public function testFindMissing() $this->binaryLoader->find($path); } - public function testFindBadPathRoot() + public function testFindBadPathRoot(): void { $path = 'var/site/storage/images/1/2/3/123-name/name.png'; $this->ioService diff --git a/tests/bundle/Core/Imagine/Cache/Resolver/ProxyResolverTest.php b/tests/bundle/Core/Imagine/Cache/Resolver/ProxyResolverTest.php index 0f53eea8d3..62293b8754 100644 --- a/tests/bundle/Core/Imagine/Cache/Resolver/ProxyResolverTest.php +++ b/tests/bundle/Core/Imagine/Cache/Resolver/ProxyResolverTest.php @@ -30,7 +30,7 @@ protected function setUp(): void $this->filter = 'medium'; } - public function testResolveUsingProxyHostWithTrailingSlash() + public function testResolveUsingProxyHostWithTrailingSlash(): void { $hosts = ['http://ezplatform.com/']; $proxyResolver = new ProxyResolver($this->resolver, $hosts); @@ -48,7 +48,7 @@ public function testResolveUsingProxyHostWithTrailingSlash() self::assertEquals($expected, $proxyResolver->resolve($this->path, $this->filter)); } - public function testResolveAndRemovePortUsingProxyHost() + public function testResolveAndRemovePortUsingProxyHost(): void { $hosts = ['http://ibexa.co']; $proxyResolver = new ProxyResolver($this->resolver, $hosts); @@ -66,7 +66,7 @@ public function testResolveAndRemovePortUsingProxyHost() self::assertEquals($expected, $proxyResolver->resolve($this->path, $this->filter)); } - public function testResolveAndRemovePortUsingProxyHostWithTrailingSlash() + public function testResolveAndRemovePortUsingProxyHostWithTrailingSlash(): void { $hosts = ['http://ibexa.co']; $proxyResolver = new ProxyResolver($this->resolver, $hosts); diff --git a/tests/bundle/Core/Imagine/Cache/Resolver/RelativeResolverTest.php b/tests/bundle/Core/Imagine/Cache/Resolver/RelativeResolverTest.php index 1d41a4f323..f3f72f075b 100644 --- a/tests/bundle/Core/Imagine/Cache/Resolver/RelativeResolverTest.php +++ b/tests/bundle/Core/Imagine/Cache/Resolver/RelativeResolverTest.php @@ -22,7 +22,7 @@ protected function setUp(): void $this->liipResolver = $this->getMockBuilder(ResolverInterface::class)->getMock(); } - public function testResolve() + public function testResolve(): void { $resolver = new RelativeResolver($this->liipResolver); diff --git a/tests/bundle/Core/Imagine/Cache/ResolverFactoryTest.php b/tests/bundle/Core/Imagine/Cache/ResolverFactoryTest.php index 32c17cf66c..e61931307f 100644 --- a/tests/bundle/Core/Imagine/Cache/ResolverFactoryTest.php +++ b/tests/bundle/Core/Imagine/Cache/ResolverFactoryTest.php @@ -38,10 +38,10 @@ protected function setUp(): void ); } - public function testCreateProxyCacheResolver() + public function testCreateProxyCacheResolver(): void { $this->configResolver - ->expects(self::at(0)) + ->expects(self::once()) ->method('hasParameter') ->with('image_host') ->willReturn(true); @@ -49,7 +49,7 @@ public function testCreateProxyCacheResolver() $host = 'http://ibexa.co'; $this->configResolver - ->expects(self::at(1)) + ->expects(self::once()) ->method('getParameter') ->with('image_host') ->willReturn($host); @@ -59,10 +59,10 @@ public function testCreateProxyCacheResolver() self::assertEquals($expected, $this->factory->createCacheResolver()); } - public function testCreateRelativeCacheResolver() + public function testCreateRelativeCacheResolver(): void { $this->configResolver - ->expects(self::at(0)) + ->expects(self::once()) ->method('hasParameter') ->with('image_host') ->willReturn(true); @@ -70,7 +70,7 @@ public function testCreateRelativeCacheResolver() $host = '/'; $this->configResolver - ->expects(self::at(1)) + ->expects(self::once()) ->method('getParameter') ->with('image_host') ->willReturn($host); diff --git a/tests/bundle/Core/Imagine/Filter/AbstractFilterTest.php b/tests/bundle/Core/Imagine/Filter/AbstractFilterTest.php index 4f4ef7ca3f..9b2acc7040 100644 --- a/tests/bundle/Core/Imagine/Filter/AbstractFilterTest.php +++ b/tests/bundle/Core/Imagine/Filter/AbstractFilterTest.php @@ -8,6 +8,7 @@ namespace Ibexa\Tests\Bundle\Core\Imagine\Filter; use Ibexa\Bundle\Core\Imagine\Filter\AbstractFilter; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; class AbstractFilterTest extends TestCase @@ -26,7 +27,7 @@ protected function getFilter() return $this->getMockForAbstractClass(AbstractFilter::class); } - public function testGetSetOptions() + public function testGetSetOptions(): void { self::assertSame([], $this->filter->getOptions()); $options = ['foo' => 'bar', 'some' => ['thing']]; @@ -34,10 +35,8 @@ public function testGetSetOptions() self::assertSame($options, $this->filter->getOptions()); } - /** - * @dataProvider getSetOptionNoDefaulValueProvider - */ - public function testGetSetOptionNoDefaultValue($optionName, $value) + #[DataProvider('getSetOptionNoDefaulValueProvider')] + public function testGetSetOptionNoDefaultValue($optionName, $value): void { self::assertFalse($this->filter->hasOption($optionName)); self::assertNull($this->filter->getOption($optionName)); @@ -46,7 +45,10 @@ public function testGetSetOptionNoDefaultValue($optionName, $value) self::assertSame($value, $this->filter->getOption($optionName)); } - public function getSetOptionNoDefaulValueProvider() + /** + * @return array + */ + public static function getSetOptionNoDefaulValueProvider(): array { return [ ['foo', 'bar'], @@ -58,10 +60,8 @@ public function getSetOptionNoDefaulValueProvider() ]; } - /** - * @dataProvider getSetOptionWithDefaulValueProvider - */ - public function testGetSetOptionWithDefaultValue($optionName, $value, $defaultValue) + #[DataProvider('getSetOptionWithDefaulValueProvider')] + public function testGetSetOptionWithDefaultValue($optionName, $value, $defaultValue): void { self::assertFalse($this->filter->hasOption($optionName)); self::assertSame($defaultValue, $this->filter->getOption($optionName, $defaultValue)); @@ -70,7 +70,10 @@ public function testGetSetOptionWithDefaultValue($optionName, $value, $defaultVa self::assertSame($value, $this->filter->getOption($optionName)); } - public function getSetOptionWithDefaulValueProvider() + /** + * @return array + */ + public static function getSetOptionWithDefaulValueProvider(): array { return [ ['foo', 'bar', 'default'], diff --git a/tests/bundle/Core/Imagine/Filter/FilterConfigurationTest.php b/tests/bundle/Core/Imagine/Filter/FilterConfigurationTest.php index fe9cf8af97..41b7831f26 100644 --- a/tests/bundle/Core/Imagine/Filter/FilterConfigurationTest.php +++ b/tests/bundle/Core/Imagine/Filter/FilterConfigurationTest.php @@ -27,7 +27,7 @@ protected function setUp(): void $this->filterConfiguration->setConfigResolver($this->configResolver); } - public function testGetOnlyImagineFilters() + public function testGetOnlyImagineFilters(): void { $fooConfig = ['fooconfig']; $barConfig = ['barconfig']; @@ -44,7 +44,7 @@ public function testGetOnlyImagineFilters() self::assertSame($barConfig, $this->filterConfiguration->get('bar')); } - public function testGetNoEzVariationInvalidImagineFilter() + public function testGetNoEzVariationInvalidImagineFilter(): void { $this->expectException(\RuntimeException::class); @@ -90,7 +90,7 @@ public function testGetWithEzVariationNullConfiguration(): void ); } - public function testGetEzVariationNoReference() + public function testGetEzVariationNoReference(): void { $fooConfig = ['fooconfig']; $barConfig = ['barconfig']; @@ -119,7 +119,7 @@ public function testGetEzVariationNoReference() ); } - public function testGetEzVariationWithReference() + public function testGetEzVariationWithReference(): void { $fooConfig = ['fooconfig']; $barConfig = ['barconfig']; @@ -149,7 +149,7 @@ public function testGetEzVariationWithReference() ); } - public function testGetEzVariationImagineFilters() + public function testGetEzVariationImagineFilters(): void { $filters = ['some_filter' => []]; $imagineConfig = ['filters' => $filters]; @@ -177,7 +177,7 @@ public function testGetEzVariationImagineFilters() ); } - public function testGetEzVariationImagineOptions() + public function testGetEzVariationImagineOptions(): void { $imagineConfig = [ 'foo_option' => 'foo', @@ -210,7 +210,7 @@ public function testGetEzVariationImagineOptions() ); } - public function testAll() + public function testAll(): void { $fooConfig = ['fooconfig']; $barConfig = ['barconfig']; diff --git a/tests/bundle/Core/Imagine/Filter/Loader/BorderFilterLoaderTest.php b/tests/bundle/Core/Imagine/Filter/Loader/BorderFilterLoaderTest.php index 3dc1640763..4e7f7faef8 100644 --- a/tests/bundle/Core/Imagine/Filter/Loader/BorderFilterLoaderTest.php +++ b/tests/bundle/Core/Imagine/Filter/Loader/BorderFilterLoaderTest.php @@ -14,22 +14,24 @@ use Imagine\Image\ImageInterface; use Imagine\Image\Palette\Color\ColorInterface; use Imagine\Image\Palette\PaletteInterface; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; class BorderFilterLoaderTest extends TestCase { - /** - * @dataProvider loadInvalidProvider - */ - public function testLoadInvalidOptions(array $options) + #[DataProvider('loadInvalidProvider')] + public function testLoadInvalidOptions(array $options): void { $this->expectException(InvalidArgumentException::class); $loader = new BorderFilterLoader(); - $loader->load($this->createMock(ImageInterface::class), $options); + $loader->load(self::createStub(ImageInterface::class), $options); } - public function loadInvalidProvider() + /** + * @return array + */ + public static function loadInvalidProvider(): array { return [ [[]], @@ -38,7 +40,7 @@ public function loadInvalidProvider() ]; } - public function testLoadDefaultColor() + public function testLoadDefaultColor(): void { $image = $this->createMock(ImageInterface::class); $options = [10, 10]; @@ -52,7 +54,7 @@ public function testLoadDefaultColor() ->expects(self::once()) ->method('color') ->with(BorderFilterLoader::DEFAULT_BORDER_COLOR) - ->will(self::returnValue($this->createMock(ColorInterface::class))); + ->will(self::returnValue(self::createStub(ColorInterface::class))); $box = $this->createMock(BoxInterface::class); $image @@ -82,10 +84,8 @@ public function testLoadDefaultColor() self::assertSame($image, $loader->load($image, $options)); } - /** - * @dataProvider loadProvider - */ - public function testLoad($thickX, $thickY, $color) + #[DataProvider('loadProvider')] + public function testLoad($thickX, $thickY, $color): void { $image = $this->createMock(ImageInterface::class); $options = [$thickX, $thickY, $color]; @@ -99,7 +99,7 @@ public function testLoad($thickX, $thickY, $color) ->expects(self::once()) ->method('color') ->with($color) - ->will(self::returnValue($this->createMock(ColorInterface::class))); + ->will(self::returnValue(self::createStub(ColorInterface::class))); $box = $this->createMock(BoxInterface::class); $image @@ -129,7 +129,10 @@ public function testLoad($thickX, $thickY, $color) self::assertSame($image, $loader->load($image, $options)); } - public function loadProvider() + /** + * @return array + */ + public static function loadProvider(): array { return [ [10, 10, '#fff'], diff --git a/tests/bundle/Core/Imagine/Filter/Loader/CropFilterLoaderTest.php b/tests/bundle/Core/Imagine/Filter/Loader/CropFilterLoaderTest.php index e937182c95..2512ce83be 100644 --- a/tests/bundle/Core/Imagine/Filter/Loader/CropFilterLoaderTest.php +++ b/tests/bundle/Core/Imagine/Filter/Loader/CropFilterLoaderTest.php @@ -11,6 +11,7 @@ use Imagine\Exception\InvalidArgumentException; use Imagine\Image\ImageInterface; use Liip\ImagineBundle\Imagine\Filter\Loader\LoaderInterface; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; class CropFilterLoaderTest extends TestCase @@ -29,17 +30,18 @@ protected function setUp(): void $this->loader->setInnerLoader($this->innerLoader); } - /** - * @dataProvider loadInvalidProvider - */ - public function testLoadInvalidOptions(array $options) + #[DataProvider('loadInvalidProvider')] + public function testLoadInvalidOptions(array $options): void { $this->expectException(InvalidArgumentException::class); - $this->loader->load($this->createMock(ImageInterface::class), $options); + $this->loader->load(self::createStub(ImageInterface::class), $options); } - public function loadInvalidProvider() + /** + * @return array + */ + public static function loadInvalidProvider(): array { return [ [[]], @@ -50,14 +52,14 @@ public function loadInvalidProvider() ]; } - public function testLoad() + public function testLoad(): void { $width = 123; $height = 789; $offsetX = 100; $offsetY = 200; - $image = $this->createMock(ImageInterface::class); + $image = self::createStub(ImageInterface::class); $this->innerLoader ->expects(self::once()) ->method('load') diff --git a/tests/bundle/Core/Imagine/Filter/Loader/GrayscaleFilterLoaderTest.php b/tests/bundle/Core/Imagine/Filter/Loader/GrayscaleFilterLoaderTest.php index eaa18287ba..3dfdb86762 100644 --- a/tests/bundle/Core/Imagine/Filter/Loader/GrayscaleFilterLoaderTest.php +++ b/tests/bundle/Core/Imagine/Filter/Loader/GrayscaleFilterLoaderTest.php @@ -14,7 +14,7 @@ class GrayscaleFilterLoaderTest extends TestCase { - public function testLoad() + public function testLoad(): void { $image = $this->createMock(ImageInterface::class); $effects = $this->createMock(EffectsInterface::class); diff --git a/tests/bundle/Core/Imagine/Filter/Loader/ReduceNoiseFilterLoaderTest.php b/tests/bundle/Core/Imagine/Filter/Loader/ReduceNoiseFilterLoaderTest.php index b4a6eb2942..6e1876491e 100644 --- a/tests/bundle/Core/Imagine/Filter/Loader/ReduceNoiseFilterLoaderTest.php +++ b/tests/bundle/Core/Imagine/Filter/Loader/ReduceNoiseFilterLoaderTest.php @@ -11,12 +11,12 @@ use Ibexa\Bundle\Core\Imagine\Filter\Loader\ReduceNoiseFilterLoader; use Imagine\Exception\NotSupportedException; use Imagine\Image\ImageInterface; +use PHPUnit\Framework\MockObject\Stub; use PHPUnit\Framework\TestCase; class ReduceNoiseFilterLoaderTest extends TestCase { - /** @var \PHPUnit\Framework\MockObject\MockObject */ - private $filter; + private FilterInterface&Stub $filter; /** @var \Ibexa\Bundle\Core\Imagine\Filter\Loader\ReduceNoiseFilterLoader */ private $loader; @@ -24,14 +24,14 @@ class ReduceNoiseFilterLoaderTest extends TestCase protected function setUp(): void { parent::setUp(); - $this->filter = $this->createMock(FilterInterface::class); + $this->filter = self::createStub(FilterInterface::class); $this->loader = new ReduceNoiseFilterLoader($this->filter); } - public function testLoadInvalidDriver() + public function testLoadInvalidDriver(): void { $this->expectException(NotSupportedException::class); - $this->loader->load($this->createMock(ImageInterface::class)); + $this->loader->load(self::createStub(ImageInterface::class)); } } diff --git a/tests/bundle/Core/Imagine/Filter/Loader/ScaleDownOnlyFilterLoaderTest.php b/tests/bundle/Core/Imagine/Filter/Loader/ScaleDownOnlyFilterLoaderTest.php index c120b142ab..79912dd4ab 100644 --- a/tests/bundle/Core/Imagine/Filter/Loader/ScaleDownOnlyFilterLoaderTest.php +++ b/tests/bundle/Core/Imagine/Filter/Loader/ScaleDownOnlyFilterLoaderTest.php @@ -11,6 +11,7 @@ use Imagine\Exception\InvalidArgumentException; use Imagine\Image\ImageInterface; use Liip\ImagineBundle\Imagine\Filter\Loader\LoaderInterface; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; class ScaleDownOnlyFilterLoaderTest extends TestCase @@ -29,17 +30,18 @@ protected function setUp(): void $this->loader->setInnerLoader($this->innerLoader); } - /** - * @dataProvider loadInvalidProvider - */ - public function testLoadInvalidOptions(array $options) + #[DataProvider('loadInvalidProvider')] + public function testLoadInvalidOptions(array $options): void { $this->expectException(InvalidArgumentException::class); - $this->loader->load($this->createMock(ImageInterface::class), $options); + $this->loader->load(self::createStub(ImageInterface::class), $options); } - public function loadInvalidProvider() + /** + * @return array + */ + public static function loadInvalidProvider(): array { return [ [[]], @@ -48,10 +50,10 @@ public function loadInvalidProvider() ]; } - public function testLoad() + public function testLoad(): void { $options = [123, 456]; - $image = $this->createMock(ImageInterface::class); + $image = self::createStub(ImageInterface::class); $this->innerLoader ->expects(self::once()) ->method('load') diff --git a/tests/bundle/Core/Imagine/Filter/Loader/ScaleExactFilterLoaderTest.php b/tests/bundle/Core/Imagine/Filter/Loader/ScaleExactFilterLoaderTest.php index 273b6dd972..3f656e07be 100644 --- a/tests/bundle/Core/Imagine/Filter/Loader/ScaleExactFilterLoaderTest.php +++ b/tests/bundle/Core/Imagine/Filter/Loader/ScaleExactFilterLoaderTest.php @@ -11,6 +11,7 @@ use Imagine\Exception\InvalidArgumentException; use Imagine\Image\ImageInterface; use Liip\ImagineBundle\Imagine\Filter\Loader\LoaderInterface; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; class ScaleExactFilterLoaderTest extends TestCase @@ -29,17 +30,18 @@ protected function setUp(): void $this->loader->setInnerLoader($this->innerLoader); } - /** - * @dataProvider loadInvalidProvider - */ - public function testLoadInvalidOptions(array $options) + #[DataProvider('loadInvalidProvider')] + public function testLoadInvalidOptions(array $options): void { $this->expectException(InvalidArgumentException::class); - $this->loader->load($this->createMock(ImageInterface::class), $options); + $this->loader->load(self::createStub(ImageInterface::class), $options); } - public function loadInvalidProvider() + /** + * @return array + */ + public static function loadInvalidProvider(): array { return [ [[]], @@ -48,10 +50,10 @@ public function loadInvalidProvider() ]; } - public function testLoad() + public function testLoad(): void { $options = [123, 456]; - $image = $this->createMock(ImageInterface::class); + $image = self::createStub(ImageInterface::class); $this->innerLoader ->expects(self::once()) ->method('load') diff --git a/tests/bundle/Core/Imagine/Filter/Loader/ScaleFilterLoaderTest.php b/tests/bundle/Core/Imagine/Filter/Loader/ScaleFilterLoaderTest.php index 873eb0d0fc..af0222e409 100644 --- a/tests/bundle/Core/Imagine/Filter/Loader/ScaleFilterLoaderTest.php +++ b/tests/bundle/Core/Imagine/Filter/Loader/ScaleFilterLoaderTest.php @@ -12,6 +12,7 @@ use Imagine\Image\Box; use Imagine\Image\ImageInterface; use Liip\ImagineBundle\Imagine\Filter\Loader\LoaderInterface; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; class ScaleFilterLoaderTest extends TestCase @@ -30,17 +31,18 @@ protected function setUp(): void $this->loader->setInnerLoader($this->innerLoader); } - /** - * @dataProvider loadInvalidProvider - */ - public function testLoadInvalidOptions(array $options) + #[DataProvider('loadInvalidProvider')] + public function testLoadInvalidOptions(array $options): void { $this->expectException(InvalidArgumentException::class); - $this->loader->load($this->createMock(ImageInterface::class), $options); + $this->loader->load(self::createStub(ImageInterface::class), $options); } - public function loadInvalidProvider() + /** + * @return array + */ + public static function loadInvalidProvider(): array { return [ [[]], @@ -49,7 +51,7 @@ public function loadInvalidProvider() ]; } - public function testLoadHeighten() + public function testLoadHeighten(): void { $width = 900; $height = 400; @@ -72,7 +74,7 @@ public function testLoadHeighten() self::assertSame($image, $this->loader->load($image, [$width, $height])); } - public function testLoadWiden() + public function testLoadWiden(): void { $width = 900; $height = 600; diff --git a/tests/bundle/Core/Imagine/Filter/Loader/ScaleHeightDownOnlyFilterLoaderTest.php b/tests/bundle/Core/Imagine/Filter/Loader/ScaleHeightDownOnlyFilterLoaderTest.php index 840cca4006..6b7cb56c78 100644 --- a/tests/bundle/Core/Imagine/Filter/Loader/ScaleHeightDownOnlyFilterLoaderTest.php +++ b/tests/bundle/Core/Imagine/Filter/Loader/ScaleHeightDownOnlyFilterLoaderTest.php @@ -29,17 +29,17 @@ protected function setUp(): void $this->loader->setInnerLoader($this->innerLoader); } - public function testLoadInvalid() + public function testLoadInvalid(): void { $this->expectException(InvalidArgumentException::class); - $this->loader->load($this->createMock(ImageInterface::class), []); + $this->loader->load(self::createStub(ImageInterface::class), []); } - public function testLoad() + public function testLoad(): void { $height = 123; - $image = $this->createMock(ImageInterface::class); + $image = self::createStub(ImageInterface::class); $this->innerLoader ->expects(self::once()) ->method('load') diff --git a/tests/bundle/Core/Imagine/Filter/Loader/ScaleHeightFilterLoaderTest.php b/tests/bundle/Core/Imagine/Filter/Loader/ScaleHeightFilterLoaderTest.php index 9b36149c03..76865c8716 100644 --- a/tests/bundle/Core/Imagine/Filter/Loader/ScaleHeightFilterLoaderTest.php +++ b/tests/bundle/Core/Imagine/Filter/Loader/ScaleHeightFilterLoaderTest.php @@ -29,17 +29,17 @@ protected function setUp(): void $this->loader->setInnerLoader($this->innerLoader); } - public function testLoadFail() + public function testLoadFail(): void { $this->expectException(InvalidArgumentException::class); - $this->loader->load($this->createMock(ImageInterface::class, [])); + $this->loader->load(self::createStub(ImageInterface::class, [])); } - public function testLoad() + public function testLoad(): void { $height = 123; - $image = $this->createMock(ImageInterface::class); + $image = self::createStub(ImageInterface::class); $this->innerLoader ->expects(self::once()) ->method('load') diff --git a/tests/bundle/Core/Imagine/Filter/Loader/ScalePercentFilterLoaderTest.php b/tests/bundle/Core/Imagine/Filter/Loader/ScalePercentFilterLoaderTest.php index 762ec807e8..6b6f85f535 100644 --- a/tests/bundle/Core/Imagine/Filter/Loader/ScalePercentFilterLoaderTest.php +++ b/tests/bundle/Core/Imagine/Filter/Loader/ScalePercentFilterLoaderTest.php @@ -12,6 +12,7 @@ use Imagine\Image\Box; use Imagine\Image\ImageInterface; use Liip\ImagineBundle\Imagine\Filter\Loader\LoaderInterface; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; class ScalePercentFilterLoaderTest extends TestCase @@ -30,17 +31,18 @@ protected function setUp(): void $this->loader->setInnerLoader($this->innerLoader); } - /** - * @dataProvider loadInvalidProvider - */ - public function testLoadInvalidOptions(array $options) + #[DataProvider('loadInvalidProvider')] + public function testLoadInvalidOptions(array $options): void { $this->expectException(InvalidArgumentException::class); - $this->loader->load($this->createMock(ImageInterface::class), $options); + $this->loader->load(self::createStub(ImageInterface::class), $options); } - public function loadInvalidProvider() + /** + * @return array + */ + public static function loadInvalidProvider(): array { return [ [[]], @@ -49,7 +51,7 @@ public function loadInvalidProvider() ]; } - public function testLoad() + public function testLoad(): void { $widthPercent = 40; $heightPercent = 125; diff --git a/tests/bundle/Core/Imagine/Filter/Loader/ScaleWidthDownOnlyFilterLoaderTest.php b/tests/bundle/Core/Imagine/Filter/Loader/ScaleWidthDownOnlyFilterLoaderTest.php index 4ad49d493d..60d8473065 100644 --- a/tests/bundle/Core/Imagine/Filter/Loader/ScaleWidthDownOnlyFilterLoaderTest.php +++ b/tests/bundle/Core/Imagine/Filter/Loader/ScaleWidthDownOnlyFilterLoaderTest.php @@ -29,17 +29,17 @@ protected function setUp(): void $this->loader->setInnerLoader($this->innerLoader); } - public function testLoadInvalid() + public function testLoadInvalid(): void { $this->expectException(InvalidArgumentException::class); - $this->loader->load($this->createMock(ImageInterface::class), []); + $this->loader->load(self::createStub(ImageInterface::class), []); } - public function testLoad() + public function testLoad(): void { $width = 123; - $image = $this->createMock(ImageInterface::class); + $image = self::createStub(ImageInterface::class); $this->innerLoader ->expects(self::once()) ->method('load') diff --git a/tests/bundle/Core/Imagine/Filter/Loader/ScaleWidthFilterLoaderTest.php b/tests/bundle/Core/Imagine/Filter/Loader/ScaleWidthFilterLoaderTest.php index 78fb82b9e0..1acee8120b 100644 --- a/tests/bundle/Core/Imagine/Filter/Loader/ScaleWidthFilterLoaderTest.php +++ b/tests/bundle/Core/Imagine/Filter/Loader/ScaleWidthFilterLoaderTest.php @@ -29,17 +29,17 @@ protected function setUp(): void $this->loader->setInnerLoader($this->innerLoader); } - public function testLoadFail() + public function testLoadFail(): void { $this->expectException(InvalidArgumentException::class); - $this->loader->load($this->createMock(ImageInterface::class, [])); + $this->loader->load(self::createStub(ImageInterface::class, [])); } - public function testLoad() + public function testLoad(): void { $width = 123; - $image = $this->createMock(ImageInterface::class); + $image = self::createStub(ImageInterface::class); $this->innerLoader ->expects(self::once()) ->method('load') diff --git a/tests/bundle/Core/Imagine/Filter/Loader/SwirlFilterLoaderTest.php b/tests/bundle/Core/Imagine/Filter/Loader/SwirlFilterLoaderTest.php index 4af693b48b..4427550f80 100644 --- a/tests/bundle/Core/Imagine/Filter/Loader/SwirlFilterLoaderTest.php +++ b/tests/bundle/Core/Imagine/Filter/Loader/SwirlFilterLoaderTest.php @@ -10,6 +10,7 @@ use Ibexa\Bundle\Core\Imagine\Filter\FilterInterface; use Ibexa\Bundle\Core\Imagine\Filter\Loader\SwirlFilterLoader; use Imagine\Image\ImageInterface; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; class SwirlFilterLoaderTest extends TestCase @@ -27,9 +28,9 @@ protected function setUp(): void $this->loader = new SwirlFilterLoader($this->filter); } - public function testLoadNoOption() + public function testLoadNoOption(): void { - $image = $this->createMock(ImageInterface::class); + $image = self::createStub(ImageInterface::class); $this->filter ->expects(self::never()) ->method('setOption'); @@ -43,12 +44,10 @@ public function testLoadNoOption() self::assertSame($image, $this->loader->load($image)); } - /** - * @dataProvider loadWithOptionProvider - */ - public function testLoadWithOption($degrees) + #[DataProvider('loadWithOptionProvider')] + public function testLoadWithOption($degrees): void { - $image = $this->createMock(ImageInterface::class); + $image = self::createStub(ImageInterface::class); $this->filter ->expects(self::once()) ->method('setOption') @@ -63,7 +62,10 @@ public function testLoadWithOption($degrees) self::assertSame($image, $this->loader->load($image, [$degrees])); } - public function loadWithOptionProvider() + /** + * @return array + */ + public static function loadWithOptionProvider(): array { return [ [10], diff --git a/tests/bundle/Core/Imagine/Filter/UnsupportedFilterTest.php b/tests/bundle/Core/Imagine/Filter/UnsupportedFilterTest.php index 6076a2a83b..0588c664a4 100644 --- a/tests/bundle/Core/Imagine/Filter/UnsupportedFilterTest.php +++ b/tests/bundle/Core/Imagine/Filter/UnsupportedFilterTest.php @@ -13,11 +13,11 @@ class UnsupportedFilterTest extends AbstractFilterTest { - public function testLoad() + public function testLoad(): void { $this->expectException(NotSupportedException::class); $filter = new UnsupportedFilter(); - $filter->apply($this->createMock(ImageInterface::class)); + $filter->apply(self::createStub(ImageInterface::class)); } } diff --git a/tests/bundle/Core/Imagine/IORepositoryResolverTest.php b/tests/bundle/Core/Imagine/IORepositoryResolverTest.php index 61500f4de5..8b172139f6 100644 --- a/tests/bundle/Core/Imagine/IORepositoryResolverTest.php +++ b/tests/bundle/Core/Imagine/IORepositoryResolverTest.php @@ -20,14 +20,15 @@ use Ibexa\Core\IO\Values\MissingBinaryFile; use Liip\ImagineBundle\Exception\Imagine\Cache\Resolver\NotResolvableException; use Liip\ImagineBundle\Model\Binary; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\MockObject\MockObject; +use PHPUnit\Framework\MockObject\Stub; use PHPUnit\Framework\TestCase; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\Routing\RequestContext; -/** - * @covers \Ibexa\Bundle\Core\Imagine\IORepositoryResolver - */ +#[CoversClass(IORepositoryResolver::class)] final class IORepositoryResolverTest extends TestCase { private IOServiceInterface & MockObject $ioService; @@ -38,7 +39,7 @@ final class IORepositoryResolverTest extends TestCase private IORepositoryResolver $imageResolver; - protected VariationPurger & MockObject $variationPurger; + protected VariationPurger&Stub $variationPurger; protected VariationPathGenerator & MockObject $variationPathGenerator; @@ -50,7 +51,7 @@ protected function setUp(): void $this->configResolver = $this->createMock(ConfigResolverInterface::class); $filterConfiguration = new FilterConfiguration(); $filterConfiguration->setConfigResolver($this->configResolver); - $this->variationPurger = $this->createMock(VariationPurger::class); + $this->variationPurger = self::createStub(VariationPurger::class); $this->variationPathGenerator = $this->createMock(VariationPathGenerator::class); $this->imageResolver = new IORepositoryResolver( $this->ioService, @@ -61,9 +62,7 @@ protected function setUp(): void ); } - /** - * @dataProvider getFilePathProvider - */ + #[DataProvider('getFilePathProvider')] public function testGetFilePath(string $path, string $filter, string $expected): void { $this->variationPathGenerator @@ -77,7 +76,7 @@ public function testGetFilePath(string $path, string $filter, string $expected): /** * @return array */ - public function getFilePathProvider(): array + public static function getFilePathProvider(): array { return [ ['Tardis/bigger/in-the-inside/RiverSong.jpg', 'thumbnail', 'Tardis/bigger/in-the-inside/RiverSong_thumbnail.jpg'], @@ -129,9 +128,7 @@ public function testIsStoredImageDoesntExist(): void self::assertFalse($this->imageResolver->isStored($path, $filter)); } - /** - * @dataProvider resolveProvider - */ + #[DataProvider('resolveProvider')] public function testResolve(string $path, string $filter, string $variationPath, ?string $requestUrl, mixed $expected): void { if ($requestUrl) { @@ -183,7 +180,7 @@ public function testResolveNotFound(): void /** * @return array */ - public function resolveProvider(): array + public static function resolveProvider(): array { return [ [ @@ -260,7 +257,7 @@ public function testStore(): void /** * @return iterable}> */ - public function getDataForTestRemove(): iterable + public static function getDataForTestRemove(): iterable { yield 'empty filters' => [ [], @@ -274,11 +271,10 @@ public function getDataForTestRemove(): iterable } /** - * @dataProvider getDataForTestRemove - * * @param string[] $filters * @param array $imageVariations */ + #[DataProvider('getDataForTestRemove')] public function testRemove(array $filters, array $imageVariations): void { $originalPath = 'foo/bar/test.jpg'; diff --git a/tests/bundle/Core/Imagine/ImageAsset/AliasGeneratorTest.php b/tests/bundle/Core/Imagine/ImageAsset/AliasGeneratorTest.php index dac3ff147d..f7c4da28f7 100644 --- a/tests/bundle/Core/Imagine/ImageAsset/AliasGeneratorTest.php +++ b/tests/bundle/Core/Imagine/ImageAsset/AliasGeneratorTest.php @@ -46,7 +46,7 @@ protected function setUp(): void ); } - public function testGetVariationOfImageAsset() + public function testGetVariationOfImageAsset(): void { $assetField = new Field([ 'value' => new ImageAsset\Value(486), @@ -96,7 +96,7 @@ public function testGetVariationOfImageAsset() self::assertEquals($expectedVariation, $actualVariation); } - public function testGetVariationOfNonImageAsset() + public function testGetVariationOfNonImageAsset(): void { $imageField = new Field([ 'value' => new Image\Value([ @@ -134,7 +134,7 @@ public function testGetVariationOfNonImageAsset() self::assertEquals($expectedVariation, $actualVariation); } - public function testSupport() + public function testSupport(): void { self::assertTrue($this->aliasGenerator->supportsValue(new ImageAsset\Value())); self::assertFalse($this->aliasGenerator->supportsValue(new Image\Value())); diff --git a/tests/bundle/Core/Imagine/PlaceholderAliasGeneratorConfiguratorTest.php b/tests/bundle/Core/Imagine/PlaceholderAliasGeneratorConfiguratorTest.php index d1e84f2a66..d94600895c 100644 --- a/tests/bundle/Core/Imagine/PlaceholderAliasGeneratorConfiguratorTest.php +++ b/tests/bundle/Core/Imagine/PlaceholderAliasGeneratorConfiguratorTest.php @@ -24,7 +24,7 @@ class PlaceholderAliasGeneratorConfiguratorTest extends TestCase 'c' => 'C', ]; - public function testConfigure() + public function testConfigure(): void { $configResolver = $this->createMock(ConfigResolverInterface::class); $configResolver @@ -33,7 +33,7 @@ public function testConfigure() ->with('io.binarydata_handler') ->willReturn(self::BINARY_HANDLER_NAME); - $provider = $this->createMock(PlaceholderProvider::class); + $provider = self::createStub(PlaceholderProvider::class); $providerRegistry = $this->createMock(PlaceholderProviderRegistry::class); $providerRegistry diff --git a/tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php b/tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php index 92a097e089..c051b972b2 100644 --- a/tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php +++ b/tests/bundle/Core/Imagine/PlaceholderAliasGeneratorTest.php @@ -24,6 +24,7 @@ use Ibexa\Core\IO\Values\BinaryFileCreateStruct; use Ibexa\Core\Repository\Values\Content\VersionInfo; use Liip\ImagineBundle\Exception\Imagine\Cache\Resolver\NotResolvableException; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; class PlaceholderAliasGeneratorTest extends TestCase @@ -64,12 +65,12 @@ protected function setUp(): void ); } - public function testGetVariationWrongValue() + public function testGetVariationWrongValue(): void { $this->expectException(\InvalidArgumentException::class); $field = new Field([ - 'value' => $this->createMock(FieldTypeValue::class), + 'value' => self::createStub(FieldTypeValue::class), 'fieldDefIdentifier' => 'image', ]); @@ -80,12 +81,10 @@ public function testGetVariationWrongValue() $this->aliasGenerator->getVariation($field, new VersionInfo(), 'foo'); } - /** - * @dataProvider getVariationProvider - */ - public function testGetVariationSkipsPlaceholderGeneration(Field $field, APIVersionInfo $versionInfo, string $variationName, array $parameters) + #[DataProvider('getVariationProvider')] + public function testGetVariationSkipsPlaceholderGeneration(Field $field, APIVersionInfo $versionInfo, string $variationName, array $parameters): void { - $expectedVariation = $this->createMock(ImageVariation::class); + $expectedVariation = self::createStub(ImageVariation::class); $this->ioResolver ->expects(self::never()) @@ -113,12 +112,10 @@ public function testGetVariationSkipsPlaceholderGeneration(Field $field, APIVers self::assertEquals($expectedVariation, $actualVariation); } - /** - * @dataProvider getVariationProvider - */ - public function testGetVariationOriginalFound(Field $field, APIVersionInfo $versionInfo, string $variationName, array $parameters) + #[DataProvider('getVariationProvider')] + public function testGetVariationOriginalFound(Field $field, APIVersionInfo $versionInfo, string $variationName, array $parameters): void { - $expectedVariation = $this->createMock(ImageVariation::class); + $expectedVariation = self::createStub(ImageVariation::class); $this->ioResolver ->expects(self::once()) @@ -146,20 +143,18 @@ public function testGetVariationOriginalFound(Field $field, APIVersionInfo $vers self::assertEquals($expectedVariation, $actualVariation); } - /** - * @dataProvider getVariationProvider - */ - public function testGetVariationOriginalNotFound(Field $field, APIVersionInfo $versionInfo, string $variationName, array $parameters) + #[DataProvider('getVariationProvider')] + public function testGetVariationOriginalNotFound(Field $field, APIVersionInfo $versionInfo, string $variationName, array $parameters): void { $placeholderPath = '/tmp/placeholder.jpg'; $binaryCreateStruct = new BinaryFileCreateStruct(); - $expectedVariation = $this->createMock(ImageVariation::class); + $expectedVariation = self::createStub(ImageVariation::class); $this->ioResolver ->expects(self::once()) ->method('resolve') ->with($field->value->id, IORepositoryResolver::VARIATION_ORIGINAL) - ->willThrowException($this->createMock(NotResolvableException::class)); + ->willThrowException(self::createStub(NotResolvableException::class)); $this->placeholderProvider ->expects(self::once()) @@ -200,9 +195,7 @@ public function testGetVariationOriginalNotFound(Field $field, APIVersionInfo $v self::assertEquals($expectedVariation, $actualVariation); } - /** - * @dataProvider getVariationProvider - */ + #[DataProvider('getVariationProvider')] public function testGetVariationReturnsPlaceholderIfBinaryDataIsNotAvailable( Field $field, APIVersionInfo $versionInfo, @@ -213,8 +206,8 @@ public function testGetVariationReturnsPlaceholderIfBinaryDataIsNotAvailable( $placeholderPath = '/tmp/placeholder.jpg'; $binaryCreateStruct = new BinaryFileCreateStruct(); - $expectedVariation = $this->createMock(ImageVariation::class); - $binaryFile = $this->createMock(BinaryFile::class); + $expectedVariation = self::createStub(ImageVariation::class); + $binaryFile = self::createStub(BinaryFile::class); $this->ioResolver ->expects(self::once()) @@ -230,7 +223,7 @@ public function testGetVariationReturnsPlaceholderIfBinaryDataIsNotAvailable( $this->ioService ->method('getFileInputStream') ->with($binaryFile) - ->willThrowException($this->createMock(NotFoundException::class)); + ->willThrowException(self::createStub(NotFoundException::class)); $this->placeholderProvider ->expects(self::once()) @@ -271,15 +264,13 @@ public function testGetVariationReturnsPlaceholderIfBinaryDataIsNotAvailable( self::assertEquals($expectedVariation, $actualVariation); } - /** - * @dataProvider supportsValueProvider - */ - public function testSupportsValue(Value $value, bool $isSupported) + #[DataProvider('supportsValueProvider')] + public function testSupportsValue(Value $value, bool $isSupported): void { self::assertSame($isSupported, $this->aliasGenerator->supportsValue($value)); } - public function supportsValueProvider(): array + public static function supportsValueProvider(): array { return [ [new NullValue(), false], @@ -287,7 +278,7 @@ public function supportsValueProvider(): array ]; } - public function getVariationProvider(): array + public static function getVariationProvider(): array { $field = new Field([ 'value' => new ImageValue([ diff --git a/tests/bundle/Core/Imagine/PlaceholderProvider/GenericProviderTest.php b/tests/bundle/Core/Imagine/PlaceholderProvider/GenericProviderTest.php index def720c8ad..aa09e5df7a 100644 --- a/tests/bundle/Core/Imagine/PlaceholderProvider/GenericProviderTest.php +++ b/tests/bundle/Core/Imagine/PlaceholderProvider/GenericProviderTest.php @@ -15,14 +15,13 @@ use Imagine\Image\ImageInterface; use Imagine\Image\ImagineInterface; use Imagine\Image\Palette\Color\ColorInterface; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; class GenericProviderTest extends TestCase { - /** - * @dataProvider getPlaceholderDataProvider - */ - public function testGetPlaceholder(ImageValue $value, $expectedText, array $options = []) + #[DataProvider('getPlaceholderDataProvider')] + public function testGetPlaceholder(ImageValue $value, $expectedText, array $options = []): void { $font = $this->createMock(AbstractFont::class); @@ -41,7 +40,7 @@ public function testGetPlaceholder(ImageValue $value, $expectedText, array $opti $font ->expects(self::any()) ->method('box') - ->willReturn($this->createMock(BoxInterface::class)); + ->willReturn(self::createStub(BoxInterface::class)); $image = $this->createMock(ImageInterface::class); @@ -70,7 +69,10 @@ public function testGetPlaceholder(ImageValue $value, $expectedText, array $opti $provider->getPlaceholder($value, $options); } - public function getPlaceholderDataProvider() + /** + * @return array + */ + public static function getPlaceholderDataProvider(): array { return [ [ diff --git a/tests/bundle/Core/Imagine/PlaceholderProviderRegistryTest.php b/tests/bundle/Core/Imagine/PlaceholderProviderRegistryTest.php index c5b421f6a3..b4d40cbf1f 100644 --- a/tests/bundle/Core/Imagine/PlaceholderProviderRegistryTest.php +++ b/tests/bundle/Core/Imagine/PlaceholderProviderRegistryTest.php @@ -9,20 +9,18 @@ use Ibexa\Bundle\Core\Imagine\PlaceholderProvider; use Ibexa\Bundle\Core\Imagine\PlaceholderProviderRegistry; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Depends; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Bundle\Core\Imagine\PlaceholderProviderRegistry - */ +#[CoversClass(PlaceholderProviderRegistry::class)] class PlaceholderProviderRegistryTest extends TestCase { private const FOO = 'foo'; private const BAR = 'bar'; - /** - * @depends testGetProviderKnown - */ - public function testConstructor() + #[Depends('testGetProviderKnown')] + public function testConstructor(): void { $providers = [ self::FOO => $this->getPlaceholderProviderMock(), @@ -35,9 +33,7 @@ public function testConstructor() self::assertSame($providers[self::BAR], $registry->getProvider(self::BAR)); } - /** - * @depends testGetProviderKnown - */ + #[Depends('testGetProviderKnown')] public function testAddProvider(): void { $provider = $this->getPlaceholderProviderMock(); @@ -48,7 +44,7 @@ public function testAddProvider(): void self::assertSame($provider, $registry->getProvider(self::FOO)); } - public function testSupports() + public function testSupports(): void { $registry = new PlaceholderProviderRegistry([ 'supported' => $this->getPlaceholderProviderMock(), @@ -58,7 +54,7 @@ public function testSupports() self::assertFalse($registry->supports('unsupported')); } - public function testGetProviderKnown() + public function testGetProviderKnown(): void { $provider = $this->getPlaceholderProviderMock(); @@ -69,7 +65,7 @@ public function testGetProviderKnown() self::assertEquals($provider, $registry->getProvider(self::FOO)); } - public function testGetProviderUnknown() + public function testGetProviderUnknown(): void { $this->expectException(\InvalidArgumentException::class); diff --git a/tests/bundle/Core/Imagine/VariationPathGenerator/AliasDirectoryVariationPathGeneratorTest.php b/tests/bundle/Core/Imagine/VariationPathGenerator/AliasDirectoryVariationPathGeneratorTest.php index fa6ecbec97..45b8288d21 100644 --- a/tests/bundle/Core/Imagine/VariationPathGenerator/AliasDirectoryVariationPathGeneratorTest.php +++ b/tests/bundle/Core/Imagine/VariationPathGenerator/AliasDirectoryVariationPathGeneratorTest.php @@ -12,7 +12,7 @@ class AliasDirectoryVariationPathGeneratorTest extends TestCase { - public function testGetVariationPath() + public function testGetVariationPath(): void { $generator = new AliasDirectoryVariationPathGenerator(); diff --git a/tests/bundle/Core/Imagine/VariationPathGenerator/OriginalDirectoryVariationPathGeneratorTest.php b/tests/bundle/Core/Imagine/VariationPathGenerator/OriginalDirectoryVariationPathGeneratorTest.php index 88edae38c2..5c3dcc9f87 100644 --- a/tests/bundle/Core/Imagine/VariationPathGenerator/OriginalDirectoryVariationPathGeneratorTest.php +++ b/tests/bundle/Core/Imagine/VariationPathGenerator/OriginalDirectoryVariationPathGeneratorTest.php @@ -12,7 +12,7 @@ class OriginalDirectoryVariationPathGeneratorTest extends TestCase { - public function testGetVariationPath() + public function testGetVariationPath(): void { $generator = new OriginalDirectoryVariationPathGenerator(); self::assertEquals( diff --git a/tests/bundle/Core/Imagine/VariationPurger/IOVariationPurgerTest.php b/tests/bundle/Core/Imagine/VariationPurger/IOVariationPurgerTest.php index de882edd19..1268d56b07 100644 --- a/tests/bundle/Core/Imagine/VariationPurger/IOVariationPurgerTest.php +++ b/tests/bundle/Core/Imagine/VariationPurger/IOVariationPurgerTest.php @@ -12,12 +12,11 @@ use Ibexa\Bundle\Core\Imagine\VariationPurger\IOVariationPurger; use Ibexa\Core\IO\IOServiceInterface; use Ibexa\Core\Persistence\Cache\Identifier\CacheIdentifierGeneratorInterface; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; use Symfony\Component\Cache\Adapter\TagAwareAdapterInterface; -/** - * @covers \Ibexa\Bundle\Core\Imagine\VariationPurger\IOVariationPurger - */ +#[CoversClass(IOVariationPurger::class)] final class IOVariationPurgerTest extends TestCase { public function testPurgesAliasList(): void @@ -31,28 +30,47 @@ public function testPurgesAliasList(): void ->expects(self::once()) ->method('getVariationNameTag') ->willReturn('image_variation_name'); + $matcher = self::exactly(2); $ioService - ->expects(self::exactly(2)) - ->method('deleteDirectory') - ->withConsecutive( - ['_aliases/medium'], - ['_aliases/large'] - ); + ->expects($matcher) + ->method('deleteDirectory')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame('_aliases/medium', $parameters[0]); + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame('_aliases/large', $parameters[0]); + } + }); + $matcher = self::exactly(2); $cacheIdentifierGenerator - ->expects(self::exactly(2)) - ->method('generateTag') - ->withConsecutive( - ['image_variation_name', ['medium']], - ['image_variation_name', ['large']] - ) - ->willReturnOnConsecutiveCalls('ign-medium', 'ign-large'); + ->expects($matcher) + ->method('generateTag')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame('image_variation_name', $parameters[0]); + $this->assertSame(['medium'], $parameters[1]); + + return 'ign-medium'; + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame('image_variation_name', $parameters[0]); + $this->assertSame(['large'], $parameters[1]); + + return 'ign-large'; + } + }); + $matcher = self::exactly(2); $tagAwareAdapter - ->expects(self::exactly(2)) - ->method('invalidateTags') - ->withConsecutive( - [['ign-medium']], - [['ign-large']] - ); + ->expects($matcher) + ->method('invalidateTags')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame(['ign-medium'], $parameters[0]); + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame(['ign-large'], $parameters[0]); + } + + return false; + }); $purger = new IOVariationPurger( $ioService, diff --git a/tests/bundle/Core/Imagine/VariationPurger/ImageFileVariationPurgerTest.php b/tests/bundle/Core/Imagine/VariationPurger/ImageFileVariationPurgerTest.php index 1310c7980d..abb9abb2b4 100644 --- a/tests/bundle/Core/Imagine/VariationPurger/ImageFileVariationPurgerTest.php +++ b/tests/bundle/Core/Imagine/VariationPurger/ImageFileVariationPurgerTest.php @@ -14,12 +14,11 @@ use Ibexa\Contracts\Core\Variation\VariationPathGenerator; use Ibexa\Core\IO\IOServiceInterface; use Ibexa\Core\IO\Values\BinaryFile; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Bundle\Core\Imagine\VariationPurger\ImageFileVariationPurger - */ +#[CoversClass(ImageFileVariationPurger::class)] final class ImageFileVariationPurgerTest extends TestCase { protected IOServiceInterface & MockObject $ioServiceMock; @@ -42,16 +41,30 @@ public function testIteratesOverItems(): void 'path/to/2nd/image.png', ] ); + $matcher = self::exactly(4); $this->pathGeneratorMock - ->expects(self::exactly(4)) - ->method('getVariationPath') - ->withConsecutive( - ['path/to/1st/image.jpg', 'large'], - ['path/to/1st/image.jpg', 'gallery'], - ['path/to/2nd/image.png', 'large'], - ['path/to/2nd/image.png', 'gallery'] - ); + ->expects($matcher) + ->method('getVariationPath')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame('path/to/1st/image.jpg', $parameters[0]); + $this->assertSame('large', $parameters[1]); + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame('path/to/1st/image.jpg', $parameters[0]); + $this->assertSame('gallery', $parameters[1]); + } + if ($matcher->numberOfInvocations() === 3) { + $this->assertSame('path/to/2nd/image.png', $parameters[0]); + $this->assertSame('large', $parameters[1]); + } + if ($matcher->numberOfInvocations() === 4) { + $this->assertSame('path/to/2nd/image.png', $parameters[0]); + $this->assertSame('gallery', $parameters[1]); + } + + return ''; + }); $purger->purge(['large', 'gallery']); } diff --git a/tests/bundle/Core/Imagine/VariationPurger/LegacyStorageImageFileListTest.php b/tests/bundle/Core/Imagine/VariationPurger/LegacyStorageImageFileListTest.php index df0ae13b76..55647ee934 100644 --- a/tests/bundle/Core/Imagine/VariationPurger/LegacyStorageImageFileListTest.php +++ b/tests/bundle/Core/Imagine/VariationPurger/LegacyStorageImageFileListTest.php @@ -12,12 +12,11 @@ use Ibexa\Bundle\Core\Imagine\VariationPurger\LegacyStorageImageFileList; use Ibexa\Contracts\Core\SiteAccess\ConfigResolverInterface; use Ibexa\Core\IO\IOConfigProvider; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Bundle\Core\Imagine\VariationPurger\LegacyStorageImageFileList - */ +#[CoversClass(LegacyStorageImageFileList::class)] final class LegacyStorageImageFileListTest extends TestCase { protected ImageFileRowReader&MockObject $rowReaderMock; diff --git a/tests/bundle/Core/Matcher/ServiceAwareMatcherFactoryTest.php b/tests/bundle/Core/Matcher/ServiceAwareMatcherFactoryTest.php index faf21dd3e1..c5f19894ff 100644 --- a/tests/bundle/Core/Matcher/ServiceAwareMatcherFactoryTest.php +++ b/tests/bundle/Core/Matcher/ServiceAwareMatcherFactoryTest.php @@ -14,13 +14,14 @@ use Ibexa\Core\MVC\Symfony\View\ContentView; use Ibexa\Core\MVC\Symfony\View\View; use Ibexa\Core\Repository\Repository; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; /** - * @covers \Ibexa\Bundle\Core\Matcher\ServiceAwareMatcherFactory - * * @phpstan-type TMatchConfigArray array}>> */ +#[CoversClass(ServiceAwareMatcherFactory::class)] final class ServiceAwareMatcherFactoryTest extends TestCase { /** @var \Ibexa\Contracts\Core\MVC\View\ViewMatcherRegistryInterface&\PHPUnit\Framework\MockObject\MockObject */ @@ -52,7 +53,7 @@ protected function setUp(): void /** * @phpstan-return iterable */ - public function getDataForTestMatch(): iterable + public static function getDataForTestMatch(): iterable { yield 'full view service-based matcher' => [ new ContentView(), @@ -84,15 +85,14 @@ public function getDataForTestMatch(): iterable } /** - * @dataProvider getDataForTestMatch - * * @phpstan-param TMatchConfigArray $matchConfig */ + #[DataProvider('getDataForTestMatch')] public function testMatch(View $view, array $matchConfig, string $matchedConfigValue): void { $serviceMatcherFactory = new ServiceAwareMatcherFactory( $this->viewMatcherRegistryMock, - $this->createMock(Repository::class), + self::createStub(Repository::class), null, $matchConfig ); diff --git a/tests/bundle/Core/Matcher/ViewMatcherRegistryTest.php b/tests/bundle/Core/Matcher/ViewMatcherRegistryTest.php index b9e8e58fe3..2461ae4933 100644 --- a/tests/bundle/Core/Matcher/ViewMatcherRegistryTest.php +++ b/tests/bundle/Core/Matcher/ViewMatcherRegistryTest.php @@ -10,11 +10,10 @@ use Ibexa\Bundle\Core\Matcher\ViewMatcherRegistry; use Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException; use Ibexa\Core\MVC\Symfony\Matcher\ViewMatcherInterface; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Bundle\Core\Matcher\ViewMatcherRegistry - */ +#[CoversClass(ViewMatcherRegistry::class)] final class ViewMatcherRegistryTest extends TestCase { private const MATCHER_NAME = 'test_matcher'; diff --git a/tests/bundle/Core/Routing/DefaultRouterTest.php b/tests/bundle/Core/Routing/DefaultRouterTest.php index d39a98301a..4b3323b42d 100644 --- a/tests/bundle/Core/Routing/DefaultRouterTest.php +++ b/tests/bundle/Core/Routing/DefaultRouterTest.php @@ -12,6 +12,8 @@ use Ibexa\Bundle\Core\SiteAccess\Matcher; use Ibexa\Core\MVC\Symfony\Routing\SimplifiedRequest; use Ibexa\Core\MVC\Symfony\SiteAccess; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; use Symfony\Bundle\FrameworkBundle\Routing\Router as FrameworkRouter; @@ -21,9 +23,7 @@ use Symfony\Component\Routing\RequestContext; use Symfony\Component\Routing\Router; -/** - * @covers \Ibexa\Bundle\Core\Routing\DefaultRouter - */ +#[CoversClass(DefaultRouter::class)] final class DefaultRouterTest extends TestCase { private const array NON_SITEACCESS_AWARE_ROUTES = ['_dontwantsiteaccess']; @@ -83,9 +83,7 @@ public function testMatchRequestRegularPathinfo(): void self::assertSame($matchedParameters, $this->createRouter()->matchRequest($request)); } - /** - * @dataProvider providerGenerateNoSiteAccess - */ + #[DataProvider('providerGenerateNoSiteAccess')] public function testGenerateNoSiteAccess(string $url): void { $this->innerRouter @@ -100,7 +98,7 @@ public function testGenerateNoSiteAccess(string $url): void /** * @return iterable */ - public function providerGenerateNoSiteAccess(): iterable + public static function providerGenerateNoSiteAccess(): iterable { return [ ['/foo/bar'], @@ -111,8 +109,6 @@ public function providerGenerateNoSiteAccess(): iterable } /** - * @dataProvider providerGenerateWithSiteAccess - * * @param string $urlGenerated The URL generated by the standard UrLGenerator * @param string $relevantUri The relevant URI part of the generated URL (without host and basepath) * @param string $expectedUrl The URL we're expecting to be finally generated, with siteaccess @@ -120,6 +116,7 @@ public function providerGenerateNoSiteAccess(): iterable * @param bool $isMatcherLexer True if the siteaccess matcher is URILexer * @param int $referenceType The type of reference to be generated (one of the constants) */ + #[DataProvider('providerGenerateWithSiteAccess')] public function testGenerateWithSiteAccess( string $urlGenerated, string $relevantUri, @@ -179,7 +176,7 @@ public function testGenerateWithSiteAccess( /** * @return iterable */ - public function providerGenerateWithSiteAccess(): iterable + public static function providerGenerateWithSiteAccess(): iterable { return [ ['/foo/bar', '/foo/bar', '/foo/bar', 'test_siteaccess', false, UrlGeneratorInterface::ABSOLUTE_PATH, null], diff --git a/tests/bundle/Core/Routing/JsRouting/ExposedRoutesExtractorTest.php b/tests/bundle/Core/Routing/JsRouting/ExposedRoutesExtractorTest.php index 4ab16993e8..7f75b1b87b 100644 --- a/tests/bundle/Core/Routing/JsRouting/ExposedRoutesExtractorTest.php +++ b/tests/bundle/Core/Routing/JsRouting/ExposedRoutesExtractorTest.php @@ -11,20 +11,21 @@ use FOS\JsRoutingBundle\Extractor\ExposedRoutesExtractorInterface; use Ibexa\Bundle\Core\Routing\JsRouting\ExposedRoutesExtractor; use Ibexa\Core\MVC\Symfony\SiteAccess; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\RequestStack; /** - * @covers \Ibexa\Bundle\Core\Routing\JsRouting\ExposedRoutesExtractor - * * @internal */ +#[CoversClass(ExposedRoutesExtractor::class)] final class ExposedRoutesExtractorTest extends TestCase { private const BASE_URL = '/foo'; - public function getDataForTestGetBaseUrl(): iterable + public static function getDataForTestGetBaseUrl(): iterable { yield 'CLI' => [ // no master request in a stack @@ -58,9 +59,7 @@ public function getDataForTestGetBaseUrl(): iterable ]; } - /** - * @dataProvider getDataForTestGetBaseUrl - */ + #[DataProvider('getDataForTestGetBaseUrl')] public function testGetBaseUrl(?Request $masterRequest, string $expectedBaseUrl): void { $innerExtractor = $this->createMock(ExposedRoutesExtractorInterface::class); diff --git a/tests/bundle/Core/Routing/UrlAliasRouterTest.php b/tests/bundle/Core/Routing/UrlAliasRouterTest.php index e3eb1d401e..4445c4a705 100644 --- a/tests/bundle/Core/Routing/UrlAliasRouterTest.php +++ b/tests/bundle/Core/Routing/UrlAliasRouterTest.php @@ -61,7 +61,7 @@ protected function resetConfigResolver() $this->router->setConfigResolver($this->configResolver); } - public function testMatchRequestDeactivatedUrlAlias() + public function testMatchRequestDeactivatedUrlAlias(): void { $this->expectException(ResourceNotFoundException::class); @@ -79,7 +79,7 @@ public function testMatchRequestDeactivatedUrlAlias() $this->router->matchRequest($this->getRequestByPathInfo('/foo')); } - public function testMatchRequestWithRootLocation() + public function testMatchRequestWithRootLocation(): void { $rootLocationId = 123; $this->resetConfigResolver(); @@ -135,7 +135,7 @@ public function testMatchRequestWithRootLocation() self::assertEquals($expected, $this->router->matchRequest($request)); } - public function testMatchRequestLocationCaseRedirectWithRootLocation() + public function testMatchRequestLocationCaseRedirectWithRootLocation(): void { $rootLocationId = 123; $this->resetConfigResolver(); @@ -193,7 +193,7 @@ public function testMatchRequestLocationCaseRedirectWithRootLocation() self::assertEquals($expected, $this->router->matchRequest($request)); } - public function testMatchRequestLocationCaseRedirectWithRootRootLocation() + public function testMatchRequestLocationCaseRedirectWithRootRootLocation(): void { $rootLocationId = 123; $this->resetConfigResolver(); @@ -251,7 +251,7 @@ public function testMatchRequestLocationCaseRedirectWithRootRootLocation() self::assertEquals($expected, $this->router->matchRequest($request)); } - public function testMatchRequestResourceCaseRedirectWithRootLocation() + public function testMatchRequestResourceCaseRedirectWithRootLocation(): void { $rootLocationId = 123; $this->resetConfigResolver(); @@ -299,7 +299,7 @@ public function testMatchRequestResourceCaseRedirectWithRootLocation() self::assertEquals($expected, $this->router->matchRequest($request)); } - public function testMatchRequestVirtualCaseRedirectWithRootLocation() + public function testMatchRequestVirtualCaseRedirectWithRootLocation(): void { $rootLocationId = 123; $this->resetConfigResolver(); @@ -345,7 +345,7 @@ public function testMatchRequestVirtualCaseRedirectWithRootLocation() self::assertEquals($expected, $this->router->matchRequest($request)); } - public function testMatchRequestWithRootLocationAndExclusion() + public function testMatchRequestWithRootLocationAndExclusion(): void { $this->resetConfigResolver(); $this->configResolver diff --git a/tests/bundle/Core/SiteAccess/Config/IOConfigResolverTest.php b/tests/bundle/Core/SiteAccess/Config/IOConfigResolverTest.php index cf6b8a1586..5ea0a28308 100644 --- a/tests/bundle/Core/SiteAccess/Config/IOConfigResolverTest.php +++ b/tests/bundle/Core/SiteAccess/Config/IOConfigResolverTest.php @@ -13,11 +13,10 @@ use Ibexa\Contracts\Core\SiteAccess\ConfigResolverInterface; use Ibexa\Core\MVC\Symfony\SiteAccess; use Ibexa\Core\MVC\Symfony\SiteAccess\SiteAccessService; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Bundle\Core\SiteAccess\Config\IOConfigResolver - */ +#[CoversClass(IOConfigResolver::class)] class IOConfigResolverTest extends TestCase { private const DEFAULT_NAMESPACE = 'ibexa.site_access.config'; diff --git a/tests/bundle/Core/SiteAccess/MatcherBuilderTest.php b/tests/bundle/Core/SiteAccess/MatcherBuilderTest.php index 66bc2bebab..39b2016219 100644 --- a/tests/bundle/Core/SiteAccess/MatcherBuilderTest.php +++ b/tests/bundle/Core/SiteAccess/MatcherBuilderTest.php @@ -12,11 +12,10 @@ use Ibexa\Bundle\Core\SiteAccess\SiteAccessMatcherRegistryInterface; use Ibexa\Core\MVC\Symfony\Routing\SimplifiedRequest; use Ibexa\Core\MVC\Symfony\SiteAccess\Matcher; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Bundle\Core\SiteAccess\MatcherBuilder - */ +#[CoversClass(MatcherBuilder::class)] class MatcherBuilderTest extends TestCase { /** @var \PHPUnit\Framework\MockObject\MockObject */ @@ -28,18 +27,18 @@ protected function setUp(): void $this->siteAccessMatcherRegistry = $this->createMock(SiteAccessMatcherRegistryInterface::class); } - public function testBuildMatcherNoService() + public function testBuildMatcherNoService(): void { $this->siteAccessMatcherRegistry ->expects(self::never()) ->method('getMatcher'); $matcherBuilder = new MatcherBuilder($this->siteAccessMatcherRegistry); - $matcher = $this->createMock(Matcher::class); + $matcher = self::createStub(Matcher::class); $builtMatcher = $matcherBuilder->buildMatcher('\\' . get_class($matcher), [], new SimplifiedRequest()); self::assertInstanceOf(get_class($matcher), $builtMatcher); } - public function testBuildMatcherServiceWrongInterface() + public function testBuildMatcherServiceWrongInterface(): void { $this->expectException(\TypeError::class); @@ -48,12 +47,12 @@ public function testBuildMatcherServiceWrongInterface() ->expects(self::once()) ->method('getMatcher') ->with($serviceId) - ->will(self::returnValue($this->createMock(Matcher::class))); + ->will(self::returnValue(self::createStub(Matcher::class))); $matcherBuilder = new MatcherBuilder($this->siteAccessMatcherRegistry); $matcherBuilder->buildMatcher("@$serviceId", [], new SimplifiedRequest()); } - public function testBuildMatcherService() + public function testBuildMatcherService(): void { $serviceId = 'foo'; $matcher = $this->createMock(CoreMatcher::class); diff --git a/tests/bundle/Core/URLChecker/Handler/HTTPHandlerTest.php b/tests/bundle/Core/URLChecker/Handler/HTTPHandlerTest.php index d2c9d63fb4..a3b9643bb0 100644 --- a/tests/bundle/Core/URLChecker/Handler/HTTPHandlerTest.php +++ b/tests/bundle/Core/URLChecker/Handler/HTTPHandlerTest.php @@ -13,13 +13,13 @@ use Ibexa\Contracts\Core\Repository\Values\URL\URL; use Ibexa\Contracts\Core\Repository\Values\URL\URLUpdateStruct; use Ibexa\Contracts\Core\SiteAccess\ConfigResolverInterface; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use ReflectionMethod; use Symfony\Component\OptionsResolver\Exception\InvalidOptionsException; -/** - * @covers \Ibexa\Bundle\Core\URLChecker\Handler\HTTPHandler - */ +#[CoversClass(HTTPHandler::class)] final class HTTPHandlerTest extends TestCase { private const PARAMETER_NAME = 'url_handler.http.options'; @@ -104,9 +104,7 @@ public function testBuildRequestHeaders(): void ); } - /** - * @dataProvider provideDataForTestIsSuccessful - */ + #[DataProvider('provideDataForTestIsSuccessful')] public function testIsSuccessful(int $statusCode, bool $expected): void { $handler = $this->createHandler([]); @@ -133,9 +131,7 @@ public static function provideDataForTestIsSuccessful(): iterable yield 'status 500' => [500, false]; } - /** - * @dataProvider provideDataForTestShouldRetryWithGet - */ + #[DataProvider('provideDataForTestShouldRetryWithGet')] public function testShouldRetryWithGet( int $statusCode, string $requestMethod, @@ -185,9 +181,7 @@ public function testCompleteRequestRetriesWithGetWhenHeadFails(): void self::assertCount(1, $queue, 'Retry must not consume the queue'); } - /** - * @dataProvider provideCompleteRequestFinalResults - */ + #[DataProvider('provideCompleteRequestFinalResults')] public function testCompleteRequestRecordsStatusAndSchedulesNextUrl( string $method, int $statusCode, diff --git a/tests/bundle/Core/URLChecker/URLCheckerTest.php b/tests/bundle/Core/URLChecker/URLCheckerTest.php index e0d6be90ec..cb0aa4709f 100644 --- a/tests/bundle/Core/URLChecker/URLCheckerTest.php +++ b/tests/bundle/Core/URLChecker/URLCheckerTest.php @@ -43,7 +43,7 @@ protected function setUp(): void $this->logger = $this->createMock(LoggerInterface::class); } - public function testCheck() + public function testCheck(): void { $query = new URLQuery(); $groups = $this->createGroupedUrls(['http', 'https']); @@ -74,7 +74,7 @@ public function testCheck() $urlChecker->check($query); } - public function testCheckUnsupported() + public function testCheckUnsupported(): void { $query = new URLQuery(); $groups = $this->createGroupedUrls(['http', 'https'], 10); diff --git a/tests/bundle/Core/ValueResolver/ContentValueResolverTest.php b/tests/bundle/Core/ValueResolver/ContentValueResolverTest.php index fdc46a07cf..d04631e352 100644 --- a/tests/bundle/Core/ValueResolver/ContentValueResolverTest.php +++ b/tests/bundle/Core/ValueResolver/ContentValueResolverTest.php @@ -34,7 +34,7 @@ public function testResolveWithValidContentId(): void $argumentMetadata = $this->createMock(ArgumentMetadata::class); $argumentMetadata->method('getType')->willReturn(Content::class); - $mockContent = $this->createMock(Content::class); + $mockContent = self::createStub(Content::class); $this->contentServiceMock ->expects(self::once()) diff --git a/tests/bundle/Core/ValueResolver/LocationValueResolverTest.php b/tests/bundle/Core/ValueResolver/LocationValueResolverTest.php index 692aa36727..58d5d8be03 100644 --- a/tests/bundle/Core/ValueResolver/LocationValueResolverTest.php +++ b/tests/bundle/Core/ValueResolver/LocationValueResolverTest.php @@ -42,7 +42,7 @@ public function testResolveWithValidLocationId(): void $argumentMetadata = $this->createMock(ArgumentMetadata::class); $argumentMetadata->method('getType')->willReturn(Location::class); - $mockLocation = $this->createMock(Location::class); + $mockLocation = self::createStub(Location::class); $this->contentPreviewHelperMock ->method('isPreviewActive') diff --git a/tests/bundle/Debug/Collector/IbexaCoreCollectorTest.php b/tests/bundle/Debug/Collector/IbexaCoreCollectorTest.php index 01cda5dd7e..ab50e09cc4 100644 --- a/tests/bundle/Debug/Collector/IbexaCoreCollectorTest.php +++ b/tests/bundle/Debug/Collector/IbexaCoreCollectorTest.php @@ -25,7 +25,7 @@ protected function setUp(): void $this->mainCollector = new IbexaCoreCollector(); } - public function testAddGetCollector() + public function testAddGetCollector(): void { $collector = $this->getDataCollectorMock(); $name = 'foobar'; @@ -38,7 +38,7 @@ public function testAddGetCollector() self::assertSame($collector, $this->mainCollector->getCollector($name)); } - public function testGetInvalidCollector() + public function testGetInvalidCollector(): void { $this->expectException(\InvalidArgumentException::class); @@ -47,7 +47,7 @@ public function testGetInvalidCollector() self::assertSame($collector, $this->mainCollector->getCollector('foo')); } - public function testGetAllCollectors() + public function testGetAllCollectors(): void { $collector1 = $this->getDataCollectorMock(); $nameCollector1 = 'collector1'; @@ -74,7 +74,7 @@ public function testGetAllCollectors() self::assertSame($allCollectors, $this->mainCollector->getAllCollectors()); } - public function testGetToolbarTemplateNothing() + public function testGetToolbarTemplateNothing(): void { $collector = $this->getDataCollectorMock(); $name = 'foobar'; @@ -86,7 +86,7 @@ public function testGetToolbarTemplateNothing() self::assertNull($this->mainCollector->getToolbarTemplate($name)); } - public function testGetToolbarTemplate() + public function testGetToolbarTemplate(): void { $collector = $this->getDataCollectorMock(); $name = 'foobar'; @@ -100,7 +100,7 @@ public function testGetToolbarTemplate() self::assertSame($toolbarTemplate, $this->mainCollector->getToolbarTemplate($name)); } - public function testGetPanelTemplateNothing() + public function testGetPanelTemplateNothing(): void { $collector = $this->getDataCollectorMock(); $name = 'foobar'; @@ -112,7 +112,7 @@ public function testGetPanelTemplateNothing() self::assertNull($this->mainCollector->getPanelTemplate($name)); } - public function testGetPanelTemplate() + public function testGetPanelTemplate(): void { $collector = $this->getDataCollectorMock(); $name = 'foobar'; @@ -126,7 +126,7 @@ public function testGetPanelTemplate() self::assertSame($panelTemplate, $this->mainCollector->getPanelTemplate($name)); } - public function testCollect() + public function testCollect(): void { $collector1 = $this->getDataCollectorMock(); $nameCollector1 = 'collector1'; diff --git a/tests/bundle/Debug/DependencyInjection/Compiler/DataCollectorPassTest.php b/tests/bundle/Debug/DependencyInjection/Compiler/DataCollectorPassTest.php index ea85c51778..800657e474 100644 --- a/tests/bundle/Debug/DependencyInjection/Compiler/DataCollectorPassTest.php +++ b/tests/bundle/Debug/DependencyInjection/Compiler/DataCollectorPassTest.php @@ -27,7 +27,7 @@ protected function registerCompilerPass(ContainerBuilder $container): void $container->addCompilerPass(new DataCollectorPass()); } - public function testAddCollector() + public function testAddCollector(): void { $defA = new Definition(); $defA->addTag('ibexa.debug.data_collector', [ diff --git a/tests/bundle/IO/BinaryStreamResponseTest.php b/tests/bundle/IO/BinaryStreamResponseTest.php index 1ebc485080..63c21bc852 100644 --- a/tests/bundle/IO/BinaryStreamResponseTest.php +++ b/tests/bundle/IO/BinaryStreamResponseTest.php @@ -11,13 +11,12 @@ use Ibexa\Bundle\IO\BinaryStreamResponse; use Ibexa\Core\IO\IOServiceInterface; use Ibexa\Core\IO\Values\BinaryFile; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; use Symfony\Component\HttpFoundation\Request; -/** - * @covers \Ibexa\Bundle\IO\BinaryStreamResponse - */ +#[CoversClass(BinaryStreamResponse::class)] final class BinaryStreamResponseTest extends TestCase { /** diff --git a/tests/bundle/IO/DependencyInjection/Compiler/IOConfigurationPassTest.php b/tests/bundle/IO/DependencyInjection/Compiler/IOConfigurationPassTest.php index d5d187c657..b8e079f131 100644 --- a/tests/bundle/IO/DependencyInjection/Compiler/IOConfigurationPassTest.php +++ b/tests/bundle/IO/DependencyInjection/Compiler/IOConfigurationPassTest.php @@ -12,14 +12,13 @@ use Ibexa\Bundle\IO\DependencyInjection\Compiler\IOConfigurationPass; use Ibexa\Bundle\IO\DependencyInjection\ConfigurationFactory; use Matthias\SymfonyDependencyInjectionTest\PhpUnit\AbstractCompilerPassTestCase; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\MockObject\MockObject; use Symfony\Component\Config\Definition\Exception\InvalidConfigurationException; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Definition; -/** - * @covers \Ibexa\Bundle\IO\DependencyInjection\Compiler\IOConfigurationPass - */ +#[CoversClass(IOConfigurationPass::class)] final class IOConfigurationPassTest extends AbstractCompilerPassTestCase { protected ConfigurationFactory & MockObject $metadataConfigurationFactoryMock; diff --git a/tests/bundle/IO/DependencyInjection/IbexaIOExtensionTest.php b/tests/bundle/IO/DependencyInjection/IbexaIOExtensionTest.php index ea3f5356b2..984e4f1d9c 100644 --- a/tests/bundle/IO/DependencyInjection/IbexaIOExtensionTest.php +++ b/tests/bundle/IO/DependencyInjection/IbexaIOExtensionTest.php @@ -31,7 +31,7 @@ protected function getContainerExtensions(): array return [$extension]; } - public function testParametersWithoutConfiguration() + public function testParametersWithoutConfiguration(): void { $this->load(); @@ -39,7 +39,7 @@ public function testParametersWithoutConfiguration() $this->assertContainerBuilderHasParameter('ibexa.io.binarydata_handlers', []); } - public function testParametersWithMetadataHandler() + public function testParametersWithMetadataHandler(): void { $config = [ 'metadata_handlers' => [ @@ -55,7 +55,7 @@ public function testParametersWithMetadataHandler() ); } - public function testParametersWithBinarydataHandler() + public function testParametersWithBinarydataHandler(): void { $config = [ 'binarydata_handlers' => [ diff --git a/tests/bundle/IO/EventListener/StreamFileListenerTest.php b/tests/bundle/IO/EventListener/StreamFileListenerTest.php index 9c5b59a7de..2c2b56c57a 100644 --- a/tests/bundle/IO/EventListener/StreamFileListenerTest.php +++ b/tests/bundle/IO/EventListener/StreamFileListenerTest.php @@ -14,15 +14,14 @@ use Ibexa\Core\IO\IOConfigProvider; use Ibexa\Core\IO\IOServiceInterface; use Ibexa\Core\IO\Values\BinaryFile; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpKernel\Event\RequestEvent; use Symfony\Component\HttpKernel\HttpKernelInterface; -/** - * @covers \Ibexa\Bundle\IO\EventListener\StreamFileListener - */ +#[CoversClass(StreamFileListener::class)] final class StreamFileListenerTest extends TestCase { private StreamFileListener $eventListener; @@ -119,7 +118,7 @@ protected function createRequest(string $semanticPath, string $host = 'localhost protected function createEvent(Request $request): RequestEvent { return new RequestEvent( - $this->createMock(HttpKernelInterface::class), + self::createStub(HttpKernelInterface::class), $request, HttpKernelInterface::MAIN_REQUEST ); diff --git a/tests/bundle/IO/FieldType/Image/ImageThumbnailProxyStrategyTest.php b/tests/bundle/IO/FieldType/Image/ImageThumbnailProxyStrategyTest.php index 8fd673dcb2..182bfa443c 100644 --- a/tests/bundle/IO/FieldType/Image/ImageThumbnailProxyStrategyTest.php +++ b/tests/bundle/IO/FieldType/Image/ImageThumbnailProxyStrategyTest.php @@ -40,7 +40,7 @@ public function testGetThumbnailThrowsExceptionIfWrappedObjectIsNull(): void $field->method('getId')->willReturn(123); $field->method('getFieldTypeIdentifier')->willReturn('ezimage'); - $versionInfo = $this->createMock(VersionInfo::class); + $versionInfo = self::createStub(VersionInfo::class); $this->imageThumbnailStrategyMock ->expects(self::once()) diff --git a/tests/bundle/IO/Migration/FileMigratorTest.php b/tests/bundle/IO/Migration/FileMigratorTest.php index 3fdf38ffa5..2723bbab52 100644 --- a/tests/bundle/IO/Migration/FileMigratorTest.php +++ b/tests/bundle/IO/Migration/FileMigratorTest.php @@ -11,16 +11,16 @@ use DateTime; use Ibexa\Bundle\IO\ApiLoader\HandlerRegistry; use Ibexa\Bundle\IO\Migration\FileMigrator\FileMigrator; +use Ibexa\Bundle\IO\Migration\MigrationHandler; use Ibexa\Contracts\Core\IO\BinaryFile; use Ibexa\Core\IO\IOBinarydataHandler; use Ibexa\Core\IO\IOMetadataHandler; use Ibexa\Core\IO\IOMetadataHandler\Flysystem; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Bundle\IO\Migration\MigrationHandler - */ +#[CoversClass(MigrationHandler::class)] final class FileMigratorTest extends TestCase { /** @var \Ibexa\Bundle\IO\ApiLoader\HandlerRegistry<\Ibexa\Core\IO\IOMetadataHandler>&\PHPUnit\Framework\MockObject\MockObject */ diff --git a/tests/bundle/RepositoryInstaller/DependencyInjection/Compiler/InstallerTagPassTest.php b/tests/bundle/RepositoryInstaller/DependencyInjection/Compiler/InstallerTagPassTest.php index 0dd8d5003b..f71876a474 100644 --- a/tests/bundle/RepositoryInstaller/DependencyInjection/Compiler/InstallerTagPassTest.php +++ b/tests/bundle/RepositoryInstaller/DependencyInjection/Compiler/InstallerTagPassTest.php @@ -11,18 +11,14 @@ use Ibexa\Bundle\RepositoryInstaller\Command\InstallPlatformCommand; use Ibexa\Bundle\RepositoryInstaller\DependencyInjection\Compiler\InstallerTagPass; use Matthias\SymfonyDependencyInjectionTest\PhpUnit\AbstractCompilerPassTestCase; +use PHPUnit\Framework\Attributes\CoversClass; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Definition; use Symfony\Component\DependencyInjection\Reference; -/** - * @covers \Ibexa\Bundle\RepositoryInstaller\DependencyInjection\Compiler\InstallerTagPass - */ +#[CoversClass(InstallerTagPass::class)] class InstallerTagPassTest extends AbstractCompilerPassTestCase { - /** - * @covers \Ibexa\Bundle\RepositoryInstaller\DependencyInjection\Compiler\InstallerTagPass::process - */ public function testProcessInjectsInstallersIntoCommand(): void { $this->setDefinition( diff --git a/tests/bundle/RepositoryInstaller/DependencyInjection/IbexaInstallerExtensionTest.php b/tests/bundle/RepositoryInstaller/DependencyInjection/IbexaInstallerExtensionTest.php index e4a48f7812..2e71110e8f 100644 --- a/tests/bundle/RepositoryInstaller/DependencyInjection/IbexaInstallerExtensionTest.php +++ b/tests/bundle/RepositoryInstaller/DependencyInjection/IbexaInstallerExtensionTest.php @@ -14,15 +14,11 @@ use Ibexa\Bundle\RepositoryInstaller\Installer\CoreInstaller; use Ibexa\Bundle\RepositoryInstaller\Installer\DbBasedInstaller; use Matthias\SymfonyDependencyInjectionTest\PhpUnit\AbstractExtensionTestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Bundle\RepositoryInstaller\DependencyInjection\IbexaRepositoryInstallerExtension - */ +#[CoversClass(IbexaRepositoryInstallerExtension::class)] class IbexaInstallerExtensionTest extends AbstractExtensionTestCase { - /** - * @covers \Ibexa\Bundle\RepositoryInstaller\DependencyInjection\IbexaRepositoryInstallerExtension::load - */ public function testLoadLoadsTaggedCoreInstaller(): void { $this->load(); @@ -37,9 +33,6 @@ public function testLoadLoadsTaggedCoreInstaller(): void ); } - /** - * @covers \Ibexa\Bundle\RepositoryInstaller\DependencyInjection\IbexaRepositoryInstallerExtension::load - */ public function testLoadLoadsTaggedInstallerCommand(): void { $this->load(); diff --git a/tests/bundle/RepositoryInstaller/IbexaRepositoryInstallerBundleTest.php b/tests/bundle/RepositoryInstaller/IbexaRepositoryInstallerBundleTest.php index a67042e6ba..fec2ae15ff 100644 --- a/tests/bundle/RepositoryInstaller/IbexaRepositoryInstallerBundleTest.php +++ b/tests/bundle/RepositoryInstaller/IbexaRepositoryInstallerBundleTest.php @@ -11,14 +11,13 @@ use Ibexa\Bundle\DoctrineSchema\DependencyInjection\DoctrineSchemaExtension; use Ibexa\Bundle\RepositoryInstaller\DependencyInjection\Compiler\InstallerTagPass; use Ibexa\Bundle\RepositoryInstaller\IbexaRepositoryInstallerBundle; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; use Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Exception\RuntimeException; -/** - * @covers \Ibexa\Bundle\RepositoryInstaller\IbexaRepositoryInstallerBundle - */ +#[CoversClass(IbexaRepositoryInstallerBundle::class)] class IbexaRepositoryInstallerBundleTest extends TestCase { private IbexaRepositoryInstallerBundle $bundle; diff --git a/tests/integration/Core/BasicKernelTest.php b/tests/integration/Core/BasicKernelTest.php index 37a5e49910..35070c3862 100644 --- a/tests/integration/Core/BasicKernelTest.php +++ b/tests/integration/Core/BasicKernelTest.php @@ -10,13 +10,13 @@ use Ibexa\Contracts\Core\Repository\Repository; use Ibexa\Contracts\Test\Core\IbexaKernelTestCase; +use PHPUnit\Framework\Attributes\CoversNothing; /** * Schema and fixtures are imported once, before the suite runs, by tests/integration/bootstrap.php — * this test only needs to boot the kernel. - * - * @coversNothing */ +#[CoversNothing] final class BasicKernelTest extends IbexaKernelTestCase { public function testBasicKernelCompiles(): void diff --git a/tests/integration/Core/BinaryBase/BinaryBaseStorage/BinaryBaseStorageTest.php b/tests/integration/Core/BinaryBase/BinaryBaseStorage/BinaryBaseStorageTest.php index ecc2247e5d..e43d9b6423 100644 --- a/tests/integration/Core/BinaryBase/BinaryBaseStorage/BinaryBaseStorageTest.php +++ b/tests/integration/Core/BinaryBase/BinaryBaseStorage/BinaryBaseStorageTest.php @@ -22,7 +22,10 @@ use Ibexa\Core\IO\Values\BinaryFile; use Ibexa\Core\IO\Values\BinaryFileCreateStruct; use Ibexa\Tests\Integration\Core\BaseCoreFieldTypeIntegrationTestCase; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; use PHPUnit\Framework\MockObject\MockObject; +use PHPUnit\Framework\MockObject\Stub; class BinaryBaseStorageTest extends BaseCoreFieldTypeIntegrationTestCase { @@ -37,8 +40,7 @@ class BinaryBaseStorageTest extends BaseCoreFieldTypeIntegrationTestCase /** @var \Ibexa\Core\FieldType\BinaryBase\BinaryBaseStorage|\PHPUnit\Framework\MockObject\MockObject */ protected $storage; - /** @var \Ibexa\Core\FieldType\Validator\FileExtensionBlackListValidator&\PHPUnit\Framework\MockObject\MockObject */ - protected $fileExtensionBlackListValidatorMock; + protected FileExtensionBlackListValidator&Stub $fileExtensionBlackListValidatorMock; protected function setUp(): void { @@ -47,7 +49,7 @@ protected function setUp(): void $this->gateway = $this->getStorageGateway(); $this->pathGeneratorMock = $this->createMock(PathGeneratorInterface::class); $this->ioServiceMock = $this->createMock(IOServiceInterface::class); - $this->fileExtensionBlackListValidatorMock = $this->createMock( + $this->fileExtensionBlackListValidatorMock = self::createStub( FileExtensionBlackListValidator::class ); $this->storage = $this->getMockBuilder(BinaryBaseStorage::class) @@ -57,7 +59,7 @@ protected function setUp(): void $this->gateway, $this->ioServiceMock, $this->pathGeneratorMock, - $this->createMock(MimeTypeDetector::class), + self::createStub(MimeTypeDetector::class), $this->fileExtensionBlackListValidatorMock, ] ) @@ -74,9 +76,7 @@ public function testHasFieldData(): void self::assertTrue($this->storage->hasFieldData()); } - /** - * @dataProvider providerOfFieldData - */ + #[DataProvider('providerOfFieldData')] public function testStoreFieldData(VersionInfo $versionInfo, Field $field): void { $binaryFileIdentifier = 'qwerty12345'; @@ -104,15 +104,10 @@ public function testStoreFieldData(VersionInfo $versionInfo, Field $field): void ->willReturn(new BinaryFile(['id' => $binaryFileIdentifier, 'uri' => '/foo'])); $this->storage->storeFieldData($versionInfo, $field); - - $this->expectNotToPerformAssertions(); } - /** - * @depends testStoreFieldData - * - * @dataProvider providerOfFieldData - */ + #[Depends('testStoreFieldData')] + #[DataProvider('providerOfFieldData')] public function testCopyLegacyField(VersionInfo $versionInfo, Field $originalField): void { $field = clone $originalField; @@ -132,7 +127,7 @@ public function testCopyLegacyField(VersionInfo $versionInfo, Field $originalFie self::assertFalse($flag); } - public function providerOfFieldData(): array + public static function providerOfFieldData(): array { $field = new Field(); $field->id = 124; diff --git a/tests/integration/Core/Doctrine/ManagedTablesSchemaAssetFilterCompositionTest.php b/tests/integration/Core/Doctrine/ManagedTablesSchemaAssetFilterCompositionTest.php index 6190785480..65ff4fb5c5 100644 --- a/tests/integration/Core/Doctrine/ManagedTablesSchemaAssetFilterCompositionTest.php +++ b/tests/integration/Core/Doctrine/ManagedTablesSchemaAssetFilterCompositionTest.php @@ -10,7 +10,9 @@ use Doctrine\Bundle\DoctrineBundle\Dbal\SchemaAssetsFilterManager; use Doctrine\DBAL\Configuration; +use Ibexa\Bundle\Core\DependencyInjection\Compiler\InjectEntityManagerMappingsPass; use Ibexa\Contracts\Core\Test\IbexaKernelTestCase; +use PHPUnit\Framework\Attributes\CoversClass; /** * Both InjectEntityManagerMappingsPass and DoctrineBundle's DbalSchemaFilterPass install a @@ -18,9 +20,8 @@ * Configuration::setSchemaAssetsFilter() overwrites rather than composes, this verifies in a * fully booted kernel - i.e. with the real compiler pass ordering - that neither the legacy * schema protection nor a project's own schema filter gets lost. - * - * @covers \Ibexa\Bundle\Core\DependencyInjection\Compiler\InjectEntityManagerMappingsPass */ +#[CoversClass(InjectEntityManagerMappingsPass::class)] final class ManagedTablesSchemaAssetFilterCompositionTest extends IbexaKernelTestCase { protected static function getKernelClass(): string diff --git a/tests/integration/Core/FieldType/FieldConstraintsStorage/FieldConstraintsStorageTest.php b/tests/integration/Core/FieldType/FieldConstraintsStorage/FieldConstraintsStorageTest.php index f2d6cfbd42..e1b6ad143e 100644 --- a/tests/integration/Core/FieldType/FieldConstraintsStorage/FieldConstraintsStorageTest.php +++ b/tests/integration/Core/FieldType/FieldConstraintsStorage/FieldConstraintsStorageTest.php @@ -16,6 +16,7 @@ use Ibexa\Tests\Integration\Core\FieldType\FieldConstraintsStorage\Stub\ExampleFieldConstraintsStorage; use Ibexa\Tests\Integration\Core\FieldType\FieldConstraintsStorage\Stub\ExampleFieldType; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; +use PHPUnit\Framework\Attributes\DependsExternal; final class FieldConstraintsStorageTest extends BaseTestCase { @@ -90,9 +91,7 @@ public function testStorageDataIsCreatedOnContentTypeCreate(): ContentType return $contentTypeService->loadContentTypeByIdentifier($contentType->identifier); } - /** - * @depends Ibexa\Tests\Integration\Core\FieldType\FieldConstraintsStorage\FieldConstraintsStorageTest::testStorageDataIsCreatedOnContentTypeCreate - */ + #[DependsExternal(self::class, 'testStorageDataIsCreatedOnContentTypeCreate')] public function testStorageDataIsUpdatedOnContentTypeUpdate(ContentType $contentType): ContentType { $repository = $this->getRepository(false); @@ -128,9 +127,7 @@ public function testStorageDataIsUpdatedOnContentTypeUpdate(ContentType $content return $contentTypeService->loadContentTypeByIdentifier($contentType->identifier); } - /** - * @depends Ibexa\Tests\Integration\Core\FieldType\FieldConstraintsStorage\FieldConstraintsStorageTest::testStorageDataIsUpdatedOnContentTypeUpdate - */ + #[DependsExternal(self::class, 'testStorageDataIsUpdatedOnContentTypeUpdate')] public function testStorageDataIsDeletedOnContentTypeDelete(ContentType $contentType): void { $fieldDefinition = $contentType->getFieldDefinition(self::EXAMPLE_FIELD_IDENTIFIER); diff --git a/tests/integration/Core/IO/BinarydataHandler/FlysystemTest.php b/tests/integration/Core/IO/BinarydataHandler/FlysystemTest.php index 3d8dcd7d34..a1bd7dd638 100644 --- a/tests/integration/Core/IO/BinarydataHandler/FlysystemTest.php +++ b/tests/integration/Core/IO/BinarydataHandler/FlysystemTest.php @@ -11,14 +11,14 @@ use Ibexa\Contracts\Core\IO\BinaryFileCreateStruct; use Ibexa\Contracts\Core\Test\IbexaKernelTestCase; use Ibexa\Core\IO\IOBinarydataHandler; +use Ibexa\Core\IO\IOBinarydataHandler\Flysystem; use Ibexa\Tests\Integration\Core\IO\FlysystemTestAdapterInterface; use League\Flysystem\FilesystemOperator; use League\Flysystem\Visibility; +use PHPUnit\Framework\Attributes\CoversClass; use Symfony\Component\DependencyInjection\ContainerInterface; -/** - * @covers \Ibexa\Core\IO\IOBinarydataHandler\Flysystem - */ +#[CoversClass(Flysystem::class)] final class FlysystemTest extends IbexaKernelTestCase { private IOBinarydataHandler $binaryDataHandler; diff --git a/tests/integration/Core/Image/ImageStorage/ImageStorageTest.php b/tests/integration/Core/Image/ImageStorage/ImageStorageTest.php index 1aa33948d6..cf312fff04 100644 --- a/tests/integration/Core/Image/ImageStorage/ImageStorageTest.php +++ b/tests/integration/Core/Image/ImageStorage/ImageStorageTest.php @@ -23,7 +23,10 @@ use Ibexa\Core\IO\Values\BinaryFile; use Ibexa\Core\IO\Values\BinaryFileCreateStruct; use Ibexa\Tests\Integration\Core\BaseCoreFieldTypeIntegrationTestCase; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; use PHPUnit\Framework\MockObject\MockObject; +use PHPUnit\Framework\MockObject\Stub; final class ImageStorageTest extends BaseCoreFieldTypeIntegrationTestCase { @@ -31,9 +34,9 @@ final class ImageStorageTest extends BaseCoreFieldTypeIntegrationTestCase private UrlRedecoratorInterface & MockObject $redecorator; - private PathGenerator & MockObject $pathGenerator; + private PathGenerator&Stub $pathGenerator; - private AliasCleanerInterface & MockObject $aliasCleaner; + private AliasCleanerInterface&Stub $aliasCleaner; private FilePathNormalizerInterface & MockObject $filePathNormalizer; @@ -41,7 +44,7 @@ final class ImageStorageTest extends BaseCoreFieldTypeIntegrationTestCase private ImageStorage $storage; - private FileExtensionBlackListValidator & MockObject $fileExtensionBlackListValidator; + private FileExtensionBlackListValidator&Stub $fileExtensionBlackListValidator; protected function setUp(): void { @@ -49,11 +52,11 @@ protected function setUp(): void $this->redecorator = $this->createMock(UrlRedecoratorInterface::class); $this->gateway = new DoctrineStorage($this->redecorator, $this->getDatabaseConnection()); - $this->pathGenerator = $this->createMock(PathGenerator::class); - $this->aliasCleaner = $this->createMock(AliasCleanerInterface::class); + $this->pathGenerator = self::createStub(PathGenerator::class); + $this->aliasCleaner = self::createStub(AliasCleanerInterface::class); $this->filePathNormalizer = $this->createMock(FilePathNormalizerInterface::class); $this->ioService = $this->createMock(IOServiceInterface::class); - $this->fileExtensionBlackListValidator = $this->createMock(FileExtensionBlackListValidator::class); + $this->fileExtensionBlackListValidator = self::createStub(FileExtensionBlackListValidator::class); $this->storage = new ImageStorage( $this->gateway, $this->ioService, @@ -70,11 +73,10 @@ public function testHasFieldData(): void } /** - * @dataProvider providerOfFieldData - * * @throws \Ibexa\Core\Base\Exceptions\InvalidArgumentException * @throws \Ibexa\Core\IO\Exception\InvalidBinaryFileIdException */ + #[DataProvider('providerOfFieldData')] public function testStoreFieldDataDuringCreate(VersionInfo $versionInfo, Field $field): void { $binaryFile = $this->runCommonStoreFieldDataMocks($field); @@ -90,11 +92,8 @@ public function testStoreFieldDataDuringCreate(VersionInfo $versionInfo, Field $ self::assertSame(1, $this->gateway->countImageReferences($binaryFile->uri)); } - /** - * @dataProvider providerOfFieldData - * - * @depends testStoreFieldDataDuringCreate - */ + #[Depends('testStoreFieldDataDuringCreate')] + #[DataProvider('providerOfFieldData')] public function testStoreFieldDataDuringUpdate(VersionInfo $versionInfo, Field $field): void { $binaryFile = $this->runCommonStoreFieldDataMocks($field); @@ -110,11 +109,8 @@ public function testStoreFieldDataDuringUpdate(VersionInfo $versionInfo, Field $ self::assertSame(1, $this->gateway->countImageReferences($binaryFile->uri)); } - /** - * @dataProvider providerOfFieldData - * - * @depends testStoreFieldDataDuringUpdate - */ + #[Depends('testStoreFieldDataDuringUpdate')] + #[DataProvider('providerOfFieldData')] public function testStoreFieldDataDuringUpdateWithDifferentImage(VersionInfo $versionInfo, Field $field): void { $versionInfo->versionNo = 2; @@ -152,9 +148,7 @@ public function testStoreFieldDataDuringUpdateWithDifferentImage(VersionInfo $ve self::assertSame(1, $this->gateway->countImageReferences($binaryFile->uri)); } - /** - * @dataProvider providerOfFieldData - */ + #[DataProvider('providerOfFieldData')] public function testStoreFieldDataWithSameImageOnAutosave(VersionInfo $versionInfo, Field $field): void { $targetPath = '1/8/6/232-eng-GB/' . $field->value->externalData['fileName']; @@ -256,7 +250,7 @@ private function runCommonStoreFieldDataMocks(Field $field): BinaryFile * \Ibexa\Contracts\Core\Persistence\Content\Field * }> */ - public function providerOfFieldData(): iterable + public static function providerOfFieldData(): iterable { $path = __DIR__ . '/image.jpg'; diff --git a/tests/integration/Core/Limitation/MemberOfLimitationTest.php b/tests/integration/Core/Limitation/MemberOfLimitationTest.php index 82ad8430d2..d4d82529ae 100644 --- a/tests/integration/Core/Limitation/MemberOfLimitationTest.php +++ b/tests/integration/Core/Limitation/MemberOfLimitationTest.php @@ -12,13 +12,14 @@ use Ibexa\Contracts\Core\Repository\Values\User\Limitation\MemberOfLimitation; use Ibexa\Core\Limitation\MemberOfLimitationType; use Ibexa\Tests\Integration\Core\Repository\Limitation\PermissionResolver\BaseLimitationIntegrationTestCase; +use PHPUnit\Framework\Attributes\DataProvider; final class MemberOfLimitationTest extends BaseLimitationIntegrationTestCase { private const ADMIN_GROUP_ID = 14; private const USERS_GROUP_ID = 4; - public function userPermissionLimitationProvider(): array + public static function userPermissionLimitationProvider(): array { $allowInAdministratorsLimitation = new MemberOfLimitation(); $allowInAdministratorsLimitation->limitationValues[] = self::ADMIN_GROUP_ID; @@ -36,9 +37,7 @@ public function userPermissionLimitationProvider(): array ]; } - /** - * @dataProvider userPermissionLimitationProvider - */ + #[DataProvider('userPermissionLimitationProvider')] public function testCanUserAssignRoleToUser(array $limitations, bool $expectedResult): void { $repository = $this->getRepository(); diff --git a/tests/integration/Core/Limitation/PermissionResolver/LanguageLimitationIntegrationTest.php b/tests/integration/Core/Limitation/PermissionResolver/LanguageLimitationIntegrationTest.php index 675e774179..fd1353e896 100644 --- a/tests/integration/Core/Limitation/PermissionResolver/LanguageLimitationIntegrationTest.php +++ b/tests/integration/Core/Limitation/PermissionResolver/LanguageLimitationIntegrationTest.php @@ -11,6 +11,7 @@ use Ibexa\Contracts\Core\Limitation\Target; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\LanguageLimitation; use Ibexa\Tests\Integration\Core\Repository\Limitation\PermissionResolver\BaseLimitationIntegrationTestCase; +use PHPUnit\Framework\Attributes\DataProvider; /** * Integration test for chosen use cases of calls to PermissionResolver::canUser. @@ -28,7 +29,7 @@ class LanguageLimitationIntegrationTest extends BaseLimitationIntegrationTestCas * * @return array */ - public function providerForCanUserCreateContent(): array + public static function providerForCanUserCreateContent(): array { $limitationForGerman = new LanguageLimitation(); $limitationForGerman->limitationValues = [self::LANG_GER_DE]; @@ -49,8 +50,6 @@ public function providerForCanUserCreateContent(): array } /** - * @dataProvider providerForCanUserCreateContent - * * @param array $limitations * @param bool $expectedResult * @@ -58,6 +57,7 @@ public function providerForCanUserCreateContent(): array * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ + #[DataProvider('providerForCanUserCreateContent')] public function testCanUserCreateContent(array $limitations, bool $expectedResult): void { $repository = $this->getRepository(); @@ -94,7 +94,7 @@ public function testCanUserCreateContent(array $limitations, bool $expectedResul * @see testCanUserEditContent * @see testCanUserPublishContent */ - public function providerForCanUserEditOrPublishContent(): array + public static function providerForCanUserEditOrPublishContent(): array { $limitationForGerman = new LanguageLimitation(); $limitationForGerman->limitationValues = [self::LANG_GER_DE]; @@ -114,8 +114,6 @@ public function providerForCanUserEditOrPublishContent(): array } /** - * @dataProvider providerForCanUserEditOrPublishContent - * * @param array $limitations * @param bool $expectedResult * @@ -123,6 +121,7 @@ public function providerForCanUserEditOrPublishContent(): array * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ + #[DataProvider('providerForCanUserEditOrPublishContent')] public function testCanUserEditContent(array $limitations, bool $expectedResult): void { $repository = $this->getRepository(); @@ -145,8 +144,6 @@ public function testCanUserEditContent(array $limitations, bool $expectedResult) } /** - * @dataProvider providerForCanUserEditOrPublishContent - * * @param array $limitations * @param bool $expectedResult * @@ -154,6 +151,7 @@ public function testCanUserEditContent(array $limitations, bool $expectedResult) * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ + #[DataProvider('providerForCanUserEditOrPublishContent')] public function testCanUserPublishContent(array $limitations, bool $expectedResult): void { $content = $this->createFolder([self::LANG_ENG_GB => 'British Folder'], 2); @@ -168,7 +166,7 @@ public function testCanUserPublishContent(array $limitations, bool $expectedResu * * @see testCanUserDeleteContent */ - public function providerForCanUserDeleteContent(): array + public static function providerForCanUserDeleteContent(): array { $limitationForGerman = new LanguageLimitation(); $limitationForGerman->limitationValues = [self::LANG_GER_DE]; @@ -188,8 +186,6 @@ public function providerForCanUserDeleteContent(): array } /** - * @dataProvider providerForCanUserDeleteContent - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation[] $limitations * @param bool $expectedResult * @@ -197,6 +193,7 @@ public function providerForCanUserDeleteContent(): array * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ + #[DataProvider('providerForCanUserDeleteContent')] public function testCanUserDeleteContent(array $limitations, bool $expectedResult): void { $content = $this->createFolder( @@ -218,7 +215,7 @@ public function testCanUserDeleteContent(array $limitations, bool $expectedResul * * @see testCanUserDeleteContentTranslation */ - public function providerForCanUserDeleteContentTranslation(): iterable + public static function providerForCanUserDeleteContentTranslation(): iterable { $limitationForGerman = new LanguageLimitation(); $limitationForGerman->limitationValues = [self::LANG_GER_DE]; @@ -249,8 +246,6 @@ public function providerForCanUserDeleteContentTranslation(): iterable } /** - * @dataProvider providerForCanUserDeleteContentTranslation - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation[] $limitations * @param string $translation * @param bool $expectedResult @@ -259,6 +254,7 @@ public function providerForCanUserDeleteContentTranslation(): iterable * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ + #[DataProvider('providerForCanUserDeleteContentTranslation')] public function testCanUserDeleteContentTranslation(array $limitations, string $translation, bool $expectedResult): void { $content = $this->createFolder( diff --git a/tests/integration/Core/Limitation/RoleLimitationTest.php b/tests/integration/Core/Limitation/RoleLimitationTest.php index 08415cf620..8a60c19500 100644 --- a/tests/integration/Core/Limitation/RoleLimitationTest.php +++ b/tests/integration/Core/Limitation/RoleLimitationTest.php @@ -11,15 +11,16 @@ use Ibexa\Contracts\Core\Repository\Repository; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\UserRoleLimitation; use Ibexa\Tests\Integration\Core\Repository\Limitation\PermissionResolver\BaseLimitationIntegrationTestCase; +use PHPUnit\Framework\Attributes\DataProvider; final class RoleLimitationTest extends BaseLimitationIntegrationTestCase { private const USERS_GROUP_ID = 4; - public function userPermissionLimitationProvider(): array + public static function userPermissionLimitationProvider(): array { $allowEditorLimitation = new UserRoleLimitation(); - $roleService = $this->getRepository()->getRoleService(); + $roleService = static::resolveRepository()->getRoleService(); $allowEditorLimitation->limitationValues[] = $roleService->loadRoleByIdentifier('Editor')->id; $allowAdministratorLimitation = new UserRoleLimitation(); @@ -31,9 +32,7 @@ public function userPermissionLimitationProvider(): array ]; } - /** - * @dataProvider userPermissionLimitationProvider - */ + #[DataProvider('userPermissionLimitationProvider')] public function testCanUserAssignRole(array $limitations, bool $expectedResult): void { $repository = $this->getRepository(); diff --git a/tests/integration/Core/MVC/Symfony/Controller/Content/DownloadControllerRequestFlowTest.php b/tests/integration/Core/MVC/Symfony/Controller/Content/DownloadControllerRequestFlowTest.php index f7acd3ee21..265bf01afc 100644 --- a/tests/integration/Core/MVC/Symfony/Controller/Content/DownloadControllerRequestFlowTest.php +++ b/tests/integration/Core/MVC/Symfony/Controller/Content/DownloadControllerRequestFlowTest.php @@ -12,9 +12,12 @@ use Ibexa\Bundle\IO\BinaryStreamResponse; use Ibexa\Contracts\Core\Repository\Values\Content\Field; use Ibexa\Contracts\Core\Test\IbexaKernelTestCase; +use Ibexa\Core\MVC\Symfony\Controller\Content\DownloadController; use Ibexa\Core\MVC\Symfony\Routing\ChainRouter; use Ibexa\Tests\Core\MVC\Symfony\Controller\Controller\Content\DownloadControllerTestTrait; use Ibexa\Tests\Integration\Core\MVC\Symfony\InternalRoutingTestKernel; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; use Symfony\Bundle\FrameworkBundle\Routing\Router as FrameworkRouter; use Symfony\Component\EventDispatcher\EventDispatcher; use Symfony\Component\HttpFoundation\Request; @@ -31,11 +34,8 @@ use Symfony\Component\Routing\RouteCollection; use Symfony\Component\Routing\RouterInterface; -/** - * @group integration - * - * @covers \Ibexa\Core\MVC\Symfony\Controller\Content\DownloadController - */ +#[CoversClass(DownloadController::class)] +#[Group('integration')] final class DownloadControllerRequestFlowTest extends IbexaKernelTestCase { use DownloadControllerTestTrait; diff --git a/tests/integration/Core/Persistence/Filter/Doctrine/FilteringQueryBuilderTest.php b/tests/integration/Core/Persistence/Filter/Doctrine/FilteringQueryBuilderTest.php index 3933a08000..f0317d8944 100644 --- a/tests/integration/Core/Persistence/Filter/Doctrine/FilteringQueryBuilderTest.php +++ b/tests/integration/Core/Persistence/Filter/Doctrine/FilteringQueryBuilderTest.php @@ -14,8 +14,10 @@ use Doctrine\DBAL\SQL\Builder\DefaultSelectSQLBuilder; use Ibexa\Contracts\Core\Persistence\Filter\Doctrine\FilteringQueryBuilder; use Ibexa\Core\Base\Exceptions\DatabaseException; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; +#[CoversClass(FilteringQueryBuilder::class)] class FilteringQueryBuilderTest extends TestCase { /** @var \Ibexa\Contracts\Core\Persistence\Filter\Doctrine\FilteringQueryBuilder */ @@ -35,9 +37,6 @@ protected function setUp(): void $this->queryBuilder = new FilteringQueryBuilder($connectionMock); } - /** - * @covers \Ibexa\Contracts\Core\Persistence\Filter\Doctrine\FilteringQueryBuilder::joinOnce - */ public function testJoinOnce(): void { $this->queryBuilder diff --git a/tests/integration/Core/Persistence/Legacy/BookmarkHandlerTest.php b/tests/integration/Core/Persistence/Legacy/BookmarkHandlerTest.php index fe419ee748..a79dca6b7c 100644 --- a/tests/integration/Core/Persistence/Legacy/BookmarkHandlerTest.php +++ b/tests/integration/Core/Persistence/Legacy/BookmarkHandlerTest.php @@ -14,11 +14,11 @@ use Ibexa\Contracts\Core\Persistence\Content\Location; use Ibexa\Contracts\Core\Persistence\Handler; use Ibexa\Contracts\Core\Repository\Values\Content\Content; +use Ibexa\Core\Persistence\Legacy\Bookmark\Handler as CoveredHandler; use Ibexa\Tests\Integration\Core\RepositoryTestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Bookmark\Handler - */ +#[CoversClass(CoveredHandler::class)] final class BookmarkHandlerTest extends RepositoryTestCase { private Handler $handler; diff --git a/tests/integration/Core/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php b/tests/integration/Core/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php index 01628fdd26..1aa0bf85b9 100644 --- a/tests/integration/Core/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php +++ b/tests/integration/Core/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php @@ -13,12 +13,12 @@ use Ibexa\Contracts\Core\Persistence\Content\VersionInfo; use Ibexa\Contracts\Core\Test\IbexaKernelTestCase; use Ibexa\Core\Persistence\Legacy\Content\Gateway\DoctrineDatabase; +use PHPUnit\Framework\Attributes\CoversClass; /** * @internal - * - * @covers \Ibexa\Core\Persistence\Legacy\Content\Gateway\DoctrineDatabase */ +#[CoversClass(DoctrineDatabase::class)] final class DoctrineDatabaseTest extends IbexaKernelTestCase { private const int CONTENT_ID = 2342; diff --git a/tests/integration/Core/Persistence/Search/Content/IndexerGatewayTest.php b/tests/integration/Core/Persistence/Search/Content/IndexerGatewayTest.php index dedf7438ee..6b91b74429 100644 --- a/tests/integration/Core/Persistence/Search/Content/IndexerGatewayTest.php +++ b/tests/integration/Core/Persistence/Search/Content/IndexerGatewayTest.php @@ -11,12 +11,13 @@ use DateTimeImmutable; use Ibexa\Core\Search\Legacy\Content\IndexerGateway; use Ibexa\Tests\Integration\Core\BaseGatewayTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; /** * @internal - * - * @covers \Ibexa\Core\Search\Legacy\Content\IndexerGateway */ +#[CoversClass(IndexerGateway::class)] final class IndexerGatewayTest extends BaseGatewayTestCase { /** @var \Ibexa\Core\Search\Legacy\Content\IndexerGateway */ @@ -32,7 +33,7 @@ protected function setUp(): void $this->gateway = new IndexerGateway($this->getRawDatabaseConnection()); } - public function getDataForContentSince(): iterable + public static function getDataForContentSince(): iterable { yield '1999-01-01' => [ new DateTimeImmutable('1999-01-01'), @@ -47,7 +48,7 @@ public function getDataForContentSince(): iterable ]; } - public function getDataForContentInSubtree(): iterable + public static function getDataForContentInSubtree(): iterable { yield '/1/5/' => [ '/1/5/', @@ -63,10 +64,9 @@ public function getDataForContentInSubtree(): iterable } /** - * @dataProvider getDataForContentSince - * * @throws \Doctrine\DBAL\Exception */ + #[DataProvider('getDataForContentSince')] public function testGetContentSince( DateTimeImmutable $since, int $expectedCount, @@ -76,10 +76,9 @@ public function testGetContentSince( } /** - * @dataProvider getDataForContentSince - * * @throws \Doctrine\DBAL\Exception */ + #[DataProvider('getDataForContentSince')] public function testCountContentSince( DateTimeImmutable $since, int $expectedCount, @@ -92,10 +91,9 @@ public function testCountContentSince( } /** - * @dataProvider getDataForContentInSubtree - * * @throws \Doctrine\DBAL\Exception */ + #[DataProvider('getDataForContentInSubtree')] public function testGetContentInSubtree( string $subtreePath, int $expectedCount, @@ -108,10 +106,9 @@ public function testGetContentInSubtree( } /** - * @dataProvider getDataForContentInSubtree - * * @throws \Doctrine\DBAL\Exception */ + #[DataProvider('getDataForContentInSubtree')] public function testCountContentInSubtree( string $subtreePath, int $expectedCount, diff --git a/tests/integration/Core/Repository/BaseTestCase.php b/tests/integration/Core/Repository/BaseTestCase.php index 72dd8d9fda..d771fef534 100644 --- a/tests/integration/Core/Repository/BaseTestCase.php +++ b/tests/integration/Core/Repository/BaseTestCase.php @@ -30,11 +30,13 @@ use Ibexa\Contracts\Core\Test\Repository\SetupFactory\Legacy as LegacySetupFactory; use Ibexa\Tests\Core\Repository\PHPUnitConstraint; use PDOException; +use PHPUnit\Framework\Attributes\UsesMethod; use PHPUnit\Framework\TestCase; /** * Base class for api specific tests. */ +#[UsesMethod(self::class, 'createCustomUserVersion1')] abstract class BaseTestCase extends TestCase { /** @@ -134,54 +136,83 @@ protected function getConfigValue($configKey) protected function getRepository(bool $initialInitializeFromScratch = true): Repository { if (null === $this->repository) { - try { - $this->repository = $this->getSetupFactory()->getRepository( - $initialInitializeFromScratch - ); - } catch (ErrorException $e) { - self::fail( - sprintf( - '%s: %s in %s:%d', - __FUNCTION__, - $e->getMessage(), - $e->getFile(), - $e->getLine() - ) - ); - } + $this->repository = self::resolveRepository($initialInitializeFromScratch); } return $this->repository; } + /** + * Resolves a fresh Repository from the environment, without instance-level caching. + * + * Extracted from {@see self::getRepository()} so that static data providers (required by + * PHPUnit 11) that need repository access to build their expected values (e.g. resolving + * identifiers to real domain objects) can do so without an instance. This mirrors what + * happened under PHPUnit 9 as well: a non-static provider ran on a throw-away instance whose + * own `$repository` cache started out empty, so it always built a fresh Repository too. + * + * @param bool $initialInitializeFromScratch Only has an effect if set in first call within a test + */ + protected static function resolveRepository(bool $initialInitializeFromScratch = true): Repository + { + try { + return self::resolveSetupFactory()->getRepository($initialInitializeFromScratch); + } catch (ErrorException $e) { + self::fail( + sprintf( + '%s: %s in %s:%d', + __FUNCTION__, + $e->getMessage(), + $e->getFile(), + $e->getLine() + ) + ); + } + } + /** * @throws \ErrorException */ protected function getSetupFactory(): SetupFactory { if (null === $this->setupFactory) { - if (false === ($setupClass = getenv('setupFactory'))) { - $setupClass = LegacySetupFactory::class; - putenv("setupFactory=$setupClass"); - } + $this->setupFactory = self::resolveSetupFactory(); + } - if (false === getenv('fixtureDir')) { - putenv('fixtureDir=Legacy'); - } + return $this->setupFactory; + } - if (false === class_exists($setupClass)) { - throw new ErrorException( - sprintf( - 'Environment variable "setupFactory" does not reference an existing class: %s. Did you forget to install a package dependency?', - $setupClass - ) - ); - } + /** + * Resolves the configured SetupFactory from the environment, without instance-level caching. + * + * Extracted from {@see self::getSetupFactory()} so that static data providers (required by + * PHPUnit 11) can determine the active search engine / setup factory without needing an + * instance. The underlying resolution is process-global (env vars), so no per-instance state + * is lost by calling this statically. + * + * @throws \ErrorException + */ + protected static function resolveSetupFactory(): SetupFactory + { + if (false === ($setupClass = getenv('setupFactory'))) { + $setupClass = LegacySetupFactory::class; + putenv("setupFactory=$setupClass"); + } - $this->setupFactory = new $setupClass(); + if (false === getenv('fixtureDir')) { + putenv('fixtureDir=Legacy'); } - return $this->setupFactory; + if (false === class_exists($setupClass)) { + throw new ErrorException( + sprintf( + 'Environment variable "setupFactory" does not reference an existing class: %s. Did you forget to install a package dependency?', + $setupClass + ) + ); + } + + return new $setupClass(); } /** @@ -343,7 +374,6 @@ protected function createUserVersion1( /** * Create a user in new user group with editor rights limited to Media Library (/1/48/). * - * @uses ::createCustomUserVersion1() * * @return \Ibexa\Contracts\Core\Repository\Values\User\User */ @@ -527,9 +557,9 @@ protected function refreshSearch(Repository $repository) $searchHandler->commit(); } - protected function isLegacySearchEngineSetup(): bool + protected static function isLegacySearchEngineSetup(): bool { - return get_class($this->getSetupFactory()) === LegacySetupFactory::class; + return get_class(self::resolveSetupFactory()) === LegacySetupFactory::class; } /** diff --git a/tests/integration/Core/Repository/BookmarkServiceTest.php b/tests/integration/Core/Repository/BookmarkServiceTest.php index 694ea6709d..450720074e 100644 --- a/tests/integration/Core/Repository/BookmarkServiceTest.php +++ b/tests/integration/Core/Repository/BookmarkServiceTest.php @@ -17,18 +17,20 @@ use Ibexa\Contracts\Core\Repository\Values\Filter\Filter; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\SectionLimitation; use Ibexa\Core\Persistence\Legacy\Bookmark\Gateway\DoctrineDatabase; +use Ibexa\Core\Repository\BookmarkService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Depends; /** * Test case for the BookmarkService. - * - * @covers \Ibexa\Contracts\Core\Repository\BookmarkService */ +#[CoversClass(BookmarkService::class)] class BookmarkServiceTest extends BaseTestCase { public const LOCATION_ID_BOOKMARKED = 5; public const LOCATION_ID_NOT_BOOKMARKED = 44; - public function testIsBookmarked() + public function testIsBookmarked(): void { $repository = $this->getRepository(); @@ -40,7 +42,7 @@ public function testIsBookmarked() self::assertTrue($isBookmarked); } - public function testIsNotBookmarked() + public function testIsNotBookmarked(): void { $repository = $this->getRepository(); @@ -52,7 +54,7 @@ public function testIsNotBookmarked() self::assertFalse($isBookmarked); } - public function testCreateBookmark() + public function testCreateBookmark(): void { $repository = $this->getRepository(); @@ -70,10 +72,8 @@ public function testCreateBookmark() self::assertTrue($afterCreateBookmark); } - /** - * @depends testCreateBookmark - */ - public function testCreateBookmarkThrowsInvalidArgumentException() + #[Depends('testCreateBookmark')] + public function testCreateBookmarkThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -88,7 +88,7 @@ public function testCreateBookmarkThrowsInvalidArgumentException() /* END: Use Case */ } - public function testDeleteBookmark() + public function testDeleteBookmark(): void { $repository = $this->getRepository(); @@ -107,10 +107,8 @@ public function testDeleteBookmark() self::assertFalse($afterDeleteBookmark); } - /** - * @depends testDeleteBookmark - */ - public function testDeleteBookmarkThrowsInvalidArgumentException() + #[Depends('testDeleteBookmark')] + public function testDeleteBookmarkThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -125,7 +123,7 @@ public function testDeleteBookmarkThrowsInvalidArgumentException() /* END: Use Case */ } - public function testLoadBookmarks() + public function testLoadBookmarks(): void { $repository = $this->getRepository(); diff --git a/tests/integration/Core/Repository/ContentService/CopyNonTranslatableFieldsFromPublishedVersionTest.php b/tests/integration/Core/Repository/ContentService/CopyNonTranslatableFieldsFromPublishedVersionTest.php index 656bfb6fd7..28f52b0c0c 100644 --- a/tests/integration/Core/Repository/ContentService/CopyNonTranslatableFieldsFromPublishedVersionTest.php +++ b/tests/integration/Core/Repository/ContentService/CopyNonTranslatableFieldsFromPublishedVersionTest.php @@ -11,12 +11,12 @@ use DateTime; use Ibexa\Contracts\Core\Repository\Values\Content\Content; use Ibexa\Contracts\Core\Repository\Values\ContentType\FieldDefinitionCreateStruct; +use Ibexa\Core\Repository\ContentService; use Ibexa\Core\Repository\Values\Content\ContentUpdateStruct; use Ibexa\Tests\Integration\Core\RepositoryTestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Contracts\Core\Repository\ContentService - */ +#[CoversClass(ContentService::class)] final class CopyNonTranslatableFieldsFromPublishedVersionTest extends RepositoryTestCase { private const GER_DE = 'ger-DE'; diff --git a/tests/integration/Core/Repository/ContentService/CopyTranslationsFromPublishedVersionTest.php b/tests/integration/Core/Repository/ContentService/CopyTranslationsFromPublishedVersionTest.php index 680f43abf4..82d5dbb6f5 100644 --- a/tests/integration/Core/Repository/ContentService/CopyTranslationsFromPublishedVersionTest.php +++ b/tests/integration/Core/Repository/ContentService/CopyTranslationsFromPublishedVersionTest.php @@ -12,12 +12,12 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Field; use Ibexa\Contracts\Core\Repository\Values\ContentType\FieldDefinitionCreateStruct; use Ibexa\Core\FieldType\TextLine; +use Ibexa\Core\Repository\ContentService; use Ibexa\Core\Repository\Values\Content\ContentUpdateStruct; use Ibexa\Tests\Integration\Core\RepositoryTestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Contracts\Core\Repository\ContentService - */ +#[CoversClass(ContentService::class)] final class CopyTranslationsFromPublishedVersionTest extends RepositoryTestCase { private const ENG_LANGUAGE_CODE = 'eng-GB'; diff --git a/tests/integration/Core/Repository/ContentService/CreateContentInNonContainerTest.php b/tests/integration/Core/Repository/ContentService/CreateContentInNonContainerTest.php index 3d1c92a41b..18190cfa30 100644 --- a/tests/integration/Core/Repository/ContentService/CreateContentInNonContainerTest.php +++ b/tests/integration/Core/Repository/ContentService/CreateContentInNonContainerTest.php @@ -9,11 +9,11 @@ namespace Ibexa\Tests\Integration\Core\Repository\ContentService; use Ibexa\Contracts\Core\Validation\ValidationFailedException; +use Ibexa\Core\Repository\ContentService; use Ibexa\Tests\Integration\Core\RepositoryTestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Contracts\Core\Repository\ContentService - */ +#[CoversClass(ContentService::class)] final class CreateContentInNonContainerTest extends RepositoryTestCase { public function testCreateContentInNonContainerTest(): void diff --git a/tests/integration/Core/Repository/ContentService/DeleteContentTest.php b/tests/integration/Core/Repository/ContentService/DeleteContentTest.php index 7ee3e023d3..93a2b9b58e 100644 --- a/tests/integration/Core/Repository/ContentService/DeleteContentTest.php +++ b/tests/integration/Core/Repository/ContentService/DeleteContentTest.php @@ -10,12 +10,12 @@ use Ibexa\Contracts\Core\Repository\TrashService; use Ibexa\Contracts\Core\Repository\Values\Content\Content; +use Ibexa\Core\Repository\ContentService; use Ibexa\Tests\Integration\Core\RepositoryTestCase; use PHPUnit\Framework\Assert; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Contracts\Core\Repository\ContentService - */ +#[CoversClass(ContentService::class)] final class DeleteContentTest extends RepositoryTestCase { /** diff --git a/tests/integration/Core/Repository/ContentService/LoadVersionInfoTest.php b/tests/integration/Core/Repository/ContentService/LoadVersionInfoTest.php index 97fc6e5316..642cf57124 100644 --- a/tests/integration/Core/Repository/ContentService/LoadVersionInfoTest.php +++ b/tests/integration/Core/Repository/ContentService/LoadVersionInfoTest.php @@ -8,11 +8,11 @@ namespace Ibexa\Tests\Integration\Core\Repository\ContentService; +use Ibexa\Core\Repository\ContentService; use Ibexa\Tests\Integration\Core\RepositoryTestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Contracts\Core\Repository\ContentService - */ +#[CoversClass(ContentService::class)] final class LoadVersionInfoTest extends RepositoryTestCase { /** diff --git a/tests/integration/Core/Repository/ContentService/MaxLanguagesContentServiceTest.php b/tests/integration/Core/Repository/ContentService/MaxLanguagesContentServiceTest.php index 0c474d28a8..e20d2d51c0 100644 --- a/tests/integration/Core/Repository/ContentService/MaxLanguagesContentServiceTest.php +++ b/tests/integration/Core/Repository/ContentService/MaxLanguagesContentServiceTest.php @@ -8,12 +8,12 @@ namespace Ibexa\Tests\Integration\Core\Repository\ContentService; +use Ibexa\Core\Repository\ContentService; use Ibexa\Tests\Integration\Core\RepositoryTestCase; +use PHPUnit\Framework\Attributes\CoversClass; use Symfony\Component\Yaml\Yaml; -/** - * @covers \Ibexa\Contracts\Core\Repository\ContentService - */ +#[CoversClass(ContentService::class)] final class MaxLanguagesContentServiceTest extends RepositoryTestCase { /** @var list */ diff --git a/tests/integration/Core/Repository/ContentService/UpdateContentTest.php b/tests/integration/Core/Repository/ContentService/UpdateContentTest.php index a1f74ceed7..d5645f0a6f 100644 --- a/tests/integration/Core/Repository/ContentService/UpdateContentTest.php +++ b/tests/integration/Core/Repository/ContentService/UpdateContentTest.php @@ -13,11 +13,11 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Section; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\SectionLimitation; use Ibexa\Contracts\Core\Repository\Values\User\User; +use Ibexa\Core\Repository\ContentService; use Ibexa\Tests\Integration\Core\RepositoryTestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Contracts\Core\Repository\ContentService - */ +#[CoversClass(ContentService::class)] final class UpdateContentTest extends RepositoryTestCase { /** diff --git a/tests/integration/Core/Repository/ContentService/VersionValidatorTest.php b/tests/integration/Core/Repository/ContentService/VersionValidatorTest.php index 1e69e70ea6..c100ed603e 100644 --- a/tests/integration/Core/Repository/ContentService/VersionValidatorTest.php +++ b/tests/integration/Core/Repository/ContentService/VersionValidatorTest.php @@ -41,7 +41,7 @@ protected function setUp(): void parent::setUp(); $this->validator = new VersionValidator( - $this->createMock(FieldTypeRegistry::class) + self::createStub(FieldTypeRegistry::class) ); $repository = $this->getRepository(); diff --git a/tests/integration/Core/Repository/ContentServiceAuthorizationTest.php b/tests/integration/Core/Repository/ContentServiceAuthorizationTest.php index 35f0522783..c50dfb5249 100644 --- a/tests/integration/Core/Repository/ContentServiceAuthorizationTest.php +++ b/tests/integration/Core/Repository/ContentServiceAuthorizationTest.php @@ -15,17 +15,20 @@ use Ibexa\Contracts\Core\Repository\Values\User\Limitation\LanguageLimitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\LocationLimitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\SubtreeLimitation; +use Ibexa\Core\Repository\ContentService; +use Ibexa\Core\Repository\Repository as CoveredRepository; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\DependsExternal; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the ContentServiceAuthorization using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService - * - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testLoadUser - * - * @group integration - * @group authorization */ +#[CoversClass(ContentService::class)] +#[CoversClass(CoveredRepository::class)] +#[Group('integration')] +#[Group('authorization')] class ContentServiceAuthorizationTest extends BaseContentServiceTestCase { /** @var \Ibexa\Contracts\Core\Repository\Values\User\User */ @@ -64,12 +67,9 @@ public function setUp(): void /** * Test for the createContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testCreateContent */ - public function testCreateContentThrowsUnauthorizedException() + #[DependsExternal(ContentServiceTest::class, 'testCreateContent')] + public function testCreateContentThrowsUnauthorizedException(): void { $this->permissionResolver->setCurrentUserReference($this->anonymousUser); @@ -91,12 +91,9 @@ public function testCreateContentThrowsUnauthorizedException() /** * Test for the createContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent($contentCreateStruct, $locationCreateStructs) - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testCreateContent */ - public function testCreateContentThrowsUnauthorizedExceptionWithSecondParameter() + #[DependsExternal(ContentServiceTest::class, 'testCreateContent')] + public function testCreateContentThrowsUnauthorizedExceptionWithSecondParameter(): void { $this->permissionResolver->setCurrentUserReference($this->anonymousUser); @@ -108,12 +105,9 @@ public function testCreateContentThrowsUnauthorizedExceptionWithSecondParameter( /** * Test for the loadContentInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentInfo() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContentInfo */ - public function testLoadContentInfoThrowsUnauthorizedException() + #[DependsExternal(ContentServiceTest::class, 'testLoadContentInfo')] + public function testLoadContentInfoThrowsUnauthorizedException(): void { $contentId = $this->generateId('object', 10); $this->setRestrictedEditorUser(); @@ -127,12 +121,9 @@ public function testLoadContentInfoThrowsUnauthorizedException() /** * Test for the sudo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\Repository::sudo() - * - * @depends testLoadContentInfoThrowsUnauthorizedException */ - public function testSudo() + #[Depends('testLoadContentInfoThrowsUnauthorizedException')] + public function testSudo(): void { $repository = $this->getRepository(); $contentId = $this->generateId('object', 10); @@ -150,12 +141,9 @@ public function testSudo() /** * Test for the loadContentInfoList() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentInfoList() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContentInfoList */ - public function testLoadContentInfoListSkipsUnauthorizedItems() + #[DependsExternal(ContentServiceTest::class, 'testLoadContentInfoList')] + public function testLoadContentInfoListSkipsUnauthorizedItems(): void { $contentId = $this->generateId('object', 10); $this->setRestrictedEditorUser(); @@ -165,12 +153,9 @@ public function testLoadContentInfoListSkipsUnauthorizedItems() /** * Test for the loadContentInfoByRemoteId() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentInfoByRemoteId() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContentInfoByRemoteId */ - public function testLoadContentInfoByRemoteIdThrowsUnauthorizedException() + #[DependsExternal(ContentServiceTest::class, 'testLoadContentInfoByRemoteId')] + public function testLoadContentInfoByRemoteIdThrowsUnauthorizedException(): void { $anonymousRemoteId = 'faaeb9be3bd98ed09f606fc16d144eca'; @@ -184,12 +169,9 @@ public function testLoadContentInfoByRemoteIdThrowsUnauthorizedException() /** * Test for the loadVersionInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfo() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadVersionInfo */ - public function testLoadVersionInfoThrowsUnauthorizedException() + #[DependsExternal(ContentServiceTest::class, 'testLoadVersionInfo')] + public function testLoadVersionInfoThrowsUnauthorizedException(): void { $contentInfo = $this->getContentInfoForAnonymousUser(); @@ -203,12 +185,9 @@ public function testLoadVersionInfoThrowsUnauthorizedException() /** * Test for the loadVersionInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfo($contentInfo, $versionNo) - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadVersionInfoWithSecondParameter */ - public function testLoadVersionInfoThrowsUnauthorizedExceptionWithSecondParameter() + #[DependsExternal(ContentServiceTest::class, 'testLoadVersionInfoWithSecondParameter')] + public function testLoadVersionInfoThrowsUnauthorizedExceptionWithSecondParameter(): void { $contentInfo = $this->getContentInfoForAnonymousUser(); @@ -222,12 +201,9 @@ public function testLoadVersionInfoThrowsUnauthorizedExceptionWithSecondParamete /** * Test for the loadVersionInfoById() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfoById() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadVersionInfoById */ - public function testLoadVersionInfoByIdThrowsUnauthorizedException() + #[DependsExternal(ContentServiceTest::class, 'testLoadVersionInfoById')] + public function testLoadVersionInfoByIdThrowsUnauthorizedException(): void { $anonymousUserId = $this->generateId('user', 10); $this->setRestrictedEditorUser(); @@ -240,12 +216,9 @@ public function testLoadVersionInfoByIdThrowsUnauthorizedException() /** * Test for the loadVersionInfoById() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfoById($contentId, $versionNo) - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadVersionInfoByIdWithSecondParameter */ - public function testLoadVersionInfoByIdThrowsUnauthorizedExceptionWithSecondParameter() + #[DependsExternal(ContentServiceTest::class, 'testLoadVersionInfoByIdWithSecondParameter')] + public function testLoadVersionInfoByIdThrowsUnauthorizedExceptionWithSecondParameter(): void { $anonymousUserId = $this->generateId('user', 10); $this->setRestrictedEditorUser(); @@ -258,12 +231,9 @@ public function testLoadVersionInfoByIdThrowsUnauthorizedExceptionWithSecondPara /** * Test for the loadVersionInfoById() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfoById($contentId, $versionNo) - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadVersionInfoById */ - public function testLoadVersionInfoByIdThrowsUnauthorizedExceptionForFirstDraft() + #[DependsExternal(ContentServiceTest::class, 'testLoadVersionInfoById')] + public function testLoadVersionInfoByIdThrowsUnauthorizedExceptionForFirstDraft(): void { $contentDraft = $this->createContentDraftVersion1(); @@ -281,12 +251,9 @@ public function testLoadVersionInfoByIdThrowsUnauthorizedExceptionForFirstDraft( /** * Test for the loadContentByContentInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByContentInfo() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContentByContentInfo */ - public function testLoadContentByContentInfoThrowsUnauthorizedException() + #[DependsExternal(ContentServiceTest::class, 'testLoadContentByContentInfo')] + public function testLoadContentByContentInfoThrowsUnauthorizedException(): void { $contentInfo = $this->getContentInfoForAnonymousUser(); @@ -300,12 +267,9 @@ public function testLoadContentByContentInfoThrowsUnauthorizedException() /** * Test for the loadContentByContentInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByContentInfo($contentInfo, $languages) - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContentByContentInfoWithLanguageParameters */ - public function testLoadContentByContentInfoThrowsUnauthorizedExceptionWithSecondParameter() + #[DependsExternal(ContentServiceTest::class, 'testLoadContentByContentInfoWithLanguageParameters')] + public function testLoadContentByContentInfoThrowsUnauthorizedExceptionWithSecondParameter(): void { $contentInfo = $this->getContentInfoForAnonymousUser(); @@ -319,12 +283,9 @@ public function testLoadContentByContentInfoThrowsUnauthorizedExceptionWithSecon /** * Test for the loadContentByContentInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByContentInfo($contentInfo, $languages, $versionNo) - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContentByContentInfoWithVersionNumberParameter */ - public function testLoadContentByContentInfoThrowsUnauthorizedExceptionWithThirdParameter() + #[DependsExternal(ContentServiceTest::class, 'testLoadContentByContentInfoWithVersionNumberParameter')] + public function testLoadContentByContentInfoThrowsUnauthorizedExceptionWithThirdParameter(): void { $contentInfo = $this->getContentInfoForAnonymousUser(); @@ -338,12 +299,9 @@ public function testLoadContentByContentInfoThrowsUnauthorizedExceptionWithThird /** * Test for the loadContentByVersionInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByVersionInfo() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContentByVersionInfo */ - public function testLoadContentByVersionInfoThrowsUnauthorizedException() + #[DependsExternal(ContentServiceTest::class, 'testLoadContentByVersionInfo')] + public function testLoadContentByVersionInfoThrowsUnauthorizedException(): void { $contentInfo = $this->getContentInfoForAnonymousUser(); @@ -359,12 +317,9 @@ public function testLoadContentByVersionInfoThrowsUnauthorizedException() /** * Test for the loadContentByVersionInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByVersionInfo($versionInfo, $languages) - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContentByVersionInfoWithSecondParameter */ - public function testLoadContentByVersionInfoThrowsUnauthorizedExceptionWithSecondParameter() + #[DependsExternal(ContentServiceTest::class, 'testLoadContentByVersionInfoWithSecondParameter')] + public function testLoadContentByVersionInfoThrowsUnauthorizedExceptionWithSecondParameter(): void { $contentInfo = $this->getContentInfoForAnonymousUser(); @@ -380,12 +335,9 @@ public function testLoadContentByVersionInfoThrowsUnauthorizedExceptionWithSecon /** * Test for the loadContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContent() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContent */ - public function testLoadContentThrowsUnauthorizedException() + #[DependsExternal(ContentServiceTest::class, 'testLoadContent')] + public function testLoadContentThrowsUnauthorizedException(): void { $anonymousUserId = $this->generateId('user', 10); $this->setRestrictedEditorUser(); @@ -398,12 +350,9 @@ public function testLoadContentThrowsUnauthorizedException() /** * Test for the loadContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContent($contentId, $languages) - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContentWithPrioritizedLanguages */ - public function testLoadContentThrowsUnauthorizedExceptionWithSecondParameter() + #[DependsExternal(ContentServiceTest::class, 'testLoadContentWithPrioritizedLanguages')] + public function testLoadContentThrowsUnauthorizedExceptionWithSecondParameter(): void { $anonymousUserId = $this->generateId('user', 10); $this->setRestrictedEditorUser(); @@ -416,12 +365,9 @@ public function testLoadContentThrowsUnauthorizedExceptionWithSecondParameter() /** * Test for the loadContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContent($contentId, $languages, $versionNo) - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContentWithThirdParameter */ - public function testLoadContentThrowsUnauthorizedExceptionWithThirdParameter() + #[DependsExternal(ContentServiceTest::class, 'testLoadContentWithThirdParameter')] + public function testLoadContentThrowsUnauthorizedExceptionWithThirdParameter(): void { $anonymousUserId = $this->generateId('user', 10); $this->setRestrictedEditorUser(); @@ -434,12 +380,9 @@ public function testLoadContentThrowsUnauthorizedExceptionWithThirdParameter() /** * Test for the loadContent() method on a draft. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContent() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContent */ - public function testLoadContentThrowsUnauthorizedExceptionOnDrafts() + #[DependsExternal(ContentServiceTest::class, 'testLoadContent')] + public function testLoadContentThrowsUnauthorizedExceptionOnDrafts(): void { $editorUser = $this->createUserVersion1(); @@ -462,12 +405,9 @@ public function testLoadContentThrowsUnauthorizedExceptionOnDrafts() * Test for the ContentService::loadContent() method on an archive. * * This test the version permission on loading archived versions - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContent() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContent */ - public function testLoadContentThrowsUnauthorizedExceptionsOnArchives() + #[DependsExternal(ContentServiceTest::class, 'testLoadContent')] + public function testLoadContentThrowsUnauthorizedExceptionsOnArchives(): void { $contentTypeService = $this->getRepository()->getContentTypeService(); @@ -507,12 +447,9 @@ public function testLoadContentThrowsUnauthorizedExceptionsOnArchives() /** * Test for the loadContentByRemoteId() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByRemoteId() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContentByRemoteId */ - public function testLoadContentByRemoteIdThrowsUnauthorizedException() + #[DependsExternal(ContentServiceTest::class, 'testLoadContentByRemoteId')] + public function testLoadContentByRemoteIdThrowsUnauthorizedException(): void { $anonymousRemoteId = 'faaeb9be3bd98ed09f606fc16d144eca'; @@ -526,12 +463,9 @@ public function testLoadContentByRemoteIdThrowsUnauthorizedException() /** * Test for the loadContentByRemoteId() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByRemoteId($remoteId, $languages) - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContentByRemoteIdWithSecondParameter */ - public function testLoadContentByRemoteIdThrowsUnauthorizedExceptionWithSecondParameter() + #[DependsExternal(ContentServiceTest::class, 'testLoadContentByRemoteIdWithSecondParameter')] + public function testLoadContentByRemoteIdThrowsUnauthorizedExceptionWithSecondParameter(): void { $anonymousRemoteId = 'faaeb9be3bd98ed09f606fc16d144eca'; @@ -545,12 +479,9 @@ public function testLoadContentByRemoteIdThrowsUnauthorizedExceptionWithSecondPa /** * Test for the loadContentByRemoteId() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByRemoteId($remoteId, $languages, $versionNo) - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContentByRemoteIdWithThirdParameter */ - public function testLoadContentByRemoteIdThrowsUnauthorizedExceptionWithThirdParameter() + #[DependsExternal(ContentServiceTest::class, 'testLoadContentByRemoteIdWithThirdParameter')] + public function testLoadContentByRemoteIdThrowsUnauthorizedExceptionWithThirdParameter(): void { $anonymousRemoteId = 'faaeb9be3bd98ed09f606fc16d144eca'; @@ -564,12 +495,9 @@ public function testLoadContentByRemoteIdThrowsUnauthorizedExceptionWithThirdPar /** * Test for the updateContentMetadata() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContentMetadata() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testUpdateContentMetadata */ - public function testUpdateContentMetadataThrowsUnauthorizedException() + #[DependsExternal(ContentServiceTest::class, 'testUpdateContentMetadata')] + public function testUpdateContentMetadataThrowsUnauthorizedException(): void { $content = $this->createContentVersion1(); @@ -596,12 +524,9 @@ public function testUpdateContentMetadataThrowsUnauthorizedException() /** * Test for the deleteContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteContent() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testDeleteContent */ - public function testDeleteContentThrowsUnauthorizedException() + #[DependsExternal(ContentServiceTest::class, 'testDeleteContent')] + public function testDeleteContentThrowsUnauthorizedException(): void { $contentVersion2 = $this->createContentVersion2(); @@ -615,9 +540,6 @@ public function testDeleteContentThrowsUnauthorizedException() $this->contentService->deleteContent($contentInfo); } - /** - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteContent() - */ public function testDeleteContentThrowsUnauthorizedExceptionWithLanguageLimitation(): void { $contentVersion2 = $this->createMultipleLanguageContentVersion2(); @@ -641,9 +563,6 @@ public function testDeleteContentThrowsUnauthorizedExceptionWithLanguageLimitati $this->contentService->deleteContent($contentInfo); } - /** - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteContent() - */ public function testDeleteContentWithLanguageLimitation(): void { $contentVersion2 = $this->createMultipleLanguageContentVersion2(); @@ -667,12 +586,9 @@ public function testDeleteContentWithLanguageLimitation(): void /** * Test for the createContentDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContentDraft() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testCreateContentDraft */ - public function testCreateContentDraftThrowsUnauthorizedException() + #[DependsExternal(ContentServiceTest::class, 'testCreateContentDraft')] + public function testCreateContentDraftThrowsUnauthorizedException(): void { $content = $this->createContentVersion1(); @@ -688,12 +604,9 @@ public function testCreateContentDraftThrowsUnauthorizedException() /** * Test for the createContentDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContentDraft($contentInfo, $versionInfo) - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testCreateContentDraftWithSecondParameter */ - public function testCreateContentDraftThrowsUnauthorizedExceptionWithSecondParameter() + #[DependsExternal(ContentServiceTest::class, 'testCreateContentDraftWithSecondParameter')] + public function testCreateContentDraftThrowsUnauthorizedExceptionWithSecondParameter(): void { $content = $this->createContentVersion1(); @@ -710,21 +623,15 @@ public function testCreateContentDraftThrowsUnauthorizedExceptionWithSecondParam /** * Test for the countContentDrafts() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::countContentDrafts() */ - public function testCountContentDraftsReturnZero() + public function testCountContentDraftsReturnZero(): void { $this->permissionResolver->setCurrentUserReference($this->anonymousUser); self::assertSame(0, $this->contentService->countContentDrafts()); } - /** - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentDraftList() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContentDraftList - */ + #[DependsExternal(ContentServiceTest::class, 'testLoadContentDraftList')] public function testLoadContentDraftListReturnsEmptyListForUserWithoutVersionReadAccess(): void { $this->permissionResolver->setCurrentUserReference($this->anonymousUser); @@ -735,11 +642,7 @@ public function testLoadContentDraftListReturnsEmptyListForUserWithoutVersionRea self::assertEmpty($draftList->items); } - /** - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentDraftList($user) - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContentDraftList - */ + #[DependsExternal(ContentServiceTest::class, 'testLoadContentDraftList')] public function testLoadContentDraftListReturnsEmptyListForUserWithoutVersionReadAccessWithUser(): void { $this->permissionResolver->setCurrentUserReference($this->anonymousUser); @@ -752,12 +655,9 @@ public function testLoadContentDraftListReturnsEmptyListForUserWithoutVersionRea /** * Test for the updateContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testUpdateContent */ - public function testUpdateContentThrowsUnauthorizedException() + #[DependsExternal(ContentServiceTest::class, 'testUpdateContent')] + public function testUpdateContentThrowsUnauthorizedException(): void { $draftVersion2 = $this->createContentDraftVersion2(); @@ -781,12 +681,9 @@ public function testUpdateContentThrowsUnauthorizedException() /** * Test for the publishVersion() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::publishVersion() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testPublishVersion */ - public function testPublishVersionThrowsUnauthorizedException() + #[DependsExternal(ContentServiceTest::class, 'testPublishVersion')] + public function testPublishVersionThrowsUnauthorizedException(): void { $draft = $this->createContentDraftVersion1(); @@ -800,12 +697,9 @@ public function testPublishVersionThrowsUnauthorizedException() /** * Test for the deleteVersion() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteVersion() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testDeleteVersion */ - public function testDeleteVersionThrowsUnauthorizedException() + #[DependsExternal(ContentServiceTest::class, 'testDeleteVersion')] + public function testDeleteVersionThrowsUnauthorizedException(): void { $draft = $this->createContentDraftVersion1(); @@ -819,12 +713,9 @@ public function testDeleteVersionThrowsUnauthorizedException() /** * Test for the loadVersions() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersions() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadVersions */ - public function testLoadVersionsThrowsUnauthorizedException() + #[DependsExternal(ContentServiceTest::class, 'testLoadVersions')] + public function testLoadVersionsThrowsUnauthorizedException(): void { $contentVersion2 = $this->createContentVersion2(); @@ -840,12 +731,9 @@ public function testLoadVersionsThrowsUnauthorizedException() /** * Test for the copyContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::copyContent() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testCopyContent */ - public function testCopyContentThrowsUnauthorizedException() + #[DependsExternal(ContentServiceTest::class, 'testCopyContent')] + public function testCopyContentThrowsUnauthorizedException(): void { $parentLocationId = $this->generateId('location', 52); @@ -877,12 +765,9 @@ public function testCopyContentThrowsUnauthorizedException() /** * Test for the copyContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::copyContent($contentInfo, $destinationLocationCreateStruct, $versionInfo) - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testCopyContentWithGivenVersion */ - public function testCopyContentThrowsUnauthorizedExceptionWithGivenVersion() + #[DependsExternal(ContentServiceTest::class, 'testCopyContentWithGivenVersion')] + public function testCopyContentThrowsUnauthorizedExceptionWithGivenVersion(): void { $parentLocationId = $this->generateId('location', 52); @@ -910,10 +795,9 @@ public function testCopyContentThrowsUnauthorizedExceptionWithGivenVersion() } /** - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadRelationList() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadRelationList + * Test for the loadRelations() method. */ + #[DependsExternal(ContentServiceTest::class, 'testLoadRelationList')] public function testLoadRelationsReturnsEmptyListForUserWithoutReadAccess(): void { $mediaEditor = $this->createMediaUserVersion1(); @@ -935,10 +819,9 @@ public function testLoadRelationsReturnsEmptyListForUserWithoutReadAccess(): voi } /** - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadRelationList() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadRelationList + * Test for the loadRelations() method. */ + #[DependsExternal(ContentServiceTest::class, 'testLoadRelationList')] public function testLoadRelationsForDraftVersionReturnsEmptyListForUserWithoutVersionReadAccess(): void { $draft = $this->createContentDraftVersion1(); @@ -953,12 +836,9 @@ public function testLoadRelationsForDraftVersionReturnsEmptyListForUserWithoutVe /** * Test for the loadReverseRelations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadReverseRelations() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadReverseRelations */ - public function testLoadReverseRelationsThrowsUnauthorizedException() + #[DependsExternal(ContentServiceTest::class, 'testLoadReverseRelations')] + public function testLoadReverseRelationsThrowsUnauthorizedException(): void { $mediaEditor = $this->createMediaUserVersion1(); @@ -976,12 +856,9 @@ public function testLoadReverseRelationsThrowsUnauthorizedException() /** * Test for the addRelation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::addRelation() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testAddRelation */ - public function testAddRelationThrowsUnauthorizedException() + #[DependsExternal(ContentServiceTest::class, 'testAddRelation')] + public function testAddRelationThrowsUnauthorizedException(): void { $mediaRemoteId = 'a6e35cbcb7cd6ae4b691f3eee30cd262'; @@ -1004,12 +881,9 @@ public function testAddRelationThrowsUnauthorizedException() /** * Test for the deleteRelation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteRelation() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testDeleteRelation */ - public function testDeleteRelationThrowsUnauthorizedException() + #[DependsExternal(ContentServiceTest::class, 'testDeleteRelation')] + public function testDeleteRelationThrowsUnauthorizedException(): void { $mediaRemoteId = 'a6e35cbcb7cd6ae4b691f3eee30cd262'; $demoDesignRemoteId = '8b8b22fe3c6061ed500fbd2b377b885f'; @@ -1064,12 +938,9 @@ private function createAnonymousWithEditorRole() * Test that for a user that doesn't have access (read permissions) to a * related object, executing loadRelationList() would not throw any exception, and * would instead expose the non-readable related object(s) as unauthorized list items. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadRelationList() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testAddRelation */ - public function testLoadRelationsWithUnauthorizedRelations() + #[DependsExternal(ContentServiceTest::class, 'testAddRelation')] + public function testLoadRelationsWithUnauthorizedRelations(): void { $mainLanguage = 'eng-GB'; @@ -1245,7 +1116,7 @@ public function testLoadRelationsWithUnauthorizedRelations() /** * Test copying Content to the authorized Location (limited by policies). */ - public function testCopyContentToAuthorizedLocation() + public function testCopyContentToAuthorizedLocation(): void { $locationService = $this->repository->getLocationService(); $roleService = $this->repository->getRoleService(); @@ -1289,7 +1160,7 @@ public function testCopyContentToAuthorizedLocation() /** * Test copying Content to the authorized Location (limited by policies). */ - public function testCopyContentToAuthorizedLocationWithSubtreeLimitation() + public function testCopyContentToAuthorizedLocationWithSubtreeLimitation(): void { $locationService = $this->repository->getLocationService(); diff --git a/tests/integration/Core/Repository/ContentServiceTest.php b/tests/integration/Core/Repository/ContentServiceTest.php index 04022d0aaf..f6e75a0b23 100644 --- a/tests/integration/Core/Repository/ContentServiceTest.php +++ b/tests/integration/Core/Repository/ContentServiceTest.php @@ -8,7 +8,6 @@ namespace Ibexa\Tests\Integration\Core\Repository; use Exception; -use Ibexa\Contracts\Core\Repository\ContentService; use Ibexa\Contracts\Core\Repository\Exceptions\BadStateException; use Ibexa\Contracts\Core\Repository\Exceptions\ContentFieldValidationException; use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException as APIInvalidArgumentException; @@ -35,8 +34,14 @@ use Ibexa\Contracts\Core\Repository\Values\User\User; use Ibexa\Core\Base\Exceptions\UnauthorizedException as CoreUnauthorizedException; use Ibexa\Core\FieldType\Relation\Value as RelationValue; +use Ibexa\Core\Repository\ContentService; use Ibexa\Core\Repository\Values\Content\ContentUpdateStruct; use InvalidArgumentException; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\DependsExternal; +use PHPUnit\Framework\Attributes\Group; use ReflectionClass; use ReflectionProperty; use Symfony\Bridge\PhpUnit\ClockMock; @@ -45,9 +50,9 @@ * Test case for operations in the ContentService using in memory storage. * * @see \Ibexa\Contracts\Core\Repository\ContentService - * - * @group content */ +#[CoversClass(ContentService::class)] +#[Group('content')] class ContentServiceTest extends BaseContentServiceTestCase { private const ADMINISTRATORS_USER_GROUP_NAME = 'Administrators'; @@ -90,15 +95,11 @@ public function setUp(): void /** * Test for the newContentCreateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::newContentCreateStruct() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testLoadContentTypeByIdentifier - * - * @group user - * @group field-type */ - public function testNewContentCreateStruct() + #[DependsExternal(ContentTypeServiceTest::class, 'testLoadContentTypeByIdentifier')] + #[Group('user')] + #[Group('field-type')] + public function testNewContentCreateStruct(): void { $contentTypeService = $this->getRepository()->getContentTypeService(); $contentType = $contentTypeService->loadContentTypeByIdentifier(self::FORUM_IDENTIFIER); @@ -112,14 +113,10 @@ public function testNewContentCreateStruct() * Test for the createContent() method. * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() - * - * @depends testNewContentCreateStruct - * - * @group user - * @group field-type */ + #[Depends('testNewContentCreateStruct')] + #[Group('user')] + #[Group('field-type')] public function testCreateContent() { $contentTypeService = $this->getRepository()->getContentTypeService(); @@ -144,12 +141,9 @@ public function testCreateContent() * * Tests made for issue #EZP-20955 where Anonymous user is granted access to create content * and should have access to do that. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent - * - * @group user - * @group field-type */ + #[Group('user')] + #[Group('field-type')] public function testCreateContentAndPublishWithPrivilegedAnonymousUser(): void { $anonymousUserId = $this->generateId('user', 10); @@ -201,11 +195,8 @@ public function testCreateContentAndPublishWithPrivilegedAnonymousUser(): void * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() - * - * @depends testCreateContent */ + #[Depends('testCreateContent')] public function testCreateContentSetsContentInfo($content) { self::assertInstanceOf(ContentInfo::class, $content->contentInfo); @@ -217,12 +208,9 @@ public function testCreateContentSetsContentInfo($content) * Test for the createContent() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() - * - * @depends testCreateContentSetsContentInfo */ - public function testCreateContentSetsExpectedContentInfo($content) + #[Depends('testCreateContentSetsContentInfo')] + public function testCreateContentSetsExpectedContentInfo($content): void { $permissionResolver = $this->getRepository()->getPermissionResolver(); @@ -261,11 +249,8 @@ public function testCreateContentSetsExpectedContentInfo($content) * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() - * - * @depends testCreateContent */ + #[Depends('testCreateContent')] public function testCreateContentSetsVersionInfo($content) { self::assertInstanceOf(VersionInfo::class, $content->getVersionInfo()); @@ -277,12 +262,9 @@ public function testCreateContentSetsVersionInfo($content) * Test for the createContent() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() - * - * @depends testCreateContentSetsVersionInfo */ - public function testCreateContentSetsExpectedVersionInfo($content) + #[Depends('testCreateContentSetsVersionInfo')] + public function testCreateContentSetsExpectedVersionInfo($content): void { $currentUserReference = $this->getRepository()->getPermissionResolver()->getCurrentUserReference(); @@ -309,12 +291,9 @@ public function testCreateContentSetsExpectedVersionInfo($content) * Test for the createContent() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() - * - * @depends testCreateContent */ - public function testCreateContentSetsExpectedContentType($content) + #[Depends('testCreateContent')] + public function testCreateContentSetsExpectedContentType($content): void { $contentType = $content->getContentType(); @@ -337,8 +316,6 @@ public function testCreateContentSetsExpectedContentType($content) /** * Test for the createContent() method with utilizing ContentType default options. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent */ public function testCreateContentWithContentTypeDefaultOptions(): void { @@ -363,12 +340,9 @@ public function testCreateContentWithContentTypeDefaultOptions(): void /** * Test for the createContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() - * - * @depends testCreateContent */ - public function testCreateContentThrowsInvalidArgumentException() + #[Depends('testCreateContent')] + public function testCreateContentThrowsInvalidArgumentException(): void { $contentTypeService = $this->getRepository()->getContentTypeService(); @@ -395,12 +369,9 @@ public function testCreateContentThrowsInvalidArgumentException() /** * Test for the createContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() - * - * @depends testCreateContent */ - public function testCreateContentThrowsInvalidArgumentExceptionOnFieldTypeNotAccept() + #[Depends('testCreateContent')] + public function testCreateContentThrowsInvalidArgumentExceptionOnFieldTypeNotAccept(): void { $contentTypeService = $this->getRepository()->getContentTypeService(); @@ -416,12 +387,9 @@ public function testCreateContentThrowsInvalidArgumentExceptionOnFieldTypeNotAcc /** * Test for the createContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() - * - * @depends testCreateContent */ - public function testCreateContentThrowsContentFieldValidationException() + #[Depends('testCreateContent')] + public function testCreateContentThrowsContentFieldValidationException(): void { $contentTypeService = $this->getRepository()->getContentTypeService(); @@ -440,12 +408,9 @@ public function testCreateContentThrowsContentFieldValidationException() /** * Test for the createContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() - * - * @depends testCreateContent */ - public function testCreateContentRequiredFieldMissing() + #[Depends('testCreateContent')] + public function testCreateContentRequiredFieldMissing(): void { $contentTypeService = $this->getRepository()->getContentTypeService(); $contentType = $contentTypeService->loadContentTypeByIdentifier(self::FORUM_IDENTIFIER); @@ -465,14 +430,10 @@ public function testCreateContentRequiredFieldMissing() * NOTE: We have bidirectional dependencies between the ContentService and * the LocationService, so that we cannot use PHPUnit's test dependencies * here. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent - * - * @depends testCreateContent - * - * @group user */ - public function testCreateContentWithLocationCreateParameterDoesNotCreateLocationImmediately() + #[Depends('testCreateContent')] + #[Group('user')] + public function testCreateContentWithLocationCreateParameterDoesNotCreateLocationImmediately(): void { $this->createContentDraftVersion1(); @@ -484,12 +445,9 @@ public function testCreateContentWithLocationCreateParameterDoesNotCreateLocatio /** * Test for the createContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent($contentCreateStruct, $locationCreateStructs) - * - * @depends testCreateContentWithLocationCreateParameterDoesNotCreateLocationImmediately */ - public function testCreateContentThrowsInvalidArgumentExceptionWithLocationCreateParameter() + #[Depends('testCreateContentWithLocationCreateParameterDoesNotCreateLocationImmediately')] + public function testCreateContentThrowsInvalidArgumentExceptionWithLocationCreateParameter(): void { $parentLocationId = $this->generateId('location', 56); // $parentLocationId is a valid location ID @@ -539,11 +497,8 @@ public function testCreateContentThrowsInvalidArgumentExceptionWithLocationCreat /** * Test for the loadContentInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentInfo() - * - * @group user */ + #[Group('user')] public function testLoadContentInfo() { $mediaFolderId = $this->generateId('object', self::MEDIA_CONTENT_ID); @@ -559,13 +514,12 @@ public function testLoadContentInfo() /** * Test for the returned value of the loadContentInfo() method. * - * @depends testLoadContentInfo * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentInfo * * @param \Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo $contentInfo */ - public function testLoadContentInfoSetsExpectedContentInfo(ContentInfo $contentInfo) + #[Depends('testLoadContentInfo')] + public function testLoadContentInfoSetsExpectedContentInfo(ContentInfo $contentInfo): void { $this->assertPropertiesCorrectUnsorted( $this->getExpectedMediaContentInfoProperties(), @@ -574,12 +528,9 @@ public function testLoadContentInfoSetsExpectedContentInfo(ContentInfo $contentI } /** - * @depends testLoadContentInfo - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentInfo - * * @param \Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo $contentInfo */ + #[Depends('testLoadContentInfo')] public function testLoadContentInfoGetContentType(ContentInfo $contentInfo): void { $contentType = $contentInfo->getContentType(); @@ -589,12 +540,9 @@ public function testLoadContentInfoGetContentType(ContentInfo $contentInfo): voi } /** - * @depends testLoadContentInfo - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentInfo - * * @param \Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo $contentInfo */ + #[Depends('testLoadContentInfo')] public function testLoadContentInfoGetSection(ContentInfo $contentInfo): void { $section = $contentInfo->getSection(); @@ -604,12 +552,9 @@ public function testLoadContentInfoGetSection(ContentInfo $contentInfo): void } /** - * @depends testLoadContentInfo - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentInfo - * * @param \Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo $contentInfo */ + #[Depends('testLoadContentInfo')] public function testLoadContentInfoGetMainLanguage(ContentInfo $contentInfo): void { $language = $contentInfo->getMainLanguage(); @@ -619,12 +564,9 @@ public function testLoadContentInfoGetMainLanguage(ContentInfo $contentInfo): vo } /** - * @depends testLoadContentInfo - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentInfo - * * @param \Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo $contentInfo */ + #[Depends('testLoadContentInfo')] public function testLoadContentInfoGetMainLocation(ContentInfo $contentInfo): void { $mainLocation = $contentInfo->getMainLocation(); @@ -634,12 +576,9 @@ public function testLoadContentInfoGetMainLocation(ContentInfo $contentInfo): vo } /** - * @depends testLoadContentInfo - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentInfo - * * @param \Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo $contentInfo */ + #[Depends('testLoadContentInfo')] public function testLoadContentInfoSetsExpectedOwnerProxy(ContentInfo $contentInfo): void { $owner = $contentInfo->getOwner(); @@ -650,12 +589,9 @@ public function testLoadContentInfoSetsExpectedOwnerProxy(ContentInfo $contentIn /** * Test for the loadContentInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentInfo() - * - * @depends testLoadContentInfo */ - public function testLoadContentInfoThrowsNotFoundException() + #[Depends('testLoadContentInfo')] + public function testLoadContentInfoThrowsNotFoundException(): void { $nonExistentContentId = $this->generateId('object', self::DB_INT_MAX); @@ -666,10 +602,8 @@ public function testLoadContentInfoThrowsNotFoundException() /** * Test for the loadContentInfoList() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentInfoList() */ - public function testLoadContentInfoList() + public function testLoadContentInfoList(): void { $mediaFolderId = $this->generateId('object', self::MEDIA_CONTENT_ID); $list = iterator_to_array($this->contentService->loadContentInfoList([$mediaFolderId])); @@ -684,12 +618,9 @@ public function testLoadContentInfoList() /** * Test for the loadContentInfoList() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentInfoList() - * - * @depends testLoadContentInfoList */ - public function testLoadContentInfoListSkipsNotFoundItems() + #[Depends('testLoadContentInfoList')] + public function testLoadContentInfoListSkipsNotFoundItems(): void { $nonExistentContentId = $this->generateId('object', self::DB_INT_MAX); $list = $this->contentService->loadContentInfoList([$nonExistentContentId]); @@ -699,8 +630,6 @@ public function testLoadContentInfoListSkipsNotFoundItems() /** * Test for the loadContentInfoByRemoteId() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentInfoByRemoteId() */ public function testLoadContentInfoByRemoteId() { @@ -715,13 +644,12 @@ public function testLoadContentInfoByRemoteId() /** * Test for the returned value of the loadContentInfoByRemoteId() method. * - * @depends testLoadContentInfoByRemoteId * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentInfoByRemoteId * * @param \Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo $contentInfo */ - public function testLoadContentInfoByRemoteIdSetsExpectedContentInfo(ContentInfo $contentInfo) + #[Depends('testLoadContentInfoByRemoteId')] + public function testLoadContentInfoByRemoteIdSetsExpectedContentInfo(ContentInfo $contentInfo): void { $this->assertPropertiesCorrectUnsorted( [ @@ -745,12 +673,9 @@ public function testLoadContentInfoByRemoteIdSetsExpectedContentInfo(ContentInfo /** * Test for the loadContentInfoByRemoteId() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentInfoByRemoteId() - * - * @depends testLoadContentInfoByRemoteId */ - public function testLoadContentInfoByRemoteIdThrowsNotFoundException() + #[Depends('testLoadContentInfoByRemoteId')] + public function testLoadContentInfoByRemoteIdThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -759,14 +684,10 @@ public function testLoadContentInfoByRemoteIdThrowsNotFoundException() /** * Test for the loadVersionInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfo() - * - * @depends testLoadContentInfo - * - * @group user */ - public function testLoadVersionInfo() + #[Depends('testLoadContentInfo')] + #[Group('user')] + public function testLoadVersionInfo(): void { $mediaFolderId = $this->generateId('object', self::MEDIA_CONTENT_ID); // $mediaFolderId contains the ID of the "Media" folder @@ -785,8 +706,6 @@ public function testLoadVersionInfo() /** * Test for the loadVersionInfoById() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfoById() */ public function testLoadVersionInfoById() { @@ -807,13 +726,12 @@ public function testLoadVersionInfoById() /** * Test for the returned value of the loadVersionInfoById() method. * - * @depends testLoadVersionInfoById * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfoById * * @param \Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo $versionInfo */ - public function testLoadVersionInfoByIdSetsExpectedVersionInfo(VersionInfo $versionInfo) + #[Depends('testLoadVersionInfoById')] + public function testLoadVersionInfoByIdSetsExpectedVersionInfo(VersionInfo $versionInfo): void { $this->assertPropertiesCorrect( [ @@ -840,10 +758,9 @@ public function testLoadVersionInfoByIdSetsExpectedVersionInfo(VersionInfo $vers } /** - * @depends testLoadVersionInfoById - * * @param \Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo $versionInfo */ + #[Depends('testLoadVersionInfoById')] public function testLoadVersionInfoByIdGetCreator(VersionInfo $versionInfo): void { $creator = $versionInfo->getCreator(); @@ -853,12 +770,9 @@ public function testLoadVersionInfoByIdGetCreator(VersionInfo $versionInfo): voi } /** - * @depends testLoadVersionInfoById - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfoById - * * @param \Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo $versionInfo */ + #[Depends('testLoadVersionInfoById')] public function testLoadVersionInfoByIdGetInitialLanguage(VersionInfo $versionInfo): void { $initialLanguage = $versionInfo->getInitialLanguage(); @@ -868,10 +782,9 @@ public function testLoadVersionInfoByIdGetInitialLanguage(VersionInfo $versionIn } /** - * @depends testLoadVersionInfoById - * * @param \Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo $versionInfo */ + #[Depends('testLoadVersionInfoById')] public function testLoadVersionInfoByIdGetLanguages(VersionInfo $versionInfo): void { $actualLanguages = iterator_to_array($versionInfo->getLanguages()); @@ -884,12 +797,9 @@ public function testLoadVersionInfoByIdGetLanguages(VersionInfo $versionInfo): v /** * Test for the loadVersionInfoById() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfoById() - * - * @depends testLoadVersionInfoById */ - public function testLoadVersionInfoByIdThrowsNotFoundException() + #[Depends('testLoadVersionInfoById')] + public function testLoadVersionInfoByIdThrowsNotFoundException(): void { $nonExistentContentId = $this->generateId('object', self::DB_INT_MAX); @@ -900,12 +810,9 @@ public function testLoadVersionInfoByIdThrowsNotFoundException() /** * Test for the loadContentByContentInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByContentInfo() - * - * @depends testLoadContentInfo */ - public function testLoadContentByContentInfo() + #[Depends('testLoadContentInfo')] + public function testLoadContentByContentInfo(): void { $mediaFolderId = $this->generateId('object', self::MEDIA_CONTENT_ID); // $mediaFolderId contains the ID of the "Media" folder @@ -924,12 +831,9 @@ public function testLoadContentByContentInfo() /** * Test for the loadContentByVersionInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByVersionInfo() - * - * @depends testLoadVersionInfo */ - public function testLoadContentByVersionInfo() + #[Depends('testLoadVersionInfo')] + public function testLoadContentByVersionInfo(): void { $mediaFolderId = $this->generateId('object', self::MEDIA_CONTENT_ID); // $mediaFolderId contains the ID of the "Media" folder @@ -951,13 +855,10 @@ public function testLoadContentByVersionInfo() /** * Test for the loadContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContent() - * - * @group user - * @group field-type */ - public function testLoadContent() + #[Group('user')] + #[Group('field-type')] + public function testLoadContent(): void { $mediaFolderId = $this->generateId('object', self::MEDIA_CONTENT_ID); // $mediaFolderId contains the ID of the "Media" folder @@ -973,12 +874,9 @@ public function testLoadContent() /** * Test for the loadContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContent() - * - * @depends testLoadContent */ - public function testLoadContentThrowsNotFoundException() + #[Depends('testLoadContent')] + public function testLoadContentThrowsNotFoundException(): void { $nonExistentContentId = $this->generateId('object', self::DB_INT_MAX); @@ -992,7 +890,7 @@ public function testLoadContentThrowsNotFoundException() * * @return array */ - public function contentRemoteIdVersionLanguageProvider() + public static function contentRemoteIdVersionLanguageProvider(): array { return [ ['f5c88a2209584891056f987fd965b0ba', null, null], @@ -1009,15 +907,14 @@ public function contentRemoteIdVersionLanguageProvider() /** * Test for the loadContentByRemoteId() method. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByRemoteId * - * @dataProvider contentRemoteIdVersionLanguageProvider * * @param string $remoteId * @param array|null $languages * @param int $versionNo */ - public function testLoadContentByRemoteId($remoteId, $languages, $versionNo) + #[DataProvider('contentRemoteIdVersionLanguageProvider')] + public function testLoadContentByRemoteId($remoteId, $languages, $versionNo): void { $content = $this->contentService->loadContentByRemoteId($remoteId, $languages, $versionNo); @@ -1035,12 +932,9 @@ public function testLoadContentByRemoteId($remoteId, $languages, $versionNo) /** * Test for the loadContentByRemoteId() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByRemoteId() - * - * @depends testLoadContentByRemoteId */ - public function testLoadContentByRemoteIdThrowsNotFoundException() + #[Depends('testLoadContentByRemoteId')] + public function testLoadContentByRemoteIdThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -1052,17 +946,13 @@ public function testLoadContentByRemoteIdThrowsNotFoundException() * Test for the publishVersion() method. * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::publishVersion() - * - * @depends testLoadContent - * @depends testLoadContentInfo - * @depends testLoadVersionInfo - * @depends testCreateContentWithLocationCreateParameterDoesNotCreateLocationImmediately - * - * @group user - * @group field-type */ + #[Depends('testLoadContent')] + #[Depends('testLoadContentInfo')] + #[Depends('testLoadVersionInfo')] + #[Depends('testCreateContentWithLocationCreateParameterDoesNotCreateLocationImmediately')] + #[Group('user')] + #[Group('field-type')] public function testPublishVersion() { ClockMock::withClockMock(false); @@ -1085,12 +975,9 @@ public function testPublishVersion() * Test for the publishVersion() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::publishVersion() - * - * @depends testPublishVersion */ - public function testPublishVersionSetsExpectedContentInfo($content) + #[Depends('testPublishVersion')] + public function testPublishVersionSetsExpectedContentInfo($content): void { $userReference = $this->getRepository()->getPermissionResolver()->getCurrentUserReference(); @@ -1127,12 +1014,9 @@ public function testPublishVersionSetsExpectedContentInfo($content) * Test for the publishVersion() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::publishVersion() - * - * @depends testPublishVersion */ - public function testPublishVersionSetsExpectedVersionInfo($content) + #[Depends('testPublishVersion')] + public function testPublishVersionSetsExpectedVersionInfo($content): void { $currentUserReference = $this->getRepository()->getPermissionResolver()->getCurrentUserReference(); @@ -1167,12 +1051,9 @@ public function testPublishVersionSetsExpectedVersionInfo($content) * Test for the publishVersion() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::publishVersion() - * - * @depends testPublishVersion */ - public function testPublishVersionSetsExpectedContentType($content) + #[Depends('testPublishVersion')] + public function testPublishVersionSetsExpectedContentType($content): void { $contentType = $content->getContentType(); @@ -1195,8 +1076,6 @@ public function testPublishVersionSetsExpectedContentType($content) /** * Test for the publishVersion() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::publishVersion */ public function testPublishVersionCreatesLocationsDefinedOnCreate(): array { @@ -1216,12 +1095,9 @@ public function testPublishVersionCreatesLocationsDefinedOnCreate(): array /** * Test for the publishVersion() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::publishVersion() - * - * @depends testPublishVersionCreatesLocationsDefinedOnCreate */ - public function testCreateContentWithLocationCreateParameterCreatesExpectedLocation(array $testData) + #[Depends('testPublishVersionCreatesLocationsDefinedOnCreate')] + public function testCreateContentWithLocationCreateParameterCreatesExpectedLocation(array $testData): void { /** @var \Ibexa\Contracts\Core\Repository\Values\Content\Content $content */ /** @var \Ibexa\Contracts\Core\Repository\Values\Content\Location $location */ @@ -1250,12 +1126,9 @@ public function testCreateContentWithLocationCreateParameterCreatesExpectedLocat /** * Test for the publishVersion() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::publishVersion() - * - * @depends testPublishVersion */ - public function testPublishVersionThrowsBadStateException() + #[Depends('testPublishVersion')] + public function testPublishVersionThrowsBadStateException(): void { $draft = $this->createContentDraftVersion1(); @@ -1270,10 +1143,8 @@ public function testPublishVersionThrowsBadStateException() /** * Test that publishVersion() does not affect publishedDate (assuming previous version exists). - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::publishVersion */ - public function testPublishVersionDoesNotChangePublishedDate() + public function testPublishVersionDoesNotChangePublishedDate(): void { $publishedContent = $this->createContentVersion1(); @@ -1300,13 +1171,9 @@ public function testPublishVersionDoesNotChangePublishedDate() * Test for the createContentDraft() method. * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContentDraft() - * - * @depends testPublishVersion - * - * @group user */ + #[Depends('testPublishVersion')] + #[Group('user')] public function testCreateContentDraft() { $content = $this->createContentVersion1(); @@ -1324,10 +1191,8 @@ public function testCreateContentDraft() /** * Test for the createContentDraft() method with given language for new draft. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContentDraft */ - public function testCreateContentDraftInOtherLanguage() + public function testCreateContentDraftInOtherLanguage(): void { $content = $this->createContentVersion1(); @@ -1350,14 +1215,10 @@ public function testCreateContentDraftInOtherLanguage() * * Test that editor has access to edit own draft. * Note: Editors have access to version_read, which is needed to load content drafts. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContentDraft() - * - * @depends testPublishVersion - * - * @group user */ - public function testCreateContentDraftAndLoadAccess() + #[Depends('testPublishVersion')] + #[Group('user')] + public function testCreateContentDraftAndLoadAccess(): void { $user = $this->createUserVersion1(); @@ -1377,12 +1238,9 @@ public function testCreateContentDraftAndLoadAccess() * Test for the createContentDraft() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $draft - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContentDraft() - * - * @depends testCreateContentDraft */ - public function testCreateContentDraftSetsExpectedProperties($draft) + #[Depends('testCreateContentDraft')] + public function testCreateContentDraftSetsExpectedProperties($draft): void { self::assertEquals( [ @@ -1400,12 +1258,9 @@ public function testCreateContentDraftSetsExpectedProperties($draft) * Test for the createContentDraft() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $draft - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContentDraft() - * - * @depends testCreateContentDraft */ - public function testCreateContentDraftSetsContentInfo($draft) + #[Depends('testCreateContentDraft')] + public function testCreateContentDraftSetsContentInfo($draft): void { $contentInfo = $draft->contentInfo; $currentUserReference = $this->getRepository()->getPermissionResolver()->getCurrentUserReference(); @@ -1436,12 +1291,9 @@ public function testCreateContentDraftSetsContentInfo($draft) * Test for the createContentDraft() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $draft - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContentDraft() - * - * @depends testCreateContentDraft */ - public function testCreateContentDraftSetsVersionInfo($draft) + #[Depends('testCreateContentDraft')] + public function testCreateContentDraftSetsVersionInfo($draft): void { $versionInfo = $draft->getVersionInfo(); $currentUserReference = $this->getRepository()->getPermissionResolver()->getCurrentUserReference(); @@ -1471,13 +1323,10 @@ public function testCreateContentDraftSetsVersionInfo($draft) * Test for the createContentDraft() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $draft - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContentDraft() - * - * @depends testCreateContentDraft - * @depends testLoadVersionInfo */ - public function testCreateContentDraftLoadVersionInfoStillLoadsPublishedVersion($draft) + #[Depends('testCreateContentDraft')] + #[Depends('testLoadVersionInfo')] + public function testCreateContentDraftLoadVersionInfoStillLoadsPublishedVersion($draft): void { $content = $this->createContentVersion1(); @@ -1492,13 +1341,10 @@ public function testCreateContentDraftLoadVersionInfoStillLoadsPublishedVersion( /** * Test for the createContentDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContentDraft() - * - * @depends testLoadContent - * @depends testCreateContentDraft */ - public function testCreateContentDraftLoadContentStillLoadsPublishedVersion() + #[Depends('testLoadContent')] + #[Depends('testCreateContentDraft')] + public function testCreateContentDraftLoadContentStillLoadsPublishedVersion(): void { $content = $this->createContentVersion1(); @@ -1513,13 +1359,10 @@ public function testCreateContentDraftLoadContentStillLoadsPublishedVersion() /** * Test for the createContentDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContentDraft() - * - * @depends testLoadContentByRemoteId - * @depends testCreateContentDraft */ - public function testCreateContentDraftLoadContentByRemoteIdStillLoadsPublishedVersion() + #[Depends('testLoadContentByRemoteId')] + #[Depends('testCreateContentDraft')] + public function testCreateContentDraftLoadContentByRemoteIdStillLoadsPublishedVersion(): void { $content = $this->createContentVersion1(); @@ -1534,13 +1377,10 @@ public function testCreateContentDraftLoadContentByRemoteIdStillLoadsPublishedVe /** * Test for the createContentDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContentDraft() - * - * @depends testLoadContentByContentInfo - * @depends testCreateContentDraft */ - public function testCreateContentDraftLoadContentByContentInfoStillLoadsPublishedVersion() + #[Depends('testLoadContentByContentInfo')] + #[Depends('testCreateContentDraft')] + public function testCreateContentDraftLoadContentByContentInfoStillLoadsPublishedVersion(): void { $content = $this->createContentVersion1(); @@ -1555,12 +1395,9 @@ public function testCreateContentDraftLoadContentByContentInfoStillLoadsPublishe /** * Test for the newContentUpdateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::newContentUpdateStruct - * - * @group user */ - public function testNewContentUpdateStruct() + #[Group('user')] + public function testNewContentUpdateStruct(): void { $updateStruct = $this->contentService->newContentUpdateStruct(); @@ -1582,15 +1419,11 @@ public function testNewContentUpdateStruct() * Test for the updateContent() method. * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent() - * - * @depends testNewContentUpdateStruct - * @depends testCreateContentDraft - * - * @group user - * @group field-type */ + #[Depends('testNewContentUpdateStruct')] + #[Depends('testCreateContentDraft')] + #[Group('user')] + #[Group('field-type')] public function testUpdateContent() { $draftVersion2 = $this->createUpdatedDraftVersion2(); @@ -1613,15 +1446,11 @@ public function testUpdateContent() * Test for the updateContent_WithDifferentUser() method. * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent() - * - * @depends testNewContentUpdateStruct - * @depends testCreateContentDraft - * - * @group user - * @group field-type */ + #[Depends('testNewContentUpdateStruct')] + #[Depends('testCreateContentDraft')] + #[Group('user')] + #[Group('field-type')] public function testUpdateContentWithDifferentUser() { $arrayWithDraftVersion2 = $this->createUpdatedDraftVersion2NotAdmin(); @@ -1644,12 +1473,9 @@ public function testUpdateContentWithDifferentUser() * Test for the updateContent() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent() - * - * @depends testUpdateContent */ - public function testUpdateContentSetsExpectedFields($content) + #[Depends('testUpdateContent')] + public function testUpdateContentSetsExpectedFields($content): void { $actual = $this->normalizeFields($content->getFields()); @@ -1679,12 +1505,9 @@ public function testUpdateContentSetsExpectedFields($content) /** * Test for the updateContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent() - * - * @depends testUpdateContent */ - public function testUpdateContentThrowsBadStateException() + #[Depends('testUpdateContent')] + public function testUpdateContentThrowsBadStateException(): void { $content = $this->createContentVersion1(); @@ -1706,12 +1529,9 @@ public function testUpdateContentThrowsBadStateException() /** * Test for the updateContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent() - * - * @depends testUpdateContent */ - public function testUpdateContentThrowsInvalidArgumentExceptionWhenFieldTypeDoesNotAccept() + #[Depends('testUpdateContent')] + public function testUpdateContentThrowsInvalidArgumentExceptionWhenFieldTypeDoesNotAccept(): void { $draft = $this->createContentDraftVersion1(); @@ -1730,12 +1550,9 @@ public function testUpdateContentThrowsInvalidArgumentExceptionWhenFieldTypeDoes /** * Test for the updateContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent() - * - * @depends testUpdateContent */ - public function testUpdateContentWhenMandatoryFieldIsEmpty() + #[Depends('testUpdateContent')] + public function testUpdateContentWhenMandatoryFieldIsEmpty(): void { $draft = $this->createContentDraftVersion1(); @@ -1757,12 +1574,9 @@ public function testUpdateContentWhenMandatoryFieldIsEmpty() /** * Test for the updateContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent() - * - * @depends testUpdateContent */ - public function testUpdateContentThrowsContentFieldValidationException() + #[Depends('testUpdateContent')] + public function testUpdateContentThrowsContentFieldValidationException(): void { $contentTypeService = $this->getRepository()->getContentTypeService(); $contentType = $contentTypeService->loadContentTypeByIdentifier('folder'); @@ -1784,12 +1598,9 @@ public function testUpdateContentThrowsContentFieldValidationException() /** * Test for the updateContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent() - * - * @depends testUpdateContent */ - public function testUpdateContentValidatorIgnoresRequiredFieldsOfNotUpdatedLanguages() + #[Depends('testUpdateContent')] + public function testUpdateContentValidatorIgnoresRequiredFieldsOfNotUpdatedLanguages(): void { $contentTypeService = $this->getRepository()->getContentTypeService(); $contentType = $contentTypeService->loadContentTypeByIdentifier('folder'); @@ -1826,12 +1637,9 @@ public function testUpdateContentValidatorIgnoresRequiredFieldsOfNotUpdatedLangu /** * Test for the updateContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent() - * - * @depends testUpdateContent */ - public function testUpdateContentWithNotUpdatingMandatoryField() + #[Depends('testUpdateContent')] + public function testUpdateContentWithNotUpdatingMandatoryField(): void { $draft = $this->createContentDraftVersion1(); @@ -1861,12 +1669,9 @@ public function testUpdateContentWithNotUpdatingMandatoryField() /** * Test for the createContentDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContentDraft($contentInfo, $versionInfo) - * - * @depends testUpdateContent */ - public function testCreateContentDraftWithSecondParameter() + #[Depends('testUpdateContent')] + public function testCreateContentDraftWithSecondParameter(): void { $contentVersion2 = $this->createContentVersion2(); @@ -1881,10 +1686,8 @@ public function testCreateContentDraftWithSecondParameter() /** * Test for the createContentDraft() method with third parameter. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContentDraft */ - public function testCreateContentDraftWithThirdParameter() + public function testCreateContentDraftWithThirdParameter(): void { $content = $this->contentService->loadContent(4); $user = $this->createUserVersion1(); @@ -1903,13 +1706,10 @@ public function testCreateContentDraftWithThirdParameter() /** * Test for the publishVersion() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::publishVersion() - * - * @depends testPublishVersion - * @depends testUpdateContent */ - public function testPublishVersionFromContentDraft() + #[Depends('testPublishVersion')] + #[Depends('testUpdateContent')] + public function testPublishVersionFromContentDraft(): void { $contentVersion2 = $this->createContentVersion2(); @@ -1932,12 +1732,9 @@ public function testPublishVersionFromContentDraft() /** * Test for the publishVersion() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::publishVersion() - * - * @depends testPublishVersionFromContentDraft */ - public function testPublishVersionFromContentDraftArchivesOldVersion() + #[Depends('testPublishVersionFromContentDraft')] + public function testPublishVersionFromContentDraftArchivesOldVersion(): void { $contentVersion2 = $this->createContentVersion2(); @@ -1960,12 +1757,9 @@ public function testPublishVersionFromContentDraftArchivesOldVersion() /** * Test for the publishVersion() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::publishVersion() - * - * @depends testPublishVersionFromContentDraft */ - public function testPublishVersionFromContentDraftUpdatesContentInfoCurrentVersion() + #[Depends('testPublishVersionFromContentDraft')] + public function testPublishVersionFromContentDraftUpdatesContentInfoCurrentVersion(): void { $contentVersion2 = $this->createContentVersion2(); @@ -1974,12 +1768,9 @@ public function testPublishVersionFromContentDraftUpdatesContentInfoCurrentVersi /** * Test for the publishVersion() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::publishVersion() - * - * @depends testPublishVersionFromContentDraft */ - public function testPublishVersionFromOldContentDraftArchivesNewerVersionNo() + #[Depends('testPublishVersionFromContentDraft')] + public function testPublishVersionFromOldContentDraftArchivesNewerVersionNo(): void { $content = $this->createContentVersion1(); @@ -2003,11 +1794,8 @@ public function testPublishVersionFromOldContentDraftArchivesNewerVersionNo() * Test for the publishVersion() method, and that it creates limited archives. * * @todo Adapt this when per content type archive limited is added on repository content type model. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::publishVersion() - * - * @depends testPublishVersionFromContentDraft */ + #[Depends('testPublishVersionFromContentDraft')] public function testPublishVersionNotCreatingUnlimitedArchives(): void { $content = $this->createContentVersion1(); @@ -2069,12 +1857,9 @@ public function testPublishVersionNotCreatingUnlimitedArchives(): void /** * Test for the newContentMetadataUpdateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::newContentMetadataUpdateStruct - * - * @group user */ - public function testNewContentMetadataUpdateStruct() + #[Group('user')] + public function testNewContentMetadataUpdateStruct(): void { // Creates a new metadata update struct $metadataUpdate = $this->contentService->newContentMetadataUpdateStruct(); @@ -2097,14 +1882,10 @@ public function testNewContentMetadataUpdateStruct() * Test for the updateContentMetadata() method. * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContentMetadata() - * - * @depends testPublishVersion - * @depends testNewContentMetadataUpdateStruct - * - * @group user */ + #[Depends('testPublishVersion')] + #[Depends('testNewContentMetadataUpdateStruct')] + #[Group('user')] public function testUpdateContentMetadata() { $content = $this->createContentVersion1(); @@ -2136,12 +1917,9 @@ public function testUpdateContentMetadata() * Test for the updateContentMetadata() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContentMetadata() - * - * @depends testUpdateContentMetadata */ - public function testUpdateContentMetadataSetsExpectedProperties($content) + #[Depends('testUpdateContentMetadata')] + public function testUpdateContentMetadataSetsExpectedProperties($content): void { $contentInfo = $content->contentInfo; $currentUserReference = $this->getRepository()->getPermissionResolver()->getCurrentUserReference(); @@ -2176,24 +1954,18 @@ public function testUpdateContentMetadataSetsExpectedProperties($content) * Test for the updateContentMetadata() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContentMetadata() - * - * @depends testUpdateContentMetadata */ - public function testUpdateContentMetadataNotUpdatesContentVersion($content) + #[Depends('testUpdateContentMetadata')] + public function testUpdateContentMetadataNotUpdatesContentVersion($content): void { self::assertEquals(1, $content->getVersionInfo()->versionNo); } /** * Test for the updateContentMetadata() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContentMetadata() - * - * @depends testUpdateContentMetadata */ - public function testUpdateContentMetadataThrowsInvalidArgumentExceptionOnDuplicateRemoteId() + #[Depends('testUpdateContentMetadata')] + public function testUpdateContentMetadataThrowsInvalidArgumentExceptionOnDuplicateRemoteId(): void { $content = $this->createContentVersion1(); @@ -2211,10 +1983,8 @@ public function testUpdateContentMetadataThrowsInvalidArgumentExceptionOnDuplica /** * Test for the updateContentMetadata() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContentMetadata */ - public function testUpdateContentMetadataThrowsInvalidArgumentExceptionOnNoMetadataPropertiesSet() + public function testUpdateContentMetadataThrowsInvalidArgumentExceptionOnNoMetadataPropertiesSet(): void { $contentInfo = $this->contentService->loadContentInfo(4); $contentMetadataUpdateStruct = $this->contentService->newContentMetadataUpdateStruct(); @@ -2224,8 +1994,6 @@ public function testUpdateContentMetadataThrowsInvalidArgumentExceptionOnNoMetad } /** - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContentMetadata - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException @@ -2249,8 +2017,6 @@ public function testUpdateContentAlwaysAvailable(): void } /** - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContentMetadata - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException @@ -2315,12 +2081,9 @@ public function testUpdateContentMainTranslation(): void /** * Test for the deleteContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteContent() - * - * @depends testPublishVersionFromContentDraft */ - public function testDeleteContent() + #[Depends('testPublishVersionFromContentDraft')] + public function testDeleteContent(): void { $contentVersion2 = $this->createContentVersion2(); @@ -2342,12 +2105,9 @@ public function testDeleteContent() * * Test for issue EZP-21057: * "contentService: Unable to delete a content with an empty file attribute" - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteContent() - * - * @depends testPublishVersionFromContentDraft */ - public function testDeleteContentWithEmptyBinaryField() + #[Depends('testPublishVersionFromContentDraft')] + public function testDeleteContentWithEmptyBinaryField(): void { $contentVersion = $this->createContentVersion1EmptyBinaryField(); @@ -2409,21 +2169,14 @@ public function testCountContentDraftsForUsers(): void self::assertSame(0, $previousUserDrafts); } - /** - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentDraftList() - */ - public function testLoadContentDraftsReturnsEmptyArrayByDefault() + public function testLoadContentDraftsReturnsEmptyArrayByDefault(): void { $contentDrafts = $this->contentService->loadContentDraftList(); self::assertSame([], $contentDrafts->items); } - /** - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentDraftList() - * - * @depends testCreateContentDraft - */ + #[Depends('testCreateContentDraft')] public function testLoadContentDraftList(): void { // "Media" content object @@ -2465,10 +2218,7 @@ public function testLoadContentDraftList(): void ); } - /** - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentDraftList($user) - */ - public function testLoadContentDraftsWithFirstParameter() + public function testLoadContentDraftsWithFirstParameter(): void { $user = $this->createUserVersion1(); @@ -2513,8 +2263,6 @@ public function testLoadContentDraftsWithFirstParameter() /** * Test for the loadContentDraftList() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentDraftList() */ public function testLoadContentDraftListWithPaginationParameters(): void { @@ -2539,8 +2287,6 @@ public function testLoadContentDraftListWithPaginationParameters(): void /** * Test for the loadContentDraftList() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentDraftList($user) */ public function testLoadContentDraftListWithForUserWithLimitation(): void { @@ -2578,8 +2324,6 @@ public function testLoadContentDraftListWithForUserWithLimitation(): void /** * Test for the loadContentDraftList() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentDraftList() */ public function testLoadAllContentDraftList(): void { @@ -2591,12 +2335,9 @@ public function testLoadAllContentDraftList(): void /** * Test for the loadVersionInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfo($contentInfo, $versionNo) - * - * @depends testPublishVersionFromContentDraft */ - public function testLoadVersionInfoWithSecondParameter() + #[Depends('testPublishVersionFromContentDraft')] + public function testLoadVersionInfoWithSecondParameter(): void { $publishedContent = $this->createContentVersion1(); @@ -2616,12 +2357,9 @@ public function testLoadVersionInfoWithSecondParameter() /** * Test for the loadVersionInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfo($contentInfo, $versionNo) - * - * @depends testLoadVersionInfoWithSecondParameter */ - public function testLoadVersionInfoThrowsNotFoundExceptionWithSecondParameter() + #[Depends('testLoadVersionInfoWithSecondParameter')] + public function testLoadVersionInfoThrowsNotFoundExceptionWithSecondParameter(): void { $draft = $this->createContentDraftVersion1(); @@ -2633,11 +2371,8 @@ public function testLoadVersionInfoThrowsNotFoundExceptionWithSecondParameter() /** * Test for the loadVersionInfoById() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfoById($contentId, $versionNo) - * - * @depends testLoadVersionInfoWithSecondParameter */ + #[Depends('testLoadVersionInfoWithSecondParameter')] public function testLoadVersionInfoByIdWithSecondParameter() { $publishedContent = $this->createContentVersion1(); @@ -2664,13 +2399,12 @@ public function testLoadVersionInfoByIdWithSecondParameter() /** * Test for the returned value of the loadVersionInfoById() method. * - * @depends testLoadVersionInfoByIdWithSecondParameter * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfoById * * @param array $data */ - public function testLoadVersionInfoByIdWithSecondParameterSetsExpectedVersionInfo(array $data) + #[Depends('testLoadVersionInfoByIdWithSecondParameter')] + public function testLoadVersionInfoByIdWithSecondParameterSetsExpectedVersionInfo(array $data): void { /** @var \Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo $versionInfo */ $versionInfo = $data['versionInfo']; @@ -2714,10 +2448,8 @@ public function testLoadVersionInfoByIdWithSecondParameterSetsExpectedVersionInf /** * Test for the loadVersionInfoById() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfoById($contentId, $versionNo) */ - public function testLoadVersionInfoByIdThrowsNotFoundExceptionWithSecondParameter() + public function testLoadVersionInfoByIdThrowsNotFoundExceptionWithSecondParameter(): void { $content = $this->createContentVersion1(); @@ -2729,13 +2461,10 @@ public function testLoadVersionInfoByIdThrowsNotFoundExceptionWithSecondParamete /** * Test for the loadContentByVersionInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByVersionInfo($versionInfo, $languages) - * - * @depends testCreateContent - * @depends testLoadContentByVersionInfo */ - public function testLoadContentByVersionInfoWithSecondParameter() + #[Depends('testCreateContent')] + #[Depends('testLoadContentByVersionInfo')] + public function testLoadContentByVersionInfoWithSecondParameter(): void { $sectionId = $this->generateId('section', 1); $contentTypeService = $this->getRepository()->getContentTypeService(); @@ -2806,12 +2535,9 @@ static function ($field1, $field2): int { /** * Test for the loadContentByContentInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByContentInfo($contentInfo, $languages) - * - * @depends testLoadContentByContentInfo */ - public function testLoadContentByContentInfoWithLanguageParameters() + #[Depends('testLoadContentByContentInfo')] + public function testLoadContentByContentInfoWithLanguageParameters(): void { $sectionId = $this->generateId('section', 1); $contentTypeService = $this->getRepository()->getContentTypeService(); @@ -2916,12 +2642,9 @@ public function testLoadContentByContentInfoWithLanguageParameters() /** * Test for the loadContentByContentInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByContentInfo($contentInfo, $languages, $versionNo) - * - * @depends testLoadContentByContentInfo */ - public function testLoadContentByContentInfoWithVersionNumberParameter() + #[Depends('testLoadContentByContentInfo')] + public function testLoadContentByContentInfoWithVersionNumberParameter(): void { $publishedContent = $this->createContentVersion1(); @@ -2948,12 +2671,9 @@ public function testLoadContentByContentInfoWithVersionNumberParameter() /** * Test for the loadContentByContentInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByContentInfo($contentInfo, $languages, $versionNo) - * - * @depends testLoadContentByContentInfoWithVersionNumberParameter */ - public function testLoadContentByContentInfoThrowsNotFoundExceptionWithVersionNumberParameter() + #[Depends('testLoadContentByContentInfoWithVersionNumberParameter')] + public function testLoadContentByContentInfoThrowsNotFoundExceptionWithVersionNumberParameter(): void { $content = $this->createContentVersion1(); @@ -2965,11 +2685,8 @@ public function testLoadContentByContentInfoThrowsNotFoundExceptionWithVersionNu /** * Test for the loadContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContent($contentId, $languages) - * - * @depends testPublishVersionFromContentDraft */ + #[Depends('testPublishVersionFromContentDraft')] public function testLoadContentWithPrioritizedLanguages() { $draft = $this->createMultipleLanguageDraftVersion1(); @@ -2985,11 +2702,11 @@ public function testLoadContentWithPrioritizedLanguages() /** * Test for the loadContent() method using undefined translation. * - * @depends testLoadContentWithPrioritizedLanguages * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $contentDraft */ - public function testLoadContentWithPrioritizedLanguagesThrowsNotFoundException(Content $contentDraft) + #[Depends('testLoadContentWithPrioritizedLanguages')] + public function testLoadContentWithPrioritizedLanguagesThrowsNotFoundException(Content $contentDraft): void { $this->expectException(NotFoundException::class); @@ -2998,11 +2715,8 @@ public function testLoadContentWithPrioritizedLanguagesThrowsNotFoundException(C /** * Test for the loadContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContent - * - * @depends testLoadContentWithPrioritizedLanguages */ + #[Depends('testLoadContentWithPrioritizedLanguages')] public function testLoadContentPassTroughPrioritizedLanguagesToContentType(Content $content): void { $contentTypeService = $this->getRepository()->getContentTypeService(); @@ -3017,12 +2731,9 @@ public function testLoadContentPassTroughPrioritizedLanguagesToContentType(Conte /** * Test for the loadContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContent($contentId, $languages, $versionNo) - * - * @depends testPublishVersionFromContentDraft */ - public function testLoadContentWithThirdParameter() + #[Depends('testPublishVersionFromContentDraft')] + public function testLoadContentWithThirdParameter(): void { $publishedContent = $this->createContentVersion1(); @@ -3042,12 +2753,9 @@ public function testLoadContentWithThirdParameter() /** * Test for the loadContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContent($contentId, $languages, $versionNo) - * - * @depends testLoadContentWithThirdParameter */ - public function testLoadContentThrowsNotFoundExceptionWithThirdParameter() + #[Depends('testLoadContentWithThirdParameter')] + public function testLoadContentThrowsNotFoundExceptionWithThirdParameter(): void { $content = $this->createContentVersion1(); @@ -3059,12 +2767,9 @@ public function testLoadContentThrowsNotFoundExceptionWithThirdParameter() /** * Test for the loadContentByRemoteId() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByRemoteId($remoteId, $languages) - * - * @depends testPublishVersionFromContentDraft */ - public function testLoadContentByRemoteIdWithSecondParameter() + #[Depends('testPublishVersionFromContentDraft')] + public function testLoadContentByRemoteIdWithSecondParameter(): void { $draft = $this->createMultipleLanguageDraftVersion1(); @@ -3083,12 +2788,9 @@ public function testLoadContentByRemoteIdWithSecondParameter() /** * Test for the loadContentByRemoteId() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByRemoteId($remoteId, $languages, $versionNo) - * - * @depends testPublishVersionFromContentDraft */ - public function testLoadContentByRemoteIdWithThirdParameter() + #[Depends('testPublishVersionFromContentDraft')] + public function testLoadContentByRemoteIdWithThirdParameter(): void { $publishedContent = $this->createContentVersion1(); @@ -3112,12 +2814,9 @@ public function testLoadContentByRemoteIdWithThirdParameter() /** * Test for the loadContentByRemoteId() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByRemoteId($remoteId, $languages, $versionNo) - * - * @depends testLoadContentByRemoteIdWithThirdParameter */ - public function testLoadContentByRemoteIdThrowsNotFoundExceptionWithThirdParameter() + #[Depends('testLoadContentByRemoteIdWithThirdParameter')] + public function testLoadContentByRemoteIdThrowsNotFoundExceptionWithThirdParameter(): void { $content = $this->createContentVersion1(); @@ -3134,11 +2833,11 @@ public function testLoadContentByRemoteIdThrowsNotFoundExceptionWithThirdParamet /** * Test that retrieval of translated name field respects prioritized language list. * - * @dataProvider getPrioritizedLanguageList * * @param string[]|null $languageCodes */ - public function testLoadContentWithPrioritizedLanguagesList($languageCodes) + #[DataProvider('getPrioritizedLanguageList')] + public function testLoadContentWithPrioritizedLanguagesList($languageCodes): void { $content = $this->createContentVersion2(); @@ -3158,7 +2857,7 @@ public function testLoadContentWithPrioritizedLanguagesList($languageCodes) /** * @return array */ - public function getPrioritizedLanguageList() + public static function getPrioritizedLanguageList(): array { return [ [[self::ENG_US]], @@ -3170,15 +2869,12 @@ public function getPrioritizedLanguageList() /** * Test for the deleteVersion() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteVersion() - * - * @depends testLoadContent - * @depends testCreateContent - * @depends testPublishVersion - * @depends testCreateContentDraft */ - public function testDeleteVersion() + #[Depends('testLoadContent')] + #[Depends('testCreateContent')] + #[Depends('testPublishVersion')] + #[Depends('testCreateContentDraft')] + public function testDeleteVersion(): void { $content = $this->createContentVersion1(); @@ -3203,14 +2899,11 @@ public function testDeleteVersion() /** * Test for the deleteVersion() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteVersion() - * - * @depends testLoadContent - * @depends testCreateContent - * @depends testPublishVersion */ - public function testDeleteVersionThrowsBadStateExceptionOnPublishedVersion() + #[Depends('testLoadContent')] + #[Depends('testCreateContent')] + #[Depends('testPublishVersion')] + public function testDeleteVersionThrowsBadStateExceptionOnPublishedVersion(): void { $content = $this->createContentVersion1(); @@ -3222,14 +2915,11 @@ public function testDeleteVersionThrowsBadStateExceptionOnPublishedVersion() /** * Test for the deleteVersion() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteVersion() - * - * @depends testLoadContent - * @depends testCreateContent - * @depends testPublishVersion */ - public function testDeleteVersionWorksIfOnlyVersionIsDraft() + #[Depends('testLoadContent')] + #[Depends('testCreateContent')] + #[Depends('testPublishVersion')] + public function testDeleteVersionWorksIfOnlyVersionIsDraft(): void { $draft = $this->createContentDraftVersion1(); @@ -3245,12 +2935,11 @@ public function testDeleteVersionWorksIfOnlyVersionIsDraft() /** * Test for the loadVersions() method. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersions() * - * @depends testPublishVersion * * @return \Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo[] */ + #[Depends('testPublishVersion')] public function testLoadVersions() { $contentVersion2 = $this->createContentVersion2(); @@ -3271,13 +2960,12 @@ public function testLoadVersions() /** * Test for the loadVersions() method. * - * @depends testLoadVersions * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersions * * @param \Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo[] $versions */ - public function testLoadVersionsSetsExpectedVersionInfo(array $versions) + #[Depends('testLoadVersions')] + public function testLoadVersionsSetsExpectedVersionInfo(array $versions): void { self::assertCount(2, $versions); @@ -3323,14 +3011,10 @@ public function testLoadVersionsSetsExpectedVersionInfo(array $versions) /** * Test for the copyContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::copyContent() - * - * @depends testPublishVersionFromContentDraft - * - * @group field-type */ - public function testCopyContent() + #[Depends('testPublishVersionFromContentDraft')] + #[Group('field-type')] + public function testCopyContent(): void { $parentLocationId = $this->generateId('location', 56); @@ -3386,14 +3070,10 @@ public function testCopyContent() /** * Test for the copyContent() method with ibexa.site_access.config.default.content.retain_owner_on_copy set to false * See settings/test/integration_legacy.yml for service override. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::copyContent() - * - * @depends testPublishVersionFromContentDraft - * - * @group field-type */ - public function testCopyContentWithNewOwner() + #[Depends('testPublishVersionFromContentDraft')] + #[Group('field-type')] + public function testCopyContentWithNewOwner(): void { $parentLocationId = $this->generateId('location', 56); @@ -3448,12 +3128,9 @@ public function testCopyContentWithNewOwner() /** * Test for the copyContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::copyContent($contentInfo, $destinationLocationCreateStruct, $versionInfo) - * - * @depends testCopyContent */ - public function testCopyContentWithGivenVersion() + #[Depends('testCopyContent')] + public function testCopyContentWithGivenVersion(): void { $parentLocationId = $this->generateId('location', 56); @@ -3506,14 +3183,11 @@ public function testCopyContentWithGivenVersion() /** * @return \Ibexa\Contracts\Core\Repository\Values\Content\Relation[] * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::addRelation - * - * @depends testPublishVersionFromContentDraft - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException */ + #[Depends('testPublishVersionFromContentDraft')] public function testAddRelation(): array { $draft = $this->createContentDraftVersion1(); @@ -3538,12 +3212,9 @@ public function testAddRelation(): array * Test for the addRelation() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Relation[] $relations - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::addRelation() - * - * @depends testAddRelation */ - public function testAddRelationAddsRelationToContent($relations) + #[Depends('testAddRelation')] + public function testAddRelationAddsRelationToContent($relations): void { self::assertCount( 1, @@ -3576,12 +3247,9 @@ protected function assertExpectedRelations($relations) * Test for the addRelation() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Relation[] $relations - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::addRelation() - * - * @depends testAddRelation */ - public function testAddRelationSetsExpectedRelations($relations) + #[Depends('testAddRelation')] + public function testAddRelationSetsExpectedRelations($relations): void { $this->assertExpectedRelations($relations); } @@ -3590,11 +3258,8 @@ public function testAddRelationSetsExpectedRelations($relations) * Test for the createContentDraft() method. * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Relation[] - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContentDraft - * - * @depends testAddRelationSetsExpectedRelations */ + #[Depends('testAddRelationSetsExpectedRelations')] public function testCreateContentDraftWithRelations() { $draft = $this->createContentDraftVersion1(); @@ -3621,9 +3286,8 @@ public function testCreateContentDraftWithRelations() * @param \Ibexa\Contracts\Core\Repository\Values\Content\Relation[] $relations * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Relation[] - * - * @depends testCreateContentDraftWithRelations */ + #[Depends('testCreateContentDraftWithRelations')] public function testCreateContentDraftWithRelationsCreatesRelations(array $relations): array { self::assertCount( @@ -3638,22 +3302,18 @@ public function testCreateContentDraftWithRelationsCreatesRelations(array $relat * Test for the createContentDraft() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Relation[] $relations - * - * @depends testCreateContentDraftWithRelationsCreatesRelations */ - public function testCreateContentDraftWithRelationsCreatesExpectedRelations($relations) + #[Depends('testCreateContentDraftWithRelationsCreatesRelations')] + public function testCreateContentDraftWithRelationsCreatesExpectedRelations($relations): void { $this->assertExpectedRelations($relations); } /** * Test for the addRelation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::addRelation() - * - * @depends testAddRelation */ - public function testAddRelationThrowsBadStateException() + #[Depends('testAddRelation')] + public function testAddRelationThrowsBadStateException(): void { $content = $this->createContentVersion1(); @@ -3670,13 +3330,10 @@ public function testAddRelationThrowsBadStateException() /** * Test for the loadRelations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadRelationList() - * - * @depends testAddRelation - * @depends testLoadRelationList */ - public function testLoadRelationsSkipsArchivedContent() + #[Depends('testAddRelation')] + #[Depends('testLoadRelationList')] + public function testLoadRelationsSkipsArchivedContent(): void { $trashService = $this->getRepository()->getTrashService(); @@ -3734,13 +3391,10 @@ public function testLoadRelationsSkipsArchivedContent() /** * Test for the loadRelations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadRelationList() - * - * @depends testAddRelation - * @depends testLoadRelationList */ - public function testLoadRelationsSkipsDraftContent() + #[Depends('testAddRelation')] + #[Depends('testLoadRelationList')] + public function testLoadRelationsSkipsDraftContent(): void { $draft = $this->createContentDraftVersion1(); @@ -3899,8 +3553,6 @@ public function testLoadRelationListWithType(): void /** * Test for the countReverseRelations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::countReverseRelations */ public function testCountReverseRelations(): void { @@ -3936,8 +3588,6 @@ public function testCountReverseRelationsWithType(): void /** * Test for the countReverseRelations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::countReverseRelations */ public function testCountReverseRelationsReturnsZeroByDefault(): void { @@ -3948,8 +3598,6 @@ public function testCountReverseRelationsReturnsZeroByDefault(): void /** * Test for the countReverseRelations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::countReverseRelations */ public function testCountReverseRelationsForUnauthorizedUser(): void { @@ -3968,12 +3616,9 @@ public function testCountReverseRelationsForUnauthorizedUser(): void /** * Test for the loadReverseRelations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadReverseRelations() - * - * @depends testAddRelation */ - public function testLoadReverseRelations() + #[Depends('testAddRelation')] + public function testLoadReverseRelations(): void { $versionInfo = $this->createContentVersion1()->getVersionInfo(); $contentInfo = $versionInfo->getContentInfo(); @@ -4050,13 +3695,10 @@ static function ($rel1, $rel2): int { /** * Test for the loadReverseRelations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadReverseRelations() - * - * @depends testAddRelation - * @depends testLoadReverseRelations */ - public function testLoadReverseRelationsSkipsArchivedContent() + #[Depends('testAddRelation')] + #[Depends('testLoadReverseRelations')] + public function testLoadReverseRelationsSkipsArchivedContent(): void { $trashService = $this->getRepository()->getTrashService(); @@ -4126,13 +3768,10 @@ public function testLoadReverseRelationsSkipsArchivedContent() /** * Test for the loadReverseRelations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadReverseRelations() - * - * @depends testAddRelation - * @depends testLoadReverseRelations */ - public function testLoadReverseRelationsSkipsDraftContent() + #[Depends('testAddRelation')] + #[Depends('testLoadReverseRelations')] + public function testLoadReverseRelationsSkipsDraftContent(): void { // Load "Media" page Content $media = $this->contentService->loadContentByRemoteId(self::MEDIA_REMOTE_ID); @@ -4188,9 +3827,6 @@ public function testLoadReverseRelationsSkipsDraftContent() ); } - /** - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadReverseRelationList - */ public function testLoadReverseRelationList(): void { $draft1 = $this->contentService->createContentDraft( @@ -4228,9 +3864,6 @@ public function testLoadReverseRelationList(): void ); } - /** - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadReverseRelationList - */ public function testLoadReverseRelationListWithPagination(): void { $draft1 = $this->contentService->createContentDraft( @@ -4269,9 +3902,6 @@ public function testLoadReverseRelationListWithPagination(): void ); } - /** - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadReverseRelationList - */ public function testLoadReverseRelationListSkipsArchivedContent(): void { $trashService = $this->getRepository()->getTrashService(); @@ -4313,10 +3943,7 @@ public function testLoadReverseRelationListSkipsArchivedContent(): void ); } - /** - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadReverseRelationList - */ - public function testLoadReverseRelationListSkipsDraftContent() + public function testLoadReverseRelationListSkipsDraftContent(): void { $draft1 = $this->contentService->createContentDraft( $this->createFolder([self::ENG_GB => 'Foo'], 2)->contentInfo @@ -4363,12 +3990,9 @@ public function testLoadReverseRelationListWithType(): void /** * Test for the deleteRelation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteRelation() - * - * @depends testLoadRelationList */ - public function testDeleteRelation() + #[Depends('testLoadRelationList')] + public function testDeleteRelation(): void { $draft = $this->createContentDraftVersion1(); @@ -4390,12 +4014,9 @@ public function testDeleteRelation() /** * Test for the deleteRelation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteRelation() - * - * @depends testDeleteRelation */ - public function testDeleteRelationThrowsBadStateException() + #[Depends('testDeleteRelation')] + public function testDeleteRelationThrowsBadStateException(): void { $content = $this->createContentVersion1(); @@ -4424,12 +4045,9 @@ public function testDeleteRelationThrowsBadStateException() /** * Test for the deleteRelation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteRelation() - * - * @depends testDeleteRelation */ - public function testDeleteRelationThrowsInvalidArgumentException() + #[Depends('testDeleteRelation')] + public function testDeleteRelationThrowsInvalidArgumentException(): void { $draft = $this->createContentDraftVersion1(); @@ -4446,13 +4064,10 @@ public function testDeleteRelationThrowsInvalidArgumentException() /** * Test for the createContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() - * - * @depends testCreateContent - * @depends testLoadContent */ - public function testCreateContentInTransactionWithRollback() + #[Depends('testCreateContent')] + #[Depends('testLoadContent')] + public function testCreateContentInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -4495,13 +4110,10 @@ public function testCreateContentInTransactionWithRollback() /** * Test for the createContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() - * - * @depends testCreateContent - * @depends testLoadContent */ - public function testCreateContentInTransactionWithCommit() + #[Depends('testCreateContent')] + #[Depends('testLoadContent')] + public function testCreateContentInTransactionWithCommit(): void { $repository = $this->getRepository(); @@ -4539,13 +4151,10 @@ public function testCreateContentInTransactionWithCommit() /** * Test for the createContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent($contentCreateStruct, $locationCreateStructs) - * - * @depends testCreateContentWithLocationCreateParameterDoesNotCreateLocationImmediately - * @depends testLoadContentThrowsNotFoundException */ - public function testCreateContentWithLocationCreateParameterInTransactionWithRollback() + #[Depends('testCreateContentWithLocationCreateParameterDoesNotCreateLocationImmediately')] + #[Depends('testLoadContentThrowsNotFoundException')] + public function testCreateContentWithLocationCreateParameterInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -4577,13 +4186,10 @@ public function testCreateContentWithLocationCreateParameterInTransactionWithRol /** * Test for the createContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent($contentCreateStruct, $locationCreateStructs) - * - * @depends testCreateContentWithLocationCreateParameterDoesNotCreateLocationImmediately - * @depends testLoadContentThrowsNotFoundException */ - public function testCreateContentWithLocationCreateParameterInTransactionWithCommit() + #[Depends('testCreateContentWithLocationCreateParameterDoesNotCreateLocationImmediately')] + #[Depends('testLoadContentThrowsNotFoundException')] + public function testCreateContentWithLocationCreateParameterInTransactionWithCommit(): void { $repository = $this->getRepository(); @@ -4611,13 +4217,10 @@ public function testCreateContentWithLocationCreateParameterInTransactionWithCom /** * Test for the createContentDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContentDraft() - * - * @depends testCreateContentDraft - * @depends testLoadContent */ - public function testCreateContentDraftInTransactionWithRollback() + #[Depends('testCreateContentDraft')] + #[Depends('testLoadContent')] + public function testCreateContentDraftInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -4656,13 +4259,10 @@ public function testCreateContentDraftInTransactionWithRollback() /** * Test for the createContentDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContentDraft() - * - * @depends testCreateContentDraft - * @depends testLoadContent */ - public function testCreateContentDraftInTransactionWithCommit() + #[Depends('testCreateContentDraft')] + #[Depends('testLoadContent')] + public function testCreateContentDraftInTransactionWithCommit(): void { $repository = $this->getRepository(); @@ -4699,13 +4299,10 @@ public function testCreateContentDraftInTransactionWithCommit() /** * Test for the publishVersion() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::publishVersion() - * - * @depends testPublishVersion - * @depends testLoadContent */ - public function testPublishVersionInTransactionWithRollback() + #[Depends('testPublishVersion')] + #[Depends('testLoadContent')] + public function testPublishVersionInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -4746,13 +4343,10 @@ public function testPublishVersionInTransactionWithRollback() /** * Test for the publishVersion() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::publishVersion() - * - * @depends testPublishVersion - * @depends testLoadVersionInfo */ - public function testPublishVersionInTransactionWithCommit() + #[Depends('testPublishVersion')] + #[Depends('testLoadVersionInfo')] + public function testPublishVersionInTransactionWithCommit(): void { $repository = $this->getRepository(); @@ -4787,14 +4381,11 @@ public function testPublishVersionInTransactionWithCommit() /** * Test for the updateContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent() - * - * @depends testUpdateContent - * @depends testLoadContent - * @depends testLoadContentInfo */ - public function testUpdateContentInTransactionWithRollback() + #[Depends('testUpdateContent')] + #[Depends('testLoadContent')] + #[Depends('testLoadContentInfo')] + public function testUpdateContentInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -4838,14 +4429,11 @@ public function testUpdateContentInTransactionWithRollback() /** * Test for the updateContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent() - * - * @depends testUpdateContent - * @depends testLoadContent - * @depends testLoadContentInfo */ - public function testUpdateContentInTransactionWithCommit() + #[Depends('testUpdateContent')] + #[Depends('testLoadContent')] + #[Depends('testLoadContentInfo')] + public function testUpdateContentInTransactionWithCommit(): void { $repository = $this->getRepository(); @@ -4889,13 +4477,10 @@ public function testUpdateContentInTransactionWithCommit() /** * Test for the updateContentMetadata() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContentMetadata() - * - * @depends testUpdateContentMetadata - * @depends testLoadContentInfo */ - public function testUpdateContentMetadataInTransactionWithRollback() + #[Depends('testUpdateContentMetadata')] + #[Depends('testLoadContentInfo')] + public function testUpdateContentMetadataInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -4937,13 +4522,10 @@ public function testUpdateContentMetadataInTransactionWithRollback() /** * Test for the updateContentMetadata() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContentMetadata() - * - * @depends testUpdateContentMetadata - * @depends testLoadContentInfo */ - public function testUpdateContentMetadataInTransactionWithCommit() + #[Depends('testUpdateContentMetadata')] + #[Depends('testLoadContentInfo')] + public function testUpdateContentMetadataInTransactionWithCommit(): void { $repository = $this->getRepository(); @@ -4985,13 +4567,10 @@ public function testUpdateContentMetadataInTransactionWithCommit() /** * Test for the updateContentMetadata() method, and how cache + transactions play together. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContentMetadata() - * - * @depends testUpdateContentMetadata - * @depends testLoadContentInfo */ - public function testUpdateContentMetadataCheckWithinTransaction() + #[Depends('testUpdateContentMetadata')] + #[Depends('testLoadContentInfo')] + public function testUpdateContentMetadataCheckWithinTransaction(): void { $repository = $this->getRepository(); $contentService = $repository->getContentService(); @@ -5032,14 +4611,11 @@ public function testUpdateContentMetadataCheckWithinTransaction() /** * Test for the deleteVersion() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteVersion() - * - * @depends testCreateContent - * @depends testLoadContentInfo - * @depends testLoadContentDraftList */ - public function testDeleteVersionInTransactionWithRollback() + #[Depends('testCreateContent')] + #[Depends('testLoadContentInfo')] + #[Depends('testLoadContentDraftList')] + public function testDeleteVersionInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -5072,14 +4648,11 @@ public function testDeleteVersionInTransactionWithRollback() /** * Test for the deleteVersion() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteVersion() - * - * @depends testCreateContent - * @depends testLoadContentInfo - * @depends testLoadContentDraftList */ - public function testDeleteVersionInTransactionWithCommit() + #[Depends('testCreateContent')] + #[Depends('testLoadContentInfo')] + #[Depends('testLoadContentDraftList')] + public function testDeleteVersionInTransactionWithCommit(): void { $repository = $this->getRepository(); @@ -5112,13 +4685,10 @@ public function testDeleteVersionInTransactionWithCommit() /** * Test for the deleteContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteContent() - * - * @depends testDeleteContent - * @depends testLoadContentInfo */ - public function testDeleteContentInTransactionWithRollback() + #[Depends('testDeleteContent')] + #[Depends('testLoadContentInfo')] + public function testDeleteContentInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -5150,13 +4720,10 @@ public function testDeleteContentInTransactionWithRollback() /** * Test for the deleteContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteContent() - * - * @depends testDeleteContent - * @depends testLoadContentInfo */ - public function testDeleteContentInTransactionWithCommit() + #[Depends('testDeleteContent')] + #[Depends('testLoadContentInfo')] + public function testDeleteContentInTransactionWithCommit(): void { $repository = $this->getRepository(); @@ -5192,12 +4759,9 @@ public function testDeleteContentInTransactionWithCommit() /** * Test for the copyContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::copyContent() - * - * @depends testCopyContent */ - public function testCopyContentInTransactionWithRollback() + #[Depends('testCopyContent')] + public function testCopyContentInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -5240,12 +4804,9 @@ public function testCopyContentInTransactionWithRollback() /** * Test for the copyContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::copyContent() - * - * @depends testCopyContent */ - public function testCopyContentInTransactionWithCommit() + #[Depends('testCopyContent')] + public function testCopyContentInTransactionWithCommit(): void { $repository = $this->getRepository(); @@ -5286,7 +4847,7 @@ public function testCopyContentInTransactionWithCommit() self::assertCount(2, $locations); } - public function testURLAliasesCreatedForNewContent() + public function testURLAliasesCreatedForNewContent(): void { $urlAliasService = $this->getRepository()->getURLAliasService(); @@ -5317,7 +4878,7 @@ public function testURLAliasesCreatedForNewContent() ); } - public function testURLAliasesCreatedForUpdatedContent() + public function testURLAliasesCreatedForUpdatedContent(): void { $urlAliasService = $this->getRepository()->getURLAliasService(); @@ -5384,7 +4945,7 @@ public function testURLAliasesCreatedForUpdatedContent() ); } - public function testCustomURLAliasesNotHistorizedOnUpdatedContent() + public function testCustomURLAliasesNotHistorizedOnUpdatedContent(): void { $urlAliasService = $this->getRepository()->getURLAliasService(); @@ -5441,7 +5002,7 @@ public function testCustomURLAliasesNotHistorizedOnUpdatedContent() * Test to ensure that old versions are not affected by updates to newer * drafts. */ - public function testUpdatingDraftDoesNotUpdateOldVersions() + public function testUpdatingDraftDoesNotUpdateOldVersions(): void { $contentVersion2 = $this->createContentVersion2(); @@ -5458,7 +5019,7 @@ public function testUpdatingDraftDoesNotUpdateOldVersions() * Test scenario with writer and publisher users. * Writer can only create content. Publisher can publish this content. */ - public function testPublishWorkflow() + public function testPublishWorkflow(): void { $this->createRoleWithPolicies('Publisher', [ ['module' => 'content', 'function' => 'read'], @@ -5497,7 +5058,7 @@ public function testPublishWorkflow() /** * Test publish / content policy is required to be able to publish content. */ - public function testPublishContentWithoutPublishPolicyThrowsException() + public function testPublishContentWithoutPublishPolicyThrowsException(): void { $this->createRoleWithPolicies('Writer', [ ['module' => 'content', 'function' => 'read'], @@ -5520,10 +5081,8 @@ public function testPublishContentWithoutPublishPolicyThrowsException() /** * Test removal of the specific translation from all the Versions of a Content Object. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteTranslation */ - public function testDeleteTranslation() + public function testDeleteTranslation(): void { $content = $this->createContentVersion2(); @@ -5547,7 +5106,7 @@ public function testDeleteTranslation() * Test deleting a Translation which is initial for some Version, updates initialLanguageCode * with mainLanguageCode (assuming they are different). */ - public function testDeleteTranslationUpdatesInitialLanguageCodeVersion() + public function testDeleteTranslationUpdatesInitialLanguageCodeVersion(): void { $content = $this->createContentVersion2(); // create another, copied, version @@ -5578,10 +5137,8 @@ public function testDeleteTranslationUpdatesInitialLanguageCodeVersion() /** * Test removal of the specific translation properly updates languages of the URL alias. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteTranslation */ - public function testDeleteTranslationUpdatesUrlAlias() + public function testDeleteTranslationUpdatesUrlAlias(): void { $urlAliasService = $this->getRepository()->getURLAliasService(); @@ -5623,10 +5180,8 @@ public function testDeleteTranslationUpdatesUrlAlias() /** * Test removal of a main translation throws BadStateException. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteTranslation */ - public function testDeleteTranslationMainLanguageThrowsBadStateException() + public function testDeleteTranslationMainLanguageThrowsBadStateException(): void { $content = $this->createContentVersion2(); @@ -5642,10 +5197,8 @@ public function testDeleteTranslationMainLanguageThrowsBadStateException() /** * Test removal of a Translation is possible when some archived Versions have only this Translation. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteTranslation */ - public function testDeleteTranslationDeletesSingleTranslationVersions() + public function testDeleteTranslationDeletesSingleTranslationVersions(): void { // content created by the createContentVersion1 method has eng-US translation only. $content = $this->createContentVersion1(); @@ -5671,10 +5224,8 @@ public function testDeleteTranslationDeletesSingleTranslationVersions() /** * Test removal of the translation by the user who is not allowed to delete a content * throws UnauthorizedException. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteTranslation */ - public function testDeleteTranslationThrowsUnauthorizedException() + public function testDeleteTranslationThrowsUnauthorizedException(): void { $content = $this->createContentVersion2(); @@ -5701,10 +5252,8 @@ public function testDeleteTranslationThrowsUnauthorizedException() /** * Test removal of a non-existent translation throws InvalidArgumentException. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteTranslation */ - public function testDeleteTranslationThrowsInvalidArgumentException() + public function testDeleteTranslationThrowsInvalidArgumentException(): void { // content created by the createContentVersion1 method has eng-US translation only. $content = $this->createContentVersion1(); @@ -5717,10 +5266,8 @@ public function testDeleteTranslationThrowsInvalidArgumentException() /** * Test deleting a Translation from Draft. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteTranslationFromDraft */ - public function testDeleteTranslationFromDraft() + public function testDeleteTranslationFromDraft(): void { $languageCode = self::ENG_GB; $content = $this->createMultipleLanguageContentVersion2(); @@ -5738,7 +5285,7 @@ public function testDeleteTranslationFromDraft() * * @return array */ - public function providerForDeleteTranslationFromDraftRemovesUrlAliasOnPublishing() + public static function providerForDeleteTranslationFromDraftRemovesUrlAliasOnPublishing(): array { return [ [ @@ -5753,9 +5300,7 @@ public function providerForDeleteTranslationFromDraftRemovesUrlAliasOnPublishing /** * Test deleting a Translation from Draft removes previously stored URL aliases for published Content. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteTranslationFromDraft * - * @dataProvider providerForDeleteTranslationFromDraftRemovesUrlAliasOnPublishing * * @param string[] $fieldValues translated field values * @@ -5764,7 +5309,8 @@ public function providerForDeleteTranslationFromDraftRemovesUrlAliasOnPublishing * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ - public function testDeleteTranslationFromDraftRemovesUrlAliasOnPublishing(array $fieldValues) + #[DataProvider('providerForDeleteTranslationFromDraftRemovesUrlAliasOnPublishing')] + public function testDeleteTranslationFromDraftRemovesUrlAliasOnPublishing(array $fieldValues): void { $urlAliasService = $this->getRepository()->getURLAliasService(); @@ -5825,7 +5371,7 @@ public function testDeleteTranslationFromDraftRemovesUrlAliasOnPublishing(array /** * Test that URL aliases for deleted Translations are properly archived. */ - public function testDeleteTranslationFromDraftArchivesUrlAliasOnPublishing() + public function testDeleteTranslationFromDraftArchivesUrlAliasOnPublishing(): void { $urlAliasService = $this->getRepository()->getURLAliasService(); @@ -5881,10 +5427,8 @@ public function testDeleteTranslationFromDraftArchivesUrlAliasOnPublishing() /** * Test deleting a Translation from Draft which has single Translation throws BadStateException. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteTranslationFromDraft */ - public function testDeleteTranslationFromDraftThrowsBadStateExceptionOnSingleTranslation() + public function testDeleteTranslationFromDraftThrowsBadStateExceptionOnSingleTranslation(): void { // create Content with single Translation $publishedContent = $this->contentService->publishVersion( @@ -5918,10 +5462,8 @@ public function testDeleteTranslationFromDraftThrowsBadStateExceptionOnSingleTra /** * Test deleting the Main Translation from Draft throws BadStateException. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteTranslationFromDraft */ - public function testDeleteTranslationFromDraftThrowsBadStateExceptionOnMainTranslation() + public function testDeleteTranslationFromDraftThrowsBadStateExceptionOnMainTranslation(): void { $mainLanguageCode = self::ENG_US; $draft = $this->createMultilingualContentDraft( @@ -5944,10 +5486,8 @@ public function testDeleteTranslationFromDraftThrowsBadStateExceptionOnMainTrans /** * Test deleting the Translation from Published Version throws BadStateException. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteTranslationFromDraft */ - public function testDeleteTranslationFromDraftThrowsBadStateExceptionOnPublishedVersion() + public function testDeleteTranslationFromDraftThrowsBadStateExceptionOnPublishedVersion(): void { $languageCode = self::ENG_US; $content = $this->createMultipleLanguageContentVersion2(); @@ -5962,10 +5502,8 @@ public function testDeleteTranslationFromDraftThrowsBadStateExceptionOnPublished /** * Test deleting a Translation from Draft throws UnauthorizedException if user cannot edit Content. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteTranslationFromDraft */ - public function testDeleteTranslationFromDraftThrowsUnauthorizedException() + public function testDeleteTranslationFromDraftThrowsUnauthorizedException(): void { $languageCode = self::ENG_GB; $content = $this->createMultipleLanguageContentVersion2(); @@ -5994,10 +5532,8 @@ public function testDeleteTranslationFromDraftThrowsUnauthorizedException() /** * Test deleting a non-existent Translation from Draft throws InvalidArgumentException. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteTranslationFromDraft */ - public function testDeleteTranslationFromDraftThrowsInvalidArgumentException() + public function testDeleteTranslationFromDraftThrowsInvalidArgumentException(): void { $languageCode = self::GER_DE; $content = $this->createMultipleLanguageContentVersion2(); @@ -6010,7 +5546,7 @@ public function testDeleteTranslationFromDraftThrowsInvalidArgumentException() /** * Test loading list of Content items. */ - public function testLoadContentListByContentInfo() + public function testLoadContentListByContentInfo(): void { $allLocationsCount = $this->locationService->getAllLocationsCount(); $contentInfoList = array_map( @@ -6038,10 +5574,8 @@ static function (Location $location) { * Test loading content versions after removing exactly two drafts. * * @see https://issues.ibexa.co/browse/EZP-30271 - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteVersion */ - public function testLoadVersionsAfterDeletingTwoDrafts() + public function testLoadVersionsAfterDeletingTwoDrafts(): void { $content = $this->createFolder([self::ENG_GB => 'Foo'], 2); @@ -6072,7 +5606,7 @@ public function testLoadVersionsAfterDeletingTwoDrafts() /** * Tests loading list of content versions of status draft. */ - public function testLoadVersionsOfStatusDraft() + public function testLoadVersionsOfStatusDraft(): void { $content = $this->createContentVersion1(); @@ -6088,7 +5622,7 @@ public function testLoadVersionsOfStatusDraft() /** * Tests loading list of content versions of status archived. */ - public function testLoadVersionsOfStatusArchived() + public function testLoadVersionsOfStatusArchived(): void { $content = $this->createContentVersion1(); @@ -6329,8 +5863,6 @@ private function getExpectedMediaContentInfoProperties() } /** - * @covers \Ibexa\Contracts\Core\Repository\ContentService::hideContent - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ContentFieldValidationException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ContentValidationException @@ -6375,13 +5907,11 @@ function (Location $parentLocation) { } /** - * @covers \Ibexa\Contracts\Core\Repository\ContentService::revealContent - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ - public function testRevealContent() + public function testRevealContent(): void { $contentTypeService = $this->getRepository()->getContentTypeService(); @@ -6507,8 +6037,6 @@ public function testPublishRevealedDraft(): void } /** - * @dataProvider draftVisibilityTransitionsProvider - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ContentFieldValidationException @@ -6516,6 +6044,7 @@ public function testPublishRevealedDraft(): void * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ContentValidationException */ + #[DataProvider('draftVisibilityTransitionsProvider')] public function testDraftVisibilityTransitions( bool $initiallyHidden, bool $secondDraftHidden @@ -6594,10 +6123,8 @@ private function createFolderDraft(): Content ); } - /** - * @depends testRevealContent - */ - public function testRevealContentWithHiddenParent() + #[Depends('testRevealContent')] + public function testRevealContentWithHiddenParent(): void { $contentTypeService = $this->getRepository()->getContentTypeService(); @@ -6658,10 +6185,8 @@ public function testRevealContentWithHiddenParent() } } - /** - * @depends testRevealContent - */ - public function testRevealContentWithHiddenChildren() + #[Depends('testRevealContent')] + public function testRevealContentWithHiddenChildren(): void { $contentTypeService = $this->getRepository()->getContentTypeService(); @@ -6736,7 +6261,7 @@ public function testRevealContentWithHiddenChildren() } } - public function testHideContentWithParentLocation() + public function testHideContentWithParentLocation(): void { $contentTypeService = $this->getRepository()->getContentTypeService(); @@ -6783,7 +6308,7 @@ public function testHideContentWithParentLocation() self::assertTrue($childLocations[0]->invisible); } - public function testChangeContentName() + public function testChangeContentName(): void { $contentDraft = $this->createContentDraft( 'folder', @@ -6805,7 +6330,7 @@ public function testChangeContentName() self::assertEquals('Polo', $updatedContent->contentInfo->name); } - public function testCopyTranslationsFromPublishedToDraft() + public function testCopyTranslationsFromPublishedToDraft(): void { $contentDraft = $this->createContentDraft( 'folder', @@ -6868,7 +6393,7 @@ public function testCopyTranslationsFromPublishedToDraft() ); } - public function testCopyTranslationsFromInvalidPublishedContentToDraft() + public function testCopyTranslationsFromInvalidPublishedContentToDraft(): void { $contentTypeService = $this->getRepository()->getContentTypeService(); @@ -6997,7 +6522,7 @@ static function (Location $location) { ); } - public function testPublishVersionWithSelectedLanguages() + public function testPublishVersionWithSelectedLanguages(): void { $publishedContent = $this->createFolder( [ @@ -7027,7 +6552,7 @@ public function testPublishVersionWithSelectedLanguages() ); } - public function testCreateContentWithRomanianSpecialCharsInTitle() + public function testCreateContentWithRomanianSpecialCharsInTitle(): void { $baseName = 'ȘșțȚdfdf'; $expectedPath = '/SstTdfdf'; diff --git a/tests/integration/Core/Repository/ContentTypeService/FindContentTypesTest.php b/tests/integration/Core/Repository/ContentTypeService/FindContentTypesTest.php index b91cc9d73d..1a84b692a7 100644 --- a/tests/integration/Core/Repository/ContentTypeService/FindContentTypesTest.php +++ b/tests/integration/Core/Repository/ContentTypeService/FindContentTypesTest.php @@ -21,11 +21,12 @@ use Ibexa\Contracts\Core\Repository\Values\ContentType\Query\Criterion\LogicalOr; use Ibexa\Contracts\Core\Repository\Values\ContentType\Query\SortClause\Identifier; use Ibexa\Contracts\Core\Repository\Values\ContentType\Query\SortClause\Name; +use Ibexa\Core\Repository\ContentTypeService; use Ibexa\Tests\Integration\Core\RepositoryTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; -/** - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService - */ +#[CoversClass(ContentTypeService::class)] final class FindContentTypesTest extends RepositoryTestCase { public function testFindContentTypesWithNullQueryFinds25Results(): void @@ -42,9 +43,8 @@ public function testFindContentTypesWithNullQueryFinds25Results(): void /** * @param list $expectedIdentifiers - * - * @dataProvider dataProviderForTestFindContentTypes */ + #[DataProvider('dataProviderForTestFindContentTypes')] public function testFindContentTypes(ContentTypeQuery $query, array $expectedIdentifiers): void { $contentTypeService = $this->getIbexaTestCore()->getContentTypeService(); @@ -151,7 +151,7 @@ public function testFindContentTypesContainingFieldDefinitions(): void /** * @return iterable}> */ - public function dataProviderForTestFindContentTypes(): iterable + public static function dataProviderForTestFindContentTypes(): iterable { yield 'identifiers' => [ new ContentTypeQuery( diff --git a/tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php b/tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php index c4fd943916..3e44d28ae3 100644 --- a/tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php +++ b/tests/integration/Core/Repository/ContentTypeServiceAuthorizationTest.php @@ -8,27 +8,24 @@ namespace Ibexa\Tests\Integration\Core\Repository; use Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException; +use Ibexa\Core\Repository\ContentTypeService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DependsExternal; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the ContentTypeServiceAuthorization using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService - * - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testLoadUser - * - * @group integration - * @group authorization */ +#[CoversClass(ContentTypeService::class)] +#[Group('integration')] +#[Group('authorization')] class ContentTypeServiceAuthorizationTest extends BaseContentTypeServiceTestCase { /** * Test for the createContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentTypeGroup() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testCreateContentTypeGroup */ - public function testCreateContentTypeGroupThrowsUnauthorizedException() + #[DependsExternal(ContentTypeServiceTest::class, 'testCreateContentTypeGroup')] + public function testCreateContentTypeGroupThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -65,12 +62,9 @@ public function testCreateContentTypeGroupThrowsUnauthorizedException() /** * Test for the updateContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateContentTypeGroup() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testUpdateContentTypeGroup */ - public function testUpdateContentTypeGroupThrowsUnauthorizedException() + #[DependsExternal(ContentTypeServiceTest::class, 'testUpdateContentTypeGroup')] + public function testUpdateContentTypeGroupThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -116,12 +110,9 @@ public function testUpdateContentTypeGroupThrowsUnauthorizedException() /** * Test for the deleteContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::deleteContentTypeGroup() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testDeleteContentTypeGroup */ - public function testDeleteContentTypeGroupThrowsUnauthorizedException() + #[DependsExternal(ContentTypeServiceTest::class, 'testDeleteContentTypeGroup')] + public function testDeleteContentTypeGroupThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -154,12 +145,9 @@ public function testDeleteContentTypeGroupThrowsUnauthorizedException() /** * Test for the createContentType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentType() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testCreateContentType */ - public function testCreateContentTypeThrowsUnauthorizedException() + #[DependsExternal(ContentTypeServiceTest::class, 'testCreateContentType')] + public function testCreateContentTypeThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -212,12 +200,9 @@ public function testCreateContentTypeThrowsUnauthorizedException() /** * Test for the updateContentTypeDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateContentTypeDraft() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testUpdateContentTypeDraft */ - public function testUpdateContentTypeDraftThrowsUnauthorizedException() + #[DependsExternal(ContentTypeServiceTest::class, 'testUpdateContentTypeDraft')] + public function testUpdateContentTypeDraftThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -265,12 +250,9 @@ public function testUpdateContentTypeDraftThrowsUnauthorizedException() /** * Test for the addFieldDefinition() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::addFieldDefinition() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testAddFieldDefinition */ - public function testAddFieldDefinitionThrowsUnauthorizedException() + #[DependsExternal(ContentTypeServiceTest::class, 'testAddFieldDefinition')] + public function testAddFieldDefinitionThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -322,12 +304,9 @@ public function testAddFieldDefinitionThrowsUnauthorizedException() /** * Test for the removeFieldDefinition() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::removeFieldDefinition() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testRemoveFieldDefinition */ - public function testRemoveFieldDefinitionThrowsUnauthorizedException() + #[DependsExternal(ContentTypeServiceTest::class, 'testRemoveFieldDefinition')] + public function testRemoveFieldDefinitionThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -356,12 +335,9 @@ public function testRemoveFieldDefinitionThrowsUnauthorizedException() /** * Test for the updateFieldDefinition() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateFieldDefinition() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testUpdateFieldDefinition */ - public function testUpdateFieldDefinitionThrowsUnauthorizedException() + #[DependsExternal(ContentTypeServiceTest::class, 'testUpdateFieldDefinition')] + public function testUpdateFieldDefinitionThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -415,12 +391,9 @@ public function testUpdateFieldDefinitionThrowsUnauthorizedException() /** * Test for the publishContentTypeDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::publishContentTypeDraft() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testPublishContentTypeDraft */ - public function testPublishContentTypeDraftThrowsUnauthorizedException() + #[DependsExternal(ContentTypeServiceTest::class, 'testPublishContentTypeDraft')] + public function testPublishContentTypeDraftThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -447,12 +420,9 @@ public function testPublishContentTypeDraftThrowsUnauthorizedException() /** * Test for the createContentTypeDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentTypeDraft() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testCreateContentTypeDraft */ - public function testCreateContentTypeDraftThrowsUnauthorizedException() + #[DependsExternal(ContentTypeServiceTest::class, 'testCreateContentTypeDraft')] + public function testCreateContentTypeDraftThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -480,12 +450,9 @@ public function testCreateContentTypeDraftThrowsUnauthorizedException() /** * Test for the deleteContentType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::deleteContentType() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testDeleteContentType */ - public function testDeleteContentTypeThrowsUnauthorizedException() + #[DependsExternal(ContentTypeServiceTest::class, 'testDeleteContentType')] + public function testDeleteContentTypeThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -513,12 +480,9 @@ public function testDeleteContentTypeThrowsUnauthorizedException() /** * Test for the copyContentType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::copyContentType() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testCopyContentType */ - public function testCopyContentTypeThrowsUnauthorizedException() + #[DependsExternal(ContentTypeServiceTest::class, 'testCopyContentType')] + public function testCopyContentTypeThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -546,12 +510,9 @@ public function testCopyContentTypeThrowsUnauthorizedException() /** * Test for the assignContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::assignContentTypeGroup() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testAssignContentTypeGroup */ - public function testAssignContentTypeGroupThrowsUnauthorizedException() + #[DependsExternal(ContentTypeServiceTest::class, 'testAssignContentTypeGroup')] + public function testAssignContentTypeGroupThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -580,12 +541,9 @@ public function testAssignContentTypeGroupThrowsUnauthorizedException() /** * Test for the unassignContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::unassignContentTypeGroup() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testUnassignContentTypeGroup */ - public function testUnassignContentTypeGroupThrowsUnauthorizedException() + #[DependsExternal(ContentTypeServiceTest::class, 'testUnassignContentTypeGroup')] + public function testUnassignContentTypeGroupThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/ContentTypeServiceTest.php b/tests/integration/Core/Repository/ContentTypeServiceTest.php index e125887a2b..3db769f4fd 100644 --- a/tests/integration/Core/Repository/ContentTypeServiceTest.php +++ b/tests/integration/Core/Repository/ContentTypeServiceTest.php @@ -30,24 +30,25 @@ use Ibexa\Contracts\Core\Repository\Values\ContentType\FieldDefinitionUpdateStruct; use Ibexa\Contracts\Core\Repository\Values\Translation\Message; use Ibexa\Core\FieldType\TextLine\Value as TextLineValue; +use Ibexa\Core\Repository\ContentTypeService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the ContentTypeService using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService - * - * @group integration - * @group content-type */ +#[CoversClass(ContentTypeService::class)] +#[CoversClass(FieldDefinitionUpdateStruct::class)] +#[Group('integration')] +#[Group('content-type')] class ContentTypeServiceTest extends BaseContentTypeServiceTestCase { /** * Test for the newContentTypeGroupCreateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::newContentTypeGroupCreateStruct() - * - * @group user */ + #[Group('user')] public function testNewContentTypeGroupCreateStruct() { $repository = $this->getRepository(); @@ -70,12 +71,9 @@ public function testNewContentTypeGroupCreateStruct() /** * Test for the newContentTypeGroupCreateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::newContentTypeGroupCreateStruct() - * - * @depends testNewContentTypeGroupCreateStruct */ - public function testNewContentTypeGroupCreateStructValues($createStruct) + #[Depends('testNewContentTypeGroupCreateStruct')] + public function testNewContentTypeGroupCreateStructValues($createStruct): void { $this->assertPropertiesCorrect( [ @@ -92,13 +90,9 @@ public function testNewContentTypeGroupCreateStructValues($createStruct) /** * Test for the createContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentTypeGroup() - * - * @depends testNewContentTypeGroupCreateStruct - * - * @group user */ + #[Depends('testNewContentTypeGroupCreateStruct')] + #[Group('user')] public function testCreateContentTypeGroup() { $repository = $this->getRepository(); @@ -137,11 +131,8 @@ public function testCreateContentTypeGroup() /** * Test for the createContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentTypeGroup() - * - * @depends testCreateContentTypeGroup */ + #[Depends('testCreateContentTypeGroup')] public function testCreateContentTypeGroupStructValues(array $data) { $createStruct = $data['createStruct']; @@ -170,12 +161,9 @@ public function testCreateContentTypeGroupStructValues(array $data) /** * Test for the createContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentTypeGroup() - * - * @depends testCreateContentTypeGroupStructValues */ - public function testCreateContentTypeGroupStructLanguageDependentValues(array $data) + #[Depends('testCreateContentTypeGroupStructValues')] + public function testCreateContentTypeGroupStructLanguageDependentValues(array $data): void { $createStruct = $data['createStruct']; $group = $data['group']; @@ -191,12 +179,9 @@ public function testCreateContentTypeGroupStructLanguageDependentValues(array $d /** * Test for the createContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentTypeGroup - * - * @depends testCreateContentTypeGroup */ - public function testCreateContentTypeGroupThrowsInvalidArgumentException() + #[Depends('testCreateContentTypeGroup')] + public function testCreateContentTypeGroupThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Argument \'$contentTypeGroupCreateStruct\' is invalid: A group with the identifier \'Content\' already exists'); @@ -217,13 +202,9 @@ public function testCreateContentTypeGroupThrowsInvalidArgumentException() /** * Test for the loadContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypeGroup() - * - * @depends testCreateContentTypeGroup - * - * @group user */ + #[Depends('testCreateContentTypeGroup')] + #[Group('user')] public function testLoadContentTypeGroup() { $repository = $this->getRepository(); @@ -263,12 +244,9 @@ public function testLoadSystemContentTypeGroup(): void /** * Test for the loadContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypeGroup() - * - * @depends testLoadContentTypeGroup */ - public function testLoadContentTypeGroupStructValues(ContentTypeGroup $group) + #[Depends('testLoadContentTypeGroup')] + public function testLoadContentTypeGroupStructValues(ContentTypeGroup $group): void { $this->assertPropertiesCorrect( [ @@ -285,10 +263,8 @@ public function testLoadContentTypeGroupStructValues(ContentTypeGroup $group) /** * Test for the loadContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypeGroup() */ - public function testLoadContentTypeGroupThrowsNotFoundException() + public function testLoadContentTypeGroupThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -300,12 +276,9 @@ public function testLoadContentTypeGroupThrowsNotFoundException() /** * Test for the loadContentTypeGroupByIdentifier() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypeGroupByIdentifier() - * - * @group user - * @group field-type */ + #[Group('user')] + #[Group('field-type')] public function testLoadContentTypeGroupByIdentifier() { $repository = $this->getRepository(); @@ -328,12 +301,9 @@ public function testLoadContentTypeGroupByIdentifier() /** * Test for the loadContentTypeGroupByIdentifier() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypeGroupByIdentifier() - * - * @depends testLoadContentTypeGroupByIdentifier */ - public function testLoadContentTypeGroupByIdentifierStructValues(ContentTypeGroup $group) + #[Depends('testLoadContentTypeGroupByIdentifier')] + public function testLoadContentTypeGroupByIdentifierStructValues(ContentTypeGroup $group): void { $repository = $this->getRepository(); $contentTypeService = $repository->getContentTypeService(); @@ -346,12 +316,9 @@ public function testLoadContentTypeGroupByIdentifierStructValues(ContentTypeGrou /** * Test for the loadContentTypeGroupByIdentifier() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypeGroupByIdentifier() - * - * @depends testLoadContentTypeGroupByIdentifier */ - public function testLoadContentTypeGroupByIdentifierThrowsNotFoundException() + #[Depends('testLoadContentTypeGroupByIdentifier')] + public function testLoadContentTypeGroupByIdentifierThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -369,11 +336,8 @@ public function testLoadContentTypeGroupByIdentifierThrowsNotFoundException() /** * Test for the loadContentTypeGroups() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypeGroups() - * - * @depends testCreateContentTypeGroup */ + #[Depends('testCreateContentTypeGroup')] public function testLoadContentTypeGroups() { $repository = $this->getRepository(); @@ -408,12 +372,9 @@ public function testLoadContentTypeGroups() /** * Test for the loadContentTypeGroups() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypeGroups() - * - * @depends testLoadContentTypeGroups */ - public function testLoadContentTypeGroupsIdentifiers($groups) + #[Depends('testLoadContentTypeGroups')] + public function testLoadContentTypeGroupsIdentifiers($groups): void { self::assertCount(4, $groups); @@ -441,10 +402,8 @@ public function testLoadContentTypeGroupsIdentifiers($groups) /** * Test for the newContentTypeGroupUpdateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::newContentTypeGroupUpdateStruct() */ - public function testNewContentTypeGroupUpdateStruct() + public function testNewContentTypeGroupUpdateStruct(): void { $repository = $this->getRepository(); @@ -462,11 +421,8 @@ public function testNewContentTypeGroupUpdateStruct() /** * Test for the updateContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateContentTypeGroup() - * - * @depends testCreateContentTypeGroup */ + #[Depends('testCreateContentTypeGroup')] public function testUpdateContentTypeGroup() { $repository = $this->getRepository(); @@ -515,11 +471,8 @@ public function testUpdateContentTypeGroup() /** * Test for the updateContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateContentTypeGroup() - * - * @depends testUpdateContentTypeGroup */ + #[Depends('testUpdateContentTypeGroup')] public function testUpdateContentTypeGroupStructValues(array $data) { $expectedValues = [ @@ -538,12 +491,9 @@ public function testUpdateContentTypeGroupStructValues(array $data) /** * Test for the updateContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateContentTypeGroup() - * - * @depends testUpdateContentTypeGroupStructValues */ - public function testUpdateContentTypeGroupStructLanguageDependentValues(array $data) + #[Depends('testUpdateContentTypeGroupStructValues')] + public function testUpdateContentTypeGroupStructLanguageDependentValues(array $data): void { $expectedValues = [ 'identifier' => $data['updateStruct']->identifier, @@ -563,12 +513,9 @@ public function testUpdateContentTypeGroupStructLanguageDependentValues(array $d /** * Test for the updateContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateContentTypeGroup - * - * @depends testUpdateContentTypeGroup */ - public function testUpdateContentTypeGroupThrowsInvalidArgumentException() + #[Depends('testUpdateContentTypeGroup')] + public function testUpdateContentTypeGroupThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Argument \'$contentTypeGroupUpdateStruct->identifier\' is invalid: given identifier already exists'); @@ -592,12 +539,9 @@ public function testUpdateContentTypeGroupThrowsInvalidArgumentException() /** * Test for the deleteContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::deleteContentTypeGroup - * - * @depends testLoadContentTypeGroup */ - public function testDeleteContentTypeGroup() + #[Depends('testLoadContentTypeGroup')] + public function testDeleteContentTypeGroup(): void { $this->expectException(NotFoundException::class); @@ -654,12 +598,9 @@ public function testDeleteContentTypeGroupWithOrphanedContentTypeDrafts(): void /** * Test for the newContentTypeCreateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::newContentTypeCreateStruct() - * - * @group user - * @group field-type */ + #[Group('user')] + #[Group('field-type')] public function testNewContentTypeCreateStruct() { $repository = $this->getRepository(); @@ -682,12 +623,9 @@ public function testNewContentTypeCreateStruct() /** * Test for the newContentTypeCreateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::newContentTypeCreateStruct() - * - * @depends testNewContentTypeCreateStruct */ - public function testNewContentTypeCreateStructValues($createStruct) + #[Depends('testNewContentTypeCreateStruct')] + public function testNewContentTypeCreateStructValues($createStruct): void { $this->assertPropertiesCorrect( [ @@ -711,12 +649,9 @@ public function testNewContentTypeCreateStructValues($createStruct) /** * Test for the newFieldDefinitionCreateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::newFieldDefinitionCreateStruct() - * - * @group user - * @group field-type */ + #[Group('user')] + #[Group('field-type')] public function testNewFieldDefinitionCreateStruct() { $repository = $this->getRepository(); @@ -737,12 +672,9 @@ public function testNewFieldDefinitionCreateStruct() /** * Test for the newFieldDefinitionCreateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::newFieldDefinitionCreateStruct() - * - * @depends testNewFieldDefinitionCreateStruct */ - public function testNewFieldDefinitionCreateStructValues($createStruct) + #[Depends('testNewFieldDefinitionCreateStruct')] + public function testNewFieldDefinitionCreateStructValues($createStruct): void { $this->assertPropertiesCorrect( [ @@ -766,12 +698,9 @@ public function testNewFieldDefinitionCreateStructValues($createStruct) /** * Test for the deleteContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::deleteContentTypeGroup() - * - * @depends testDeleteContentTypeGroup */ - public function testDeleteContentTypeGroupThrowsInvalidArgumentException() + #[Depends('testDeleteContentTypeGroup')] + public function testDeleteContentTypeGroupThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -789,16 +718,12 @@ public function testDeleteContentTypeGroupThrowsInvalidArgumentException() /** * Test for the createContentType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentType() - * - * @depends testNewContentTypeCreateStruct - * @depends testNewFieldDefinitionCreateStruct - * @depends testLoadContentTypeGroupByIdentifier - * - * @group user - * @group field-type */ + #[Depends('testNewContentTypeCreateStruct')] + #[Depends('testNewFieldDefinitionCreateStruct')] + #[Depends('testLoadContentTypeGroupByIdentifier')] + #[Group('user')] + #[Group('field-type')] public function testCreateContentType() { $repository = $this->getRepository(); @@ -901,13 +826,12 @@ public function testCreateContentType() /** * Test for the createContentType() method struct values. * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentType * - * @depends testCreateContentType * * @param array $data */ - public function testCreateContentTypeStructValues(array $data) + #[Depends('testCreateContentType')] + public function testCreateContentTypeStructValues(array $data): void { $typeCreate = $data['typeCreate']; $contentType = $data['contentType']; @@ -1036,12 +960,9 @@ protected function assertContentTypeGroupsCorrect($expectedGroups, $actualGroups /** * Test for the createContentType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentType() - * - * @depends testCreateContentType */ - public function testCreateContentTypeThrowsInvalidArgumentExceptionDuplicateIdentifier() + #[Depends('testCreateContentType')] + public function testCreateContentTypeThrowsInvalidArgumentExceptionDuplicateIdentifier(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Argument \'$contentTypeCreateStruct\' is invalid: Another content type with identifier \'folder\' exists'); @@ -1071,12 +992,9 @@ public function testCreateContentTypeThrowsInvalidArgumentExceptionDuplicateIden /** * Test for the createContentType() method trying to create content type with already existing * remoteId. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentType() - * - * @depends testCreateContentType */ - public function testCreateContentTypeThrowsInvalidArgumentExceptionDuplicateRemoteId() + #[Depends('testCreateContentType')] + public function testCreateContentTypeThrowsInvalidArgumentExceptionDuplicateRemoteId(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Another content type with remoteId \'a3d405b81be900468eb153d774f4f0d2\' exists'); @@ -1106,12 +1024,9 @@ public function testCreateContentTypeThrowsInvalidArgumentExceptionDuplicateRemo /** * Test for the createContentType() method creating content with duplicate field identifiers. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentType - * - * @depends testCreateContentType */ - public function testCreateContentTypeThrowsInvalidArgumentExceptionDuplicateFieldIdentifier() + #[Depends('testCreateContentType')] + public function testCreateContentTypeThrowsInvalidArgumentExceptionDuplicateFieldIdentifier(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Argument \'$contentTypeCreateStruct\' is invalid: The argument contains duplicate Field definition identifier \'title\''); @@ -1144,12 +1059,9 @@ public function testCreateContentTypeThrowsInvalidArgumentExceptionDuplicateFiel /** * Test for the createContentTypeGroup() method trying to create a content type with already * existing identifier. - * - * @depends testCreateContentType - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentType */ - public function testCreateContentTypeThrowsInvalidArgumentExceptionDuplicateContentTypeIdentifier() + #[Depends('testCreateContentType')] + public function testCreateContentTypeThrowsInvalidArgumentExceptionDuplicateContentTypeIdentifier(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Another content type with identifier \'blog-post\' exists'); @@ -1183,12 +1095,9 @@ public function testCreateContentTypeThrowsInvalidArgumentExceptionDuplicateCont /** * Test for the createContentType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentType() - * - * @depends testCreateContentType */ - public function testCreateContentTypeThrowsContentTypeFieldDefinitionValidationException() + #[Depends('testCreateContentType')] + public function testCreateContentTypeThrowsContentTypeFieldDefinitionValidationException(): void { $repository = $this->getRepository(); @@ -1242,12 +1151,9 @@ public function testCreateContentTypeThrowsContentTypeFieldDefinitionValidationE /** * Test for the createContentTypeGroup() method called with no groups. - * - * @depends testCreateContentType - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentTypeGroup */ - public function testCreateContentTypeThrowsInvalidArgumentExceptionGroupsEmpty() + #[Depends('testCreateContentType')] + public function testCreateContentTypeThrowsInvalidArgumentExceptionGroupsEmpty(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Argument \'$contentTypeGroups\' is invalid: The argument must contain at least one content type group'); @@ -1268,8 +1174,6 @@ public function testCreateContentTypeThrowsInvalidArgumentExceptionGroupsEmpty() /** * Test for the newContentTypeUpdateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::newContentTypeUpdateStruct() */ public function testNewContentTypeUpdateStruct() { @@ -1291,12 +1195,9 @@ public function testNewContentTypeUpdateStruct() /** * Test for the newContentTypeUpdateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::newContentTypeUpdateStruct() - * - * @depends testNewContentTypeUpdateStruct */ - public function testNewContentTypeUpdateStructValues($typeUpdate) + #[Depends('testNewContentTypeUpdateStruct')] + public function testNewContentTypeUpdateStructValues($typeUpdate): void { foreach ($typeUpdate as $propertyName => $propertyValue) { self::assertNull( @@ -1308,12 +1209,9 @@ public function testNewContentTypeUpdateStructValues($typeUpdate) /** * Test for the loadContentTypeDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypeDraft() - * - * @depends testCreateContentType */ - public function testLoadContentTypeDraft() + #[Depends('testCreateContentType')] + public function testLoadContentTypeDraft(): void { $repository = $this->getRepository(); $contentTypeService = $repository->getContentTypeService(); @@ -1334,12 +1232,9 @@ public function testLoadContentTypeDraft() /** * Test for the loadContentTypeDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypeDraft() - * - * @depends testLoadContentTypeDraft */ - public function testLoadContentTypeDraftThrowsNotFoundException() + #[Depends('testLoadContentTypeDraft')] + public function testLoadContentTypeDraftThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -1356,10 +1251,8 @@ public function testLoadContentTypeDraftThrowsNotFoundException() /** * Test for the loadContentTypeDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypeDraft() */ - public function testLoadContentTypeDraftThrowsNotFoundExceptionIfDiffrentOwner() + public function testLoadContentTypeDraftThrowsNotFoundExceptionIfDiffrentOwner(): void { $this->expectException(NotFoundException::class); @@ -1377,10 +1270,8 @@ public function testLoadContentTypeDraftThrowsNotFoundExceptionIfDiffrentOwner() /** * Test for the loadContentTypeDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypeDraft() */ - public function testCanLoadContentTypeDraftEvenIfDiffrentOwner() + public function testCanLoadContentTypeDraftEvenIfDiffrentOwner(): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); @@ -1399,8 +1290,6 @@ public function testCanLoadContentTypeDraftEvenIfDiffrentOwner() /** * Test for the updateContentTypeDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateContentTypeDraft() */ public function testUpdateContentTypeDraft() { @@ -1451,12 +1340,9 @@ public function testUpdateContentTypeDraft() /** * Test for the updateContentTypeDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateContentTypeDraft() - * - * @depends testUpdateContentTypeDraft */ - public function testUpdateContentTypeDraftStructValues($data) + #[Depends('testUpdateContentTypeDraft')] + public function testUpdateContentTypeDraftStructValues($data): void { $originalType = $data['originalType']; $updateStruct = $data['updateStruct']; @@ -1495,13 +1381,11 @@ public function testUpdateContentTypeDraftStructValues($data) } /** - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateContentTypeDraft - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ - public function testUpdateContentTypeDraftWithNewTranslation() + public function testUpdateContentTypeDraftWithNewTranslation(): void { $repository = $this->getRepository(); $contentTypeService = $repository->getContentTypeService(); @@ -1536,12 +1420,9 @@ public function testUpdateContentTypeDraftWithNewTranslation() /** * Test for the updateContentTypeDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateContentTypeDraft() - * - * @depends testUpdateContentTypeDraft */ - public function testUpdateContentTypeDraftThrowsInvalidArgumentExceptionDuplicateIdentifier() + #[Depends('testUpdateContentTypeDraft')] + public function testUpdateContentTypeDraftThrowsInvalidArgumentExceptionDuplicateIdentifier(): void { $this->expectException(InvalidArgumentException::class); @@ -1561,12 +1442,9 @@ public function testUpdateContentTypeDraftThrowsInvalidArgumentExceptionDuplicat /** * Test for the updateContentTypeDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateContentTypeDraft() - * - * @depends testUpdateContentTypeDraft */ - public function testUpdateContentTypeDraftThrowsInvalidArgumentExceptionDuplicateRemoteId() + #[Depends('testUpdateContentTypeDraft')] + public function testUpdateContentTypeDraftThrowsInvalidArgumentExceptionDuplicateRemoteId(): void { $this->expectException(InvalidArgumentException::class); @@ -1586,12 +1464,9 @@ public function testUpdateContentTypeDraftThrowsInvalidArgumentExceptionDuplicat /** * Test for the updateContentTypeDraft() method. - * - * @depends testUpdateContentTypeDraft - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateContentTypeDraft */ - public function testUpdateContentTypeDraftThrowsInvalidArgumentExceptionNoDraftForAuthenticatedUser() + #[Depends('testUpdateContentTypeDraft')] + public function testUpdateContentTypeDraftThrowsInvalidArgumentExceptionNoDraftForAuthenticatedUser(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Argument \'$contentTypeDraft\' is invalid: There is no content type draft assigned to the authenticated user'); @@ -1625,11 +1500,8 @@ public function testUpdateContentTypeDraftThrowsInvalidArgumentExceptionNoDraftF * Test for the addFieldDefinition() method. * * @return array - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::addFieldDefinition() - * - * @depends testCreateContentType */ + #[Depends('testCreateContentType')] public function testAddFieldDefinition() { $repository = $this->getRepository(); @@ -1680,12 +1552,9 @@ public function testAddFieldDefinition() /** * Test for the addFieldDefinition() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::addFieldDefinition() - * - * @depends testAddFieldDefinition */ - public function testAddFieldDefinitionStructValues(array $data) + #[Depends('testAddFieldDefinition')] + public function testAddFieldDefinitionStructValues(array $data): void { $loadedType = $data['loadedType']; $fieldDefCreate = $data['fieldDefCreate']; @@ -1708,12 +1577,9 @@ public function testAddFieldDefinitionStructValues(array $data) /** * Test for the addFieldDefinition() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::addFieldDefinition() - * - * @depends testAddFieldDefinition */ - public function testAddFieldDefinitionThrowsInvalidArgumentExceptionDuplicateFieldIdentifier() + #[Depends('testAddFieldDefinition')] + public function testAddFieldDefinitionThrowsInvalidArgumentExceptionDuplicateFieldIdentifier(): void { $this->expectException(InvalidArgumentException::class); @@ -1735,12 +1601,9 @@ public function testAddFieldDefinitionThrowsInvalidArgumentExceptionDuplicateFie * * Testing that field definition of non-repeatable field type can not be added multiple * times to the same ContentType. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::addFieldDefinition() - * - * @depends testAddFieldDefinition */ - public function testAddFieldDefinitionThrowsContentTypeFieldDefinitionValidationException() + #[Depends('testAddFieldDefinition')] + public function testAddFieldDefinitionThrowsContentTypeFieldDefinitionValidationException(): void { $repository = $this->getRepository(); $contentTypeService = $repository->getContentTypeService(); @@ -1795,12 +1658,9 @@ public function testAddFieldDefinitionThrowsContentTypeFieldDefinitionValidation * * Testing that field definition of non-repeatable field type can not be added multiple * times to the same ContentType. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::addFieldDefinition() - * - * @depends testAddFieldDefinition */ - public function testAddFieldDefinitionThrowsBadStateExceptionNonRepeatableField() + #[Depends('testAddFieldDefinition')] + public function testAddFieldDefinitionThrowsBadStateExceptionNonRepeatableField(): void { $this->expectException(BadStateException::class); $this->expectExceptionMessage('The content type already contains a Field definition of the singular Field Type \'ibexa_user\''); @@ -1838,10 +1698,8 @@ public function testAddFieldDefinitionThrowsBadStateExceptionNonRepeatableField( * * Testing that field definition of non-repeatable field type can not be added multiple * times to the same ContentTypeCreateStruct. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentType() */ - public function testCreateContentThrowsContentTypeValidationException() + public function testCreateContentThrowsContentTypeValidationException(): void { $this->expectException(ContentTypeValidationException::class); $this->expectExceptionMessage('Field Type \'ibexa_user\' is singular and cannot be used more than once in a content type'); @@ -1891,12 +1749,9 @@ public function testCreateContentThrowsContentTypeValidationException() * * Testing adding field definition of the field type that can not be added to the ContentType that * already has Content instances. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::addFieldDefinition() - * - * @depends testAddFieldDefinition */ - public function testAddFieldDefinitionThrowsBadStateExceptionContentInstances() + #[Depends('testAddFieldDefinition')] + public function testAddFieldDefinitionThrowsBadStateExceptionContentInstances(): void { $this->expectException(BadStateException::class); $this->expectExceptionMessage('A Field definition of the \'ibexa_user\' Field Type cannot be added because the content type already has Content items'); @@ -1933,11 +1788,8 @@ public function testAddFieldDefinitionThrowsBadStateExceptionContentInstances() * Test for the removeFieldDefinition() method. * * @return array - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::removeFieldDefinition() - * - * @depends testCreateContentType */ + #[Depends('testCreateContentType')] public function testRemoveFieldDefinition() { $repository = $this->getRepository(); @@ -1968,12 +1820,9 @@ public function testRemoveFieldDefinition() * Test for the removeFieldDefinition() method. * * @param array $data - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::removeFieldDefinition() - * - * @depends testRemoveFieldDefinition */ - public function testRemoveFieldDefinitionRemoved(array $data) + #[Depends('testRemoveFieldDefinition')] + public function testRemoveFieldDefinitionRemoved(array $data): void { $removedFieldDefinition = $data['removedFieldDefinition']; $loadedType = $data['loadedType']; @@ -1992,12 +1841,9 @@ public function testRemoveFieldDefinitionRemoved(array $data) /** * Test for the removeFieldDefinition() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::removeFieldDefinition() - * - * @depends testRemoveFieldDefinition */ - public function testRemoveFieldDefinitionThrowsInvalidArgumentException() + #[Depends('testRemoveFieldDefinition')] + public function testRemoveFieldDefinitionThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -2019,12 +1865,9 @@ public function testRemoveFieldDefinitionThrowsInvalidArgumentException() /** * Test removeFieldDefinition() method for field in a different draft throws an exception. - * - * @depends testRemoveFieldDefinition - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::removeFieldDefinition */ - public function testRemoveFieldDefinitionThrowsInvalidArgumentExceptionOnWrongDraft() + #[Depends('testRemoveFieldDefinition')] + public function testRemoveFieldDefinitionThrowsInvalidArgumentExceptionOnWrongDraft(): void { $this->expectException(InvalidArgumentException::class); @@ -2042,11 +1885,8 @@ public function testRemoveFieldDefinitionThrowsInvalidArgumentExceptionOnWrongDr /** * Test for the removeFieldDefinition() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::removeFieldDefinition() - * - * @depends testRemoveFieldDefinition */ + #[Depends('testRemoveFieldDefinition')] public function testRemoveFieldDefinitionRemovesFieldFromContent() { $repository = $this->getRepository(); @@ -2113,12 +1953,9 @@ public function testRemoveFieldDefinitionRemovesFieldFromContent() * Test for the removeFieldDefinition() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content[] $data - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::removeFieldDefinition - * - * @depends testRemoveFieldDefinitionRemovesFieldFromContent */ - public function testRemoveFieldDefinitionRemovesFieldFromContentRemoved($data) + #[Depends('testRemoveFieldDefinitionRemovesFieldFromContent')] + public function testRemoveFieldDefinitionRemovesFieldFromContentRemoved($data): void { list( $contentVersion1Archived, @@ -2142,11 +1979,8 @@ public function testRemoveFieldDefinitionRemovesFieldFromContentRemoved($data) /** * Test for the addFieldDefinition() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::addFieldDefinition() - * - * @depends testAddFieldDefinition */ + #[Depends('testAddFieldDefinition')] public function testAddFieldDefinitionAddsFieldToContent() { $repository = $this->getRepository(); @@ -2234,12 +2068,9 @@ public function testAddFieldDefinitionAddsFieldToContent() * Test for the addFieldDefinition() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content[] $data - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::addFieldDefinition() - * - * @depends testAddFieldDefinitionAddsFieldToContent */ - public function testAddFieldDefinitionAddsFieldToContentAdded(array $data) + #[Depends('testAddFieldDefinitionAddsFieldToContent')] + public function testAddFieldDefinitionAddsFieldToContentAdded(array $data): void { list( $contentVersion1Archived, @@ -2272,8 +2103,6 @@ public function testAddFieldDefinitionAddsFieldToContentAdded(array $data) /** * Test for the newFieldDefinitionUpdateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::newFieldDefinitionUpdateStruct() */ public function testNewFieldDefinitionUpdateStruct() { @@ -2296,13 +2125,12 @@ public function testNewFieldDefinitionUpdateStruct() /** * Test for the newFieldDefinitionUpdateStruct() method. * - * @depends testNewFieldDefinitionUpdateStruct * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::newContentTypeUpdateStruct * * @param \Ibexa\Contracts\Core\Repository\Values\ContentType\FieldDefinitionUpdateStruct $fieldDefinitionUpdateStruct */ - public function testNewFieldDefinitionUpdateStructValues($fieldDefinitionUpdateStruct) + #[Depends('testNewFieldDefinitionUpdateStruct')] + public function testNewFieldDefinitionUpdateStructValues($fieldDefinitionUpdateStruct): void { foreach ($fieldDefinitionUpdateStruct as $propertyName => $propertyValue) { self::assertNull( @@ -2316,11 +2144,8 @@ public function testNewFieldDefinitionUpdateStructValues($fieldDefinitionUpdateS * Test for the updateFieldDefinition() method. * * @return array - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateFieldDefinition() - * - * @depends testLoadContentTypeDraft */ + #[Depends('testLoadContentTypeDraft')] public function testUpdateFieldDefinition() { $repository = $this->getRepository(); @@ -2372,10 +2197,7 @@ public function testUpdateFieldDefinition() ]; } - /** - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateFieldDefinition - */ - public function testUpdateFieldDefinitionWithNewTranslation() + public function testUpdateFieldDefinitionWithNewTranslation(): void { $repository = $this->getRepository(); $contentTypeService = $repository->getContentTypeService(); @@ -2440,12 +2262,9 @@ public function testUpdateFieldDefinitionWithNewTranslation() * Test for the updateFieldDefinition() method. * * @param array $data - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateFieldDefinition() - * - * @depends testUpdateFieldDefinition */ - public function testUpdateFieldDefinitionStructValues(array $data) + #[Depends('testUpdateFieldDefinition')] + public function testUpdateFieldDefinitionStructValues(array $data): void { $originalField = $data['originalField']; $updatedField = $data['updatedField']; @@ -2473,11 +2292,8 @@ public function testUpdateFieldDefinitionStructValues(array $data) /** * Test for the updateFieldDefinition() method using an empty FieldDefinitionUpdateStruct. - * - * @covers \Ibexa\Contracts\Core\Repository\Values\ContentType\FieldDefinitionUpdateStruct - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateFieldDefinition */ - public function testUpdateFieldDefinitionWithEmptyStruct() + public function testUpdateFieldDefinitionWithEmptyStruct(): void { $repository = $this->getRepository(); $contentTypeService = $repository->getContentTypeService(); @@ -2502,10 +2318,8 @@ public function testUpdateFieldDefinitionWithEmptyStruct() /** * Test for the updateFieldDefinition() method with already defined field identifier. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateFieldDefinition */ - public function testUpdateFieldDefinitionThrowsInvalidArgumentExceptionFieldIdentifierExists() + public function testUpdateFieldDefinitionThrowsInvalidArgumentExceptionFieldIdentifierExists(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Argument \'$fieldDefinitionUpdateStruct\' is invalid: Another Field definition with identifier \'title\' exists in the content type'); @@ -2533,12 +2347,9 @@ public function testUpdateFieldDefinitionThrowsInvalidArgumentExceptionFieldIden /** * Test for the updateFieldDefinition() method trying to update non-existent field. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateFieldDefinition() - * - * @depends testLoadContentTypeDraft */ - public function testUpdateFieldDefinitionThrowsInvalidArgumentExceptionForUndefinedField() + #[Depends('testLoadContentTypeDraft')] + public function testUpdateFieldDefinitionThrowsInvalidArgumentExceptionForUndefinedField(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Argument \'$fieldDefinition\' is invalid: The given Field definition does not belong to the content type'); @@ -2567,12 +2378,9 @@ public function testUpdateFieldDefinitionThrowsInvalidArgumentExceptionForUndefi /** * Test for the publishContentTypeDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::publishContentTypeDraft() - * - * @depends testLoadContentTypeDraft */ - public function testPublishContentTypeDraft() + #[Depends('testLoadContentTypeDraft')] + public function testPublishContentTypeDraft(): void { $repository = $this->getRepository(); $contentTypeService = $repository->getContentTypeService(); @@ -2597,12 +2405,9 @@ public function testPublishContentTypeDraft() /** * Test for the publishContentTypeDraft() method setting proper ContentType nameSchema. - * - * @depends testPublishContentTypeDraft - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::publishContentTypeDraft */ - public function testPublishContentTypeDraftSetsNameSchema() + #[Depends('testPublishContentTypeDraft')] + public function testPublishContentTypeDraftSetsNameSchema(): void { $repository = $this->getRepository(); $contentTypeService = $repository->getContentTypeService(); @@ -2635,10 +2440,8 @@ public function testPublishContentTypeDraftSetsNameSchema() /** * Test that publishing content type Draft refreshes list of content types in content type groups. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::publishContentTypeDraft */ - public function testPublishContentTypeDraftRefreshesContentTypesList() + public function testPublishContentTypeDraftRefreshesContentTypesList(): void { $repository = $this->getRepository(); $contentTypeService = $repository->getContentTypeService(); @@ -2689,12 +2492,9 @@ static function (ContentType $contentType) { /** * Test for the publishContentTypeDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::publishContentTypeDraft() - * - * @depends testPublishContentTypeDraft */ - public function testPublishContentTypeDraftThrowsBadStateException() + #[Depends('testPublishContentTypeDraft')] + public function testPublishContentTypeDraftThrowsBadStateException(): void { $this->expectException(BadStateException::class); @@ -2713,12 +2513,9 @@ public function testPublishContentTypeDraftThrowsBadStateException() /** * Test for the createContentTypeGroup() method trying to create content type without any fields. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::publishContentTypeDraft() - * - * @depends testPublishContentTypeDraft */ - public function testPublishContentTypeDraftThrowsInvalidArgumentExceptionWithoutFields() + #[Depends('testPublishContentTypeDraft')] + public function testPublishContentTypeDraftThrowsInvalidArgumentExceptionWithoutFields(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Argument \'$contentTypeDraft\' is invalid: The content type draft should have at least one Field definition'); @@ -2748,14 +2545,10 @@ public function testPublishContentTypeDraftThrowsInvalidArgumentExceptionWithout /** * Test for the loadContentType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentType() - * - * @depends testCreateContentType - * - * @group user - * @group field-type */ + #[Depends('testCreateContentType')] + #[Group('user')] + #[Group('field-type')] public function testLoadContentType() { $repository = $this->getRepository(); @@ -2779,11 +2572,11 @@ public function testLoadContentType() /** * Test that multi-language logic respects prioritized language list. * - * @dataProvider getPrioritizedLanguageList * * @param string[] $languageCodes */ - public function testLoadContentTypeWithPrioritizedLanguagesList(array $languageCodes) + #[DataProvider('getPrioritizedLanguageList')] + public function testLoadContentTypeWithPrioritizedLanguagesList(array $languageCodes): void { $repository = $this->getRepository(); $contentTypeService = $repository->getContentTypeService(); @@ -2818,7 +2611,7 @@ public function testLoadContentTypeWithPrioritizedLanguagesList(array $languageC /** * @return array */ - public function getPrioritizedLanguageList() + public static function getPrioritizedLanguageList(): array { return [ [[]], @@ -2831,11 +2624,8 @@ public function getPrioritizedLanguageList() /** * Test for the loadContentType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentType() - * - * @depends testLoadContentType */ + #[Depends('testLoadContentType')] public function testLoadContentTypeStructValues($userGroupType) { $repository = $this->getRepository(); @@ -2873,12 +2663,9 @@ public function testLoadContentTypeStructValues($userGroupType) /** * Test for the loadContentType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentType() - * - * @depends testLoadContentTypeStructValues */ - public function testLoadContentTypeFieldDefinitions(APIFieldDefinitionCollection $fieldDefinitions) + #[Depends('testLoadContentTypeStructValues')] + public function testLoadContentTypeFieldDefinitions(APIFieldDefinitionCollection $fieldDefinitions): void { $expectedFieldDefinitions = [ 'name' => [ @@ -2969,12 +2756,9 @@ static function ($fieldDefinition) { /** * Test for the loadContentType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentType() - * - * @depends testLoadContentType */ - public function testLoadContentTypeThrowsNotFoundException() + #[Depends('testLoadContentType')] + public function testLoadContentTypeThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -2993,13 +2777,9 @@ public function testLoadContentTypeThrowsNotFoundException() * Test for the loadContentTypeByIdentifier() method. * * @return \Ibexa\Contracts\Core\Repository\Values\ContentType\ContentType - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypeByIdentifier() - * - * @depends testLoadContentType - * - * @group user */ + #[Depends('testLoadContentType')] + #[Group('user')] public function testLoadContentTypeByIdentifier() { $repository = $this->getRepository(); @@ -3022,12 +2802,9 @@ public function testLoadContentTypeByIdentifier() * Test for the loadContentTypeByIdentifier() method. * * @param \Ibexa\Contracts\Core\Repository\Values\ContentType\ContentType $contentType - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypeByIdentifier() - * - * @depends testLoadContentTypeByIdentifier */ - public function testLoadContentTypeByIdentifierReturnsCorrectInstance($contentType) + #[Depends('testLoadContentTypeByIdentifier')] + public function testLoadContentTypeByIdentifierReturnsCorrectInstance($contentType): void { $repository = $this->getRepository(); $contentTypeService = $repository->getContentTypeService(); @@ -3040,12 +2817,9 @@ public function testLoadContentTypeByIdentifierReturnsCorrectInstance($contentTy /** * Test for the loadContentTypeByIdentifier() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypeByIdentifier() - * - * @depends testLoadContentTypeByIdentifier */ - public function testLoadContentTypeByIdentifierThrowsNotFoundException() + #[Depends('testLoadContentTypeByIdentifier')] + public function testLoadContentTypeByIdentifierThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -3061,11 +2835,8 @@ public function testLoadContentTypeByIdentifierThrowsNotFoundException() /** * Test for the loadContentTypeByRemoteId() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypeByRemoteId() - * - * @depends testLoadContentType */ + #[Depends('testLoadContentType')] public function testLoadContentTypeByRemoteId() { $repository = $this->getRepository(); @@ -3089,12 +2860,9 @@ public function testLoadContentTypeByRemoteId() /** * Test for the loadContentTypeByRemoteId() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypeByRemoteId() - * - * @depends testLoadContentTypeByRemoteId */ - public function testLoadContentTypeByRemoteIdReturnsCorrectInstance($contentType) + #[Depends('testLoadContentTypeByRemoteId')] + public function testLoadContentTypeByRemoteIdReturnsCorrectInstance($contentType): void { $repository = $this->getRepository(); $contentTypeService = $repository->getContentTypeService(); @@ -3107,12 +2875,9 @@ public function testLoadContentTypeByRemoteIdReturnsCorrectInstance($contentType /** * Test for the loadContentTypeByRemoteId() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypeByRemoteId() - * - * @depends testLoadContentType */ - public function testLoadContentTypeByRemoteIdThrowsNotFoundException() + #[Depends('testLoadContentType')] + public function testLoadContentTypeByRemoteIdThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -3128,12 +2893,9 @@ public function testLoadContentTypeByRemoteIdThrowsNotFoundException() /** * Test for the loadContentTypeList() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypeList() - * - * @depends testLoadContentType */ - public function testLoadContentTypeList() + #[Depends('testLoadContentType')] + public function testLoadContentTypeList(): void { $repository = $this->getRepository(); $contentTypeService = $repository->getContentTypeService(); @@ -3153,11 +2915,8 @@ public function testLoadContentTypeList() /** * Test for the loadContentTypes() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypes() - * - * @depends testLoadContentType */ + #[Depends('testLoadContentType')] public function testLoadContentTypes() { $repository = $this->getRepository(); @@ -3180,12 +2939,9 @@ public function testLoadContentTypes() /** * Test for the loadContentTypes() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::loadContentTypes() - * - * @depends testLoadContentTypes */ - public function testLoadContentTypesContent(array $types) + #[Depends('testLoadContentTypes')] + public function testLoadContentTypesContent(array $types): void { $repository = $this->getRepository(); $contentTypeService = $repository->getContentTypeService(); @@ -3211,11 +2967,8 @@ static function ($a, $b): int { /** * Test for the createContentTypeDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentTypeDraft() - * - * @depends testLoadContentType */ + #[Depends('testLoadContentType')] public function testCreateContentTypeDraft() { $repository = $this->getRepository(); @@ -3241,11 +2994,8 @@ public function testCreateContentTypeDraft() /** * Test for the createContentTypeDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentTypeDraft() - * - * @depends testCreateContentTypeDraft */ + #[Depends('testCreateContentTypeDraft')] public function testCreateContentTypeDraftStructValues(array $data) { $originalType = $data['originalType']; @@ -3294,12 +3044,9 @@ public function testCreateContentTypeDraftStructValues(array $data) /** * Test for the createContentTypeDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentTypeDraft() - * - * @depends testCreateContentTypeDraftStructValues */ - public function testCreateContentTypeDraftStructLanguageDependentValues(array $data) + #[Depends('testCreateContentTypeDraftStructValues')] + public function testCreateContentTypeDraftStructLanguageDependentValues(array $data): void { $originalType = $data['originalType']; $typeDraft = $data['typeDraft']; @@ -3318,12 +3065,9 @@ public function testCreateContentTypeDraftStructLanguageDependentValues(array $d /** * Test for the createContentTypeDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentTypeDraft() - * - * @depends testCreateContentTypeDraft */ - public function testCreateContentTypeDraftThrowsBadStateException() + #[Depends('testCreateContentTypeDraft')] + public function testCreateContentTypeDraftThrowsBadStateException(): void { $this->expectException(BadStateException::class); @@ -3343,12 +3087,9 @@ public function testCreateContentTypeDraftThrowsBadStateException() /** * Test for the deleteContentType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::deleteContentType() - * - * @depends testLoadContentTypeByIdentifier */ - public function testDeleteContentType() + #[Depends('testLoadContentTypeByIdentifier')] + public function testDeleteContentType(): void { $this->expectException(NotFoundException::class); @@ -3368,12 +3109,9 @@ public function testDeleteContentType() /** * Test for the deleteContentType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::deleteContentType() - * - * @depends testDeleteContentType */ - public function testDeleteContentTypeThrowsBadStateException() + #[Depends('testDeleteContentType')] + public function testDeleteContentTypeThrowsBadStateException(): void { $this->expectException(BadStateException::class); @@ -3394,11 +3132,8 @@ public function testDeleteContentTypeThrowsBadStateException() * Test for the copyContentType() method. * * @return array - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::copyContentType() - * - * @depends testLoadContentTypeByIdentifier */ + #[Depends('testLoadContentTypeByIdentifier')] public function testCopyContentType() { $repository = $this->getRepository(); @@ -3441,12 +3176,9 @@ public function testCopyContentType() * Test for the copyContentType() method. * * @param array $data - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::copyContentType() - * - * @depends testCopyContentType */ - public function testCopyContentTypeStructValues(array $data) + #[Depends('testCopyContentType')] + public function testCopyContentTypeStructValues(array $data): void { $originalType = $data['originalType']; $copiedType = $data['copiedType']; @@ -3532,12 +3264,9 @@ private function assertCopyContentTypeValues($originalType, $copiedType, $exclud /** * Test for the copyContentType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::copyContentType($contentType, $user) - * - * @depends testCopyContentType */ - public function testCopyContentTypeWithSecondParameter() + #[Depends('testCopyContentType')] + public function testCopyContentTypeWithSecondParameter(): void { $repository = $this->getRepository(); @@ -3564,14 +3293,11 @@ public function testCopyContentTypeWithSecondParameter() /** * Test for the assignContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::assignContentTypeGroup() - * - * @depends testLoadContentTypeGroupByIdentifier - * @depends testLoadContentTypeByIdentifier - * @depends testLoadContentType */ - public function testAssignContentTypeGroup() + #[Depends('testLoadContentTypeGroupByIdentifier')] + #[Depends('testLoadContentTypeByIdentifier')] + #[Depends('testLoadContentType')] + public function testAssignContentTypeGroup(): void { $repository = $this->getRepository(); @@ -3601,12 +3327,9 @@ public function testAssignContentTypeGroup() /** * Test for the assignContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::assignContentTypeGroup() - * - * @depends testAssignContentTypeGroup */ - public function testAssignContentTypeGroupThrowsInvalidArgumentException() + #[Depends('testAssignContentTypeGroup')] + public function testAssignContentTypeGroupThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -3627,12 +3350,9 @@ public function testAssignContentTypeGroupThrowsInvalidArgumentException() /** * Test for the unassignContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::unassignContentTypeGroup() - * - * @depends testAssignContentTypeGroup */ - public function testUnassignContentTypeGroup() + #[Depends('testAssignContentTypeGroup')] + public function testUnassignContentTypeGroup(): void { $repository = $this->getRepository(); @@ -3666,12 +3386,9 @@ public function testUnassignContentTypeGroup() /** * Test for the unassignContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::unassignContentTypeGroup() - * - * @depends testUnassignContentTypeGroup */ - public function testUnassignContentTypeGroupThrowsInvalidArgumentException() + #[Depends('testUnassignContentTypeGroup')] + public function testUnassignContentTypeGroupThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -3690,12 +3407,9 @@ public function testUnassignContentTypeGroupThrowsInvalidArgumentException() /** * Test for the unassignContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::unassignContentTypeGroup() - * - * @depends testUnassignContentTypeGroup */ - public function testUnassignContentTypeGroupThrowsBadStateException() + #[Depends('testUnassignContentTypeGroup')] + public function testUnassignContentTypeGroupThrowsBadStateException(): void { $this->expectException(BadStateException::class); @@ -3716,13 +3430,10 @@ public function testUnassignContentTypeGroupThrowsBadStateException() /** * Test for the createContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentTypeGroup() - * - * @depends testLoadContentTypeGroup - * @depends testCreateContentTypeGroup */ - public function testCreateContentTypeGroupInTransactionWithRollback() + #[Depends('testLoadContentTypeGroup')] + #[Depends('testCreateContentTypeGroup')] + public function testCreateContentTypeGroupInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -3763,13 +3474,10 @@ public function testCreateContentTypeGroupInTransactionWithRollback() /** * Test for the createContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentTypeGroup() - * - * @depends testLoadContentTypeGroup - * @depends testCreateContentTypeGroup */ - public function testCreateContentTypeGroupInTransactionWithCommit() + #[Depends('testLoadContentTypeGroup')] + #[Depends('testCreateContentTypeGroup')] + public function testCreateContentTypeGroupInTransactionWithCommit(): void { $repository = $this->getRepository(); @@ -3806,13 +3514,10 @@ public function testCreateContentTypeGroupInTransactionWithCommit() /** * Test for the updateContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateContentTypeGroup() - * - * @depends testUpdateContentTypeGroup - * @depends testLoadContentTypeGroupByIdentifier */ - public function testUpdateContentTypeGroupInTransactionWithRollback() + #[Depends('testUpdateContentTypeGroup')] + #[Depends('testLoadContentTypeGroupByIdentifier')] + public function testUpdateContentTypeGroupInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -3850,13 +3555,10 @@ public function testUpdateContentTypeGroupInTransactionWithRollback() /** * Test for the updateContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateContentTypeGroup() - * - * @depends testUpdateContentTypeGroup - * @depends testLoadContentTypeGroupByIdentifier */ - public function testUpdateContentTypeGroupInTransactionWithCommit() + #[Depends('testUpdateContentTypeGroup')] + #[Depends('testLoadContentTypeGroupByIdentifier')] + public function testUpdateContentTypeGroupInTransactionWithCommit(): void { $repository = $this->getRepository(); @@ -3896,13 +3598,10 @@ public function testUpdateContentTypeGroupInTransactionWithCommit() /** * Test for the deleteContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::deleteContentTypeGroup() - * - * @depends testDeleteContentTypeGroup - * @depends testLoadContentTypeGroupByIdentifierThrowsNotFoundException */ - public function testDeleteContentTypeGroupWithRollback() + #[Depends('testDeleteContentTypeGroup')] + #[Depends('testLoadContentTypeGroupByIdentifierThrowsNotFoundException')] + public function testDeleteContentTypeGroupWithRollback(): void { $repository = $this->getRepository(); @@ -3945,13 +3644,10 @@ public function testDeleteContentTypeGroupWithRollback() /** * Test for the deleteContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::deleteContentTypeGroup() - * - * @depends testDeleteContentTypeGroup - * @depends testLoadContentTypeGroupByIdentifierThrowsNotFoundException */ - public function testDeleteContentTypeGroupWithCommit() + #[Depends('testDeleteContentTypeGroup')] + #[Depends('testLoadContentTypeGroupByIdentifierThrowsNotFoundException')] + public function testDeleteContentTypeGroupWithCommit(): void { $repository = $this->getRepository(); @@ -3994,13 +3690,10 @@ public function testDeleteContentTypeGroupWithCommit() /** * Test for the createContentType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentType() - * - * @depends testCreateContentType - * @depends testLoadContentTypeByIdentifierThrowsNotFoundException */ - public function testCreateContentTypeInTransactionWithRollback() + #[Depends('testCreateContentType')] + #[Depends('testLoadContentTypeByIdentifierThrowsNotFoundException')] + public function testCreateContentTypeInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -4055,13 +3748,10 @@ public function testCreateContentTypeInTransactionWithRollback() /** * Test for the createContentType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::createContentType() - * - * @depends testCreateContentType - * @depends testLoadContentTypeByIdentifierThrowsNotFoundException */ - public function testCreateContentTypeInTransactionWithCommit() + #[Depends('testCreateContentType')] + #[Depends('testLoadContentTypeByIdentifierThrowsNotFoundException')] + public function testCreateContentTypeInTransactionWithCommit(): void { $repository = $this->getRepository(); @@ -4112,14 +3802,11 @@ public function testCreateContentTypeInTransactionWithCommit() /** * Test for the copyContentType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::copyContentType() - * - * @depends testCopyContentType - * @depends testLoadContentTypeByIdentifier - * @depends testLoadContentTypeThrowsNotFoundException */ - public function testCopyContentTypeInTransactionWithRollback() + #[Depends('testCopyContentType')] + #[Depends('testLoadContentTypeByIdentifier')] + #[Depends('testLoadContentTypeThrowsNotFoundException')] + public function testCopyContentTypeInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -4157,14 +3844,11 @@ public function testCopyContentTypeInTransactionWithRollback() /** * Test for the copyContentType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::copyContentType() - * - * @depends testCopyContentType - * @depends testLoadContentTypeByIdentifier - * @depends testLoadContentTypeThrowsNotFoundException */ - public function testCopyContentTypeInTransactionWithCommit() + #[Depends('testCopyContentType')] + #[Depends('testLoadContentTypeByIdentifier')] + #[Depends('testLoadContentTypeThrowsNotFoundException')] + public function testCopyContentTypeInTransactionWithCommit(): void { $repository = $this->getRepository(); @@ -4198,13 +3882,10 @@ public function testCopyContentTypeInTransactionWithCommit() /** * Test for the deleteContentType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::deleteContentType() - * - * @depends testCopyContentType - * @depends testLoadContentTypeByIdentifierThrowsNotFoundException */ - public function testDeleteContentTypeInTransactionWithRollback() + #[Depends('testCopyContentType')] + #[Depends('testLoadContentTypeByIdentifierThrowsNotFoundException')] + public function testDeleteContentTypeInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -4238,13 +3919,10 @@ public function testDeleteContentTypeInTransactionWithRollback() /** * Test for the deleteContentType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::deleteContentType() - * - * @depends testCopyContentType - * @depends testLoadContentTypeByIdentifierThrowsNotFoundException */ - public function testDeleteContentTypeInTransactionWithCommit() + #[Depends('testCopyContentType')] + #[Depends('testLoadContentTypeByIdentifierThrowsNotFoundException')] + public function testDeleteContentTypeInTransactionWithCommit(): void { $repository = $this->getRepository(); @@ -4282,12 +3960,9 @@ public function testDeleteContentTypeInTransactionWithCommit() /** * Test for the assignContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::assignContentTypeGroup() - * - * @depends testAssignContentTypeGroup */ - public function testAssignContentTypeGroupInTransactionWithRollback() + #[Depends('testAssignContentTypeGroup')] + public function testAssignContentTypeGroupInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -4329,12 +4004,9 @@ public function testAssignContentTypeGroupInTransactionWithRollback() /** * Test for the assignContentTypeGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::assignContentTypeGroup() - * - * @depends testAssignContentTypeGroup */ - public function testAssignContentTypeGroupInTransactionWithCommit() + #[Depends('testAssignContentTypeGroup')] + public function testAssignContentTypeGroupInTransactionWithCommit(): void { $repository = $this->getRepository(); @@ -4376,10 +4048,8 @@ public function testAssignContentTypeGroupInTransactionWithCommit() /** * Test for the isContentTypeUsed() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::isContentTypeUsed() */ - public function testIsContentTypeUsed() + public function testIsContentTypeUsed(): void { $repository = $this->getRepository(); @@ -4398,14 +4068,12 @@ public function testIsContentTypeUsed() } /** - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::removeContentTypeTranslation - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ - public function testRemoveContentTypeTranslation() + public function testRemoveContentTypeTranslation(): void { $repository = $this->getRepository(); $contentTypeService = $repository->getContentTypeService(); @@ -4440,14 +4108,12 @@ public function testRemoveContentTypeTranslation() } /** - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::removeContentTypeTranslation - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ - public function testRemoveContentTypeTranslationWithMultilingualData() + public function testRemoveContentTypeTranslationWithMultilingualData(): void { $repository = $this->getRepository(); $contentTypeService = $repository->getContentTypeService(); @@ -4503,13 +4169,11 @@ public function testRemoveContentTypeTranslationWithMultilingualData() } /** - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::updateContentTypeDraft - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ - public function testUpdateContentTypeDraftWithNewTranslationWithMultilingualData() + public function testUpdateContentTypeDraftWithNewTranslationWithMultilingualData(): void { $repository = $this->getRepository(); $contentTypeService = $repository->getContentTypeService(); @@ -4635,10 +4299,8 @@ public function testUpdateContentTypeDraftWithNewTranslationWithMultilingualData /** * Test for the deleteUserDrafts() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentTypeService::deleteUserDrafts() */ - public function testDeleteUserDrafts() + public function testDeleteUserDrafts(): void { $this->expectException(NotFoundException::class); diff --git a/tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php b/tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php index 6342258050..66602f88f3 100644 --- a/tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/AuthorIntegrationTest.php @@ -13,13 +13,13 @@ use Ibexa\Core\FieldType\Author\AuthorCollection; use Ibexa\Core\FieldType\Author\Type; use Ibexa\Core\FieldType\Author\Value as AuthorValue; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] class AuthorIntegrationTest extends SearchMultivaluedBaseIntegrationTestCase { /** @@ -188,7 +188,7 @@ public function assertFieldDataLoadedCorrect(Field $field) * * @return array[] */ - public function provideInvalidCreationFieldData() + public static function provideInvalidCreationFieldData(): array { return [ ['Sindelfingen', InvalidArgumentException::class], @@ -248,9 +248,9 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidUpdateFieldData() + public static function provideInvalidUpdateFieldData(): array { - return $this->provideInvalidCreationFieldData(); + return self::provideInvalidCreationFieldData(); } /** @@ -307,7 +307,7 @@ public function assertCopiedFieldDataLoadedCorrectly(Field $field) * * @return array */ - public function provideToHashData() + public static function provideToHashData(): array { return [ [ @@ -340,7 +340,7 @@ public function provideToHashData() * * @return array */ - public function provideFromHashData() + public static function provideFromHashData(): array { return [ [ @@ -366,7 +366,10 @@ public function provideFromHashData() ]; } - public function providerForTestIsEmptyValue() + /** + * @return array + */ + public static function providerForTestIsEmptyValue(): array { return [ [new AuthorValue()], @@ -374,11 +377,24 @@ public function providerForTestIsEmptyValue() ]; } - public function providerForTestIsNotEmptyValue() + /** + * @return array + */ + public static function providerForTestIsNotEmptyValue(): array { return [ [ - $this->getValidCreationFieldData(), + new AuthorValue( + [ + new Author( + [ + 'id' => 23, + 'name' => 'Hans Mueller', + 'email' => 'hans@example.com', + ] + ), + ] + ), ], [ new AuthorValue( @@ -396,7 +412,7 @@ public function providerForTestIsNotEmptyValue() ]; } - protected function getValidSearchValueOne() + protected static function getValidSearchValueOne() { return [ new Author( @@ -409,7 +425,7 @@ protected function getValidSearchValueOne() ]; } - protected function getValidSearchValueTwo() + protected static function getValidSearchValueTwo() { return [ new Author( @@ -422,17 +438,17 @@ protected function getValidSearchValueTwo() ]; } - protected function getSearchTargetValueOne(): string + protected static function getSearchTargetValueOne(): string { return 'Ferdinand'; } - protected function getSearchTargetValueTwo(): string + protected static function getSearchTargetValueTwo(): string { return 'Greta'; } - protected function getAdditionallyIndexedFieldData() + protected static function getAdditionallyIndexedFieldData() { return [ [ @@ -453,7 +469,7 @@ protected function getAdditionallyIndexedFieldData() ]; } - protected function getValidMultivaluedSearchValuesOne() + protected static function getValidMultivaluedSearchValuesOne() { return [ new Author( @@ -473,7 +489,7 @@ protected function getValidMultivaluedSearchValuesOne() ]; } - protected function getValidMultivaluedSearchValuesTwo() + protected static function getValidMultivaluedSearchValuesTwo() { return [ new Author( @@ -500,17 +516,17 @@ protected function getValidMultivaluedSearchValuesTwo() ]; } - protected function getMultivaluedSearchTargetValuesOne() + protected static function getMultivaluedSearchTargetValuesOne() { return ['Antoinette', 'Ferdinand']; } - protected function getMultivaluedSearchTargetValuesTwo() + protected static function getMultivaluedSearchTargetValuesTwo() { return ['Greta', 'Leopold', 'Maximilian']; } - protected function getAdditionallyIndexedMultivaluedFieldData() + protected static function getAdditionallyIndexedMultivaluedFieldData() { return [ [ @@ -526,7 +542,7 @@ protected function getAdditionallyIndexedMultivaluedFieldData() ]; } - protected function getFullTextIndexedFieldData() + protected static function getFullTextIndexedFieldData() { return [ ['Ferdinand', 'Greta'], diff --git a/tests/integration/Core/Repository/FieldType/BaseBinaryFileIntegrationTestCaseCase.php b/tests/integration/Core/Repository/FieldType/BaseBinaryFileIntegrationTestCaseCase.php index ce0eafd88a..c89ee12e42 100644 --- a/tests/integration/Core/Repository/FieldType/BaseBinaryFileIntegrationTestCaseCase.php +++ b/tests/integration/Core/Repository/FieldType/BaseBinaryFileIntegrationTestCaseCase.php @@ -35,30 +35,30 @@ abstract public function asserFieldValueIsCorrectInstance(Field $field): void; /** * @phpstan-return TFixtureDataHash */ - abstract protected function getFixtureData(): array; + abstract protected static function getFixtureData(): array; - abstract protected function buildBinaryFileValue(string $fileId): BinaryBaseValue; + abstract protected static function buildBinaryFileValue(string $fileId): BinaryBaseValue; /** * @phpstan-return list */ - abstract public function provideFromHashData(): array; + abstract public static function provideFromHashData(): array; /** * @phpstan-return list */ - abstract public function provideToHashData(): array; + abstract public static function provideToHashData(): array; /** * @phpstan-param TBaseBinaryFileFieldValueHash $fileFieldValueData */ - abstract protected function buildBinaryFileValueFromFixtureData(array $fileFieldValueData): BinaryBaseValue; + abstract protected static function buildBinaryFileValueFromFixtureData(array $fileFieldValueData): BinaryBaseValue; public function assertFieldDataLoadedCorrect(Field $field): void { $this->asserFieldValueIsCorrectInstance($field); - $fixtureData = $this->getFixtureData(); + $fixtureData = static::getFixtureData(); $this->assertCreatedUpdatedBinaryFieldDataLoadedCorrectly($fixtureData['create'], $field); } @@ -66,7 +66,7 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field): void { $this->asserFieldValueIsCorrectInstance($field); - $fixtureData = $this->getFixtureData(); + $fixtureData = static::getFixtureData(); $this->assertCreatedUpdatedBinaryFieldDataLoadedCorrectly($fixtureData['update'], $field); } @@ -137,7 +137,7 @@ public function getFieldName(): string /** * @return list */ - public function provideInvalidCreationFieldData(): array + public static function provideInvalidCreationFieldData(): array { return [ [ @@ -147,7 +147,7 @@ public function provideInvalidCreationFieldData(): array InvalidArgumentValue::class, ], [ - $this->buildBinaryFileValue(self::FOO_BAR_SAMPLE_FILE_PATH), + static::buildBinaryFileValue(self::FOO_BAR_SAMPLE_FILE_PATH), InvalidArgumentValue::class, ], ]; @@ -155,26 +155,26 @@ public function provideInvalidCreationFieldData(): array public function getValidCreationFieldData(): BinaryBaseValue { - $fixtureData = $this->getFixtureData(); + $fixtureData = static::getFixtureData(); - return $this->buildBinaryFileValueFromFixtureData($fixtureData['create']); + return static::buildBinaryFileValueFromFixtureData($fixtureData['create']); } public function getValidUpdateFieldData(): BinaryBaseValue { - $fixtureData = $this->getFixtureData(); + $fixtureData = static::getFixtureData(); - return $this->buildBinaryFileValueFromFixtureData($fixtureData['update']); + return static::buildBinaryFileValueFromFixtureData($fixtureData['update']); } /** * @return list> */ - public function providerForTestIsNotEmptyValue(): array + public static function providerForTestIsNotEmptyValue(): array { return [ [ - $this->getValidCreationFieldData(), + static::buildBinaryFileValueFromFixtureData(static::getFixtureData()['create']), ], ]; } @@ -182,9 +182,9 @@ public function providerForTestIsNotEmptyValue(): array /** * @return list */ - public function provideInvalidUpdateFieldData(): array + public static function provideInvalidUpdateFieldData(): array { - return $this->provideInvalidCreationFieldData(); + return static::provideInvalidCreationFieldData(); } protected function getStoragePrefix(): string @@ -197,17 +197,17 @@ protected function getStoragePrefix(): string return $configValue; } - protected function getSearchTargetValueOne(): string + protected static function getSearchTargetValueOne(): string { - $value = $this->getValidSearchValueOne(); + $value = static::getValidSearchValueOne(); // ensure case-insensitivity return strtoupper($value->fileName); } - protected function getSearchTargetValueTwo(): string + protected static function getSearchTargetValueTwo(): string { - $value = $this->getValidSearchValueTwo(); + $value = static::getValidSearchValueTwo(); // ensure case-insensitivity return strtoupper($value->fileName); @@ -216,13 +216,13 @@ protected function getSearchTargetValueTwo(): string /** * @return list> */ - protected function getAdditionallyIndexedFieldData(): array + protected static function getAdditionallyIndexedFieldData(): array { return [ [ 'file_size', - $this->getValidSearchValueOne()->fileSize, - $this->getValidSearchValueTwo()->fileSize, + static::getValidSearchValueOne()->fileSize, + static::getValidSearchValueTwo()->fileSize, ], [ 'mime_type', diff --git a/tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php b/tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php index 0dc30df3ab..4ceb3cb805 100644 --- a/tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php +++ b/tests/integration/Core/Repository/FieldType/BaseIntegrationTestCase.php @@ -13,7 +13,13 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Content; use Ibexa\Contracts\Core\Repository\Values\Content\Field; use Ibexa\Contracts\Core\Repository\Values\ContentType\FieldDefinition; +use Ibexa\Core\FieldType\FieldType; +use Ibexa\Core\Repository\ContentService; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for legacy storage field types. @@ -37,11 +43,13 @@ * - Test toHash * - Test fromHash * - * @group integration - * @group field-type * * @todo Finalize dependencies to other tests (including groups!) */ +#[CoversClass(FieldType::class)] +#[CoversClass(ContentService::class)] +#[Group('integration')] +#[Group('field-type')] abstract class BaseIntegrationTestCase extends BaseTestCase { /** @@ -50,6 +58,13 @@ abstract class BaseIntegrationTestCase extends BaseTestCase */ public const VERSION_ARCHIVE_LIMIT = 5; + /** + * Sentinel value a {@see self::providerForTestIsEmptyValue()} override returns when the + * field type has no "empty" representation, since PHPUnit 11 treats an empty data provider + * as a hard error rather than a skip. + */ + protected const string NO_EMPTY_VALUE_DATA = '__no_empty_value_data__'; + /** * Identifier of the custom field. * @@ -151,7 +166,7 @@ abstract public function assertFieldDataLoadedCorrect(Field $field); * * @return array[] */ - abstract public function provideInvalidCreationFieldData(); + abstract public static function provideInvalidCreationFieldData(); /** * Get valid field data for updating content. @@ -191,7 +206,7 @@ abstract public function assertUpdatedFieldDataLoadedCorrect(Field $field); * * @return array[] */ - abstract public function provideInvalidUpdateFieldData(); + abstract public static function provideInvalidUpdateFieldData(); /** * Asserts the the field data was loaded correctly. @@ -223,7 +238,7 @@ abstract public function assertCopiedFieldDataLoadedCorrectly(Field $field); * * @return array */ - abstract public function provideToHashData(); + abstract public static function provideToHashData(); /** * Get hashes and their respective converted values. @@ -245,7 +260,7 @@ abstract public function provideToHashData(); * * @return array */ - abstract public function provideFromHashData(); + abstract public static function provideFromHashData(); /** * Method called after content creation. @@ -382,34 +397,28 @@ protected function getOverride($key, array $overrideValues, $default) return isset($overrideValues[$key]) ? $overrideValues[$key] : $default; } - /** - * @covers \Ibexa\Core\FieldType\FieldType::isEmptyValue - * - * @dataProvider providerForTestIsEmptyValue - */ - public function testIsEmptyValue($value) + #[DataProvider('providerForTestIsEmptyValue')] + public function testIsEmptyValue($value): void { + if ($value === self::NO_EMPTY_VALUE_DATA) { + self::markTestSkipped('This field type has no "empty" value representation.'); + } + self::assertTrue($this->getRepository()->getFieldTypeService()->getFieldType($this->getTypeName())->isEmptyValue($value)); } - abstract public function providerForTestIsEmptyValue(); + abstract public static function providerForTestIsEmptyValue(); - /** - * @covers \Ibexa\Core\FieldType\FieldType::isEmptyValue - * - * @dataProvider providerForTestIsNotEmptyValue - */ - public function testIsNotEmptyValue($value) + #[DataProvider('providerForTestIsNotEmptyValue')] + public function testIsNotEmptyValue($value): void { self::assertFalse($this->getRepository()->getFieldTypeService()->getFieldType($this->getTypeName())->isEmptyValue($value)); } - abstract public function providerForTestIsNotEmptyValue(); + abstract public static function providerForTestIsNotEmptyValue(); - /** - * @depends testCreateContentType - */ - public function testContentTypeField($contentType) + #[Depends('testCreateContentType')] + public function testContentTypeField($contentType): void { self::assertSame( $this->getTypeName(), @@ -417,9 +426,7 @@ public function testContentTypeField($contentType) ); } - /** - * @depends testCreateContentType - */ + #[Depends('testCreateContentType')] public function testLoadContentTypeField() { $contentType = $this->testCreateContentType(); @@ -430,9 +437,7 @@ public function testLoadContentTypeField() return $contentTypeService->loadContentType($contentType->id); } - /** - * @depends testLoadContentTypeField - */ + #[Depends('testLoadContentTypeField')] public function testLoadContentTypeFieldType($contentType) { self::assertSame( @@ -443,7 +448,7 @@ public function testLoadContentTypeFieldType($contentType) return $contentType->fieldDefinitions[1]; } - public function testSettingsSchema() + public function testSettingsSchema(): void { $repository = $this->getRepository(); $fieldTypeService = $repository->getFieldTypeService(); @@ -455,10 +460,8 @@ public function testSettingsSchema() ); } - /** - * @depends testLoadContentTypeFieldType - */ - public function testLoadContentTypeFieldData(FieldDefinition $fieldDefinition) + #[Depends('testLoadContentTypeFieldType')] + public function testLoadContentTypeFieldData(FieldDefinition $fieldDefinition): void { self::assertEquals( $this->getTypeName(), @@ -477,10 +480,8 @@ public function testLoadContentTypeFieldData(FieldDefinition $fieldDefinition) ); } - /** - * @depends testCreateContentType - */ - public function testCreateContentTypeFailsWithInvalidFieldSettings() + #[Depends('testCreateContentType')] + public function testCreateContentTypeFailsWithInvalidFieldSettings(): void { $this->expectException(ContentTypeFieldDefinitionValidationException::class); @@ -490,7 +491,7 @@ public function testCreateContentTypeFailsWithInvalidFieldSettings() ); } - public function testValidatorSchema() + public function testValidatorSchema(): void { $repository = $this->getRepository(); $fieldTypeService = $repository->getFieldTypeService(); @@ -502,10 +503,8 @@ public function testValidatorSchema() ); } - /** - * @depends testCreateContentType - */ - public function testCreateContentTypeFailsWithInvalidValidatorConfiguration() + #[Depends('testCreateContentType')] + public function testCreateContentTypeFailsWithInvalidValidatorConfiguration(): void { $this->expectException(ContentTypeFieldDefinitionValidationException::class); @@ -515,9 +514,7 @@ public function testCreateContentTypeFailsWithInvalidValidatorConfiguration() ); } - /** - * @depends testLoadContentTypeField - */ + #[Depends('testLoadContentTypeField')] public function testCreateContent() { return $this->createContent($this->getValidCreationFieldData()); @@ -597,9 +594,7 @@ protected function createMultilingualContent(array $names, array $fieldData, arr return $contentService->createContent($createStruct, $locationCreateStructs); } - /** - * @depends testCreateContent - */ + #[Depends('testCreateContent')] public function testCreatedFieldType($content) { foreach ($content->getFields() as $field) { @@ -611,9 +606,7 @@ public function testCreatedFieldType($content) self::fail('Custom field not found.'); } - /** - * @depends testCreateContent - */ + #[Depends('testCreateContent')] public function testPublishContent() { $draft = $this->testCreateContent(); @@ -628,9 +621,7 @@ public function testPublishContent() return $contentService->publishVersion($draft->getVersionInfo()); } - /** - * @depends testPublishContent - */ + #[Depends('testPublishContent')] public function testPublishedFieldType($content) { foreach ($content->getFields() as $field) { @@ -642,10 +633,8 @@ public function testPublishedFieldType($content) self::fail('Custom field not found.'); } - /** - * @depends testPublishContent - */ - public function testPublishedName(Content $content) + #[Depends('testPublishContent')] + public function testPublishedName(Content $content): void { self::assertEquals( $content->getFieldValue('name') . ' ' . $this->getFieldName(), @@ -653,9 +642,7 @@ public function testPublishedName(Content $content) ); } - /** - * @depends testCreateContent - */ + #[Depends('testCreateContent')] public function testLoadField() { $content = $this->testCreateContent(); @@ -666,9 +653,7 @@ public function testLoadField() return $contentService->loadContent($content->contentInfo->id); } - /** - * @depends testLoadField - */ + #[Depends('testLoadField')] public function testLoadFieldType() { $content = $this->testCreateContent(); @@ -682,10 +667,8 @@ public function testLoadFieldType() self::fail('Custom field not found.'); } - /** - * @depends testLoadFieldType - */ - public function testLoadExternalData() + #[Depends('testLoadFieldType')] + public function testLoadExternalData(): void { $this->assertFieldDataLoadedCorrect($this->testLoadFieldType()); } @@ -701,20 +684,18 @@ public function testCreateContentWithEmptyFieldValue() /** * Test that publishing (and thus indexing) content with an empty field value does not fail. * - * @depends testCreateContentWithEmptyFieldValue * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $contentDraft */ - public function testPublishContentWithEmptyFieldValue(Content $contentDraft) + #[Depends('testCreateContentWithEmptyFieldValue')] + public function testPublishContentWithEmptyFieldValue(Content $contentDraft): void { $this->getRepository(false)->getContentService()->publishVersion( $contentDraft->versionInfo ); } - /** - * @depends testCreateContentWithEmptyFieldValue - */ + #[Depends('testCreateContentWithEmptyFieldValue')] public function testCreatedEmptyFieldValue($content) { foreach ($content->getFields() as $field) { @@ -726,11 +707,8 @@ public function testCreatedEmptyFieldValue($content) self::fail('Custom field not found.'); } - /** - * @depends testCreateContentWithEmptyFieldValue - * - * @group xx - */ + #[Depends('testCreateContentWithEmptyFieldValue')] + #[Group('xx')] public function testLoadEmptyFieldValue() { $content = $this->testCreateContentWithEmptyFieldValue(); @@ -741,9 +719,7 @@ public function testLoadEmptyFieldValue() return $contentService->loadContent($content->contentInfo->id); } - /** - * @depends testLoadEmptyFieldValue - */ + #[Depends('testLoadEmptyFieldValue')] public function testLoadEmptyFieldValueType($content) { foreach ($content->getFields() as $field) { @@ -755,10 +731,8 @@ public function testLoadEmptyFieldValueType($content) self::fail('Custom field not found.'); } - /** - * @depends testLoadEmptyFieldValueType - */ - public function testLoadEmptyFieldValueData($field) + #[Depends('testLoadEmptyFieldValueType')] + public function testLoadEmptyFieldValueData($field): void { /** @var \Ibexa\Core\FieldType\FieldType $fieldType */ $fieldType = $this->getRepository()->getFieldTypeService()->getFieldType($this->getTypeName()); @@ -775,9 +749,7 @@ public function testLoadEmptyFieldValueData($field) ); } - /** - * @depends testLoadFieldType - */ + #[Depends('testLoadFieldType')] public function testUpdateField() { return $this->updateContent($this->getValidUpdateFieldData()); @@ -811,9 +783,7 @@ public function updateContent($fieldData, $setField = true) return $contentService->updateContent($draft->versionInfo, $updateStruct); } - /** - * @depends testUpdateField - */ + #[Depends('testUpdateField')] public function testUpdateTypeFieldStillAvailable($content) { foreach ($content->getFields() as $field) { @@ -825,10 +795,8 @@ public function testUpdateTypeFieldStillAvailable($content) self::fail('Custom field not found.'); } - /** - * @depends testUpdateTypeFieldStillAvailable - */ - public function testUpdatedDataCorrect(Field $field) + #[Depends('testUpdateTypeFieldStillAvailable')] + public function testUpdatedDataCorrect(Field $field): void { $this->assertUpdatedFieldDataLoadedCorrect($field); } @@ -841,9 +809,7 @@ public function testUpdateFieldNoNewContent() return $this->updateContent(null, false); } - /** - * @depends testUpdateFieldNoNewContent - */ + #[Depends('testUpdateFieldNoNewContent')] public function testUpdateNoNewContentTypeFieldStillAvailable($content) { foreach ($content->getFields() as $field) { @@ -855,17 +821,13 @@ public function testUpdateNoNewContentTypeFieldStillAvailable($content) self::fail('Custom field not found.'); } - /** - * @depends testUpdateNoNewContentTypeFieldStillAvailable - */ - public function testUpdatedNoNewContentDataCorrect(Field $field) + #[Depends('testUpdateNoNewContentTypeFieldStillAvailable')] + public function testUpdatedNoNewContentDataCorrect(Field $field): void { $this->assertFieldDataLoadedCorrect($field); } - /** - * @depends testCreateContent - */ + #[Depends('testCreateContent')] public function testCopyField($content) { $content = $this->testCreateContent(); @@ -887,9 +849,7 @@ public function testCopyField($content) return $contentService->loadContent($copied->id); } - /** - * @depends testCopyField - */ + #[Depends('testCopyField')] public function testCopiedFieldType($content) { foreach ($content->getFields() as $field) { @@ -901,18 +861,14 @@ public function testCopiedFieldType($content) self::fail('Custom field not found.'); } - /** - * @depends testCopiedFieldType - */ - public function testCopiedExternalData(Field $field) + #[Depends('testCopiedFieldType')] + public function testCopiedExternalData(Field $field): void { $this->assertCopiedFieldDataLoadedCorrectly($field); } - /** - * @depends testCopyField - */ - public function testDeleteContent($content) + #[Depends('testCopyField')] + public function testDeleteContent($content): void { $this->expectException(NotFoundException::class); @@ -930,9 +886,8 @@ public function testDeleteContent($content) * Tests failing content creation. * * @param mixed $failingValue - * - * @dataProvider provideInvalidCreationFieldData */ + #[DataProvider('provideInvalidCreationFieldData')] public function testCreateContentFails($failingValue, ?string $expectedException): void { $this->expectException($expectedException); @@ -944,9 +899,8 @@ public function testCreateContentFails($failingValue, ?string $expectedException * * @param mixed $failingValue * @param string $expectedException - * - * @dataProvider provideInvalidUpdateFieldData */ + #[DataProvider('provideInvalidUpdateFieldData')] public function testUpdateContentFails($failingValue, $expectedException) { $this->expectException($expectedException); @@ -973,7 +927,7 @@ protected function removeFieldDefinition() /** * Tests removal of field definition from the ContentType of the Content. */ - public function testRemoveFieldDefinition() + public function testRemoveFieldDefinition(): void { $content = $this->removeFieldDefinition(); @@ -1025,10 +979,8 @@ public function testAddFieldDefinition() ); } - /** - * @dataProvider provideToHashData - */ - public function testToHash($value, $expectedHash) + #[DataProvider('provideToHashData')] + public function testToHash($value, $expectedHash): void { $repository = $this->getRepository(); $fieldTypeService = $repository->getFieldTypeService(); @@ -1041,14 +993,12 @@ public function testToHash($value, $expectedHash) } /** - * @depends testCreateContent - * - * @dataProvider provideFromHashData - * * @todo: Requires correct registered FieldTypeService, needs to be * maintained! */ - public function testFromHash($hash, $expectedValue) + #[Depends('testCreateContent')] + #[DataProvider('provideFromHashData')] + public function testFromHash($hash, $expectedValue): void { $repository = $this->getRepository(); $fieldTypeService = $repository->getFieldTypeService(); @@ -1063,7 +1013,7 @@ public function testFromHash($hash, $expectedValue) /** * Test that exceeding default version archive limit has no effect on a published content. */ - public function testExceededVersionArchiveLimitHasNoEffectOnContent() + public function testExceededVersionArchiveLimitHasNoEffectOnContent(): void { $repository = $this->getRepository(); $contentService = $repository->getContentService(); @@ -1088,7 +1038,7 @@ public function testExceededVersionArchiveLimitHasNoEffectOnContent() /** * Test that deleting new draft does not affect data of published version. */ - public function testDeleteDraftOfPublishedContentDoesNotDeleteData() + public function testDeleteDraftOfPublishedContentDoesNotDeleteData(): void { $repository = $this->getRepository(); $contentService = $repository->getContentService(); @@ -1110,7 +1060,7 @@ public function testDeleteDraftOfPublishedContentDoesNotDeleteData() /** * Test creating new translation from existing content with empty field. */ - public function testUpdateContentWithNewTranslationOnEmptyField() + public function testUpdateContentWithNewTranslationOnEmptyField(): void { $repository = $this->getRepository(); $contentService = $repository->getContentService(); @@ -1149,10 +1099,8 @@ public function getValidMultilingualFieldData(array $languageCodes) /** * Test that removing Translation from all Versions works for data from a Field Type. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteTranslation */ - public function testDeleteTranslation() + public function testDeleteTranslation(): void { $repository = $this->getRepository(); $contentService = $repository->getContentService(); diff --git a/tests/integration/Core/Repository/FieldType/BinaryFileIntegrationTest.php b/tests/integration/Core/Repository/FieldType/BinaryFileIntegrationTest.php index abcaf4b84f..cb24db44b7 100644 --- a/tests/integration/Core/Repository/FieldType/BinaryFileIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/BinaryFileIntegrationTest.php @@ -12,16 +12,16 @@ use Ibexa\Contracts\Core\Test\Repository\SetupFactory\Legacy; use Ibexa\Core\FieldType\BinaryBase\Value as BinaryBaseValue; use Ibexa\Core\FieldType\BinaryFile\Value as BinaryFileValue; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] final class BinaryFileIntegrationTest extends BaseBinaryFileIntegrationTestCaseCase { - protected function getFixtureData(): array + protected static function getFixtureData(): array { return [ 'create' => [ @@ -69,7 +69,7 @@ public function getValidFieldSettings(): array return []; } - protected function buildBinaryFileValueFromFixtureData(array $fileFieldValueData): BinaryBaseValue + protected static function buildBinaryFileValueFromFixtureData(array $fileFieldValueData): BinaryBaseValue { return new BinaryFileValue($fileFieldValueData); } @@ -82,7 +82,7 @@ public function asserFieldValueIsCorrectInstance(Field $field): void ); } - protected function buildBinaryFileValue(string $fileId): BinaryBaseValue + protected static function buildBinaryFileValue(string $fileId): BinaryBaseValue { return new BinaryFileValue( [ @@ -91,15 +91,15 @@ protected function buildBinaryFileValue(string $fileId): BinaryBaseValue ); } - public function provideToHashData(): array + public static function provideToHashData(): array { - $fixture = $this->getFixtureData(); + $fixture = static::getFixtureData(); $expected = $fixture['create']; $expected['downloadCount'] = 0; $expected['uri'] = $expected['inputUri']; $expected['path'] = $expected['inputUri']; - $fieldValue = $this->getValidCreationFieldData(); + $fieldValue = static::buildBinaryFileValueFromFixtureData($fixture['create']); $fieldValue->uri = $expected['uri']; return [ @@ -110,13 +110,13 @@ public function provideToHashData(): array ]; } - public function provideFromHashData(): array + public static function provideFromHashData(): array { - $fixture = $this->getFixtureData(); + $fixture = static::getFixtureData(); $fixture['create']['downloadCount'] = 0; $fixture['create']['uri'] = $fixture['create']['inputUri']; - $fieldValue = $this->getValidCreationFieldData(); + $fieldValue = static::buildBinaryFileValueFromFixtureData($fixture['create']); $fieldValue->uri = $fixture['create']['uri']; return [ @@ -130,7 +130,7 @@ public function provideFromHashData(): array /** * @return list> */ - public function providerForTestIsEmptyValue(): array + public static function providerForTestIsEmptyValue(): array { return [ [new BinaryFileValue()], @@ -138,7 +138,7 @@ public function providerForTestIsEmptyValue(): array ]; } - protected function getValidSearchValueOne(): BinaryFileValue + protected static function getValidSearchValueOne(): BinaryFileValue { return new BinaryFileValue( [ @@ -164,7 +164,7 @@ protected function checkSearchEngineSupport(): void } } - protected function getValidSearchValueTwo(): BinaryFileValue + protected static function getValidSearchValueTwo(): BinaryFileValue { return new BinaryFileValue( [ diff --git a/tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php b/tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php index 55929544fa..d825659582 100644 --- a/tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/CheckboxIntegrationTest.php @@ -16,13 +16,17 @@ use Ibexa\Contracts\Core\Test\Repository\SetupFactory\Legacy; use Ibexa\Core\Base\Exceptions\InvalidArgumentType; use Ibexa\Core\FieldType\Checkbox\Value as CheckboxValue; +use Ibexa\Core\Repository\SearchService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[CoversClass(SearchService::class)] +#[Group('integration')] +#[Group('field-type')] class CheckboxIntegrationTest extends SearchBaseIntegrationTestCase { private const IS_ACTIVE_FIELD_DEF_IDENTIFIER = 'is_active'; @@ -145,7 +149,7 @@ public function assertFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidCreationFieldData() + public static function provideInvalidCreationFieldData(): array { return [ [ @@ -188,9 +192,9 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidUpdateFieldData() + public static function provideInvalidUpdateFieldData(): array { - return $this->provideInvalidCreationFieldData(); + return self::provideInvalidCreationFieldData(); } /** @@ -237,7 +241,7 @@ public function assertCopiedFieldDataLoadedCorrectly(Field $field) * * @return array */ - public function provideToHashData() + public static function provideToHashData(): array { return [ [ @@ -254,7 +258,7 @@ public function provideToHashData() * * @return array */ - public function provideFromHashData() + public static function provideFromHashData(): array { return [ [ @@ -264,15 +268,22 @@ public function provideFromHashData() ]; } - public function providerForTestIsEmptyValue() + /** + * @return array + */ + public static function providerForTestIsEmptyValue(): array { - return []; + // Checkbox has no "empty" value: it is always either true or false. + return [[self::NO_EMPTY_VALUE_DATA]]; } - public function providerForTestIsNotEmptyValue() + /** + * @return array + */ + public static function providerForTestIsNotEmptyValue(): array { return [ - [$this->getValidCreationFieldData()], + [new CheckboxValue(true)], [new CheckboxValue(true)], [new CheckboxValue()], [new CheckboxValue(null)], @@ -280,31 +291,31 @@ public function providerForTestIsNotEmptyValue() ]; } - protected function getValidSearchValueOne(): bool + protected static function getValidSearchValueOne(): bool { return false; } - protected function getValidSearchValueTwo(): bool + protected static function getValidSearchValueTwo(): bool { return true; } - protected function getSearchTargetValueOne() + protected static function getSearchTargetValueOne() { // Handling Legacy Search Engine, which stores Checkbox value as integer - if ($this->getSetupFactory() instanceof Legacy) { - return (int)$this->getValidSearchValueOne(); + if (static::resolveSetupFactory() instanceof Legacy) { + return (int)static::getValidSearchValueOne(); } return parent::getSearchTargetValueOne(); } - protected function getSearchTargetValueTwo() + protected static function getSearchTargetValueTwo() { // Handling Legacy Search Engine, which stores Checkbox value as integer - if ($this->getSetupFactory() instanceof Legacy) { - return (int)$this->getValidSearchValueTwo(); + if (static::resolveSetupFactory() instanceof Legacy) { + return (int)static::getValidSearchValueTwo(); } return parent::getSearchTargetValueTwo(); @@ -313,7 +324,7 @@ protected function getSearchTargetValueTwo() /** * Data corresponds to Content items created by {@see createCheckboxContentItems}. */ - public function getDataForTestFindContentFieldCriterion(): iterable + public static function getDataForTestFindContentFieldCriterion(): iterable { // there are 2 Content items created, one with is_active = true, the other one with is_active = false yield 'active' => [true]; @@ -321,14 +332,11 @@ public function getDataForTestFindContentFieldCriterion(): iterable } /** - * @dataProvider getDataForTestFindContentFieldCriterion - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ + #[DataProvider('getDataForTestFindContentFieldCriterion')] public function testFindContentFieldCriterion(bool $isActive): void { $repository = $this->getRepository(); diff --git a/tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php b/tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php index d0539fea37..5d3eff1aa5 100644 --- a/tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/CountryIntegrationTest.php @@ -11,13 +11,13 @@ use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException; use Ibexa\Contracts\Core\Repository\Values\Content\Field; use Ibexa\Core\FieldType\Country\Value as CountryValue; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] class CountryIntegrationTest extends SearchMultivaluedBaseIntegrationTestCase { /** @@ -162,7 +162,7 @@ public function assertFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidCreationFieldData() + public static function provideInvalidCreationFieldData(): array { return [ [ @@ -242,9 +242,9 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidUpdateFieldData() + public static function provideInvalidUpdateFieldData(): array { - return $this->provideInvalidCreationFieldData(); + return self::provideInvalidCreationFieldData(); } /** @@ -298,7 +298,7 @@ public function assertCopiedFieldDataLoadedCorrectly(Field $field) * * @return array */ - public function provideToHashData() + public static function provideToHashData(): array { return [ [ @@ -330,7 +330,7 @@ public function provideToHashData() * * @return array */ - public function provideFromHashData() + public static function provideFromHashData(): array { return [ [ @@ -355,7 +355,10 @@ public function provideFromHashData() ]; } - public function providerForTestIsEmptyValue() + /** + * @return array + */ + public static function providerForTestIsEmptyValue(): array { return [ [new CountryValue()], @@ -363,36 +366,48 @@ public function providerForTestIsEmptyValue() ]; } - public function providerForTestIsNotEmptyValue() + /** + * @return array + */ + public static function providerForTestIsNotEmptyValue(): array { return [ [ - $this->getValidCreationFieldData(), + new CountryValue( + [ + 'BE' => [ + 'Name' => 'Belgium', + 'Alpha2' => 'BE', + 'Alpha3' => 'BEL', + 'IDC' => 32, + ], + ] + ), ], ]; } - protected function getValidSearchValueOne() + protected static function getValidSearchValueOne() { return ['Andorra']; } - protected function getValidSearchValueTwo() + protected static function getValidSearchValueTwo() { return ['Trinidad and Tobago']; } - protected function getSearchTargetValueOne(): string + protected static function getSearchTargetValueOne(): string { return 'Andorra'; } - protected function getSearchTargetValueTwo(): string + protected static function getSearchTargetValueTwo(): string { return 'Trinidad and Tobago'; } - protected function getAdditionallyIndexedFieldData() + protected static function getAdditionallyIndexedFieldData() { return [ [ @@ -423,17 +438,17 @@ protected function getAdditionallyIndexedFieldData() ]; } - protected function getValidMultivaluedSearchValuesOne() + protected static function getValidMultivaluedSearchValuesOne() { return ['Andorra', 'Bolivia']; } - protected function getValidMultivaluedSearchValuesTwo() + protected static function getValidMultivaluedSearchValuesTwo() { return ['Syrian Arab Republic', 'Trinidad and Tobago']; } - protected function getAdditionallyIndexedMultivaluedFieldData() + protected static function getAdditionallyIndexedMultivaluedFieldData() { return [ [ @@ -459,7 +474,7 @@ protected function getAdditionallyIndexedMultivaluedFieldData() ]; } - protected function getFullTextIndexedFieldData() + protected static function getFullTextIndexedFieldData() { return [ ['Andorra', 'Tobago'], diff --git a/tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php b/tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php index 5cf50e4a63..5e893a1e38 100644 --- a/tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/DateAndTimeIntegrationTest.php @@ -12,13 +12,14 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Field; use Ibexa\Contracts\Core\Test\Repository\SetupFactory\Legacy; use Ibexa\Core\FieldType\DateAndTime\Value as DateAndTimeValue; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] class DateAndTimeIntegrationTest extends SearchBaseIntegrationTestCase { /** @@ -166,7 +167,7 @@ public function assertFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidCreationFieldData() + public static function provideInvalidCreationFieldData(): array { return [ [ @@ -208,9 +209,9 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidUpdateFieldData() + public static function provideInvalidUpdateFieldData(): array { - return $this->provideInvalidCreationFieldData(); + return self::provideInvalidCreationFieldData(); } /** @@ -218,9 +219,8 @@ public function provideInvalidUpdateFieldData() * * @param mixed $failingValue * @param string $expectedException - * - * @dataProvider provideInvalidUpdateFieldData */ + #[DataProvider('provideInvalidUpdateFieldData')] public function testUpdateContentFails($failingValue, $expectedException) { return [ @@ -274,7 +274,7 @@ public function assertCopiedFieldDataLoadedCorrectly(Field $field) * * @return array */ - public function provideToHashData() + public static function provideToHashData(): array { return [ [ @@ -294,7 +294,7 @@ public function provideToHashData() * * @return array */ - public function provideFromHashData() + public static function provideFromHashData(): array { return [ [ @@ -307,37 +307,43 @@ public function provideFromHashData() ]; } - public function providerForTestIsEmptyValue() + /** + * @return array + */ + public static function providerForTestIsEmptyValue(): array { return [ [new DateAndTimeValue()], ]; } - public function providerForTestIsNotEmptyValue() + /** + * @return array + */ + public static function providerForTestIsNotEmptyValue(): array { return [ [ - $this->getValidCreationFieldData(), + DateAndTimeValue::fromTimestamp(123456), ], ]; } - protected function getValidSearchValueOne(): string + protected static function getValidSearchValueOne(): string { return '2012-04-15T15:43:56Z'; } - protected function getValidSearchValueTwo(): string + protected static function getValidSearchValueTwo(): string { return '2015-04-15T15:43:56Z'; } - protected function getSearchTargetValueOne() + protected static function getSearchTargetValueOne() { // Handling Legacy Search Engine, which stores DateAndTime value as integer timestamp - if ($this->getSetupFactory() instanceof Legacy) { - $dateTime = new DateTime($this->getValidSearchValueOne()); + if (static::resolveSetupFactory() instanceof Legacy) { + $dateTime = new DateTime(static::getValidSearchValueOne()); return $dateTime->getTimestamp(); } @@ -345,11 +351,11 @@ protected function getSearchTargetValueOne() return parent::getSearchTargetValueOne(); } - protected function getSearchTargetValueTwo() + protected static function getSearchTargetValueTwo() { // Handling Legacy Search Engine, which stores DateAndTime value as integer timestamp - if ($this->getSetupFactory() instanceof Legacy) { - $dateTime = new DateTime($this->getValidSearchValueTwo()); + if (static::resolveSetupFactory() instanceof Legacy) { + $dateTime = new DateTime(static::getValidSearchValueTwo()); return $dateTime->getTimestamp(); } diff --git a/tests/integration/Core/Repository/FieldType/DateIntegrationTest.php b/tests/integration/Core/Repository/FieldType/DateIntegrationTest.php index 1e7b05d2fa..3061f2cd2d 100644 --- a/tests/integration/Core/Repository/FieldType/DateIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/DateIntegrationTest.php @@ -13,13 +13,13 @@ use Ibexa\Contracts\Core\Test\Repository\SetupFactory\Legacy; use Ibexa\Core\FieldType\Date\Type; use Ibexa\Core\FieldType\Date\Value as DateValue; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] class DateIntegrationTest extends SearchBaseIntegrationTestCase { /** @@ -156,7 +156,7 @@ public function assertFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidCreationFieldData() + public static function provideInvalidCreationFieldData(): array { return [ [ @@ -200,9 +200,9 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidUpdateFieldData() + public static function provideInvalidUpdateFieldData(): array { - return $this->provideInvalidCreationFieldData(); + return self::provideInvalidCreationFieldData(); } /** @@ -238,7 +238,7 @@ public function assertCopiedFieldDataLoadedCorrectly(Field $field) * * @return array */ - public function provideToHashData() + public static function provideToHashData(): array { $timestamp = 186401; $dateTime = new DateTime("@{$timestamp}"); @@ -274,7 +274,7 @@ public function provideToHashData() * * @return array */ - public function provideFromHashData() + public static function provideFromHashData(): array { $timestamp = 123456; @@ -299,47 +299,53 @@ public function provideFromHashData() ]; } - public function providerForTestIsEmptyValue() + /** + * @return array + */ + public static function providerForTestIsEmptyValue(): array { return [ [new DateValue()], ]; } - public function providerForTestIsNotEmptyValue() + /** + * @return array + */ + public static function providerForTestIsNotEmptyValue(): array { return [ [ - $this->getValidCreationFieldData(), + DateValue::fromTimestamp(86400), ], ]; } - protected function getValidSearchValueOne(): int + protected static function getValidSearchValueOne(): int { return 86400; } - protected function getValidSearchValueTwo(): int + protected static function getValidSearchValueTwo(): int { return 172800; } - protected function getSearchTargetValueOne() + protected static function getSearchTargetValueOne() { // Handling Legacy Search Engine, which stores Date value as timestamp - if ($this->getSetupFactory() instanceof Legacy) { - return $this->getValidSearchValueOne(); + if (static::resolveSetupFactory() instanceof Legacy) { + return static::getValidSearchValueOne(); } return '1970-01-02T00:00:00Z'; } - protected function getSearchTargetValueTwo() + protected static function getSearchTargetValueTwo() { // Handling Legacy Search Engine, which stores Date value as timestamp - if ($this->getSetupFactory() instanceof Legacy) { - return $this->getValidSearchValueTwo(); + if (static::resolveSetupFactory() instanceof Legacy) { + return static::getValidSearchValueTwo(); } return '1970-01-03T00:00:00Z'; diff --git a/tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php b/tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php index e9c4901fa5..98c2051079 100644 --- a/tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/EmailAddressIntegrationTest.php @@ -11,13 +11,13 @@ use Ibexa\Core\Base\Exceptions\ContentFieldValidationException; use Ibexa\Core\Base\Exceptions\InvalidArgumentException; use Ibexa\Core\FieldType\EmailAddress\Value as EmailAddressValue; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] class EmailAddressIntegrationTest extends SearchBaseIntegrationTestCase { /** @@ -144,7 +144,7 @@ public function assertFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidCreationFieldData() + public static function provideInvalidCreationFieldData(): array { return [ [ @@ -207,9 +207,9 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidUpdateFieldData() + public static function provideInvalidUpdateFieldData(): array { - return $this->provideInvalidCreationFieldData(); + return self::provideInvalidCreationFieldData(); } /** @@ -256,7 +256,7 @@ public function assertCopiedFieldDataLoadedCorrectly(Field $field) * * @return array */ - public function provideToHashData() + public static function provideToHashData(): array { return [ [ @@ -273,7 +273,7 @@ public function provideToHashData() * * @return array */ - public function provideFromHashData() + public static function provideFromHashData(): array { return [ [ @@ -283,7 +283,10 @@ public function provideFromHashData() ]; } - public function providerForTestIsEmptyValue() + /** + * @return array + */ + public static function providerForTestIsEmptyValue(): array { return [ [new EmailAddressValue()], @@ -292,38 +295,41 @@ public function providerForTestIsEmptyValue() ]; } - public function providerForTestIsNotEmptyValue() + /** + * @return array + */ + public static function providerForTestIsNotEmptyValue(): array { return [ [ - $this->getValidCreationFieldData(), + new EmailAddressValue('spam@ibexa.co'), ], ]; } - protected function getValidSearchValueOne(): string + protected static function getValidSearchValueOne(): string { return 'holmes4@ibexa.co'; } - protected function getSearchTargetValueOne(): string + protected static function getSearchTargetValueOne(): string { // ensure case-insensitivity - return strtoupper($this->getValidSearchValueOne()); + return strtoupper(static::getValidSearchValueOne()); } - protected function getValidSearchValueTwo(): string + protected static function getValidSearchValueTwo(): string { return 'wyoming.knott@o2.ru'; } - protected function getSearchTargetValueTwo(): string + protected static function getSearchTargetValueTwo(): string { // ensure case-insensitivity - return strtoupper($this->getValidSearchValueTwo()); + return strtoupper(static::getValidSearchValueTwo()); } - protected function getFullTextIndexedFieldData() + protected static function getFullTextIndexedFieldData() { return [ ['holmes4@ibexa.co', 'wyoming.knott@o2.ru'], diff --git a/tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php b/tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php index 7674cce809..2efb329c48 100644 --- a/tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php +++ b/tests/integration/Core/Repository/FieldType/FileSearchBaseIntegrationTestCase.php @@ -8,16 +8,16 @@ namespace Ibexa\Tests\Integration\Core\Repository\FieldType; use FilesystemIterator; +use PHPUnit\Framework\Attributes\Group; use RecursiveDirectoryIterator; use RecursiveIteratorIterator; use UnexpectedValueException; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] abstract class FileSearchBaseIntegrationTestCase extends SearchBaseIntegrationTestCase { /** @@ -193,7 +193,7 @@ protected function uriExistsOnIO($uri) /** * Tests that a VersionUpdate can remove the stored file. */ - public function testUpdateWithRemove() + public function testUpdateWithRemove(): void { $type = $this->createContentType( $this->getValidFieldSettings(), diff --git a/tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php b/tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php index 2b08f704e8..c18f82794e 100644 --- a/tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/FloatIntegrationTest.php @@ -11,13 +11,13 @@ use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException; use Ibexa\Contracts\Core\Repository\Values\Content\Field; use Ibexa\Core\FieldType\Float\Value as FloatValue; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] class FloatIntegrationTest extends SearchBaseIntegrationTestCase { /** @@ -156,7 +156,7 @@ public function assertFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidCreationFieldData() + public static function provideInvalidCreationFieldData(): array { return [ [ @@ -205,9 +205,9 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidUpdateFieldData() + public static function provideInvalidUpdateFieldData(): array { - return $this->provideInvalidCreationFieldData(); + return self::provideInvalidCreationFieldData(); } /** @@ -254,7 +254,7 @@ public function assertCopiedFieldDataLoadedCorrectly(Field $field) * * @return array */ - public function provideToHashData() + public static function provideToHashData(): array { return [ [ @@ -271,7 +271,7 @@ public function provideToHashData() * * @return array */ - public function provideFromHashData() + public static function provideFromHashData(): array { return [ [ @@ -281,30 +281,36 @@ public function provideFromHashData() ]; } - public function providerForTestIsEmptyValue() + /** + * @return array + */ + public static function providerForTestIsEmptyValue(): array { return [ [new FloatValue()], ]; } - public function providerForTestIsNotEmptyValue() + /** + * @return array + */ + public static function providerForTestIsNotEmptyValue(): array { return [ [ - $this->getValidCreationFieldData(), + new FloatValue(23.5), ], [new FloatValue(0)], [new FloatValue(0.0)], ]; } - protected function getValidSearchValueOne(): float + protected static function getValidSearchValueOne(): float { return 25.519; } - protected function getValidSearchValueTwo(): float + protected static function getValidSearchValueTwo(): float { return 25.59; } diff --git a/tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php b/tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php index a060f73fe3..a0585183f5 100644 --- a/tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/ISBNIntegrationTest.php @@ -11,13 +11,13 @@ use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException; use Ibexa\Contracts\Core\Repository\Values\Content\Field; use Ibexa\Core\FieldType\ISBN\Value as ISBNValue; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] class ISBNIntegrationTest extends SearchBaseIntegrationTestCase { /** @@ -144,7 +144,7 @@ public function assertFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidCreationFieldData() + public static function provideInvalidCreationFieldData(): array { return [ [ @@ -197,9 +197,9 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidUpdateFieldData() + public static function provideInvalidUpdateFieldData(): array { - return $this->provideInvalidCreationFieldData(); + return self::provideInvalidCreationFieldData(); } /** @@ -245,7 +245,7 @@ public function assertCopiedFieldDataLoadedCorrectly(Field $field) * * @return array */ - public function provideToHashData() + public static function provideToHashData(): array { return [ [ @@ -270,7 +270,7 @@ public function provideToHashData() * * @return array */ - public function provideFromHashData() + public static function provideFromHashData(): array { return [ [ @@ -292,7 +292,10 @@ public function provideFromHashData() ]; } - public function providerForTestIsEmptyValue() + /** + * @return array + */ + public static function providerForTestIsEmptyValue(): array { return [ [new ISBNValue()], @@ -301,26 +304,29 @@ public function providerForTestIsEmptyValue() ]; } - public function providerForTestIsNotEmptyValue() + /** + * @return array + */ + public static function providerForTestIsNotEmptyValue(): array { return [ [ - $this->getValidCreationFieldData(), + new ISBNValue('9789722514095'), ], ]; } - protected function getValidSearchValueOne(): string + protected static function getValidSearchValueOne(): string { return '9780099067504'; } - protected function getValidSearchValueTwo(): string + protected static function getValidSearchValueTwo(): string { return '9780380448340'; } - protected function getFullTextIndexedFieldData() + protected static function getFullTextIndexedFieldData() { return [ ['9780099067504', '9780380448340'], diff --git a/tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php b/tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php index 98b190b7e1..12b9de86da 100644 --- a/tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/ImageIntegrationTest.php @@ -18,14 +18,14 @@ use Ibexa\Core\FieldType\Image\Value as ImageValue; use Ibexa\Core\IO\IOServiceInterface; use Ibexa\Core\Persistence\Legacy\Content\Gateway; +use PHPUnit\Framework\Attributes\Group; use stdClass; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] class ImageIntegrationTest extends FileSearchBaseIntegrationTestCase { /** @@ -50,7 +50,7 @@ protected function getStoragePrefix() * * @return array */ - protected function getFixtureData(): array + protected static function getFixtureData(): array { return [ 'create' => [ @@ -210,7 +210,7 @@ public function getInvalidValidatorConfiguration(): array */ public function getValidCreationFieldData(): ImageValue { - $fixtureData = $this->getFixtureData(); + $fixtureData = static::getFixtureData(); return new ImageValue($fixtureData['create']); } @@ -238,7 +238,7 @@ public function assertFieldDataLoadedCorrect(Field $field): void $field->value ); - $fixtureData = $this->getFixtureData(); + $fixtureData = static::getFixtureData(); $expectedData = $fixtureData['create']; // Will be nullified by external storage @@ -260,7 +260,7 @@ public function assertFieldDataLoadedCorrect(Field $field): void self::$loadedImagePath = $field->value->id; } - public function provideInvalidCreationFieldData(): array + public static function provideInvalidCreationFieldData(): array { return [ // will fail because the provided file doesn't exist, and fileSize/fileName won't be set @@ -280,7 +280,7 @@ public function provideInvalidCreationFieldData(): array */ public function getValidUpdateFieldData(): ImageValue { - $fixtureData = $this->getFixtureData(); + $fixtureData = static::getFixtureData(); return new ImageValue($fixtureData['update']); } @@ -292,7 +292,7 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field): void $field->value ); - $fixtureData = $this->getFixtureData(); + $fixtureData = static::getFixtureData(); $expectedData = $fixtureData['update']; // Will change during storage @@ -314,9 +314,9 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field): void ); } - public function provideInvalidUpdateFieldData(): array + public static function provideInvalidUpdateFieldData(): array { - return $this->provideInvalidCreationFieldData(); + return self::provideInvalidCreationFieldData(); } /** @@ -355,7 +355,7 @@ public function assertCopiedFieldDataLoadedCorrectly(Field $field): void * * @return array */ - public function provideToHashData(): array + public static function provideToHashData(): array { return [ [ @@ -418,14 +418,14 @@ public function provideToHashData(): array * * @return array */ - public function provideFromHashData(): array + public static function provideFromHashData(): array { - $fixture = $this->getFixtureData(); + $fixture = static::getFixtureData(); return [ [ $fixture['create'], - $this->getValidCreationFieldData(), + new ImageValue($fixture['create']), ], ]; } @@ -485,7 +485,7 @@ public function testInherentCopyForNewLanguage(): void * \Ibexa\Core\FieldType\Image\Value * }> */ - public function providerForTestIsEmptyValue(): array + public static function providerForTestIsEmptyValue(): array { return [ [new ImageValue()], @@ -497,11 +497,11 @@ public function providerForTestIsEmptyValue(): array * \Ibexa\Core\FieldType\Image\Value * }> */ - public function providerForTestIsNotEmptyValue(): array + public static function providerForTestIsNotEmptyValue(): array { return [ [ - $this->getValidCreationFieldData(), + new ImageValue(static::getFixtureData()['create']), ], ]; } @@ -630,7 +630,7 @@ protected function checkSearchEngineSupport(): void } } - protected function getValidSearchValueOne(): ImageValue + protected static function getValidSearchValueOne(): ImageValue { return new ImageValue( [ @@ -642,7 +642,7 @@ protected function getValidSearchValueOne(): ImageValue ); } - protected function getValidSearchValueTwo(): ImageValue + protected static function getValidSearchValueTwo(): ImageValue { return new ImageValue( [ @@ -654,9 +654,9 @@ protected function getValidSearchValueTwo(): ImageValue ); } - protected function getSearchTargetValueOne(): string + protected static function getSearchTargetValueOne(): string { - $value = $this->getValidSearchValueOne(); + $value = static::getValidSearchValueOne(); /** * ensure case-insensitivity. @@ -666,9 +666,9 @@ protected function getSearchTargetValueOne(): string return strtoupper($value->fileName); } - protected function getSearchTargetValueTwo(): string + protected static function getSearchTargetValueTwo(): string { - $value = $this->getValidSearchValueTwo(); + $value = static::getValidSearchValueTwo(); /** * ensure case-insensitivity. @@ -678,18 +678,18 @@ protected function getSearchTargetValueTwo(): string return strtoupper($value->fileName); } - protected function getAdditionallyIndexedFieldData(): array + protected static function getAdditionallyIndexedFieldData(): array { return [ [ 'alternative_text', - $this->getValidSearchValueOne()->alternativeText, - $this->getValidSearchValueTwo()->alternativeText, + static::getValidSearchValueOne()->alternativeText, + static::getValidSearchValueTwo()->alternativeText, ], [ 'file_size', - $this->getValidSearchValueOne()->fileSize, - $this->getValidSearchValueTwo()->fileSize, + static::getValidSearchValueOne()->fileSize, + static::getValidSearchValueTwo()->fileSize, ], [ 'mime_type', diff --git a/tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php b/tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php index 238d6bcfe9..096ad4bbdb 100644 --- a/tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/IntegerIntegrationTest.php @@ -11,13 +11,13 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Field; use Ibexa\Core\Base\Exceptions\InvalidArgumentType; use Ibexa\Core\FieldType\Integer\Value as IntegerValue; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] class IntegerIntegrationTest extends SearchBaseIntegrationTestCase { /** @@ -156,7 +156,7 @@ public function assertFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidCreationFieldData() + public static function provideInvalidCreationFieldData(): array { return [ [ @@ -207,9 +207,9 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidUpdateFieldData() + public static function provideInvalidUpdateFieldData(): array { - return $this->provideInvalidCreationFieldData(); + return self::provideInvalidCreationFieldData(); } /** @@ -256,7 +256,7 @@ public function assertCopiedFieldDataLoadedCorrectly(Field $field) * * @return array */ - public function provideToHashData() + public static function provideToHashData(): array { return [ [ @@ -273,7 +273,7 @@ public function provideToHashData() * * @return array */ - public function provideFromHashData() + public static function provideFromHashData(): array { return [ [ @@ -283,35 +283,41 @@ public function provideFromHashData() ]; } - public function providerForTestIsEmptyValue() + /** + * @return array + */ + public static function providerForTestIsEmptyValue(): array { return [ [new IntegerValue()], ]; } - public function providerForTestIsNotEmptyValue() + /** + * @return array + */ + public static function providerForTestIsNotEmptyValue(): array { return [ [ - $this->getValidCreationFieldData(), + new IntegerValue(23), ], [new IntegerValue(0)], [new IntegerValue(0.0)], ]; } - protected function getValidSearchValueOne(): int + protected static function getValidSearchValueOne(): int { return 25; } - protected function getValidSearchValueTwo(): int + protected static function getValidSearchValueTwo(): int { return 26; } - protected function getFullTextIndexedFieldData() + protected static function getFullTextIndexedFieldData() { return [ ['25', '26'], diff --git a/tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php b/tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php index dae412664d..6cfd0ca3d0 100644 --- a/tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/KeywordIntegrationTest.php @@ -13,13 +13,17 @@ use Ibexa\Contracts\Core\Repository\Values\ContentType\ContentType; use Ibexa\Core\Base\Exceptions\InvalidArgumentType; use Ibexa\Core\FieldType\Keyword\Value as KeywordValue; +use Ibexa\Core\Repository\SearchService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[CoversClass(SearchService::class)] +#[Group('integration')] +#[Group('field-type')] class KeywordIntegrationTest extends SearchMultivaluedBaseIntegrationTestCase { /** @@ -156,7 +160,7 @@ public function assertFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidCreationFieldData() + public static function provideInvalidCreationFieldData(): array { return [ [ @@ -200,9 +204,9 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidUpdateFieldData() + public static function provideInvalidUpdateFieldData(): array { - return $this->provideInvalidCreationFieldData(); + return self::provideInvalidCreationFieldData(); } /** @@ -246,7 +250,7 @@ public function assertCopiedFieldDataLoadedCorrectly(Field $field) * * @return array */ - public function provideToHashData() + public static function provideToHashData(): array { return [ [ @@ -263,7 +267,7 @@ public function provideToHashData() * * @return array */ - public function provideFromHashData() + public static function provideFromHashData(): array { return [ [ @@ -273,7 +277,10 @@ public function provideFromHashData() ]; } - public function providerForTestIsEmptyValue() + /** + * @return array + */ + public static function providerForTestIsEmptyValue(): array { return [ [new KeywordValue()], @@ -282,11 +289,14 @@ public function providerForTestIsEmptyValue() ]; } - public function providerForTestIsNotEmptyValue() + /** + * @return array + */ + public static function providerForTestIsNotEmptyValue(): array { return [ [ - $this->getValidCreationFieldData(), + new KeywordValue(['foo', 'bar', 'sindelfingen']), ], [ new KeywordValue(['0']), @@ -297,7 +307,7 @@ public function providerForTestIsNotEmptyValue() /** * Test updating multiple contents with ibexa_keyword field preserves proper fields values. */ - public function testUpdateContentKeywords() + public function testUpdateContentKeywords(): void { $contentType = $this->testCreateContentType(); $contentService = $this->getRepository()->getContentService(); @@ -397,7 +407,7 @@ public function testGoBackToDifferentVersionWithDifferentKeywords(): void self::assertEqualsCanonicalizing($contentDraft03->getFieldValue('data'), $value01); } - public function testKeywordsAreCaseSensitive() + public function testKeywordsAreCaseSensitive(): void { $contentType = $this->testCreateContentType(); $publishedContent01 = $this->createAndPublishContent('Foo', $contentType, md5(uniqid(__METHOD__, true))); @@ -441,22 +451,22 @@ protected function createAndPublishContent($fieldData, ContentType $contentType, return $contentService->publishVersion($contentDraft->versionInfo); } - protected function getValidSearchValueOne(): string + protected static function getValidSearchValueOne(): string { return 'add'; } - protected function getValidSearchValueTwo(): string + protected static function getValidSearchValueTwo(): string { return 'branch'; } - protected function getValidMultivaluedSearchValuesOne() + protected static function getValidMultivaluedSearchValuesOne() { return ['add', 'branch']; } - protected function getValidMultivaluedSearchValuesTwo() + protected static function getValidMultivaluedSearchValuesTwo() { return ['commit', 'delete']; } @@ -466,14 +476,17 @@ public function checkFullTextSupport() // Does nothing } - protected function getFullTextIndexedFieldData() + protected static function getFullTextIndexedFieldData() { return [ ['add', 'branch'], ]; } - public function providerForTestTruncateField() + /** + * @return array + */ + public static function providerForTestTruncateField(): array { return [ [new KeywordValue()], @@ -487,13 +500,13 @@ public function providerForTestTruncateField() /** * Test that setting an empty value truncates field data. * - * @dataProvider providerForTestTruncateField * * @param mixed $emptyValue data representing an empty value * * @todo Move this method to BaseIntegrationTest when fixed for all field types. */ - public function testTruncateField($emptyValue) + #[DataProvider('providerForTestTruncateField')] + public function testTruncateField($emptyValue): void { $repository = $this->getRepository(); $contentService = $repository->getContentService(); @@ -575,10 +588,8 @@ protected function createKeywordContent() /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() */ - public function testFindContentFieldCriterion() + public function testFindContentFieldCriterion(): void { $this->createKeywordContent(); $repository = $this->getRepository(); diff --git a/tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php b/tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php index 3d7c2dc6d3..37e022de62 100644 --- a/tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/MapLocationIntegrationTest.php @@ -10,13 +10,13 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Field; use Ibexa\Core\Base\Exceptions\InvalidArgumentType; use Ibexa\Core\FieldType\MapLocation\Value as MapLocationValue; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] class MapLocationIntegrationTest extends BaseIntegrationTestCase { /** @@ -135,7 +135,7 @@ public function assertFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidCreationFieldData() + public static function provideInvalidCreationFieldData(): array { return [ [ @@ -208,9 +208,9 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidUpdateFieldData() + public static function provideInvalidUpdateFieldData(): array { - return $this->provideInvalidCreationFieldData(); + return self::provideInvalidCreationFieldData(); } /** @@ -249,7 +249,7 @@ public function assertCopiedFieldDataLoadedCorrectly(Field $field) * * @return array */ - public function provideToHashData() + public static function provideToHashData(): array { return [ [ @@ -276,7 +276,7 @@ public function provideToHashData() * * @return array */ - public function provideFromHashData() + public static function provideFromHashData(): array { return [ [ @@ -296,7 +296,10 @@ public function provideFromHashData() ]; } - public function providerForTestIsEmptyValue() + /** + * @return array + */ + public static function providerForTestIsEmptyValue(): array { return [ [new MapLocationValue()], @@ -311,11 +314,20 @@ public function providerForTestIsEmptyValue() ]; } - public function providerForTestIsNotEmptyValue() + /** + * @return array + */ + public static function providerForTestIsNotEmptyValue(): array { return [ [ - $this->getValidCreationFieldData(), + new MapLocationValue( + [ + 'latitude' => 51.559997, + 'longitude' => 6.767921, + 'address' => 'Bielefeld', + ] + ), ], [ new MapLocationValue( diff --git a/tests/integration/Core/Repository/FieldType/MediaIntegrationTest.php b/tests/integration/Core/Repository/FieldType/MediaIntegrationTest.php index d278005d20..8190b299ec 100644 --- a/tests/integration/Core/Repository/FieldType/MediaIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/MediaIntegrationTest.php @@ -12,16 +12,16 @@ use Ibexa\Core\FieldType\BinaryBase\Value as BinaryBaseValue; use Ibexa\Core\FieldType\Media\Type as MediaType; use Ibexa\Core\FieldType\Media\Value as MediaValue; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] final class MediaIntegrationTest extends BaseBinaryFileIntegrationTestCaseCase { - protected function getFixtureData(): array + protected static function getFixtureData(): array { return [ 'create' => [ @@ -81,7 +81,7 @@ public function getValidFieldSettings(): array ]; } - protected function buildBinaryFileValueFromFixtureData(array $fileFieldValueData): BinaryBaseValue + protected static function buildBinaryFileValueFromFixtureData(array $fileFieldValueData): BinaryBaseValue { return new MediaValue($fileFieldValueData); } @@ -94,7 +94,7 @@ public function asserFieldValueIsCorrectInstance(Field $field): void ); } - protected function buildBinaryFileValue(string $fileId): BinaryBaseValue + protected static function buildBinaryFileValue(string $fileId): BinaryBaseValue { return new MediaValue( [ @@ -103,9 +103,9 @@ protected function buildBinaryFileValue(string $fileId): BinaryBaseValue ); } - public function provideToHashData(): array + public static function provideToHashData(): array { - $fixture = $this->getFixtureData(); + $fixture = static::getFixtureData(); $expected = $fixture['create']; $expected['uri'] = $expected['inputUri']; @@ -118,7 +118,7 @@ public function provideToHashData(): array $expected['width'] = 0; $expected['height'] = 0; - $fieldValue = $this->getValidCreationFieldData(); + $fieldValue = static::buildBinaryFileValueFromFixtureData($fixture['create']); $fieldValue->uri = $expected['uri']; return [ @@ -129,12 +129,12 @@ public function provideToHashData(): array ]; } - public function provideFromHashData(): array + public static function provideFromHashData(): array { - $fixture = $this->getFixtureData(); + $fixture = static::getFixtureData(); $fixture['create']['uri'] = $fixture['create']['id']; - $fieldValue = $this->getValidCreationFieldData(); + $fieldValue = static::buildBinaryFileValueFromFixtureData($fixture['create']); $fieldValue->uri = $fixture['create']['uri']; return [ @@ -148,14 +148,14 @@ public function provideFromHashData(): array /** * @return list> */ - public function providerForTestIsEmptyValue(): array + public static function providerForTestIsEmptyValue(): array { return [ [new MediaValue()], ]; } - protected function getValidSearchValueOne(): MediaValue + protected static function getValidSearchValueOne(): MediaValue { return new MediaValue( [ @@ -166,7 +166,7 @@ protected function getValidSearchValueOne(): MediaValue ); } - protected function getValidSearchValueTwo(): MediaValue + protected static function getValidSearchValueTwo(): MediaValue { return new MediaValue( [ diff --git a/tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php b/tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php index fcb3d6206f..4e7e6d219a 100644 --- a/tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/RelationIntegrationTest.php @@ -15,13 +15,14 @@ use Ibexa\Core\Base\Exceptions\InvalidArgumentType; use Ibexa\Core\FieldType\Relation\Value as RelationValue; use Ibexa\Core\Repository\Values\Content\Relation; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] +#[Group('relation')] class RelationIntegrationTest extends SearchBaseIntegrationTestCase { use RelationSearchBaseIntegrationTestTrait; @@ -98,9 +99,6 @@ public function getSettingsSchema() ]; } - /** - * @covers \Ibexa\Tests\Integration\Core\Repository\FieldType\BaseIntegrationTestCase::getValidatorSchema() - */ public function getValidatorSchema() { return []; @@ -208,7 +206,7 @@ public function assertFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidCreationFieldData() + public static function provideInvalidCreationFieldData(): array { return [ [ @@ -244,9 +242,9 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field): void ); } - public function provideInvalidUpdateFieldData() + public static function provideInvalidUpdateFieldData(): array { - return $this->provideInvalidCreationFieldData(); + return self::provideInvalidCreationFieldData(); } /** @@ -294,7 +292,7 @@ public function assertCopiedFieldDataLoadedCorrectly(Field $field): void * * @return array */ - public function provideToHashData() + public static function provideToHashData(): array { return [ [ @@ -313,7 +311,7 @@ public function provideToHashData() * * @return array */ - public function provideFromHashData() + public static function provideFromHashData(): array { return [ [ @@ -323,40 +321,46 @@ public function provideFromHashData() ]; } - public function providerForTestIsEmptyValue() + /** + * @return array + */ + public static function providerForTestIsEmptyValue(): array { return [ [new RelationValue()], ]; } - public function providerForTestIsNotEmptyValue() + /** + * @return array + */ + public static function providerForTestIsNotEmptyValue(): array { return [ [ - $this->getValidCreationFieldData(), + new RelationValue(4), ], ]; } - protected function getValidSearchValueOne(): int + protected static function getValidSearchValueOne(): int { // Using different values for Legacy Search Engine, in order to demonstrate that sort will // depend on how search engine stores field type's value. Legacy stores it as integer, while // other engines store it as string. - if ($this->getSetupFactory() instanceof Legacy) { + if (static::resolveSetupFactory() instanceof Legacy) { return 4; } return 10; } - protected function getValidSearchValueTwo(): int + protected static function getValidSearchValueTwo(): int { // Using different values for Legacy Search Engine, in order to demonstrate that sort will // depend on how search engine stores field type's value. Legacy stores it as integer, while // other engines store it as string. - if ($this->getSetupFactory() instanceof Legacy) { + if (static::resolveSetupFactory() instanceof Legacy) { return 49; } diff --git a/tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php b/tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php index 126876cc97..522a503393 100644 --- a/tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/RelationListIntegrationTest.php @@ -15,13 +15,14 @@ use Ibexa\Core\FieldType\RelationList\Type as RelationListType; use Ibexa\Core\FieldType\RelationList\Value as RelationListValue; use Ibexa\Core\Repository\Values\Content\Relation; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] +#[Group('relation')] class RelationListIntegrationTest extends SearchMultivaluedBaseIntegrationTestCase { use RelationSearchBaseIntegrationTestTrait; @@ -235,7 +236,7 @@ public function assertFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidCreationFieldData() + public static function provideInvalidCreationFieldData(): array { return [ [ @@ -271,9 +272,9 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field): void ); } - public function provideInvalidUpdateFieldData() + public static function provideInvalidUpdateFieldData(): array { - return $this->provideInvalidCreationFieldData(); + return self::provideInvalidCreationFieldData(); } /** @@ -320,7 +321,7 @@ public function assertCopiedFieldDataLoadedCorrectly(Field $field): void * * @return array */ - public function provideToHashData() + public static function provideToHashData(): array { return [ [ @@ -339,7 +340,7 @@ public function provideToHashData() * * @return array */ - public function provideFromHashData() + public static function provideFromHashData(): array { return [ [ @@ -349,7 +350,10 @@ public function provideFromHashData() ]; } - public function providerForTestIsEmptyValue() + /** + * @return array + */ + public static function providerForTestIsEmptyValue(): array { return [ [new RelationListValue()], @@ -357,41 +361,44 @@ public function providerForTestIsEmptyValue() ]; } - public function providerForTestIsNotEmptyValue() + /** + * @return array + */ + public static function providerForTestIsNotEmptyValue(): array { return [ [ - $this->getValidCreationFieldData(), + new RelationListValue([4, 49]), ], ]; } - protected function getValidSearchValueOne() + protected static function getValidSearchValueOne() { return [11]; } - protected function getValidSearchValueTwo() + protected static function getValidSearchValueTwo() { return [12]; } - protected function getSearchTargetValueOne(): int + protected static function getSearchTargetValueOne(): int { return 11; } - protected function getSearchTargetValueTwo(): int + protected static function getSearchTargetValueTwo(): int { return 12; } - protected function getValidMultivaluedSearchValuesOne() + protected static function getValidMultivaluedSearchValuesOne() { return [11, 12]; } - protected function getValidMultivaluedSearchValuesTwo() + protected static function getValidMultivaluedSearchValuesTwo() { return [13, 14]; } diff --git a/tests/integration/Core/Repository/FieldType/RelationSearchBaseIntegrationTestTrait.php b/tests/integration/Core/Repository/FieldType/RelationSearchBaseIntegrationTestTrait.php index 849db5a8b9..0e45c47c73 100644 --- a/tests/integration/Core/Repository/FieldType/RelationSearchBaseIntegrationTestTrait.php +++ b/tests/integration/Core/Repository/FieldType/RelationSearchBaseIntegrationTestTrait.php @@ -17,10 +17,6 @@ /** * Base integration test for field types handling content relations. * - * @group integration - * @group field-type - * @group relation - * * @since 6.1 */ trait RelationSearchBaseIntegrationTestTrait diff --git a/tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php b/tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php index 36d8898a79..93083d6c78 100644 --- a/tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php +++ b/tests/integration/Core/Repository/FieldType/SearchBaseIntegrationTestCase.php @@ -23,6 +23,8 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Search\SearchResult; use Ibexa\Contracts\Core\Test\Repository\SetupFactory\Legacy; use Ibexa\Core\Search\Common\FieldNameResolver; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; /** * Integration test for searching and sorting with Field criterion and Field sort clause. @@ -117,7 +119,7 @@ abstract class SearchBaseIntegrationTestCase extends BaseIntegrationTestCase * * @return mixed */ - abstract protected function getValidSearchValueOne(); + abstract protected static function getValidSearchValueOne(); /** * Get search target field value One. @@ -127,9 +129,9 @@ abstract protected function getValidSearchValueOne(); * * @return mixed */ - protected function getSearchTargetValueOne() + protected static function getSearchTargetValueOne() { - return $this->getValidSearchValueOne(); + return static::getValidSearchValueOne(); } /** @@ -145,7 +147,7 @@ protected function getSearchTargetValueOne() * * @return mixed */ - abstract protected function getValidSearchValueTwo(); + abstract protected static function getValidSearchValueTwo(); /** * Get search target field value Two. @@ -155,9 +157,9 @@ abstract protected function getValidSearchValueTwo(); * * @return mixed */ - protected function getSearchTargetValueTwo() + protected static function getSearchTargetValueTwo() { - return $this->getValidSearchValueTwo(); + return static::getValidSearchValueTwo(); } /** @@ -182,7 +184,7 @@ protected function getSearchTargetValueTwo() * * @return array */ - protected function getAdditionallyIndexedFieldData() + protected static function getAdditionallyIndexedFieldData() { return []; } @@ -209,11 +211,11 @@ protected function getAdditionallyIndexedFieldData() * * @return array */ - protected function getFullTextIndexedFieldData() + protected static function getFullTextIndexedFieldData() { - self::markTestSkipped( - 'Skipped by default, override in the concrete test case as required by the field type.' - ); + // Empty by default; fullTextFindProvider() falls back to a skip-sentinel row for this + // case, since markTestSkipped() cannot be called from a static data provider (PHPUnit 11). + return []; } public function checkFullTextSupport() @@ -331,13 +333,13 @@ public function testCreateTestContent(): array * * @return array */ - public function findProvider() + public static function findProvider(): array { - $additionalFields = $this->getAdditionallyIndexedFieldData(); + $additionalFields = static::getAdditionallyIndexedFieldData(); $additionalFields[] = [ null, - $this->getSearchTargetValueOne(), - $this->getSearchTargetValueTwo(), + static::getSearchTargetValueOne(), + static::getSearchTargetValueTwo(), ]; $templates = [ [true, true], @@ -369,12 +371,10 @@ public function findProvider() * value EQ One * * The result should contain Content One. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindEqualsOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindEqualsOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new Field('data', Operator::EQ, $valueOne); @@ -389,12 +389,10 @@ public function testFindEqualsOne($valueOne, $valueTwo, $filter, $content, $modi * NOT( value EQ One ) * * The result should contain Content Two. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindNotEqualsOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindNotEqualsOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new LogicalNot(new Field('data', Operator::EQ, $valueOne)); @@ -409,12 +407,10 @@ public function testFindNotEqualsOne($valueOne, $valueTwo, $filter, $content, $m * value EQ Two * * The result should contain Content Two. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindEqualsTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindEqualsTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new Field('data', Operator::EQ, $valueTwo); @@ -429,12 +425,10 @@ public function testFindEqualsTwo($valueOne, $valueTwo, $filter, $content, $modi * NOT( value EQ Two ) * * The result should contain Content One. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindNotEqualsTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindNotEqualsTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new LogicalNot(new Field('data', Operator::EQ, $valueTwo)); @@ -449,12 +443,10 @@ public function testFindNotEqualsTwo($valueOne, $valueTwo, $filter, $content, $m * value IN [One] * * The result should contain Content One. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindInOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindInOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new Field('data', Operator::IN, [$valueOne]); @@ -469,12 +461,10 @@ public function testFindInOne($valueOne, $valueTwo, $filter, $content, $modifyFi * NOT( value IN [One] ) * * The result should contain Content Two. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindNotInOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindNotInOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new LogicalNot( new Field('data', Operator::IN, [$valueOne]) @@ -491,12 +481,10 @@ public function testFindNotInOne($valueOne, $valueTwo, $filter, $content, $modif * value IN [Two] * * The result should contain Content Two. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindInTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindInTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new Field('data', Operator::IN, [$valueTwo]); @@ -511,12 +499,10 @@ public function testFindInTwo($valueOne, $valueTwo, $filter, $content, $modifyFi * NOT( value IN [Two] ) * * The result should contain Content One. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindNotInTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindNotInTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new LogicalNot( new Field('data', Operator::IN, [$valueTwo]) @@ -533,12 +519,10 @@ public function testFindNotInTwo($valueOne, $valueTwo, $filter, $content, $modif * value IN [One,Two] * * The result should contain both Content One and Content Two. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindInOneTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindInOneTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new Field( 'data', @@ -560,12 +544,10 @@ public function testFindInOneTwo($valueOne, $valueTwo, $filter, $content, $modif * NOT( value IN [One,Two] ) * * The result should be empty. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindNotInOneTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindNotInOneTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new LogicalNot( new Field( @@ -589,12 +571,10 @@ public function testFindNotInOneTwo($valueOne, $valueTwo, $filter, $content, $mo * value GT One * * The result should contain Content Two. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindGreaterThanOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindGreaterThanOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new Field('data', Operator::GT, $valueOne); @@ -609,12 +589,10 @@ public function testFindGreaterThanOne($valueOne, $valueTwo, $filter, $content, * NOT( value GT One ) * * The result should contain Content One. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindNotGreaterThanOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindNotGreaterThanOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new LogicalNot(new Field('data', Operator::GT, $valueOne)); @@ -629,12 +607,10 @@ public function testFindNotGreaterThanOne($valueOne, $valueTwo, $filter, $conten * value GT Two * * The result should be empty. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindGreaterThanTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindGreaterThanTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new Field('data', Operator::GT, $valueTwo); @@ -649,12 +625,10 @@ public function testFindGreaterThanTwo($valueOne, $valueTwo, $filter, $content, * NOT( value GT Two ) * * The result should contain both Content One and Content Two. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindNotGreaterThanTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindNotGreaterThanTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new LogicalNot(new Field('data', Operator::GT, $valueTwo)); @@ -669,12 +643,10 @@ public function testFindNotGreaterThanTwo($valueOne, $valueTwo, $filter, $conten * value GTE One * * The result should contain both Content One and Content Two. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindGreaterThanOrEqualOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindGreaterThanOrEqualOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new Field('data', Operator::GTE, $valueOne); @@ -689,12 +661,10 @@ public function testFindGreaterThanOrEqualOne($valueOne, $valueTwo, $filter, $co * NOT( value GTE One ) * * The result should be empty. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindNotGreaterThanOrEqual($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindNotGreaterThanOrEqual($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new LogicalNot(new Field('data', Operator::GTE, $valueOne)); @@ -709,12 +679,10 @@ public function testFindNotGreaterThanOrEqual($valueOne, $valueTwo, $filter, $co * value GTE Two * * The result should contain Content Two. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindGreaterThanOrEqualTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindGreaterThanOrEqualTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new Field('data', Operator::GTE, $valueTwo); @@ -729,12 +697,10 @@ public function testFindGreaterThanOrEqualTwo($valueOne, $valueTwo, $filter, $co * NOT( value GTE Two ) * * The result should contain Content One. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindNotGreaterThanOrEqualTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindNotGreaterThanOrEqualTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new LogicalNot(new Field('data', Operator::GTE, $valueTwo)); @@ -749,12 +715,10 @@ public function testFindNotGreaterThanOrEqualTwo($valueOne, $valueTwo, $filter, * value LT One * * The result should be empty. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindLowerThanOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindLowerThanOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new Field('data', Operator::LT, $valueOne); @@ -769,12 +733,10 @@ public function testFindLowerThanOne($valueOne, $valueTwo, $filter, $content, $m * NOT( value LT One ) * * The result should contain both Content One and Content Two. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindNotLowerThanOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindNotLowerThanOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new LogicalNot(new Field('data', Operator::LT, $valueOne)); @@ -789,12 +751,10 @@ public function testFindNotLowerThanOne($valueOne, $valueTwo, $filter, $content, * value LT Two * * The result should contain Content One. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindLowerThanTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindLowerThanTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new Field('data', Operator::LT, $valueTwo); @@ -809,12 +769,10 @@ public function testFindLowerThanTwo($valueOne, $valueTwo, $filter, $content, $m * NOT( value LT Two ) * * The result should contain Content Two. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindNotLowerThanTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindNotLowerThanTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new LogicalNot(new Field('data', Operator::LT, $valueTwo)); @@ -829,12 +787,10 @@ public function testFindNotLowerThanTwo($valueOne, $valueTwo, $filter, $content, * value LTE One * * The result should contain Content One. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindLowerThanOrEqualOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindLowerThanOrEqualOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new Field('data', Operator::LTE, $valueOne); @@ -849,12 +805,10 @@ public function testFindLowerThanOrEqualOne($valueOne, $valueTwo, $filter, $cont * NOT( value LTE One ) * * The result should contain Content Two. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindNotLowerThanOrEqualOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindNotLowerThanOrEqualOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new LogicalNot(new Field('data', Operator::LTE, $valueOne)); @@ -869,12 +823,10 @@ public function testFindNotLowerThanOrEqualOne($valueOne, $valueTwo, $filter, $c * value LTE Two * * The result should contain both Content One and Content Two. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindLowerThanOrEqualTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindLowerThanOrEqualTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new Field('data', Operator::LTE, $valueTwo); @@ -889,12 +841,10 @@ public function testFindLowerThanOrEqualTwo($valueOne, $valueTwo, $filter, $cont * NOT( value LTE Two ) * * The result should be empty. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindNotLowerThanOrEqualTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindNotLowerThanOrEqualTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new LogicalNot(new Field('data', Operator::LTE, $valueTwo)); @@ -909,12 +859,10 @@ public function testFindNotLowerThanOrEqualTwo($valueOne, $valueTwo, $filter, $c * value BETWEEN [One,Two] * * The result should contain both Content One and Content Two. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindBetweenOneTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindBetweenOneTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new Field( 'data', @@ -936,12 +884,10 @@ public function testFindBetweenOneTwo($valueOne, $valueTwo, $filter, $content, $ * NOT( value BETWEEN [One,Two] ) * * The result should contain both Content One and Content Two. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindNotBetweenOneTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindNotBetweenOneTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new LogicalNot( new Field( @@ -965,12 +911,10 @@ public function testFindNotBetweenOneTwo($valueOne, $valueTwo, $filter, $content * value BETWEEN [Two,One] * * The result should be empty. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindBetweenTwoOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindBetweenTwoOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new Field( 'data', @@ -992,12 +936,10 @@ public function testFindBetweenTwoOne($valueOne, $valueTwo, $filter, $content, $ * NOT( value BETWEEN [Two,One] ) * * The result should contain both Content One and Content Two. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindNotBetweenTwoOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindNotBetweenTwoOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new LogicalNot( new Field( @@ -1021,12 +963,10 @@ public function testFindNotBetweenTwoOne($valueOne, $valueTwo, $filter, $content * value CONTAINS One * * The result should contain Content One. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindContainsOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindContainsOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new Field('data', Operator::CONTAINS, $valueOne); @@ -1041,12 +981,10 @@ public function testFindContainsOne($valueOne, $valueTwo, $filter, $content, $mo * NOT( value CONTAINS One ) * * The result should contain Content Two. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindNotContainsOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindNotContainsOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new LogicalNot(new Field('data', Operator::CONTAINS, $valueOne)); @@ -1061,12 +999,10 @@ public function testFindNotContainsOne($valueOne, $valueTwo, $filter, $content, * value CONTAINS Two * * The result should contain Content Two. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindContainsTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindContainsTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new Field('data', Operator::CONTAINS, $valueTwo); @@ -1081,12 +1017,10 @@ public function testFindContainsTwo($valueOne, $valueTwo, $filter, $content, $mo * NOT( value CONTAINS Two ) * * The result should contain Content One. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindNotContainsTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindNotContainsTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { $criteria = new LogicalNot( new Field('data', Operator::CONTAINS, $valueTwo) @@ -1097,12 +1031,10 @@ public function testFindNotContainsTwo($valueOne, $valueTwo, $filter, $content, /** * Tests search with LIKE operator, with NO wildcard. - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindLikeOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindLikeOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { // (in case test is skipped for current search engine) $this->supportsLikeWildcard($valueOne); @@ -1114,12 +1046,10 @@ public function testFindLikeOne($valueOne, $valueTwo, $filter, $content, $modify /** * Tests search with LIKE operator, with wildcard at the end (on strings). - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindNotLikeOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindNotLikeOne($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { if ($this->supportsLikeWildcard($valueOne)) { $valueOne = substr_replace($valueOne, '*', -1, 1); @@ -1134,12 +1064,10 @@ public function testFindNotLikeOne($valueOne, $valueTwo, $filter, $content, $mod /** * Tests search with LIKE operator, with wildcard at the start (on strings). - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindLikeTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindLikeTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { if ($this->supportsLikeWildcard($valueTwo)) { $valueTwo = substr_replace($valueTwo, '*', 1, 1); @@ -1152,12 +1080,10 @@ public function testFindLikeTwo($valueOne, $valueTwo, $filter, $content, $modify /** * Tests search with LIKE operator, with wildcard in the middle (on strings). - * - * @dataProvider findProvider - * - * @depends testCreateTestContent */ - public function testFindNotLikeTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('findProvider')] + public function testFindNotLikeTwo($valueOne, $valueTwo, $filter, $content, $modifyField, array $context): void { if ($this->supportsLikeWildcard($valueTwo)) { $valueTwo = substr_replace($valueTwo, '*', 2, 1); @@ -1248,9 +1174,12 @@ protected function doModifyField(array $criteriaOrSortClauses, string $fieldName } } - public function sortProvider() + /** + * @return array + */ + public static function sortProvider(): array { - $additionalFields = $this->getAdditionallyIndexedFieldData(); + $additionalFields = static::getAdditionallyIndexedFieldData(); $additionalFields[] = null; $templates = [ [true, true], @@ -1273,12 +1202,10 @@ public function sortProvider() /** * Tests Content Search sort with Field sort clause on a field of specific field type. - * - * @dataProvider sortProvider - * - * @depends testCreateTestContent */ - public function testSort($ascending, $content, $modifyField, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('sortProvider')] + public function testSort($ascending, $content, $modifyField, array $context): void { [$repository, $contentOneId, $contentTwoId] = $context; $sortClause = new FieldSortClause( @@ -1301,8 +1228,26 @@ public function testSort($ascending, $content, $modifyField, array $context) $this->assertSortResult($searchResult, $ascending, $contentOneId, $contentTwoId); } - public function fullTextFindProvider() + /** + * Sentinel value yielded by {@see self::fullTextFindProvider()} when + * {@see self::getFullTextIndexedFieldData()} is empty (default), since PHPUnit 11 treats an + * empty data provider as a hard error rather than a skip. testFullTextFind* skip on it. + */ + protected const NO_FULLTEXT_DATA = '__no_fulltext_data__'; + + /** + * @return array + */ + public static function fullTextFindProvider(): array { + $indexedFieldData = static::getFullTextIndexedFieldData(); + + if ($indexedFieldData === []) { + return [ + [self::NO_FULLTEXT_DATA, self::NO_FULLTEXT_DATA, false, false], + ]; + } + $templates = [ [true, true], [true, false], @@ -1312,7 +1257,7 @@ public function fullTextFindProvider() $fixture = []; - foreach ($this->getFullTextIndexedFieldData() as $valueSet) { + foreach ($indexedFieldData as $valueSet) { foreach ($templates as $template) { array_unshift($template, $valueSet[1]); array_unshift($template, $valueSet[0]); @@ -1324,13 +1269,16 @@ public function fullTextFindProvider() return $fixture; } - /** - * @dataProvider fullTextFindProvider - * - * @depends testCreateTestContent - */ - public function testFullTextFindOne($valueOne, $valueTwo, $filter, $content, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('fullTextFindProvider')] + public function testFullTextFindOne($valueOne, $valueTwo, $filter, $content, array $context): void { + if ($valueOne === self::NO_FULLTEXT_DATA) { + self::markTestSkipped( + 'Skipped by default, override getFullTextIndexedFieldData() in the concrete test case as required by the field type.' + ); + } + $this->checkFullTextSupport(); $criteria = new Criterion\FullText($valueOne); @@ -1338,13 +1286,16 @@ public function testFullTextFindOne($valueOne, $valueTwo, $filter, $content, arr $this->assertFindResult($context, $criteria, true, false, $filter, $content, null); } - /** - * @dataProvider fullTextFindProvider - * - * @depends testCreateTestContent - */ - public function testFullTextFindTwo($valueOne, $valueTwo, $filter, $content, array $context) + #[Depends('testCreateTestContent')] + #[DataProvider('fullTextFindProvider')] + public function testFullTextFindTwo($valueOne, $valueTwo, $filter, $content, array $context): void { + if ($valueOne === self::NO_FULLTEXT_DATA) { + self::markTestSkipped( + 'Skipped by default, override getFullTextIndexedFieldData() in the concrete test case as required by the field type.' + ); + } + $this->checkFullTextSupport(); $criteria = new Criterion\FullText($valueTwo); diff --git a/tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php b/tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php index d7516cc2e4..5e823919d6 100644 --- a/tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php +++ b/tests/integration/Core/Repository/FieldType/SearchMultivaluedBaseIntegrationTestCase.php @@ -11,6 +11,8 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\LogicalNot; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\Operator; use Ibexa\Contracts\Core\Test\Repository\SetupFactory\Legacy; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; /** * Integration test for searching and sorting with Field criterion and Field sort clause. @@ -50,7 +52,7 @@ abstract class SearchMultivaluedBaseIntegrationTestCase extends SearchBaseIntegr * * @return mixed */ - abstract protected function getValidMultivaluedSearchValuesOne(); + abstract protected static function getValidMultivaluedSearchValuesOne(); /** * Get search target field value One. @@ -60,9 +62,9 @@ abstract protected function getValidMultivaluedSearchValuesOne(); * * @return mixed */ - protected function getMultivaluedSearchTargetValuesOne() + protected static function getMultivaluedSearchTargetValuesOne() { - return $this->getValidMultivaluedSearchValuesOne(); + return static::getValidMultivaluedSearchValuesOne(); } /** @@ -76,7 +78,7 @@ protected function getMultivaluedSearchTargetValuesOne() * * @return mixed */ - abstract protected function getValidMultivaluedSearchValuesTwo(); + abstract protected static function getValidMultivaluedSearchValuesTwo(); /** * Get search target field value Two. @@ -86,12 +88,12 @@ abstract protected function getValidMultivaluedSearchValuesTwo(); * * @return mixed */ - protected function getMultivaluedSearchTargetValuesTwo() + protected static function getMultivaluedSearchTargetValuesTwo() { - return $this->getValidMultivaluedSearchValuesTwo(); + return static::getValidMultivaluedSearchValuesTwo(); } - protected function getAdditionallyIndexedMultivaluedFieldData() + protected static function getAdditionallyIndexedMultivaluedFieldData() { return []; } @@ -181,13 +183,13 @@ public function testCreateMultivaluedTestContent(): array * * @return array */ - public function findMultivaluedProvider() + public static function findMultivaluedProvider(): array { - $additionalFields = $this->getAdditionallyIndexedMultivaluedFieldData(); + $additionalFields = static::getAdditionallyIndexedMultivaluedFieldData(); $additionalFields[] = [ null, - $this->getMultivaluedSearchTargetValuesOne(), - $this->getMultivaluedSearchTargetValuesTwo(), + static::getMultivaluedSearchTargetValuesOne(), + static::getMultivaluedSearchTargetValuesTwo(), ]; $templates = [ [true, true], @@ -219,12 +221,10 @@ public function findMultivaluedProvider() * value EQ One * * The result should contain Content One. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedEqualsOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedEqualsOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::EQ); @@ -243,12 +243,10 @@ public function testFindMultivaluedEqualsOne($valuesOne, $valuesTwo, $filter, $c * NOT( value EQ One ) * * The result should contain Content Two. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedNotEqualsOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedNotEqualsOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::EQ); @@ -267,12 +265,10 @@ public function testFindMultivaluedNotEqualsOne($valuesOne, $valuesTwo, $filter, * value IN [One] * * The result should contain Content One. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedInOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedInOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::IN); @@ -289,12 +285,10 @@ public function testFindMultivaluedInOne($valuesOne, $valuesTwo, $filter, $conte * NOT( value IN [One] ) * * The result should contain Content Two. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedNotInOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedNotInOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::IN); @@ -313,12 +307,10 @@ public function testFindMultivaluedNotInOne($valuesOne, $valuesTwo, $filter, $co * value IN [One,Two] * * The result should contain both Content One and Content Two. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedInOneTwo($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedInOneTwo($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::IN); @@ -335,12 +327,10 @@ public function testFindMultivaluedInOneTwo($valuesOne, $valuesTwo, $filter, $co * NOT( value IN [One,Two] ) * * The result should be empty. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedNotInOneTwo($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedNotInOneTwo($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::IN); @@ -359,12 +349,10 @@ public function testFindMultivaluedNotInOneTwo($valuesOne, $valuesTwo, $filter, * value CONTAINS One * * The result should contain Content One. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedContainsOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedContainsOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::CONTAINS); @@ -383,12 +371,10 @@ public function testFindMultivaluedContainsOne($valuesOne, $valuesTwo, $filter, * NOT( value CONTAINS One ) * * The result should contain Content Two. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedNotContainsOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedNotContainsOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::CONTAINS); @@ -407,12 +393,10 @@ public function testFindMultivaluedNotContainsOne($valuesOne, $valuesTwo, $filte * value GT One[0] * * The result should contain both Content One and Content Two. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedGreaterThanOneFindsOneTwo($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedGreaterThanOneFindsOneTwo($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::GT); @@ -429,12 +413,10 @@ public function testFindMultivaluedGreaterThanOneFindsOneTwo($valuesOne, $values * value GT One[1] * * The result should contain Content Two. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedGreaterThanOneFindsTwo($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedGreaterThanOneFindsTwo($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::GT); @@ -451,12 +433,10 @@ public function testFindMultivaluedGreaterThanOneFindsTwo($valuesOne, $valuesTwo * NOT( value GT One[0] ) * * The result should be empty. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedNotGreaterThanOneFindsOneTwo($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedNotGreaterThanOneFindsOneTwo($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::GT); @@ -473,12 +453,10 @@ public function testFindMultivaluedNotGreaterThanOneFindsOneTwo($valuesOne, $val * NOT( value GT One[1] ) * * The result should contain Content One. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedNotGreaterThanOneFindsTwo($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedNotGreaterThanOneFindsTwo($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::GT); @@ -495,12 +473,10 @@ public function testFindMultivaluedNotGreaterThanOneFindsTwo($valuesOne, $values * value GTE One * * The result should contain both Content One and Content Two. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedGreaterThanOrEqualOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedGreaterThanOrEqualOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::GTE); @@ -519,12 +495,10 @@ public function testFindMultivaluedGreaterThanOrEqualOne($valuesOne, $valuesTwo, * NOT( value GTE One ) * * The result should be empty. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedNotGreaterThanOrEqual($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedNotGreaterThanOrEqual($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::GTE); @@ -543,12 +517,10 @@ public function testFindMultivaluedNotGreaterThanOrEqual($valuesOne, $valuesTwo, * value LT One[0] * * The result should be empty. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedLowerThanOneEmpty($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedLowerThanOneEmpty($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::LT); @@ -565,12 +537,10 @@ public function testFindMultivaluedLowerThanOneEmpty($valuesOne, $valuesTwo, $fi * value LT One[1] * * The result should contain Content One. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedLowerThanOneFindsOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedLowerThanOneFindsOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::LT); @@ -587,12 +557,10 @@ public function testFindMultivaluedLowerThanOneFindsOne($valuesOne, $valuesTwo, * NOT( value LT One[0] ) * * The result should contain both Content One and Content Two. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedNotLowerThanOneEmpty($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedNotLowerThanOneEmpty($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::LT); @@ -609,12 +577,10 @@ public function testFindMultivaluedNotLowerThanOneEmpty($valuesOne, $valuesTwo, * NOT( value LT One[1] ) * * The result should contain Content Two. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedNotLowerThanOneFindsOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedNotLowerThanOneFindsOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::LT); @@ -631,12 +597,10 @@ public function testFindMultivaluedNotLowerThanOneFindsOne($valuesOne, $valuesTw * value LTE One * * The result should contain Content One. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedLowerThanOrEqualOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedLowerThanOrEqualOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::LTE); @@ -655,12 +619,10 @@ public function testFindMultivaluedLowerThanOrEqualOne($valuesOne, $valuesTwo, $ * NOT( value LTE One ) * * The result should contain Content Two. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedNotLowerThanOrEqualOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedNotLowerThanOrEqualOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::LTE); @@ -679,12 +641,10 @@ public function testFindMultivaluedNotLowerThanOrEqualOne($valuesOne, $valuesTwo * value BETWEEN [One,Two] * * The result should contain both Content One and Content Two. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedBetweenOneTwo($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedBetweenOneTwo($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::BETWEEN); @@ -712,12 +672,10 @@ public function testFindMultivaluedBetweenOneTwo($valuesOne, $valuesTwo, $filter * NOT( value BETWEEN [One,Two] ) * * The result should contain both Content One and Content Two. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedNotBetweenOneTwo($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedNotBetweenOneTwo($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::BETWEEN); @@ -747,12 +705,10 @@ public function testFindMultivaluedNotBetweenOneTwo($valuesOne, $valuesTwo, $fil * value BETWEEN [Two,One] * * The result should be empty. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedBetweenTwoOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedBetweenTwoOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::BETWEEN); @@ -780,12 +736,10 @@ public function testFindMultivaluedBetweenTwoOne($valuesOne, $valuesTwo, $filter * NOT( value BETWEEN [Two,One] ) * * The result should contain both Content One and Content Two. - * - * @dataProvider findMultivaluedProvider - * - * @depends testCreateMultivaluedTestContent */ - public function testFindMultivaluedNotBetweenTwoOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context) + #[Depends('testCreateMultivaluedTestContent')] + #[DataProvider('findMultivaluedProvider')] + public function testFindMultivaluedNotBetweenTwoOne($valuesOne, $valuesTwo, $filter, $content, $modifyField, array $context): void { $this->checkOperatorSupport(Operator::BETWEEN); diff --git a/tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php b/tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php index 2b81e3ae53..47bbca5222 100644 --- a/tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/SelectionIntegrationTest.php @@ -11,13 +11,13 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Field; use Ibexa\Core\Base\Exceptions\InvalidArgumentType; use Ibexa\Core\FieldType\Selection\Value as SelectionValue; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] class SelectionIntegrationTest extends SearchMultivaluedBaseIntegrationTestCase { /** @@ -181,7 +181,7 @@ public function assertFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidCreationFieldData() + public static function provideInvalidCreationFieldData(): array { return [ [ @@ -228,9 +228,9 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidUpdateFieldData() + public static function provideInvalidUpdateFieldData(): array { - return $this->provideInvalidCreationFieldData(); + return self::provideInvalidCreationFieldData(); } /** @@ -277,7 +277,7 @@ public function assertCopiedFieldDataLoadedCorrectly(Field $field) * * @return array */ - public function provideToHashData() + public static function provideToHashData(): array { return [ [ @@ -294,7 +294,7 @@ public function provideToHashData() * * @return array */ - public function provideFromHashData() + public static function provideFromHashData(): array { return [ [ @@ -304,7 +304,10 @@ public function provideFromHashData() ]; } - public function providerForTestIsEmptyValue() + /** + * @return array + */ + public static function providerForTestIsEmptyValue(): array { return [ [new SelectionValue()], @@ -312,11 +315,14 @@ public function providerForTestIsEmptyValue() ]; } - public function providerForTestIsNotEmptyValue() + /** + * @return array + */ + public static function providerForTestIsNotEmptyValue(): array { return [ [ - $this->getValidCreationFieldData(), + new SelectionValue([0, 2]), ], [ new SelectionValue([0]), @@ -324,27 +330,27 @@ public function providerForTestIsNotEmptyValue() ]; } - protected function getValidSearchValueOne() + protected static function getValidSearchValueOne() { return [1]; } - protected function getValidSearchValueTwo() + protected static function getValidSearchValueTwo() { return [2]; } - protected function getSearchTargetValueOne() + protected static function getSearchTargetValueOne() { return 1; } - protected function getSearchTargetValueTwo() + protected static function getSearchTargetValueTwo() { return 2; } - protected function getAdditionallyIndexedFieldData() + protected static function getAdditionallyIndexedFieldData() { return [ [ @@ -360,17 +366,17 @@ protected function getAdditionallyIndexedFieldData() ]; } - protected function getValidMultivaluedSearchValuesOne() + protected static function getValidMultivaluedSearchValuesOne() { return [0, 1]; } - protected function getValidMultivaluedSearchValuesTwo() + protected static function getValidMultivaluedSearchValuesTwo() { return [2, 3, 4]; } - protected function getAdditionallyIndexedMultivaluedFieldData() + protected static function getAdditionallyIndexedMultivaluedFieldData() { return [ [ @@ -381,7 +387,7 @@ protected function getAdditionallyIndexedMultivaluedFieldData() ]; } - protected function getFullTextIndexedFieldData() + protected static function getFullTextIndexedFieldData() { return [ ['Bielefeld', 'Sindelfingen'], diff --git a/tests/integration/Core/Repository/FieldType/SelectionMultilingualIntegrationTest.php b/tests/integration/Core/Repository/FieldType/SelectionMultilingualIntegrationTest.php index 0cdb894853..f4c567883c 100644 --- a/tests/integration/Core/Repository/FieldType/SelectionMultilingualIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/SelectionMultilingualIntegrationTest.php @@ -7,12 +7,13 @@ namespace Ibexa\Tests\Integration\Core\Repository\FieldType; +use PHPUnit\Framework\Attributes\Group; + /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] class SelectionMultilingualIntegrationTest extends SelectionIntegrationTest { /** @@ -90,7 +91,7 @@ public function getFieldName(): string return 'Arkansas' . ' ' . 'Mississippi'; } - protected function getAdditionallyIndexedFieldData() + protected static function getAdditionallyIndexedFieldData() { return [ [ @@ -106,7 +107,7 @@ protected function getAdditionallyIndexedFieldData() ]; } - protected function getAdditionallyIndexedMultivaluedFieldData() + protected static function getAdditionallyIndexedMultivaluedFieldData() { return [ [ @@ -117,7 +118,7 @@ protected function getAdditionallyIndexedMultivaluedFieldData() ]; } - protected function getFullTextIndexedFieldData() + protected static function getFullTextIndexedFieldData() { return [ ['Hudson', 'Mississippi'], diff --git a/tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php b/tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php index 57bd917726..33c45b9091 100644 --- a/tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/TextBlockIntegrationTest.php @@ -10,13 +10,13 @@ use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException; use Ibexa\Contracts\Core\Repository\Values\Content\Field; use Ibexa\Core\FieldType\TextBlock\Value as TextBlockValue; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] class TextBlockIntegrationTest extends SearchBaseIntegrationTestCase { /** @@ -144,7 +144,7 @@ public function assertFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidCreationFieldData() + public static function provideInvalidCreationFieldData(): array { return [ [ @@ -187,9 +187,9 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidUpdateFieldData() + public static function provideInvalidUpdateFieldData(): array { - return $this->provideInvalidCreationFieldData(); + return self::provideInvalidCreationFieldData(); } /** @@ -236,7 +236,7 @@ public function assertCopiedFieldDataLoadedCorrectly(Field $field) * * @return array */ - public function provideToHashData() + public static function provideToHashData(): array { return [ [ @@ -253,7 +253,7 @@ public function provideToHashData() * * @return array */ - public function provideFromHashData() + public static function provideFromHashData(): array { return [ [ @@ -263,7 +263,10 @@ public function provideFromHashData() ]; } - public function providerForTestIsEmptyValue() + /** + * @return array + */ + public static function providerForTestIsEmptyValue(): array { return [ [new TextBlockValue()], @@ -275,39 +278,42 @@ public function providerForTestIsEmptyValue() ]; } - public function providerForTestIsNotEmptyValue() + /** + * @return array + */ + public static function providerForTestIsNotEmptyValue(): array { return [ [ - $this->getValidCreationFieldData(), + new TextBlockValue('Example'), ], [new TextBlockValue('0')], ]; } - protected function getValidSearchValueOne(): string + protected static function getValidSearchValueOne(): string { return 'caution is the " path to mediocrity something completely different'; } - protected function getSearchTargetValueOne(): string + protected static function getSearchTargetValueOne(): string { // ensure case-insensitivity return strtoupper('caution is the " path to mediocrity something completely different'); } - protected function getValidSearchValueTwo(): string + protected static function getValidSearchValueTwo(): string { return "truth suffers from ' too much analysis hello and goodbye"; } - protected function getSearchTargetValueTwo(): string + protected static function getSearchTargetValueTwo(): string { // ensure case-insensitivity return strtoupper("truth suffers from ' too much analysis hello and goodbye"); } - protected function getFullTextIndexedFieldData() + protected static function getFullTextIndexedFieldData() { return [ ['path', 'analysis'], diff --git a/tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php b/tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php index 464a6423f4..2b4b8f059a 100644 --- a/tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/TextLineIntegrationTest.php @@ -11,13 +11,13 @@ use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException; use Ibexa\Contracts\Core\Repository\Values\Content\Field; use Ibexa\Core\FieldType\TextLine\Value as TextLineValue; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] class TextLineIntegrationTest extends SearchBaseIntegrationTestCase { /** @@ -156,7 +156,7 @@ public function assertFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidCreationFieldData() + public static function provideInvalidCreationFieldData(): array { return [ [ @@ -207,9 +207,9 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidUpdateFieldData() + public static function provideInvalidUpdateFieldData(): array { - return $this->provideInvalidCreationFieldData(); + return self::provideInvalidCreationFieldData(); } /** @@ -256,7 +256,7 @@ public function assertCopiedFieldDataLoadedCorrectly(Field $field) * * @return array */ - public function provideToHashData() + public static function provideToHashData(): array { return [ [ @@ -273,7 +273,7 @@ public function provideToHashData() * * @return array */ - public function provideFromHashData() + public static function provideFromHashData(): array { return [ [ @@ -283,7 +283,10 @@ public function provideFromHashData() ]; } - public function providerForTestIsEmptyValue() + /** + * @return array + */ + public static function providerForTestIsEmptyValue(): array { return [ [new TextLineValue()], @@ -293,39 +296,42 @@ public function providerForTestIsEmptyValue() ]; } - public function providerForTestIsNotEmptyValue() + /** + * @return array + */ + public static function providerForTestIsNotEmptyValue(): array { return [ [ - $this->getValidCreationFieldData(), + new TextLineValue('Example'), ], [new TextLineValue('0')], ]; } - protected function getValidSearchValueOne(): string + protected static function getValidSearchValueOne(): string { return 'aaa'; } - protected function getSearchTargetValueOne(): string + protected static function getSearchTargetValueOne(): string { // ensure case-insensitivity - return strtoupper($this->getValidSearchValueOne()); + return strtoupper(static::getValidSearchValueOne()); } - protected function getValidSearchValueTwo(): string + protected static function getValidSearchValueTwo(): string { return 'bbb'; } - protected function getSearchTargetValueTwo(): string + protected static function getSearchTargetValueTwo(): string { // ensure case-insensitivity - return strtoupper($this->getValidSearchValueTwo()); + return strtoupper(static::getValidSearchValueTwo()); } - protected function getFullTextIndexedFieldData() + protected static function getFullTextIndexedFieldData() { return [ ['aaa', 'bbb'], diff --git a/tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php b/tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php index 18346147b0..fc13b1b4c3 100644 --- a/tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/TimeIntegrationTest.php @@ -11,13 +11,14 @@ use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException; use Ibexa\Contracts\Core\Repository\Values\Content\Field; use Ibexa\Core\FieldType\Time\Value as TimeValue; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] class TimeIntegrationTest extends SearchBaseIntegrationTestCase { /** @@ -160,7 +161,7 @@ public function assertFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidCreationFieldData() + public static function provideInvalidCreationFieldData(): array { return [ [ @@ -203,9 +204,9 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidUpdateFieldData() + public static function provideInvalidUpdateFieldData(): array { - return $this->provideInvalidCreationFieldData(); + return self::provideInvalidCreationFieldData(); } /** @@ -213,9 +214,8 @@ public function provideInvalidUpdateFieldData() * * @param mixed $failingValue * @param string $expectedException - * - * @dataProvider provideInvalidUpdateFieldData */ + #[DataProvider('provideInvalidUpdateFieldData')] public function testUpdateContentFails($failingValue, $expectedException) { return [ @@ -269,7 +269,7 @@ public function assertCopiedFieldDataLoadedCorrectly(Field $field) * * @return array */ - public function provideToHashData() + public static function provideToHashData(): array { $timestamp = 123456; $dateTime = new DateTime("@{$timestamp}"); @@ -289,7 +289,7 @@ public function provideToHashData() * * @return array */ - public function provideFromHashData() + public static function provideFromHashData(): array { return [ [ @@ -299,38 +299,44 @@ public function provideFromHashData() ]; } - public function providerForTestIsEmptyValue() + /** + * @return array + */ + public static function providerForTestIsEmptyValue(): array { return [ [new TimeValue()], ]; } - public function providerForTestIsNotEmptyValue() + /** + * @return array + */ + public static function providerForTestIsNotEmptyValue(): array { return [ [ - $this->getValidCreationFieldData(), + new TimeValue(3661), ], ]; } - protected function getValidSearchValueOne() + protected static function getValidSearchValueOne() { - return new TimeValue($this->getSearchTargetValueOne()); + return new TimeValue(static::getSearchTargetValueOne()); } - protected function getValidSearchValueTwo() + protected static function getValidSearchValueTwo() { - return new TimeValue($this->getSearchTargetValueTwo()); + return new TimeValue(static::getSearchTargetValueTwo()); } - protected function getSearchTargetValueOne(): int + protected static function getSearchTargetValueOne(): int { return 9600; } - protected function getSearchTargetValueTwo(): int + protected static function getSearchTargetValueTwo(): int { return 14400; } diff --git a/tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php b/tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php index 7eed11de62..a237ccf53d 100644 --- a/tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/UrlIntegrationTest.php @@ -10,13 +10,13 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Field; use Ibexa\Core\Base\Exceptions\InvalidArgumentType; use Ibexa\Core\FieldType\Url\Value as UrlValue; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] class UrlIntegrationTest extends SearchBaseIntegrationTestCase { /** @@ -138,7 +138,7 @@ public function assertFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidCreationFieldData() + public static function provideInvalidCreationFieldData(): array { return [ [ @@ -186,9 +186,9 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field) ); } - public function provideInvalidUpdateFieldData() + public static function provideInvalidUpdateFieldData(): array { - return $this->provideInvalidCreationFieldData(); + return self::provideInvalidCreationFieldData(); } /** @@ -236,7 +236,7 @@ public function assertCopiedFieldDataLoadedCorrectly(Field $field) * * @return array */ - public function provideToHashData() + public static function provideToHashData(): array { return [ [ @@ -263,7 +263,7 @@ public function provideToHashData() * * @return array */ - public function provideFromHashData() + public static function provideFromHashData(): array { return [ [ @@ -277,7 +277,10 @@ public function provideFromHashData() ]; } - public function providerForTestIsEmptyValue() + /** + * @return array + */ + public static function providerForTestIsEmptyValue(): array { return [ [new UrlValue()], @@ -287,11 +290,14 @@ public function providerForTestIsEmptyValue() ]; } - public function providerForTestIsNotEmptyValue() + /** + * @return array + */ + public static function providerForTestIsNotEmptyValue(): array { return [ [ - $this->getValidCreationFieldData(), + new UrlValue('http://example.com', 'Example'), ], [ new UrlValue('http://example.com'), @@ -299,27 +305,27 @@ public function providerForTestIsNotEmptyValue() ]; } - protected function getValidSearchValueOne() + protected static function getValidSearchValueOne() { return new UrlValue('http://ample.com', 'Ample'); } - protected function getValidSearchValueTwo() + protected static function getValidSearchValueTwo() { return new UrlValue('http://example.com', 'Example'); } - protected function getSearchTargetValueOne(): string + protected static function getSearchTargetValueOne(): string { return 'http://ample.com'; } - protected function getSearchTargetValueTwo(): string + protected static function getSearchTargetValueTwo(): string { return 'http://example.com'; } - protected function getAdditionallyIndexedFieldData() + protected static function getAdditionallyIndexedFieldData() { return [ [ @@ -331,7 +337,7 @@ protected function getAdditionallyIndexedFieldData() ]; } - protected function getFullTextIndexedFieldData() + protected static function getFullTextIndexedFieldData() { return [ ['ample', 'example'], diff --git a/tests/integration/Core/Repository/FieldType/UserIntegrationTest.php b/tests/integration/Core/Repository/FieldType/UserIntegrationTest.php index 42149e7089..2241e2b790 100644 --- a/tests/integration/Core/Repository/FieldType/UserIntegrationTest.php +++ b/tests/integration/Core/Repository/FieldType/UserIntegrationTest.php @@ -17,13 +17,14 @@ use Ibexa\Core\FieldType\User\Value as UserValue; use Ibexa\Core\Repository\Values\User\User; use Ibexa\Tests\Core\FieldType\DataProvider\UserValidatorConfigurationSchemaProvider; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\Group; /** * Integration test for use field type. - * - * @group integration - * @group field-type */ +#[Group('integration')] +#[Group('field-type')] class UserIntegrationTest extends BaseIntegrationTestCase { private const TEST_LOGIN = 'hans'; @@ -191,7 +192,7 @@ public function assertFieldDataLoadedCorrect(Field $field) self::assertNotNull($field->value->contentId); } - public function provideInvalidCreationFieldData() + public static function provideInvalidCreationFieldData(): array { return []; } @@ -252,7 +253,7 @@ public function assertUpdatedFieldDataLoadedCorrect(Field $field) self::assertNotNull($field->value->contentId); } - public function provideInvalidUpdateFieldData() + public static function provideInvalidUpdateFieldData(): array { return [ [ @@ -315,7 +316,7 @@ public function assertCopiedFieldDataLoadedCorrectly(Field $field) * * @return array */ - public function provideToHashData() + public static function provideToHashData(): array { return [ [ @@ -356,7 +357,7 @@ public function provideToHashData() * * @return array */ - public function provideFromHashData() + public static function provideFromHashData(): array { return [ [ @@ -405,12 +406,15 @@ protected function createContent($fieldData, $contentType = null) return $contentService->createContentDraft($user->content->contentInfo, $user->content->versionInfo); } - public function testCreateContentWithEmptyFieldValue() + public function testCreateContentWithEmptyFieldValue(): void { self::markTestSkipped('User field will never be created empty'); } - public function providerForTestIsEmptyValue() + /** + * @return array + */ + public static function providerForTestIsEmptyValue(): array { return [ [new UserValue()], @@ -418,16 +422,24 @@ public function providerForTestIsEmptyValue() ]; } - public function providerForTestIsNotEmptyValue() + /** + * @return array + */ + public static function providerForTestIsNotEmptyValue(): array { return [ [ - $this->getValidCreationFieldData(), + new UserValue([ + 'login' => self::TEST_LOGIN, + 'email' => sprintf('%s@example.com', self::TEST_LOGIN), + 'enabled' => true, + 'plainPassword' => 'PassWord42', + ]), ], ]; } - public function testRemoveFieldDefinition() + public function testRemoveFieldDefinition(): void { $repository = $this->getRepository(); $contentService = $repository->getContentService(); @@ -457,9 +469,7 @@ public function testAddFieldDefinition() return parent::testAddFieldDefinition(); } - /** - * @depends testCreateContent - */ + #[Depends('testCreateContent')] public function testCopyField($content) { // Users cannot be copied. @@ -469,18 +479,14 @@ public function testCopyField($content) return parent::testCopyField($content); } - /** - * @depends testCopyField - */ - public function testCopiedFieldType($content) + #[Depends('testCopyField')] + public function testCopiedFieldType($content): void { self::markTestSkipped('Users cannot be copied, content is not passed to test.'); } - /** - * @depends testCopiedFieldType - */ - public function testCopiedExternalData(Field $field) + #[Depends('testCopiedFieldType')] + public function testCopiedExternalData(Field $field): void { self::markTestSkipped('Users cannot be copied, field is not passed to test.'); } @@ -488,7 +494,7 @@ public function testCopiedExternalData(Field $field) /** * @see https://issues.ibexa.co/browse/EZP-30966 */ - public function testUpdateFieldDefinitionWithIncompleteSettingsSchema() + public function testUpdateFieldDefinitionWithIncompleteSettingsSchema(): void { $contentTypeService = $this->getRepository()->getContentTypeService(); $contentType = $this->testCreateContentType(); diff --git a/tests/integration/Core/Repository/FieldTypeServiceTest.php b/tests/integration/Core/Repository/FieldTypeServiceTest.php index d3e64a880d..64689aacaf 100644 --- a/tests/integration/Core/Repository/FieldTypeServiceTest.php +++ b/tests/integration/Core/Repository/FieldTypeServiceTest.php @@ -8,22 +8,21 @@ namespace Ibexa\Tests\Integration\Core\Repository; use Ibexa\Contracts\Core\Repository\FieldType; +use Ibexa\Core\Repository\FieldTypeService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the FieldTypeService using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\FieldTypeService - * - * @group field-type */ +#[CoversClass(FieldTypeService::class)] +#[Group('field-type')] class FieldTypeServiceTest extends BaseTestCase { /** * Test for the getFieldTypes() method. - * - * @covers \Ibexa\Contracts\Core\Repository\FieldTypeService::getFieldTypes() */ - public function testGetFieldTypes() + public function testGetFieldTypes(): void { $repository = $this->getRepository(); @@ -49,10 +48,8 @@ public function testGetFieldTypes() * Test for the getFieldType() method. * * Expects FieldType "ibexa_url" to be available! - * - * @covers \Ibexa\Contracts\Core\Repository\FieldTypeService::getFieldType() */ - public function testGetFieldType() + public function testGetFieldType(): void { $repository = $this->getRepository(); @@ -75,10 +72,8 @@ public function testGetFieldType() /** * Test for the getFieldType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\FieldTypeService::getFieldType() */ - public function testGetFieldTypeThrowsNotFoundException() + public function testGetFieldTypeThrowsNotFoundException(): void { $this->expectException(\RuntimeException::class); @@ -94,10 +89,8 @@ public function testGetFieldTypeThrowsNotFoundException() /** * Test for the hasFieldType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\FieldTypeService::hasFieldType() */ - public function testHasFieldTypeReturnsTrue() + public function testHasFieldTypeReturnsTrue(): void { $repository = $this->getRepository(); @@ -113,10 +106,8 @@ public function testHasFieldTypeReturnsTrue() /** * Test for the hasFieldType() method. - * - * @covers \Ibexa\Contracts\Core\Repository\FieldTypeService::hasFieldType() */ - public function testHasFieldTypeReturnsFalse() + public function testHasFieldTypeReturnsFalse(): void { $repository = $this->getRepository(); diff --git a/tests/integration/Core/Repository/Filtering/BaseRepositoryFilteringTestCase.php b/tests/integration/Core/Repository/Filtering/BaseRepositoryFilteringTestCase.php index b0f0c448ee..05c5ec008d 100644 --- a/tests/integration/Core/Repository/Filtering/BaseRepositoryFilteringTestCase.php +++ b/tests/integration/Core/Repository/Filtering/BaseRepositoryFilteringTestCase.php @@ -18,13 +18,19 @@ use Ibexa\Contracts\Core\Repository\Values\Filter\FilteringCriterion; use Ibexa\Contracts\Core\Repository\Values\Filter\FilteringSortClause; use Ibexa\Contracts\Core\Repository\Values\User\Limitation; +use Ibexa\Core\Repository\ContentService; +use Ibexa\Core\Repository\LocationService; use Ibexa\Tests\Core\Repository\Filtering\TestContentProvider; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; use IteratorAggregate; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; /** * @internal for internal use by Ibexa Kernel test cases */ +#[CoversClass(ContentService::class)] +#[CoversClass(LocationService::class)] abstract class BaseRepositoryFilteringTestCase extends BaseTestCase { private const PAGINATION_EXPECTED_TOTAL_COUNT = 5; @@ -46,15 +52,11 @@ abstract protected function compareWithSearchResults(Filter $filter, IteratorAgg abstract protected function getDefaultSortClause(): FilteringSortClause; /** - * @dataProvider getFilterFactories - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::find - * @covers \Ibexa\Contracts\Core\Repository\LocationService::find - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ + #[DataProvider('getFilterFactories')] public function testFind(callable $filterFactory): void { $filter = $this->buildFilter( @@ -130,10 +132,6 @@ public function testFindPaginated(): void } /** - * @covers \Ibexa\Contracts\Core\Repository\ContentService::find - * - * @dataProvider getUserLimitationData - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation[] $limitations * @param string[] $expectedContentRemoteIds * @@ -141,6 +139,7 @@ public function testFindPaginated(): void * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ + #[DataProvider('getUserLimitationData')] public function testFindByUserWithLimitations( array $limitations, array $expectedContentRemoteIds @@ -168,7 +167,7 @@ public function testFindByUserWithLimitations( /** * Data provider consumed by children implementations. */ - public function getFilterFactories(): iterable + public static function getFilterFactories(): iterable { // Note: Filter relying on database data cannot be instantiated here // because database data is not available yet @@ -206,7 +205,7 @@ static function (Content $parentFolder): Filter { 5, ]; - foreach ($this->getCriteriaForInitialData() as $dataSetName => $filter) { + foreach (static::getCriteriaForInitialData() as $dataSetName => $filter) { yield $dataSetName => [ static function (Content $parentFolder) use ($filter): Filter { return new Filter($filter); @@ -227,7 +226,7 @@ static function (Content $parentFolder) use ($filter): Filter { * * @see getFilterFactories */ - public function getCriteriaForInitialData(): iterable + public static function getCriteriaForInitialData(): iterable { yield 'Ancestor=/1/5/44/45/' => new Criterion\Ancestor('/1/5/44/45/'); yield 'ContentId=57' => new Criterion\ContentId(57); @@ -315,9 +314,9 @@ protected function assertTotalCount(FilteringCriterion $criterion, int $searchTo * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ - public function getUserLimitationData(): iterable + public static function getUserLimitationData(): iterable { - $repository = $this->getRepository(false); + $repository = static::resolveRepository(false); // Content type Limitations $contentTypeService = $repository->getContentTypeService(); diff --git a/tests/integration/Core/Repository/Filtering/ContentFilteringTest.php b/tests/integration/Core/Repository/Filtering/ContentFilteringTest.php index d3fe38391c..eb5098d509 100644 --- a/tests/integration/Core/Repository/Filtering/ContentFilteringTest.php +++ b/tests/integration/Core/Repository/Filtering/ContentFilteringTest.php @@ -26,6 +26,7 @@ use Ibexa\Tests\Core\Repository\Filtering\TestContentProvider; use function iterator_to_array; use IteratorAggregate; +use PHPUnit\Framework\Attributes\DataProvider; use function sprintf; /** @@ -38,16 +39,14 @@ final class ContentFilteringTest extends BaseRepositoryFilteringTestCase /** * @return iterable */ - public function isBookmarkedProvider(): iterable + public static function isBookmarkedProvider(): iterable { // [isBookmarkedCriterion, initialCount, afterCreateCount, afterDeleteCount] yield 'bookmarked=true' => [true, 0, 1, 0]; yield 'bookmarked=false' => [false, 1, 0, 1]; } - /** - * @dataProvider isBookmarkedProvider - */ + #[DataProvider('isBookmarkedProvider')] public function testIsBookmarkedTrueAndFalse( bool $isBookmarked, int $initialCount, @@ -337,7 +336,7 @@ protected function getDefaultSortClause(): FilteringSortClause return new SortClause\ContentId(); } - public function getFilterFactories(): iterable + public static function getFilterFactories(): iterable { yield from parent::getFilterFactories(); @@ -444,14 +443,13 @@ public function testFindContentWithExternalStorageFields(): void } /** - * @dataProvider getDataForTestFindContentWithLocationCriterion - * * @param string[] $expectedContentRemoteIds * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ + #[DataProvider('getDataForTestFindContentWithLocationCriterion')] public function testFindContentUsingLocationCriterion( callable $filterFactory, array $expectedContentRemoteIds @@ -464,7 +462,7 @@ public function testFindContentUsingLocationCriterion( ); } - public function getDataForTestFindContentWithLocationCriterion(): iterable + public static function getDataForTestFindContentWithLocationCriterion(): iterable { yield 'Content items with secondary Location ignored in content filtering, sorted by Content ID' => [ static function (Content $parentFolder): Filter { @@ -522,10 +520,9 @@ protected function assertFoundContentItemsByRemoteIds( } /** - * @dataProvider getListOfSupportedSortClauses - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException */ + #[DataProvider('getListOfSupportedSortClauses')] public function testFindWithSortClauses(string $sortClauseFQCN): void { $this->performAndAssertSimpleSortClauseQuery(new $sortClauseFQCN(Query::SORT_ASC)); @@ -618,7 +615,7 @@ public function testObjectStateIdCriterionOnMultipleObjectStates(): void } } - public function getListOfSupportedSortClauses(): iterable + public static function getListOfSupportedSortClauses(): iterable { yield 'Content\\Id' => [SortClause\ContentId::class]; yield 'ContentName' => [SortClause\ContentName::class]; diff --git a/tests/integration/Core/Repository/Filtering/LegacyContentFilteringTest.php b/tests/integration/Core/Repository/Filtering/LegacyContentFilteringTest.php index 5f278b1cdf..c0d5170aad 100644 --- a/tests/integration/Core/Repository/Filtering/LegacyContentFilteringTest.php +++ b/tests/integration/Core/Repository/Filtering/LegacyContentFilteringTest.php @@ -16,12 +16,12 @@ use Ibexa\Tests\Integration\Core\Repository\Filtering\Fixtures\LegacyLocationSortClause; use Ibexa\Tests\Integration\Core\RepositoryTestCase; use function iterator_to_array; +use PHPUnit\Framework\Attributes\Group; /** * Integration BC check for legacy location sort clauses wired through the container. - * - * @group repository */ +#[Group('repository')] final class LegacyContentFilteringTest extends RepositoryTestCase { public function testLegacyLocationSortClause(): void diff --git a/tests/integration/Core/Repository/Filtering/LocationFilteringTest.php b/tests/integration/Core/Repository/Filtering/LocationFilteringTest.php index 460ecd524b..04d58ba247 100644 --- a/tests/integration/Core/Repository/Filtering/LocationFilteringTest.php +++ b/tests/integration/Core/Repository/Filtering/LocationFilteringTest.php @@ -16,6 +16,7 @@ use Ibexa\Contracts\Core\Repository\Values\Filter\Filter; use Ibexa\Contracts\Core\Repository\Values\Filter\FilteringSortClause; use IteratorAggregate; +use PHPUnit\Framework\Attributes\DataProvider; /** * @internal @@ -54,16 +55,14 @@ public function testBookmarkedAndNotBookmarkedCountsMatchTotal(): void /** * @return iterable */ - public function isBookmarkedProvider(): iterable + public static function isBookmarkedProvider(): iterable { // [isBookmarkedCriterion, initialCount, afterCreateCount, afterDeleteCount] yield 'bookmarked=true' => [true, 0, 1, 0]; yield 'bookmarked=false' => [false, 1, 0, 1]; } - /** - * @dataProvider isBookmarkedProvider - */ + #[DataProvider('isBookmarkedProvider')] public function testIsBookmarkedTrueAndFalse( bool $isBookmarked, int $initialCount, @@ -189,7 +188,7 @@ protected function getDefaultSortClause(): FilteringSortClause return new Query\SortClause\Location\Id(); } - public function getCriteriaForInitialData(): iterable + public static function getCriteriaForInitialData(): iterable { yield 'Location\\Depth=2' => new Criterion\Location\Depth(Criterion\Operator::EQ, 2); yield 'Location\\IsMainLocation' => new Criterion\Location\IsMainLocation( diff --git a/tests/integration/Core/Repository/LanguageServiceAuthorizationTest.php b/tests/integration/Core/Repository/LanguageServiceAuthorizationTest.php index e5e35eb203..6897510f25 100644 --- a/tests/integration/Core/Repository/LanguageServiceAuthorizationTest.php +++ b/tests/integration/Core/Repository/LanguageServiceAuthorizationTest.php @@ -8,25 +8,22 @@ namespace Ibexa\Tests\Integration\Core\Repository; use Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException; +use Ibexa\Core\Repository\LanguageService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the LanguageService using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService - * - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testLoadUser - * - * @group integration - * @group authorization */ +#[CoversClass(LanguageService::class)] +#[Group('integration')] +#[Group('authorization')] class LanguageServiceAuthorizationTest extends BaseTestCase { /** * Test for the createLanguage() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::createLanguage() */ - public function testCreateLanguageThrowsUnauthorizedException() + public function testCreateLanguageThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -55,10 +52,8 @@ public function testCreateLanguageThrowsUnauthorizedException() /** * Test for the updateLanguageName() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::updateLanguageName() */ - public function testUpdateLanguageNameThrowsUnauthorizedException() + public function testUpdateLanguageNameThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -91,10 +86,8 @@ public function testUpdateLanguageNameThrowsUnauthorizedException() /** * Test for the enableLanguage() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::enableLanguage() */ - public function testEnableLanguageThrowsUnauthorizedException() + public function testEnableLanguageThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -125,10 +118,8 @@ public function testEnableLanguageThrowsUnauthorizedException() /** * Test for the disableLanguage() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::disableLanguage() */ - public function testDisableLanguageThrowsUnauthorizedException() + public function testDisableLanguageThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -159,10 +150,8 @@ public function testDisableLanguageThrowsUnauthorizedException() /** * Test for the deleteLanguage() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::deleteLanguage() */ - public function testDeleteLanguageThrowsUnauthorizedException() + public function testDeleteLanguageThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/LanguageServiceMaximumSupportedLanguagesTest.php b/tests/integration/Core/Repository/LanguageServiceMaximumSupportedLanguagesTest.php index d4fd5ad626..26892d6b24 100644 --- a/tests/integration/Core/Repository/LanguageServiceMaximumSupportedLanguagesTest.php +++ b/tests/integration/Core/Repository/LanguageServiceMaximumSupportedLanguagesTest.php @@ -8,15 +8,19 @@ namespace Ibexa\Tests\Integration\Core\Repository; use Ibexa\Contracts\Core\Test\Repository\SetupFactory\Legacy as LegacySetupFactory; +use Ibexa\Core\Repository\LanguageService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DependsExternal; +use PHPUnit\Framework\Attributes\Group; /** * Test case for maximum number of languages supported in the LanguageService. * * @see \Ibexa\Contracts\Core\Repository\LanguageService - * - * @group integration - * @group language */ +#[CoversClass(LanguageService::class)] +#[Group('integration')] +#[Group('language')] class LanguageServiceMaximumSupportedLanguagesTest extends BaseTestCase { /** @var \Ibexa\Contracts\Core\Repository\LanguageService */ @@ -73,12 +77,9 @@ protected function tearDown(): void /** * Test for the number of maximum language that can be created. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::createLanguage() - * - * @depends Ibexa\Tests\Integration\Core\Repository\LanguageServiceTest::testNewLanguageCreateStruct */ - public function testCreateMaximumLanguageLimit() + #[DependsExternal(LanguageServiceTest::class, 'testNewLanguageCreateStruct')] + public function testCreateMaximumLanguageLimit(): void { $this->expectException(\RuntimeException::class); $this->expectExceptionMessage('Maximum number of languages reached.'); diff --git a/tests/integration/Core/Repository/LanguageServiceTest.php b/tests/integration/Core/Repository/LanguageServiceTest.php index 3226bce22e..e727be4e16 100644 --- a/tests/integration/Core/Repository/LanguageServiceTest.php +++ b/tests/integration/Core/Repository/LanguageServiceTest.php @@ -12,23 +12,23 @@ use Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException; use Ibexa\Contracts\Core\Repository\Values\Content\Language; use Ibexa\Contracts\Core\Repository\Values\Content\LanguageCreateStruct; +use Ibexa\Core\Repository\LanguageService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the LanguageService using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService - * - * @group integration - * @group language */ +#[CoversClass(LanguageService::class)] +#[Group('integration')] +#[Group('language')] class LanguageServiceTest extends BaseTestCase { /** * Test for the newLanguageCreateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::newLanguageCreateStruct */ - public function testNewLanguageCreateStruct() + public function testNewLanguageCreateStruct(): void { $repository = $this->getRepository(); @@ -57,11 +57,8 @@ public function testNewLanguageCreateStruct() * Test for the createLanguage() method. * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Language - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::createLanguage - * - * @depends testNewLanguageCreateStruct */ + #[Depends('testNewLanguageCreateStruct')] public function testCreateLanguage() { $repository = $this->getRepository(); @@ -89,12 +86,9 @@ public function testCreateLanguage() * Test for the createLanguage() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Language $language - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::createLanguage - * - * @depends testCreateLanguage */ - public function testCreateLanguageSetsIdPropertyOnReturnedLanguage($language) + #[Depends('testCreateLanguage')] + public function testCreateLanguageSetsIdPropertyOnReturnedLanguage($language): void { self::assertNotNull($language->id); } @@ -103,12 +97,9 @@ public function testCreateLanguageSetsIdPropertyOnReturnedLanguage($language) * Test for the createLanguage() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Language $language - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::createLanguage - * - * @depends testCreateLanguage */ - public function testCreateLanguageSetsExpectedProperties($language) + #[Depends('testCreateLanguage')] + public function testCreateLanguageSetsExpectedProperties($language): void { self::assertEquals( [ @@ -126,12 +117,9 @@ public function testCreateLanguageSetsExpectedProperties($language) /** * Test for the createLanguage() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::createLanguage - * - * @depends testCreateLanguage */ - public function testCreateLanguageThrowsInvalidArgumentException() + #[Depends('testCreateLanguage')] + public function testCreateLanguageThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Argument \'languageCreateStruct\' is invalid: language with the "nor-NO" language code already exists'); @@ -156,13 +144,9 @@ public function testCreateLanguageThrowsInvalidArgumentException() /** * Test for the loadLanguageById() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::loadLanguageById - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::loadLanguageListById - * - * @depends testCreateLanguage */ - public function testLoadLanguageById() + #[Depends('testCreateLanguage')] + public function testLoadLanguageById(): void { $repository = $this->getRepository(); @@ -191,13 +175,9 @@ public function testLoadLanguageById() /** * Test for the loadLanguageById() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::loadLanguageById - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::loadLanguageListById - * - * @depends testLoadLanguageById */ - public function testLoadLanguageByIdThrowsNotFoundException() + #[Depends('testLoadLanguageById')] + public function testLoadLanguageByIdThrowsNotFoundException(): void { $repository = $this->getRepository(); @@ -218,12 +198,9 @@ public function testLoadLanguageByIdThrowsNotFoundException() /** * Test for the updateLanguageName() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::updateLanguageName - * - * @depends testLoadLanguageById */ - public function testUpdateLanguageName() + #[Depends('testLoadLanguageById')] + public function testUpdateLanguageName(): void { $repository = $this->getRepository(); @@ -266,10 +243,8 @@ public function testUpdateLanguageName() /** * Test service method for updating language name throwing InvalidArgumentException. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::updateLanguageName */ - public function testUpdateLanguageNameThrowsInvalidArgumentException() + public function testUpdateLanguageNameThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Argument \'newName\' is invalid: \'\' is incorrect value'); @@ -283,12 +258,9 @@ public function testUpdateLanguageNameThrowsInvalidArgumentException() /** * Test for the enableLanguage() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::enableLanguage - * - * @depends testLoadLanguageById */ - public function testEnableLanguage() + #[Depends('testLoadLanguageById')] + public function testEnableLanguage(): void { $repository = $this->getRepository(); @@ -313,12 +285,9 @@ public function testEnableLanguage() /** * Test for the disableLanguage() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::disableLanguage - * - * @depends testLoadLanguageById */ - public function testDisableLanguage() + #[Depends('testLoadLanguageById')] + public function testDisableLanguage(): void { $repository = $this->getRepository(); @@ -343,13 +312,9 @@ public function testDisableLanguage() /** * Test for the loadLanguage() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::loadLanguage - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::loadLanguageListByCode - * - * @depends testCreateLanguage */ - public function testLoadLanguage() + #[Depends('testCreateLanguage')] + public function testLoadLanguage(): void { $repository = $this->getRepository(); @@ -395,13 +360,9 @@ public function testLoadLanguage() /** * Test for the loadLanguage() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::loadLanguage - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::loadLanguageListByCode - * - * @depends testLoadLanguage */ - public function testLoadLanguageThrowsNotFoundException() + #[Depends('testLoadLanguage')] + public function testLoadLanguageThrowsNotFoundException(): void { $repository = $this->getRepository(); @@ -419,10 +380,8 @@ public function testLoadLanguageThrowsNotFoundException() /** * Test service method for loading language throwing InvalidArgumentException. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::loadLanguage */ - public function testLoadLanguageThrowsInvalidArgumentException() + public function testLoadLanguageThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Argument \'languageCode\' is invalid: language code has an invalid value'); @@ -434,13 +393,10 @@ public function testLoadLanguageThrowsInvalidArgumentException() /** * Test for the loadLanguages() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::loadLanguages - * - * @depends testCreateLanguage - * @depends testLoadLanguage */ - public function testLoadLanguages() + #[Depends('testCreateLanguage')] + #[Depends('testLoadLanguage')] + public function testLoadLanguages(): void { $repository = $this->getRepository(); @@ -480,11 +436,8 @@ public function testLoadLanguages() /** * Test for the loadLanguages() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::loadLanguages - * - * @depends testCreateLanguage */ + #[Depends('testCreateLanguage')] public function loadLanguagesReturnsAnEmptyArrayByDefault() { $repository = $this->getRepository(); @@ -496,12 +449,9 @@ public function loadLanguagesReturnsAnEmptyArrayByDefault() /** * Test for the deleteLanguage() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::deleteLanguage - * - * @depends testLoadLanguages */ - public function testDeleteLanguage() + #[Depends('testLoadLanguages')] + public function testDeleteLanguage(): void { $repository = $this->getRepository(); $languageService = $repository->getContentLanguageService(); @@ -539,12 +489,9 @@ public function testDeleteLanguage() * NOTE: This test has a dependency against several methods in the content * service, but because there is no topological sort for test dependencies * we cannot declare them here. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::deleteLanguage - * - * @depends testDeleteLanguage */ - public function testDeleteLanguageThrowsInvalidArgumentException() + #[Depends('testDeleteLanguage')] + public function testDeleteLanguageThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Argument \'language\' is invalid: Cannot delete language: some content still references the language'); @@ -585,15 +532,13 @@ public function testDeleteLanguageThrowsInvalidArgumentException() /** * Test for the getDefaultLanguageCode() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::getDefaultLanguageCode */ - public function testGetDefaultLanguageCode() + public function testGetDefaultLanguageCode(): void { $repository = $this->getRepository(); $languageService = $repository->getContentLanguageService(); - self::assertRegExp( + self::assertMatchesRegularExpression( '(^[a-z]{3}\-[A-Z]{2}$)', $languageService->getDefaultLanguageCode() ); @@ -601,12 +546,9 @@ public function testGetDefaultLanguageCode() /** * Test for the createLanguage() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::createLanguage - * - * @depends testCreateLanguage */ - public function testCreateLanguageInTransactionWithRollback() + #[Depends('testCreateLanguage')] + public function testCreateLanguageInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -647,12 +589,9 @@ public function testCreateLanguageInTransactionWithRollback() /** * Test for the createLanguage() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::createLanguage - * - * @depends testCreateLanguage */ - public function testCreateLanguageInTransactionWithCommit() + #[Depends('testCreateLanguage')] + public function testCreateLanguageInTransactionWithCommit(): void { $repository = $this->getRepository(); @@ -689,12 +628,9 @@ public function testCreateLanguageInTransactionWithCommit() /** * Test for the updateLanguageName() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::updateLanguageName - * - * @depends testUpdateLanguageName */ - public function testUpdateLanguageNameInTransactionWithRollback() + #[Depends('testUpdateLanguageName')] + public function testUpdateLanguageNameInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -728,12 +664,9 @@ public function testUpdateLanguageNameInTransactionWithRollback() /** * Test for the updateLanguageName() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LanguageService::updateLanguageName - * - * @depends testUpdateLanguageName */ - public function testUpdateLanguageNameInTransactionWithCommit() + #[Depends('testUpdateLanguageName')] + public function testUpdateLanguageNameInTransactionWithCommit(): void { $repository = $this->getRepository(); diff --git a/tests/integration/Core/Repository/Limitation/PermissionResolver/ContentLimitationsMixIntegrationTest.php b/tests/integration/Core/Repository/Limitation/PermissionResolver/ContentLimitationsMixIntegrationTest.php index 7e0fdf8cc7..a1d6b87adf 100644 --- a/tests/integration/Core/Repository/Limitation/PermissionResolver/ContentLimitationsMixIntegrationTest.php +++ b/tests/integration/Core/Repository/Limitation/PermissionResolver/ContentLimitationsMixIntegrationTest.php @@ -10,6 +10,7 @@ use Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo; use Ibexa\Contracts\Core\Repository\Values\User\Limitation; +use PHPUnit\Framework\Attributes\DataProvider; /** * Test mix of chosen core Content Limitations. @@ -25,9 +26,9 @@ class ContentLimitationsMixIntegrationTest extends BaseLimitationIntegrationTest * * This provider also checks if all registered Limitations are used. */ - public function providerForCanUser(): array + public static function providerForCanUser(): array { - $commonLimitations = $this->getCommonLimitations(); + $commonLimitations = self::getCommonLimitations(); $contentCreateLimitations = array_merge( $commonLimitations, [ @@ -65,8 +66,6 @@ public function providerForCanUser(): array } /** - * @dataProvider providerForCanUser - * * @param string $module * @param string $function * @param array $limitations @@ -78,6 +77,7 @@ public function providerForCanUser(): array * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ + #[DataProvider('providerForCanUser')] public function testCanUser( string $module, string $function, @@ -107,7 +107,7 @@ public function testCanUser( * * @return \Ibexa\Contracts\Core\Repository\Values\User\Limitation[] */ - private function getCommonLimitations(): array + private static function getCommonLimitations(): array { return [ new Limitation\ContentTypeLimitation([self::LIMITATION_VALUES => [1]]), diff --git a/tests/integration/Core/Repository/Limitation/PermissionResolver/LocationLimitationIntegrationTest.php b/tests/integration/Core/Repository/Limitation/PermissionResolver/LocationLimitationIntegrationTest.php index 95b7b7f799..5a24209361 100644 --- a/tests/integration/Core/Repository/Limitation/PermissionResolver/LocationLimitationIntegrationTest.php +++ b/tests/integration/Core/Repository/Limitation/PermissionResolver/LocationLimitationIntegrationTest.php @@ -11,12 +11,13 @@ use Ibexa\Contracts\Core\Limitation\Target\Version; use Ibexa\Contracts\Core\Repository\Repository; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\LocationLimitation; +use PHPUnit\Framework\Attributes\DataProvider; class LocationLimitationIntegrationTest extends BaseLimitationIntegrationTestCase { private const LOCATION_ID = 2; - public function providerForCanUserEditOrPublishContent(): array + public static function providerForCanUserEditOrPublishContent(): array { $limitationRoot = new LocationLimitation(); $limitationRoot->limitationValues = [self::LOCATION_ID]; @@ -27,8 +28,6 @@ public function providerForCanUserEditOrPublishContent(): array } /** - * @dataProvider providerForCanUserEditOrPublishContent - * * @param array $limitations * @param bool $expectedResult * @@ -36,6 +35,7 @@ public function providerForCanUserEditOrPublishContent(): array * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ + #[DataProvider('providerForCanUserEditOrPublishContent')] public function testCanUserEditContent(array $limitations, bool $expectedResult): void { $repository = $this->getRepository(); @@ -65,12 +65,11 @@ public function testCanUserEditContent(array $limitations, bool $expectedResult) } /** - * @dataProvider providerForCanUserEditOrPublishContent - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ + #[DataProvider('providerForCanUserEditOrPublishContent')] public function testCanUserReadTrashedContent(array $limitations, bool $expectedResult): void { $repository = $this->getRepository(); diff --git a/tests/integration/Core/Repository/LocationServiceAuthorizationTest.php b/tests/integration/Core/Repository/LocationServiceAuthorizationTest.php index 1268b52fd0..86d448145c 100644 --- a/tests/integration/Core/Repository/LocationServiceAuthorizationTest.php +++ b/tests/integration/Core/Repository/LocationServiceAuthorizationTest.php @@ -12,27 +12,24 @@ use Ibexa\Contracts\Core\Repository\Values\User\Limitation\LanguageLimitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\OwnerLimitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\SubtreeLimitation; +use Ibexa\Core\Repository\LocationService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DependsExternal; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the LocationService using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService - * - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testCreateUser - * - * @group integration - * @group authorization */ +#[CoversClass(LocationService::class)] +#[Group('integration')] +#[Group('authorization')] class LocationServiceAuthorizationTest extends BaseTestCase { /** * Test for the createLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::createLocation() - * - * @depends Ibexa\Tests\Integration\Core\Repository\LocationServiceTest::testCreateLocation */ - public function testCreateLocationThrowsUnauthorizedException() + #[DependsExternal(LocationServiceTest::class, 'testCreateLocation')] + public function testCreateLocationThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -70,12 +67,9 @@ public function testCreateLocationThrowsUnauthorizedException() /** * Test for the createLocation() method. Tests a case when user doesn't have content/manage_locations policy for the new location ID. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::createLocation() - * - * @depends Ibexa\Tests\Integration\Core\Repository\LocationServiceTest::testCreateLocation */ - public function testCreateLocationThrowsUnauthorizedExceptionDueToLackOfContentManageLocationsPolicy() + #[DependsExternal(LocationServiceTest::class, 'testCreateLocation')] + public function testCreateLocationThrowsUnauthorizedExceptionDueToLackOfContentManageLocationsPolicy(): void { $this->expectException(UnauthorizedException::class); @@ -131,12 +125,9 @@ public function testCreateLocationThrowsUnauthorizedExceptionDueToLackOfContentM /** * Test for the loadLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocation() - * - * @depends Ibexa\Tests\Integration\Core\Repository\LocationServiceTest::testLoadLocation */ - public function testLoadLocationThrowsUnauthorizedException() + #[DependsExternal(LocationServiceTest::class, 'testLoadLocation')] + public function testLoadLocationThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -160,8 +151,6 @@ public function testLoadLocationThrowsUnauthorizedException() /** * Test for the loadLocationList() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocationList */ public function testLoadLocationListFiltersUnauthorizedLocations(): void { @@ -181,12 +170,9 @@ public function testLoadLocationListFiltersUnauthorizedLocations(): void /** * Test for the loadLocationByRemoteId() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocationByRemoteId() - * - * @depends Ibexa\Tests\Integration\Core\Repository\LocationServiceTest::testLoadLocationByRemoteId */ - public function testLoadLocationByRemoteIdThrowsUnauthorizedException() + #[DependsExternal(LocationServiceTest::class, 'testLoadLocationByRemoteId')] + public function testLoadLocationByRemoteIdThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -211,12 +197,9 @@ public function testLoadLocationByRemoteIdThrowsUnauthorizedException() /** * Test for the loadLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocations() - * - * @depends Ibexa\Tests\Integration\Core\Repository\LocationServiceTest::testLoadLocations */ - public function testLoadLocationsNoAccess() + #[DependsExternal(LocationServiceTest::class, 'testLoadLocations')] + public function testLoadLocationsNoAccess(): void { $repository = $this->getRepository(); $locationService = $repository->getLocationService(); @@ -241,12 +224,9 @@ public function testLoadLocationsNoAccess() /** * Test for the updateLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::updateLocation() - * - * @depends Ibexa\Tests\Integration\Core\Repository\LocationServiceTest::testUpdateLocation */ - public function testUpdateLocationThrowsUnauthorizedException() + #[DependsExternal(LocationServiceTest::class, 'testUpdateLocation')] + public function testUpdateLocationThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -281,12 +261,9 @@ public function testUpdateLocationThrowsUnauthorizedException() /** * Test for the swapLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::swapLocation() - * - * @depends Ibexa\Tests\Integration\Core\Repository\LocationServiceTest::testSwapLocation */ - public function testSwapLocationThrowsUnauthorizedException() + #[DependsExternal(LocationServiceTest::class, 'testSwapLocation')] + public function testSwapLocationThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -323,12 +300,9 @@ public function testSwapLocationThrowsUnauthorizedException() /** * Test for the hideLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::hideLocation() - * - * @depends Ibexa\Tests\Integration\Core\Repository\LocationServiceTest::testHideLocation */ - public function testHideLocationThrowsUnauthorizedException() + #[DependsExternal(LocationServiceTest::class, 'testHideLocation')] + public function testHideLocationThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -354,12 +328,9 @@ public function testHideLocationThrowsUnauthorizedException() /** * Test for the unhideLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::unhideLocation() - * - * @depends Ibexa\Tests\Integration\Core\Repository\LocationServiceTest::testUnhideLocation */ - public function testUnhideLocationThrowsUnauthorizedException() + #[DependsExternal(LocationServiceTest::class, 'testUnhideLocation')] + public function testUnhideLocationThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -388,12 +359,9 @@ public function testUnhideLocationThrowsUnauthorizedException() /** * Test for the deleteLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::deleteLocation() - * - * @depends Ibexa\Tests\Integration\Core\Repository\LocationServiceTest::testDeleteLocation */ - public function testDeleteLocationThrowsUnauthorizedException() + #[DependsExternal(LocationServiceTest::class, 'testDeleteLocation')] + public function testDeleteLocationThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -417,9 +385,6 @@ public function testDeleteLocationThrowsUnauthorizedException() /* END: Use Case */ } - /** - * @covers \Ibexa\Contracts\Core\Repository\LocationService::deleteLocation() - */ public function testDeleteLocationThrowsUnauthorizedExceptionWithLanguageLimitation(): void { $repository = $this->getRepository(); @@ -452,12 +417,9 @@ public function testDeleteLocationThrowsUnauthorizedExceptionWithLanguageLimitat /** * Test for the deleteLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::deleteLocation() - * - * @depends Ibexa\Tests\Integration\Core\Repository\LocationServiceTest::testDeleteLocation */ - public function testDeleteLocationWithSubtreeThrowsUnauthorizedException() + #[DependsExternal(LocationServiceTest::class, 'testDeleteLocation')] + public function testDeleteLocationWithSubtreeThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); $this->expectExceptionMessage('The User does not have the \'remove\' \'content\' permission'); @@ -551,12 +513,9 @@ public function testDeleteLocationWithSubtreeThrowsUnauthorizedException() /** * Test for the copySubtree() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::copySubtree() - * - * @depends Ibexa\Tests\Integration\Core\Repository\LocationServiceTest::testCopySubtree */ - public function testCopySubtreeThrowsUnauthorizedException() + #[DependsExternal(LocationServiceTest::class, 'testCopySubtree')] + public function testCopySubtreeThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -596,12 +555,9 @@ public function testCopySubtreeThrowsUnauthorizedException() /** * Test for the moveSubtree() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::moveSubtree() - * - * @depends Ibexa\Tests\Integration\Core\Repository\LocationServiceTest::testMoveSubtree */ - public function testMoveSubtreeThrowsUnauthorizedException() + #[DependsExternal(LocationServiceTest::class, 'testMoveSubtree')] + public function testMoveSubtreeThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/LocationServiceTest.php b/tests/integration/Core/Repository/LocationServiceTest.php index a87338e808..a24603dbc9 100644 --- a/tests/integration/Core/Repository/LocationServiceTest.php +++ b/tests/integration/Core/Repository/LocationServiceTest.php @@ -26,23 +26,25 @@ use Ibexa\Contracts\Core\Repository\Values\Content\URLAlias; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\SubtreeLimitation; use Ibexa\Core\Persistence\Legacy\Content\Location\Gateway; +use Ibexa\Core\Repository\LocationService; use Ibexa\Core\Repository\Values\Content\ContentUpdateStruct; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\DependsExternal; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the LocationService using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService - * - * @group location */ +#[CoversClass(LocationService::class)] +#[Group('location')] class LocationServiceTest extends BaseTestCase { /** * Test for the newLocationCreateStruct() method. * * @return \Ibexa\Contracts\Core\Repository\Values\Content\LocationCreateStruct - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::newLocationCreateStruct() */ public function testNewLocationCreateStruct() { @@ -70,12 +72,9 @@ public function testNewLocationCreateStruct() * Test for the newLocationCreateStruct() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\LocationCreateStruct $locationCreate - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::newLocationCreateStruct() - * - * @depends testNewLocationCreateStruct */ - public function testNewLocationCreateStructValues(LocationCreateStruct $locationCreate) + #[Depends('testNewLocationCreateStruct')] + public function testNewLocationCreateStructValues(LocationCreateStruct $locationCreate): void { $this->assertPropertiesCorrect( [ @@ -93,11 +92,8 @@ public function testNewLocationCreateStructValues(LocationCreateStruct $location /** * Test for the createLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::createLocation() - * - * @depends testNewLocationCreateStruct */ + #[Depends('testNewLocationCreateStruct')] public function testCreateLocation() { $repository = $this->getRepository(); @@ -141,12 +137,9 @@ public function testCreateLocation() /** * Test for the createLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::createLocation - * - * @depends testCreateLocation - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testHideContent */ + #[Depends('testCreateLocation')] + #[DependsExternal(ContentServiceTest::class, 'testHideContent')] public function testCreateLocationChecksContentVisibility(): void { $repository = $this->getRepository(); @@ -183,8 +176,6 @@ public function testCreateLocationChecksContentVisibility(): void /** * Test for the createLocation() method with utilizing default ContentType sorting options. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::createLocation */ public function testCreateLocationWithContentTypeSortingOptions(): void { @@ -220,12 +211,9 @@ public function testCreateLocationWithContentTypeSortingOptions(): void /** * Test for the createLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::createLocation() - * - * @depends testCreateLocation */ - public function testCreateLocationStructValues(array $data) + #[Depends('testCreateLocation')] + public function testCreateLocationStructValues(array $data): void { $locationCreate = $data['locationCreate']; $createdLocation = $data['createdLocation']; @@ -252,12 +240,9 @@ public function testCreateLocationStructValues(array $data) /** * Test for the createLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::createLocation() - * - * @depends testNewLocationCreateStruct */ - public function testCreateLocationThrowsInvalidArgumentExceptionContentAlreadyBelowParent() + #[Depends('testNewLocationCreateStruct')] + public function testCreateLocationThrowsInvalidArgumentExceptionContentAlreadyBelowParent(): void { $this->expectException(InvalidArgumentException::class); @@ -287,12 +272,9 @@ public function testCreateLocationThrowsInvalidArgumentExceptionContentAlreadyBe /** * Test for the createLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::createLocation() - * - * @depends testNewLocationCreateStruct */ - public function testCreateLocationThrowsInvalidArgumentExceptionParentIsSubLocationOfContent() + #[Depends('testNewLocationCreateStruct')] + public function testCreateLocationThrowsInvalidArgumentExceptionParentIsSubLocationOfContent(): void { $this->expectException(InvalidArgumentException::class); @@ -322,12 +304,9 @@ public function testCreateLocationThrowsInvalidArgumentExceptionParentIsSubLocat /** * Test for the createLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::createLocation() - * - * @depends testNewLocationCreateStruct */ - public function testCreateLocationThrowsInvalidArgumentExceptionRemoteIdExists() + #[Depends('testNewLocationCreateStruct')] + public function testCreateLocationThrowsInvalidArgumentExceptionRemoteIdExists(): void { $this->expectException(InvalidArgumentException::class); @@ -357,14 +336,10 @@ public function testCreateLocationThrowsInvalidArgumentExceptionRemoteIdExists() /** * Test for the createLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::createLocation() - * - * @depends testNewLocationCreateStruct - * - * @dataProvider dataProviderForOutOfRangeLocationPriority */ - public function testCreateLocationThrowsInvalidArgumentExceptionPriorityIsOutOfRange($priority) + #[Depends('testNewLocationCreateStruct')] + #[DataProvider('dataProviderForOutOfRangeLocationPriority')] + public function testCreateLocationThrowsInvalidArgumentExceptionPriorityIsOutOfRange($priority): void { $this->expectException(InvalidArgumentException::class); @@ -396,19 +371,19 @@ public function testCreateLocationThrowsInvalidArgumentExceptionPriorityIsOutOfR /* END: Use Case */ } - public function dataProviderForOutOfRangeLocationPriority() + /** + * @return array + */ + public static function dataProviderForOutOfRangeLocationPriority(): array { return [[-2147483649], [2147483648]]; } /** * Test for the createLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::createLocation() - * - * @depends testCreateLocation */ - public function testCreateLocationInTransactionWithRollback() + #[Depends('testCreateLocation')] + public function testCreateLocationInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -456,11 +431,8 @@ public function testCreateLocationInTransactionWithRollback() * Test for the loadLocation() method. * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Location - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocation - * - * @depends testCreateLocation */ + #[Depends('testCreateLocation')] public function testLoadLocation() { $repository = $this->getRepository(); @@ -484,12 +456,9 @@ public function testLoadLocation() /** * Test for the loadLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocation() - * - * @depends testLoadLocation */ - public function testLoadLocationRootStructValues() + #[Depends('testLoadLocation')] + public function testLoadLocationRootStructValues(): void { $repository = $this->getRepository(); $locationService = $repository->getLocationService(); @@ -563,12 +532,9 @@ private function assertRootLocationStructValues(Location $location): void * Test for the loadLocation() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Location $location - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocation() - * - * @depends testLoadLocation */ - public function testLoadLocationStructValues(Location $location) + #[Depends('testLoadLocation')] + public function testLoadLocationStructValues(Location $location): void { $this->assertPropertiesCorrect( [ @@ -600,7 +566,7 @@ public function testLoadLocationStructValues(Location $location) self::assertEquals(4, $content->contentInfo->id); } - public function testLoadLocationPrioritizedLanguagesFallback() + public function testLoadLocationPrioritizedLanguagesFallback(): void { $repository = $this->getRepository(); @@ -656,12 +622,9 @@ public function testLoadLocationThrowsNotFoundExceptionForNotAvailableContent(): /** * Test for the loadLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocation() - * - * @depends testCreateLocation */ - public function testLoadLocationThrowsNotFoundException() + #[Depends('testCreateLocation')] + public function testLoadLocationThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -679,8 +642,6 @@ public function testLoadLocationThrowsNotFoundException() /** * Test for the loadLocationList() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocationList */ public function testLoadLocationList(): void { @@ -699,11 +660,8 @@ public function testLoadLocationList(): void /** * Test for the loadLocationList() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocationList - * - * @depends testLoadLocationList */ + #[Depends('testLoadLocationList')] public function testLoadLocationListPrioritizedLanguagesFallback(): void { $repository = $this->getRepository(); @@ -720,11 +678,8 @@ public function testLoadLocationListPrioritizedLanguagesFallback(): void /** * Test for the loadLocationList() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocationList - * - * @depends testLoadLocationListPrioritizedLanguagesFallback */ + #[Depends('testLoadLocationListPrioritizedLanguagesFallback')] public function testLoadLocationListPrioritizedLanguagesFallbackAndAlwaysAvailable(): void { $repository = $this->getRepository(); @@ -744,10 +699,8 @@ public function testLoadLocationListPrioritizedLanguagesFallbackAndAlwaysAvailab /** * Test for the loadLocationList() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocationList */ - public function testLoadLocationListWithRootLocationId() + public function testLoadLocationListWithRootLocationId(): void { $repository = $this->getRepository(); @@ -766,10 +719,8 @@ public function testLoadLocationListWithRootLocationId() * Test for the loadLocationList() method. * * Ensures the list is returned in the same order as passed IDs array. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocationList */ - public function testLoadLocationListInCorrectOrder() + public function testLoadLocationListInCorrectOrder(): void { $repository = $this->getRepository(); $locationService = $repository->getLocationService(); @@ -788,12 +739,9 @@ public function testLoadLocationListInCorrectOrder() /** * Test for the loadLocationByRemoteId() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocationByRemoteId() - * - * @depends testLoadLocation */ - public function testLoadLocationByRemoteId() + #[Depends('testLoadLocation')] + public function testLoadLocationByRemoteId(): void { $repository = $this->getRepository(); @@ -813,12 +761,9 @@ public function testLoadLocationByRemoteId() /** * Test for the loadLocationByRemoteId() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocationByRemoteId() - * - * @depends testLoadLocation */ - public function testLoadLocationByRemoteIdThrowsNotFoundException() + #[Depends('testLoadLocation')] + public function testLoadLocationByRemoteIdThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -836,11 +781,8 @@ public function testLoadLocationByRemoteIdThrowsNotFoundException() /** * Test for the loadLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocations() - * - * @depends testCreateLocation */ + #[Depends('testCreateLocation')] public function testLoadLocations() { $repository = $this->getRepository(); @@ -869,12 +811,9 @@ public function testLoadLocations() /** * Test for the loadLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocations() - * - * @depends testLoadLocations */ - public function testLoadLocationsContent(array $locations) + #[Depends('testLoadLocations')] + public function testLoadLocationsContent(array $locations): void { self::assertCount(1, $locations); foreach ($locations as $loadedLocation) { @@ -903,11 +842,8 @@ static function (Location $location) { * Test for the loadLocations() method. * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Location[] - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocations($contentInfo, $rootLocation) - * - * @depends testLoadLocations */ + #[Depends('testLoadLocations')] public function testLoadLocationsLimitedSubtree() { $repository = $this->getRepository(); @@ -951,12 +887,9 @@ public function testLoadLocationsLimitedSubtree() * Test for the loadLocations() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Location[] $locations - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocations() - * - * @depends testLoadLocationsLimitedSubtree */ - public function testLoadLocationsLimitedSubtreeContent(array $locations) + #[Depends('testLoadLocationsLimitedSubtree')] + public function testLoadLocationsLimitedSubtreeContent(array $locations): void { self::assertCount(1, $locations); @@ -968,12 +901,9 @@ public function testLoadLocationsLimitedSubtreeContent(array $locations) /** * Test for the loadLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocations() - * - * @depends testLoadLocations */ - public function testLoadLocationsThrowsBadStateException() + #[Depends('testLoadLocations')] + public function testLoadLocationsThrowsBadStateException(): void { $this->expectException(BadStateException::class); @@ -999,12 +929,9 @@ public function testLoadLocationsThrowsBadStateException() /** * Test for the loadLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocations($contentInfo, $rootLocation) - * - * @depends testLoadLocations */ - public function testLoadLocationsThrowsBadStateExceptionLimitedSubtree() + #[Depends('testLoadLocations')] + public function testLoadLocationsThrowsBadStateExceptionLimitedSubtree(): void { $this->expectException(BadStateException::class); @@ -1035,11 +962,8 @@ public function testLoadLocationsThrowsBadStateExceptionLimitedSubtree() /** * Test for the loadLocationChildren() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocationChildren - * - * @depends testLoadLocation */ + #[Depends('testLoadLocation')] public function testLoadLocationChildren() { $repository = $this->getRepository(); @@ -1069,8 +993,6 @@ public function testLoadLocationChildren() /** * Test loading parent Locations for draft Content. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadParentLocationsForDraftContent */ public function testLoadParentLocationsForDraftContent() { @@ -1106,11 +1028,11 @@ public function testLoadParentLocationsForDraftContent() /** * Test that trying to load parent Locations throws Exception if Content is not a draft. * - * @depends testLoadParentLocationsForDraftContent * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $contentDraft */ - public function testLoadParentLocationsForDraftContentThrowsBadStateException(Content $contentDraft) + #[Depends('testLoadParentLocationsForDraftContent')] + public function testLoadParentLocationsForDraftContentThrowsBadStateException(Content $contentDraft): void { $this->expectException(BadStateException::class); $this->expectExceptionMessageMatches('/is already published/'); @@ -1126,10 +1048,8 @@ public function testLoadParentLocationsForDraftContentThrowsBadStateException(Co /** * Test for the getLocationChildCount() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::getLocationChildCount() */ - public function testGetLocationChildCount() + public function testGetLocationChildCount(): void { // $locationId is the ID of an existing location $locationService = $this->getRepository()->getLocationService(); @@ -1144,8 +1064,6 @@ public function testGetLocationChildCount() /** * Test for the getLocationChildCount() method with a limitation on the number of children. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::getLocationChildCount() */ public function testGetLocationChildCountWithLimitation(): void { @@ -1163,12 +1081,9 @@ public function testGetLocationChildCountWithLimitation(): void /** * Test for the loadLocationChildren() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocationChildren() - * - * @depends testLoadLocationChildren */ - public function testLoadLocationChildrenData(LocationList $locations) + #[Depends('testLoadLocationChildren')] + public function testLoadLocationChildrenData(LocationList $locations): void { self::assertCount(5, $locations->locations); self::assertEquals(5, $locations->getTotalCount()); @@ -1197,9 +1112,6 @@ static function (Location $location) { ); } - /** - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocationChildren - */ public function testLoadLocationChildrenWithOffset(): LocationList { $repository = $this->getRepository(); @@ -1222,11 +1134,8 @@ public function testLoadLocationChildrenWithOffset(): LocationList * Test for the loadLocationChildren() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\LocationList $locations - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocationChildren - * - * @depends testLoadLocationChildrenWithOffset */ + #[Depends('testLoadLocationChildrenWithOffset')] public function testLoadLocationChildrenDataWithOffset(LocationList $locations): void { self::assertCount(3, $locations->locations); @@ -1248,11 +1157,7 @@ public function testLoadLocationChildrenDataWithOffset(LocationList $locations): ); } - /** - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocationChildren - * - * @depends testLoadLocationChildren - */ + #[Depends('testLoadLocationChildren')] public function testLoadLocationChildrenWithOffsetAndLimit(): LocationList { $repository = $this->getRepository(); @@ -1271,11 +1176,7 @@ public function testLoadLocationChildrenWithOffsetAndLimit(): LocationList return $childLocations; } - /** - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocationChildren - * - * @depends testLoadLocationChildrenWithOffsetAndLimit - */ + #[Depends('testLoadLocationChildrenWithOffsetAndLimit')] public function testLoadLocationChildrenDataWithOffsetAndLimit(LocationList $locations): void { self::assertCount(2, $locations->locations); @@ -1296,7 +1197,7 @@ public function testLoadLocationChildrenDataWithOffsetAndLimit(LocationList $loc ); } - public function providerForLoadLocationChildrenRespectsParentSortingClauses(): iterable + public static function providerForLoadLocationChildrenRespectsParentSortingClauses(): iterable { yield 'Name_ASC' => [ Location::SORT_FIELD_NAME, @@ -1391,12 +1292,9 @@ private function createStructureForTestLoadLocationChildrenRespectsParentSorting } /** - * @covers \Ibexa\Contracts\Core\Repository\LocationService::loadLocationChildren - * - * @dataProvider providerForLoadLocationChildrenRespectsParentSortingClauses - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\Exception */ + #[DataProvider('providerForLoadLocationChildrenRespectsParentSortingClauses')] public function testLoadLocationChildrenRespectsParentSortingClauses( int $sortField, int $sortOrder, @@ -1428,10 +1326,8 @@ static function (Location $location) { /** * Test for the newLocationUpdateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::newLocationUpdateStruct */ - public function testNewLocationUpdateStruct() + public function testNewLocationUpdateStruct(): void { $repository = $this->getRepository(); @@ -1459,11 +1355,8 @@ public function testNewLocationUpdateStruct() /** * Test for the updateLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::updateLocation() - * - * @depends testLoadLocation */ + #[Depends('testLoadLocation')] public function testUpdateLocation() { $repository = $this->getRepository(); @@ -1498,12 +1391,9 @@ public function testUpdateLocation() /** * Test for the updateLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::updateLocation() - * - * @depends testUpdateLocation */ - public function testUpdateLocationStructValues(array $data) + #[Depends('testUpdateLocation')] + public function testUpdateLocationStructValues(array $data): void { $originalLocation = $data['originalLocation']; $updateStruct = $data['updateStruct']; @@ -1529,12 +1419,9 @@ public function testUpdateLocationStructValues(array $data) /** * Test for the updateLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::updateLocation() - * - * @depends testLoadLocation */ - public function testUpdateLocationWithSameRemoteId() + #[Depends('testLoadLocation')] + public function testUpdateLocationWithSameRemoteId(): void { $repository = $this->getRepository(); @@ -1565,12 +1452,9 @@ public function testUpdateLocationWithSameRemoteId() /** * Test for the updateLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::updateLocation() - * - * @depends testLoadLocation */ - public function testUpdateLocationThrowsInvalidArgumentException() + #[Depends('testLoadLocation')] + public function testUpdateLocationThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -1595,14 +1479,10 @@ public function testUpdateLocationThrowsInvalidArgumentException() /** * Test for the updateLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::updateLocation() - * - * @depends testLoadLocation - * - * @dataProvider dataProviderForOutOfRangeLocationPriority */ - public function testUpdateLocationThrowsInvalidArgumentExceptionPriorityIsOutOfRange($priority) + #[Depends('testLoadLocation')] + #[DataProvider('dataProviderForOutOfRangeLocationPriority')] + public function testUpdateLocationThrowsInvalidArgumentExceptionPriorityIsOutOfRange($priority): void { $this->expectException(InvalidArgumentException::class); @@ -1628,12 +1508,9 @@ public function testUpdateLocationThrowsInvalidArgumentExceptionPriorityIsOutOfR /** * Test for the updateLocation() method. * Ref EZP-23302: Update Location fails if no change is performed with the update. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::updateLocation() - * - * @depends testLoadLocation */ - public function testUpdateLocationTwice() + #[Depends('testLoadLocation')] + public function testUpdateLocationTwice(): void { $repository = $this->getRepository(); $permissionResolver = $repository->getPermissionResolver(); @@ -1660,12 +1537,9 @@ public function testUpdateLocationTwice() /** * Test for the swapLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::swapLocation() - * - * @depends testLoadLocation */ - public function testSwapLocation() + #[Depends('testLoadLocation')] + public function testSwapLocation(): void { $repository = $this->getRepository(); $locationService = $repository->getLocationService(); @@ -1721,7 +1595,6 @@ public function testSwapLocation() /** * Test for the swapLocation() method with custom aliases. * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::swapLocation * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException @@ -1764,7 +1637,6 @@ public function testSwapLocationForContentWithCustomUrlAliases(): void /** * Test swapping secondary Location with main Location. * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::swapLocation * * @see https://issues.ibexa.co/browse/EZP-28663 * @@ -1871,13 +1743,12 @@ static function (Location $location) { } /** - * @depends testSwapLocationForMainAndSecondaryLocation - * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content[] $contentItems Content items created by testSwapLocationForSecondaryLocation * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ - public function testSwapLocationDoesNotCorruptSearchResults(array $contentItems) + #[Depends('testSwapLocationForMainAndSecondaryLocation')] + public function testSwapLocationDoesNotCorruptSearchResults(array $contentItems): void { $repository = $this->getRepository(false); $searchService = $repository->getSearchService(); @@ -1920,7 +1791,6 @@ static function (SearchHit $searchHit) { /** * Test swapping two secondary (non-main) Locations. * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::swapLocation * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException @@ -1977,10 +1847,8 @@ public function testSwapLocationForSecondaryLocations(): void /** * Test swapping Main Location of a Content with another one updates Content item Main Location. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::swapLocation */ - public function testSwapLocationUpdatesMainLocation() + public function testSwapLocationUpdatesMainLocation(): void { $repository = $this->getRepository(); $locationService = $repository->getLocationService(); @@ -2015,10 +1883,8 @@ public function testSwapLocationUpdatesMainLocation() /** * Test if location swap affects related bookmarks. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::swapLocation */ - public function testBookmarksAreSwappedAfterSwapLocation() + public function testBookmarksAreSwappedAfterSwapLocation(): void { $repository = $this->getRepository(); @@ -2052,12 +1918,9 @@ public function testBookmarksAreSwappedAfterSwapLocation() /** * Test for the hideLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::hideLocation() - * - * @depends testLoadLocation */ - public function testHideLocation() + #[Depends('testLoadLocation')] + public function testHideLocation(): void { $repository = $this->getRepository(); @@ -2123,12 +1986,9 @@ protected function assertSubtreeProperties(array $expectedValues, Location $loca /** * Test for the unhideLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::unhideLocation() - * - * @depends testHideLocation */ - public function testUnhideLocation() + #[Depends('testHideLocation')] + public function testUnhideLocation(): void { $repository = $this->getRepository(); @@ -2168,12 +2028,9 @@ public function testUnhideLocation() /** * Test for the unhideLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::unhideLocation() - * - * @depends testUnhideLocation */ - public function testUnhideLocationNotUnhidesHiddenSubtree() + #[Depends('testUnhideLocation')] + public function testUnhideLocationNotUnhidesHiddenSubtree(): void { $repository = $this->getRepository(); @@ -2234,12 +2091,9 @@ public function testUnhideLocationNotUnhidesHiddenSubtree() /** * Test for the deleteLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::deleteLocation() - * - * @depends testLoadLocation */ - public function testDeleteLocation() + #[Depends('testLoadLocation')] + public function testDeleteLocation(): void { $repository = $this->getRepository(); @@ -2284,12 +2138,9 @@ public function testDeleteLocation() /** * Test for the deleteLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::deleteLocation() - * - * @depends testDeleteLocation */ - public function testDeleteLocationDecrementsChildCountOnParent() + #[Depends('testDeleteLocation')] + public function testDeleteLocationDecrementsChildCountOnParent(): void { $repository = $this->getRepository(); @@ -2332,10 +2183,8 @@ public function testDeleteLocationDecrementsChildCountOnParent() * Test for the deleteLocation() method. * * Related issue: EZP-21904 - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::deleteLocation() */ - public function testDeleteContentObjectLastLocation() + public function testDeleteContentObjectLastLocation(): void { $this->expectException(NotFoundException::class); @@ -2376,12 +2225,9 @@ public function testDeleteContentObjectLastLocation() /** * Test for the deleteLocation() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::deleteLocation - * - * @depends testDeleteLocation */ - public function testDeleteLocationDeletesRelatedBookmarks() + #[Depends('testDeleteLocation')] + public function testDeleteLocationDeletesRelatedBookmarks(): void { $repository = $this->getRepository(); @@ -2428,9 +2274,6 @@ public function testDeleteLocationDeletesRelatedBookmarks() ); } - /** - * @covers \Ibexa\Contracts\Core\Repository\LocationService::deleteLocation - */ public function testDeleteUnusedLocationWhichPreviousHadContentWithRelativeAlias(): void { $repository = $this->getRepository(false); @@ -2498,12 +2341,9 @@ public function testDeleteUnusedLocationWhichPreviousHadContentWithRelativeAlias /** * Test for the copySubtree() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::copySubtree() - * - * @depends testLoadLocation */ - public function testCopySubtree() + #[Depends('testLoadLocation')] + public function testCopySubtree(): void { $repository = $this->getRepository(); @@ -2551,12 +2391,9 @@ public function testCopySubtree() /** * Test for the copySubtree() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::copySubtree() - * - * @depends testLoadLocation */ - public function testCopySubtreeWithAliases() + #[Depends('testLoadLocation')] + public function testCopySubtreeWithAliases(): void { $repository = $this->getRepository(); $urlAliasService = $repository->getURLAliasService(); @@ -2590,9 +2427,6 @@ public function testCopySubtreeWithAliases() $this->assertGeneratedAliases($urlAliasService, $expectedSubItemAliases); } - /** - * @covers \Ibexa\Contracts\Core\Repository\LocationService::copySubtree - */ public function testCopySubtreeWithTranslatedContent(): void { $repository = $this->getRepository(); @@ -2673,12 +2507,9 @@ private function assertDefaultContentStates(ContentInfo $contentInfo) /** * Test for the copySubtree() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::copySubtree() - * - * @depends testCopySubtree */ - public function testCopySubtreeUpdatesSubtreeProperties() + #[Depends('testCopySubtree')] + public function testCopySubtreeUpdatesSubtreeProperties(): void { $repository = $this->getRepository(); $locationService = $repository->getLocationService(); @@ -2740,12 +2571,9 @@ public function testCopySubtreeUpdatesSubtreeProperties() /** * Test for the copySubtree() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::copySubtree() - * - * @depends testCopySubtree */ - public function testCopySubtreeIncrementsChildCountOfNewParent() + #[Depends('testCopySubtree')] + public function testCopySubtreeIncrementsChildCountOfNewParent(): void { $repository = $this->getRepository(); $locationService = $repository->getLocationService(); @@ -2784,9 +2612,6 @@ public function testCopySubtreeIncrementsChildCountOfNewParent() self::assertEquals($childCountBefore + 1, $childCountAfter); } - /** - * @covers \Ibexa\Contracts\Core\Repository\LocationService::copySubtree() - */ public function testCopySubtreeWithInvisibleChild(): void { $repository = $this->getRepository(); @@ -2829,12 +2654,9 @@ public function testCopySubtreeWithInvisibleChild(): void /** * Test for the copySubtree() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::copySubtree() - * - * @depends testCopySubtree */ - public function testCopySubtreeThrowsInvalidArgumentException() + #[Depends('testCopySubtree')] + public function testCopySubtreeThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -2866,11 +2688,8 @@ public function testCopySubtreeThrowsInvalidArgumentException() /** * Test for the moveSubtree() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::moveSubtree - * - * @depends testLoadLocation */ + #[Depends('testLoadLocation')] public function testMoveSubtree(): void { $repository = $this->getRepository(); @@ -2917,11 +2736,8 @@ public function testMoveSubtree(): void /** * Test for the moveSubtree() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::moveSubtree - * - * @depends testLoadLocation */ + #[Depends('testLoadLocation')] public function testMoveSubtreeToLocationWithoutContent(): void { $repository = $this->getRepository(); @@ -2953,11 +2769,8 @@ public function testMoveSubtreeToLocationWithoutContent(): void /** * Test for the moveSubtree() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::moveSubtree - * - * @depends testLoadLocation */ + #[Depends('testLoadLocation')] public function testMoveSubtreeThrowsExceptionOnMoveNotIntoContainer(): void { $repository = $this->getRepository(); @@ -2987,11 +2800,8 @@ public function testMoveSubtreeThrowsExceptionOnMoveNotIntoContainer(): void /** * Test for the moveSubtree() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::moveSubtree - * - * @depends testLoadLocation */ + #[Depends('testLoadLocation')] public function testMoveSubtreeThrowsExceptionOnMoveToSame(): void { $repository = $this->getRepository(); @@ -3017,11 +2827,8 @@ public function testMoveSubtreeThrowsExceptionOnMoveToSame(): void /** * Test for the moveSubtree() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::moveSubtree - * - * @depends testMoveSubtree */ + #[Depends('testMoveSubtree')] public function testMoveSubtreeHidden(): void { $repository = $this->getRepository(); @@ -3071,12 +2878,9 @@ public function testMoveSubtreeHidden(): void /** * Test for the moveSubtree() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::moveSubtree() - * - * @depends testMoveSubtree */ - public function testMoveSubtreeUpdatesSubtreeProperties() + #[Depends('testMoveSubtree')] + public function testMoveSubtreeUpdatesSubtreeProperties(): void { $repository = $this->getRepository(); $locationService = $repository->getLocationService(); @@ -3133,12 +2937,9 @@ public function testMoveSubtreeUpdatesSubtreeProperties() /** * Test for the moveSubtree() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::moveSubtree() - * - * @depends testMoveSubtreeUpdatesSubtreeProperties */ - public function testMoveSubtreeUpdatesSubtreePropertiesHidden() + #[Depends('testMoveSubtreeUpdatesSubtreeProperties')] + public function testMoveSubtreeUpdatesSubtreePropertiesHidden(): void { $repository = $this->getRepository(); $locationService = $repository->getLocationService(); @@ -3199,12 +3000,9 @@ public function testMoveSubtreeUpdatesSubtreePropertiesHidden() /** * Test for the moveSubtree() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::moveSubtree() - * - * @depends testMoveSubtree */ - public function testMoveSubtreeIncrementsChildCountOfNewParent() + #[Depends('testMoveSubtree')] + public function testMoveSubtreeIncrementsChildCountOfNewParent(): void { $repository = $this->getRepository(); $locationService = $repository->getLocationService(); @@ -3258,12 +3056,9 @@ public function testMoveSubtreeIncrementsChildCountOfNewParent() /** * Test for the moveSubtree() method. - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::moveSubtree() - * - * @depends testMoveSubtree */ - public function testMoveSubtreeDecrementsChildCountOfOldParent() + #[Depends('testMoveSubtree')] + public function testMoveSubtreeDecrementsChildCountOfOldParent(): void { $repository = $this->getRepository(); $locationService = $repository->getLocationService(); @@ -3318,13 +3113,12 @@ public function testMoveSubtreeDecrementsChildCountOfOldParent() /** * Test moving invisible (hidden by parent) subtree. * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::moveSubtree * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ - public function testMoveInvisibleSubtree() + public function testMoveInvisibleSubtree(): void { $repository = $this->getRepository(); $locationService = $repository->getLocationService(); @@ -3358,9 +3152,8 @@ public function testMoveInvisibleSubtree() /** * Test for the moveSubtree() method. - * - * @depends testMoveSubtree */ + #[Depends('testMoveSubtree')] public function testMoveSubtreeThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -3398,7 +3191,6 @@ public function testMoveSubtreeThrowsInvalidArgumentException(): void * Test that Legacy ibexa_content_tree.path_identification_string field is correctly updated * after moving subtree. * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::moveSubtree * * @throws \ErrorException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException @@ -3446,8 +3238,6 @@ public function testMoveSubtreeUpdatesPathIdentificationString(): void /** * Test that is_visible is set correct for children when moving a location where a child is hidden by content (not by location). - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::moveSubtree */ public function testMoveSubtreeKeepsContentHiddenOnChildrenAndParent(): void { @@ -3509,8 +3299,6 @@ public function testMoveSubtreeKeepsContentHiddenOnChildrenAndParent(): void /** * Test that is_visible is set correct for children when moving a content which is hidden (location is not hidden). - * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::moveSubtree */ public function testMoveSubtreeKeepsContentHiddenOnChildren(): void { @@ -3577,7 +3365,6 @@ public function testMoveSubtreeKeepsContentHiddenOnChildren(): void * Test validating whether content that is being moved is still allowed to be moved when one of its locations * is inaccessible by a current user, however, when moved location is accessible. * - * @covers \Ibexa\Contracts\Core\Repository\LocationService::moveSubtree * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\Exception */ diff --git a/tests/integration/Core/Repository/NonRedundantFieldSetTest.php b/tests/integration/Core/Repository/NonRedundantFieldSetTest.php index 868a91d9e0..c95285fada 100644 --- a/tests/integration/Core/Repository/NonRedundantFieldSetTest.php +++ b/tests/integration/Core/Repository/NonRedundantFieldSetTest.php @@ -9,17 +9,20 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Content; use Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo; +use Ibexa\Core\Repository\ContentService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\DependsExternal; +use PHPUnit\Framework\Attributes\Group; /** * Test case for create and update Content operations in the ContentService with regard to * non-redundant set of fields being passed to the storage. * * These tests depends on TextLine field type being functional. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService - * - * @group content */ +#[CoversClass(ContentService::class)] +#[Group('content')] class NonRedundantFieldSetTest extends BaseNonRedundantFieldSetTestCase { /** @@ -27,13 +30,12 @@ class NonRedundantFieldSetTest extends BaseNonRedundantFieldSetTestCase * * Default values are stored. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testCreateContent - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testCreateContentType * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content */ + #[DependsExternal(ContentServiceTest::class, 'testCreateContent')] + #[DependsExternal(ContentTypeServiceTest::class, 'testCreateContentType')] public function testCreateContentDefaultValues() { $mainLanguageCode = 'eng-US'; @@ -52,13 +54,12 @@ public function testCreateContentDefaultValues() /** * Test for the createContent() method. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() * - * @depends testCreateContentDefaultValues * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content */ - public function testCreateContentDefaultValuesFields(Content $content) + #[Depends('testCreateContentDefaultValues')] + public function testCreateContentDefaultValuesFields(Content $content): void { self::assertCount(1, $content->versionInfo->languageCodes); self::assertContains('eng-US', $content->versionInfo->languageCodes); @@ -76,13 +77,12 @@ public function testCreateContentDefaultValuesFields(Content $content) * * Creating fields with empty values, no values being passed to storage. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testCreateContent - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testCreateContentType * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content */ + #[DependsExternal(ContentServiceTest::class, 'testCreateContent')] + #[DependsExternal(ContentTypeServiceTest::class, 'testCreateContentType')] public function testCreateContentEmptyValues() { $mainLanguageCode = 'eng-US'; @@ -101,13 +101,12 @@ public function testCreateContentEmptyValues() /** * Test for the createContent() method. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() * - * @depends testCreateContentEmptyValues * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content */ - public function testCreateContentEmptyValuesFields(Content $content) + #[Depends('testCreateContentEmptyValues')] + public function testCreateContentEmptyValuesFields(Content $content): void { $emptyValue = $this->getRepository()->getFieldTypeService()->getFieldType('ibexa_string')->getEmptyValue(); @@ -129,13 +128,12 @@ public function testCreateContentEmptyValuesFields(Content $content) * Creating fields with empty values, no values being passed to storage. * Case where additional language is not stored. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testCreateContent - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testCreateContentType * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content */ + #[DependsExternal(ContentServiceTest::class, 'testCreateContent')] + #[DependsExternal(ContentTypeServiceTest::class, 'testCreateContentType')] public function testCreateContentEmptyValuesTranslationNotStored() { $mainLanguageCode = 'eng-US'; @@ -154,13 +152,12 @@ public function testCreateContentEmptyValuesTranslationNotStored() /** * Test for the createContent() method. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() * - * @depends testCreateContentEmptyValuesTranslationNotStored * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content */ - public function testCreateContentEmptyValuesTranslationNotStoredFields(Content $content) + #[Depends('testCreateContentEmptyValuesTranslationNotStored')] + public function testCreateContentEmptyValuesTranslationNotStoredFields(Content $content): void { $emptyValue = $this->getRepository()->getFieldTypeService()->getFieldType('ibexa_string')->getEmptyValue(); @@ -184,13 +181,12 @@ public function testCreateContentEmptyValuesTranslationNotStoredFields(Content $ * * Creating with two languages, main language is always stored (even with all values being empty). * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testCreateContent - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testCreateContentType * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content */ + #[DependsExternal(ContentServiceTest::class, 'testCreateContent')] + #[DependsExternal(ContentTypeServiceTest::class, 'testCreateContentType')] public function testCreateContentTwoLanguagesMainTranslationStored() { $mainLanguageCode = 'eng-US'; @@ -209,13 +205,12 @@ public function testCreateContentTwoLanguagesMainTranslationStored() /** * Test for the createContent() method. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() * - * @depends testCreateContentTwoLanguagesMainTranslationStored * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content */ - public function testCreateContentTwoLanguagesMainTranslationStoredFields(Content $content) + #[Depends('testCreateContentTwoLanguagesMainTranslationStored')] + public function testCreateContentTwoLanguagesMainTranslationStoredFields(Content $content): void { $emptyValue = $this->getRepository()->getFieldTypeService()->getFieldType('ibexa_string')->getEmptyValue(); @@ -244,13 +239,12 @@ public function testCreateContentTwoLanguagesMainTranslationStoredFields(Content * Creating with two languages, second (not main one) language with empty values, causing no fields * for it being passed to the storage. Second language will not be stored. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testCreateContent - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testCreateContentType * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content */ + #[DependsExternal(ContentServiceTest::class, 'testCreateContent')] + #[DependsExternal(ContentTypeServiceTest::class, 'testCreateContentType')] public function testCreateContentTwoLanguagesSecondTranslationNotStored() { $mainLanguageCode = 'eng-US'; @@ -268,13 +262,12 @@ public function testCreateContentTwoLanguagesSecondTranslationNotStored() /** * Test for the createContent() method. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() * - * @depends testCreateContentTwoLanguagesSecondTranslationNotStored * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content */ - public function testCreateContentTwoLanguagesSecondTranslationNotStoredFields(Content $content) + #[Depends('testCreateContentTwoLanguagesSecondTranslationNotStored')] + public function testCreateContentTwoLanguagesSecondTranslationNotStoredFields(Content $content): void { $emptyValue = $this->getRepository()->getFieldTypeService()->getFieldType('ibexa_string')->getEmptyValue(); @@ -297,13 +290,12 @@ public function testCreateContentTwoLanguagesSecondTranslationNotStoredFields(Co * * Creating with no fields in struct, using only default values. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testCreateContent - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testCreateContentType * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content */ + #[DependsExternal(ContentServiceTest::class, 'testCreateContent')] + #[DependsExternal(ContentTypeServiceTest::class, 'testCreateContentType')] public function testCreateContentDefaultValuesNoStructFields() { $mainLanguageCode = 'eng-US'; @@ -319,13 +311,12 @@ public function testCreateContentDefaultValuesNoStructFields() /** * Test for the createContent() method. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() * - * @depends testCreateContentDefaultValuesNoStructFields * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content */ - public function testCreateContentDefaultValuesNoStructFieldsFields(Content $content) + #[Depends('testCreateContentDefaultValuesNoStructFields')] + public function testCreateContentDefaultValuesNoStructFieldsFields(Content $content): void { $emptyValue = $this->getRepository()->getFieldTypeService()->getFieldType('ibexa_string')->getEmptyValue(); @@ -345,13 +336,12 @@ public function testCreateContentDefaultValuesNoStructFieldsFields(Content $cont * * Creating in two languages with no given field values for main language. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testCreateContent - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testCreateContentType * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content */ + #[DependsExternal(ContentServiceTest::class, 'testCreateContent')] + #[DependsExternal(ContentTypeServiceTest::class, 'testCreateContentType')] public function testCreateContentTwoLanguagesNoValuesForMainLanguage() { $mainLanguageCode = 'eng-US'; @@ -369,13 +359,12 @@ public function testCreateContentTwoLanguagesNoValuesForMainLanguage() /** * Test for the createContent() method. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() * - * @depends testCreateContentTwoLanguagesNoValuesForMainLanguage * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content */ - public function testCreateContentTwoLanguagesNoValuesForMainLanguageFields(Content $content) + #[Depends('testCreateContentTwoLanguagesNoValuesForMainLanguage')] + public function testCreateContentTwoLanguagesNoValuesForMainLanguageFields(Content $content): void { $emptyValue = $this->getRepository()->getFieldTypeService()->getFieldType('ibexa_string')->getEmptyValue(); @@ -400,12 +389,11 @@ public function testCreateContentTwoLanguagesNoValuesForMainLanguageFields(Conte /** * Test for the createContentDraft() method. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContentDraft() * - * @depends testCreateContentTwoLanguagesMainTranslationStoredFields * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content[] */ + #[Depends('testCreateContentTwoLanguagesMainTranslationStoredFields')] public function testCreateContentDraft() { $repository = $this->getRepository(); @@ -423,11 +411,11 @@ public function testCreateContentDraft() /** * Test for the createContentDraft() method. * - * @depends testCreateContentDraft * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content[] $data */ - public function testCreateContentDraftFields(array $data) + #[Depends('testCreateContentDraft')] + public function testCreateContentDraftFields(array $data): void { $content = $data[1]; @@ -454,12 +442,12 @@ public function testCreateContentDraftFields(array $data) /** * Test for the createContentDraft() method. * - * @depends testCreateContentDraft - * @depends testCreateContentDraftFields * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content[] $data */ - public function testCreateContentDraftFieldsRetainsIds(array $data) + #[Depends('testCreateContentDraft')] + #[Depends('testCreateContentDraftFields')] + public function testCreateContentDraftFieldsRetainsIds(array $data): void { $this->assertFieldIds($data[0], $data[1]); } @@ -472,13 +460,12 @@ public function testCreateContentDraftFieldsRetainsIds(array $data) * - value for new language is empty * - value for new language is not empty * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testCreateContent - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testCreateContentType * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content */ + #[DependsExternal(ContentServiceTest::class, 'testCreateContent')] + #[DependsExternal(ContentTypeServiceTest::class, 'testCreateContentType')] public function testUpdateContentWithNewLanguage() { $initialLanguageCode = 'ger-DE'; @@ -495,13 +482,12 @@ public function testUpdateContentWithNewLanguage() /** * Test for the updateContent() method. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent() * - * @depends testUpdateContentWithNewLanguage * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content */ - public function testUpdateContentWithNewLanguageFields(Content $content) + #[Depends('testUpdateContentWithNewLanguage')] + public function testUpdateContentWithNewLanguageFields(Content $content): void { $emptyValue = $this->getRepository()->getFieldTypeService()->getFieldType('ibexa_string')->getEmptyValue(); @@ -540,13 +526,12 @@ public function testUpdateContentWithNewLanguageFields(Content $content) * - existing language value updated with empty value * - existing language value not changed * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testCreateContent - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testCreateContentType * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content */ + #[DependsExternal(ContentServiceTest::class, 'testCreateContent')] + #[DependsExternal(ContentTypeServiceTest::class, 'testCreateContentType')] public function testUpdateContentWithNewLanguageVariant() { $initialLanguageCode = 'ger-DE'; @@ -564,13 +549,12 @@ public function testUpdateContentWithNewLanguageVariant() /** * Test for the updateContent() method. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent() * - * @depends testUpdateContentWithNewLanguageVariant * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content */ - public function testUpdateContentWithNewLanguageVariantFields(Content $content) + #[Depends('testUpdateContentWithNewLanguageVariant')] + public function testUpdateContentWithNewLanguageVariantFields(Content $content): void { $emptyValue = $this->getRepository()->getFieldTypeService()->getFieldType('ibexa_string')->getEmptyValue(); @@ -604,13 +588,12 @@ public function testUpdateContentWithNewLanguageVariantFields(Content $content) * * Updating with with new language and no field values given in the update struct. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testCreateContent - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testCreateContentType * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content */ + #[DependsExternal(ContentServiceTest::class, 'testCreateContent')] + #[DependsExternal(ContentTypeServiceTest::class, 'testCreateContentType')] public function testUpdateContentWithNewLanguageNoValues() { $initialLanguageCode = 'ger-DE'; @@ -625,13 +608,12 @@ public function testUpdateContentWithNewLanguageNoValues() /** * Test for the updateContent() method. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent() * - * @depends testUpdateContentWithNewLanguageNoValues * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content */ - public function testUpdateContentWithNewLanguageNoValuesFields(Content $content) + #[Depends('testUpdateContentWithNewLanguageNoValues')] + public function testUpdateContentWithNewLanguageNoValuesFields(Content $content): void { $emptyValue = $this->getRepository()->getFieldTypeService()->getFieldType('ibexa_string')->getEmptyValue(); @@ -666,13 +648,12 @@ public function testUpdateContentWithNewLanguageNoValuesFields(Content $content) * When updating Content with two languages, updating non-translatable field will also update it's value * for non-main language. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testCreateContent - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testCreateContentType * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content */ + #[DependsExternal(ContentServiceTest::class, 'testCreateContent')] + #[DependsExternal(ContentTypeServiceTest::class, 'testCreateContentType')] public function testUpdateContentUpdatingNonTranslatableFieldUpdatesFieldCopy() { $initialLanguageCode = 'eng-US'; @@ -690,13 +671,12 @@ public function testUpdateContentUpdatingNonTranslatableFieldUpdatesFieldCopy() /** * Test for the updateContent() method. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent() * - * @depends testUpdateContentUpdatingNonTranslatableFieldUpdatesFieldCopy * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content */ - public function testUpdateContentUpdatingNonTranslatableFieldUpdatesFieldCopyFields(Content $content) + #[Depends('testUpdateContentUpdatingNonTranslatableFieldUpdatesFieldCopy')] + public function testUpdateContentUpdatingNonTranslatableFieldUpdatesFieldCopyFields(Content $content): void { $emptyValue = $this->getRepository()->getFieldTypeService()->getFieldType('ibexa_string')->getEmptyValue(); @@ -723,13 +703,12 @@ public function testUpdateContentUpdatingNonTranslatableFieldUpdatesFieldCopyFie * * Updating with two languages, initial language is always stored (even with all values being empty). * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent() * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testCreateContent - * @depends Ibexa\Tests\Integration\Core\Repository\ContentTypeServiceTest::testCreateContentType * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content */ + #[DependsExternal(ContentServiceTest::class, 'testCreateContent')] + #[DependsExternal(ContentTypeServiceTest::class, 'testCreateContentType')] public function testUpdateContentWithTwoLanguagesInitialLanguageTranslationNotCreated() { $initialLanguageCode = 'ger-DE'; @@ -748,13 +727,12 @@ public function testUpdateContentWithTwoLanguagesInitialLanguageTranslationNotCr /** * Test for the updateContent() method. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent() * - * @depends testUpdateContentWithTwoLanguagesInitialLanguageTranslationNotCreated * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Content $content */ - public function testUpdateContentWithTwoLanguagesInitialLanguageTranslationNotCreatedFields(Content $content) + #[Depends('testUpdateContentWithTwoLanguagesInitialLanguageTranslationNotCreated')] + public function testUpdateContentWithTwoLanguagesInitialLanguageTranslationNotCreatedFields(Content $content): void { $emptyValue = $this->getRepository()->getFieldTypeService()->getFieldType('ibexa_string')->getEmptyValue(); diff --git a/tests/integration/Core/Repository/NotificationServiceTest.php b/tests/integration/Core/Repository/NotificationServiceTest.php index 6ca767193f..fe480b5ec3 100644 --- a/tests/integration/Core/Repository/NotificationServiceTest.php +++ b/tests/integration/Core/Repository/NotificationServiceTest.php @@ -13,12 +13,14 @@ use Ibexa\Contracts\Core\Repository\Values\Notification\CreateStruct; use Ibexa\Contracts\Core\Repository\Values\Notification\Query\Criterion\Type; use Ibexa\Contracts\Core\Repository\Values\Notification\Query\NotificationQuery; +use Ibexa\Core\Repository\NotificationService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Depends; /** * Test case for the NotificationService. - * - * @covers \Ibexa\Contracts\Core\Repository\NotificationService */ +#[CoversClass(NotificationService::class)] class NotificationServiceTest extends BaseTestCase { public function testLoadNotifications(): void @@ -207,9 +209,7 @@ public function testCreateNotification(): void self::assertGreaterThan(0, $notification->id); } - /** - * @depends testCreateNotification - */ + #[Depends('testCreateNotification')] public function testCreateNotificationThrowsInvalidArgumentExceptionOnMissingOwner(): void { $this->expectException(InvalidArgumentException::class); @@ -228,9 +228,7 @@ public function testCreateNotificationThrowsInvalidArgumentExceptionOnMissingOwn /* END: Use Case */ } - /** - * @depends testCreateNotification - */ + #[Depends('testCreateNotification')] public function testCreateNotificationThrowsInvalidArgumentExceptionOnMissingType(): void { $this->expectException(InvalidArgumentException::class); diff --git a/tests/integration/Core/Repository/ObjectStateServiceAuthorizationTest.php b/tests/integration/Core/Repository/ObjectStateServiceAuthorizationTest.php index e92a5a5465..fd4b348549 100644 --- a/tests/integration/Core/Repository/ObjectStateServiceAuthorizationTest.php +++ b/tests/integration/Core/Repository/ObjectStateServiceAuthorizationTest.php @@ -8,25 +8,24 @@ namespace Ibexa\Tests\Integration\Core\Repository; use Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException; +use Ibexa\Core\Repository\ObjectStateService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DependsExternal; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the ObjectStateService using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService - * - * @group integration - * @group authorization */ +#[CoversClass(ObjectStateService::class)] +#[Group('integration')] +#[Group('authorization')] class ObjectStateServiceAuthorizationTest extends BaseTestCase { /** * Test for the createObjectStateGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::createObjectStateGroup() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ObjectStateServiceTest::testCreateObjectStateGroup */ - public function testCreateObjectStateGroupThrowsUnauthorizedException() + #[DependsExternal(ObjectStateServiceTest::class, 'testCreateObjectStateGroup')] + public function testCreateObjectStateGroupThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -66,12 +65,9 @@ public function testCreateObjectStateGroupThrowsUnauthorizedException() /** * Test for the updateObjectStateGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::updateObjectStateGroup() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ObjectStateServiceTest::testUpdateObjectStateGroup */ - public function testUpdateObjectStateGroupThrowsUnauthorizedException() + #[DependsExternal(ObjectStateServiceTest::class, 'testUpdateObjectStateGroup')] + public function testUpdateObjectStateGroupThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -116,12 +112,9 @@ public function testUpdateObjectStateGroupThrowsUnauthorizedException() /** * Test for the deleteObjectStateGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::deleteObjectStateGroup() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ObjectStateServiceTest::testDeleteObjectStateGroup */ - public function testDeleteObjectStateGroupThrowsUnauthorizedException() + #[DependsExternal(ObjectStateServiceTest::class, 'testDeleteObjectStateGroup')] + public function testDeleteObjectStateGroupThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -153,12 +146,9 @@ public function testDeleteObjectStateGroupThrowsUnauthorizedException() /** * Test for the createObjectState() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::createObjectState() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ObjectStateServiceTest::testCreateObjectState */ - public function testCreateObjectStateThrowsUnauthorizedException() + #[DependsExternal(ObjectStateServiceTest::class, 'testCreateObjectState')] + public function testCreateObjectStateThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -205,12 +195,9 @@ public function testCreateObjectStateThrowsUnauthorizedException() /** * Test for the updateObjectState() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::updateObjectState() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ObjectStateServiceTest::testUpdateObjectState */ - public function testUpdateObjectStateThrowsUnauthorizedException() + #[DependsExternal(ObjectStateServiceTest::class, 'testUpdateObjectState')] + public function testUpdateObjectStateThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -256,12 +243,9 @@ public function testUpdateObjectStateThrowsUnauthorizedException() /** * Test for the setPriorityOfObjectState() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::setPriorityOfObjectState() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ObjectStateServiceTest::testSetPriorityOfObjectState */ - public function testSetPriorityOfObjectStateThrowsUnauthorizedException() + #[DependsExternal(ObjectStateServiceTest::class, 'testSetPriorityOfObjectState')] + public function testSetPriorityOfObjectStateThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -295,12 +279,9 @@ public function testSetPriorityOfObjectStateThrowsUnauthorizedException() /** * Test for the deleteObjectState() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::deleteObjectState() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ObjectStateServiceTest::testDeleteObjectState */ - public function testDeleteObjectStateThrowsUnauthorizedException() + #[DependsExternal(ObjectStateServiceTest::class, 'testDeleteObjectState')] + public function testDeleteObjectStateThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -330,12 +311,9 @@ public function testDeleteObjectStateThrowsUnauthorizedException() /** * Test for the setContentState() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::setContentState() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ObjectStateServiceTest::testSetContentState */ - public function testSetContentStateThrowsUnauthorizedException() + #[DependsExternal(ObjectStateServiceTest::class, 'testSetContentState')] + public function testSetContentStateThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/ObjectStateServiceTest.php b/tests/integration/Core/Repository/ObjectStateServiceTest.php index 86c8c96835..0c2d011f05 100644 --- a/tests/integration/Core/Repository/ObjectStateServiceTest.php +++ b/tests/integration/Core/Repository/ObjectStateServiceTest.php @@ -16,14 +16,18 @@ use Ibexa\Contracts\Core\Repository\Values\ObjectState\ObjectStateGroupCreateStruct; use Ibexa\Contracts\Core\Repository\Values\ObjectState\ObjectStateGroupUpdateStruct; use Ibexa\Contracts\Core\Repository\Values\ObjectState\ObjectStateUpdateStruct; +use Ibexa\Core\Repository\ObjectStateService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\DependsExternal; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the ObjectStateService using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService - * - * @group object-state */ +#[CoversClass(ObjectStateService::class)] +#[Group('object-state')] class ObjectStateServiceTest extends BaseTestCase { private const EXISTING_OBJECT_STATE_GROUP_IDENTIFIER = 'ibexa_lock'; @@ -34,9 +38,6 @@ class ObjectStateServiceTest extends BaseTestCase /** * Test for the newObjectStateGroupCreateStruct() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::newObjectStateGroupCreateStruct() */ public function testNewObjectStateGroupCreateStruct() { @@ -62,10 +63,9 @@ public function testNewObjectStateGroupCreateStruct() * testNewObjectStateGroupCreateStructValues. * * @param \Ibexa\Contracts\Core\Repository\Values\ObjectState\ObjectStateGroupCreateStruct $objectStateGroupCreate - * - * @depends testNewObjectStateGroupCreateStruct */ - public function testNewObjectStateGroupCreateStructValues(ObjectStateGroupCreateStruct $objectStateGroupCreate) + #[Depends('testNewObjectStateGroupCreateStruct')] + public function testNewObjectStateGroupCreateStructValues(ObjectStateGroupCreateStruct $objectStateGroupCreate): void { $this->assertPropertiesCorrect( [ @@ -80,9 +80,6 @@ public function testNewObjectStateGroupCreateStructValues(ObjectStateGroupCreate /** * Test for the newObjectStateGroupUpdateStruct() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::newObjectStateGroupUpdateStruct() */ public function testNewObjectStateGroupUpdateStruct() { @@ -106,10 +103,9 @@ public function testNewObjectStateGroupUpdateStruct() * testNewObjectStateGroupUpdateStructValues. * * @param \Ibexa\Contracts\Core\Repository\Values\ObjectState\ObjectStateGroupUpdateStruct $objectStateGroupUpdate - * - * @depends testNewObjectStateGroupUpdateStruct */ - public function testNewObjectStateGroupUpdateStructValues(ObjectStateGroupUpdateStruct $objectStateGroupUpdate) + #[Depends('testNewObjectStateGroupUpdateStruct')] + public function testNewObjectStateGroupUpdateStructValues(ObjectStateGroupUpdateStruct $objectStateGroupUpdate): void { $this->assertPropertiesCorrect( [ @@ -124,9 +120,6 @@ public function testNewObjectStateGroupUpdateStructValues(ObjectStateGroupUpdate /** * Test for the newObjectStateCreateStruct() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::newObjectStateCreateStruct() */ public function testNewObjectStateCreateStruct() { @@ -152,10 +145,9 @@ public function testNewObjectStateCreateStruct() * testNewObjectStateCreateStructValues. * * @param \Ibexa\Contracts\Core\Repository\Values\ObjectState\ObjectStateCreateStruct $objectStateCreate - * - * @depends testNewObjectStateCreateStruct */ - public function testNewObjectStateCreateStructValues(ObjectStateCreateStruct $objectStateCreate) + #[Depends('testNewObjectStateCreateStruct')] + public function testNewObjectStateCreateStructValues(ObjectStateCreateStruct $objectStateCreate): void { $this->assertPropertiesCorrect( [ @@ -171,9 +163,6 @@ public function testNewObjectStateCreateStructValues(ObjectStateCreateStruct $ob /** * Test for the newObjectStateUpdateStruct() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::newObjectStateUpdateStruct() */ public function testNewObjectStateUpdateStruct() { @@ -197,10 +186,9 @@ public function testNewObjectStateUpdateStruct() * testNewObjectStateUpdateStructValues. * * @param \Ibexa\Contracts\Core\Repository\Values\ObjectState\ObjectStateUpdateStruct $objectStateUpdate - * - * @depends testNewObjectStateUpdateStruct */ - public function testNewObjectStateUpdateStructValues(ObjectStateUpdateStruct $objectStateUpdate) + #[Depends('testNewObjectStateUpdateStruct')] + public function testNewObjectStateUpdateStructValues(ObjectStateUpdateStruct $objectStateUpdate): void { $this->assertPropertiesCorrect( [ @@ -215,12 +203,8 @@ public function testNewObjectStateUpdateStructValues(ObjectStateUpdateStruct $ob /** * Test for the createObjectStateGroup() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::createObjectStateGroup() - * - * @depends testNewObjectStateGroupCreateStructValues */ + #[Depends('testNewObjectStateGroupCreateStructValues')] public function testCreateObjectStateGroup() { $repository = $this->getRepository(); @@ -258,10 +242,9 @@ public function testCreateObjectStateGroup() * testCreateObjectStateGroupStructValues. * * @param \Ibexa\Contracts\Core\Repository\Values\ObjectState\ObjectStateGroup $createdObjectStateGroup - * - * @depends testCreateObjectStateGroup */ - public function testCreateObjectStateGroupStructValues(ObjectStateGroup $createdObjectStateGroup) + #[Depends('testCreateObjectStateGroup')] + public function testCreateObjectStateGroupStructValues(ObjectStateGroup $createdObjectStateGroup): void { $this->assertPropertiesCorrect( [ @@ -284,13 +267,9 @@ public function testCreateObjectStateGroupStructValues(ObjectStateGroup $created /** * Test for the createObjectStateGroup() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::createObjectStateGroup() - * - * @depends testCreateObjectStateGroup */ - public function testCreateObjectStateGroupThrowsInvalidArgumentException() + #[Depends('testCreateObjectStateGroup')] + public function testCreateObjectStateGroupThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -320,10 +299,8 @@ public function testCreateObjectStateGroupThrowsInvalidArgumentException() /** * Test for the loadObjectStateGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::loadObjectStateGroup */ - public function testLoadObjectStateGroup() + public function testLoadObjectStateGroup(): void { $repository = $this->getRepository(); @@ -358,13 +335,9 @@ public function testLoadObjectStateGroup() /** * Test for the loadObjectStateGroup() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::loadObjectStateGroup() - * - * @depends testLoadObjectStateGroup */ - public function testLoadObjectStateGroupThrowsNotFoundException() + #[Depends('testLoadObjectStateGroup')] + public function testLoadObjectStateGroupThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -383,9 +356,6 @@ public function testLoadObjectStateGroupThrowsNotFoundException() /* END: Use Case */ } - /** - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::loadGroupByIdentifier - */ public function testLoadObjectStateGroupByIdentifier(): void { $repository = $this->getRepository(); @@ -414,9 +384,6 @@ public function testLoadObjectStateGroupByIdentifier(): void ); } - /** - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::loadGroupByIdentifier - */ public function testLoadObjectStateGroupByIdentifierThrowsNotFoundException(): void { $repository = $this->getRepository(); @@ -436,13 +403,9 @@ public function testLoadObjectStateGroupByIdentifierThrowsNotFoundException(): v /** * Test for the loadObjectStateGroups() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::loadObjectStateGroups() - * - * @depends testLoadObjectStateGroup */ - public function testLoadObjectStateGroups() + #[Depends('testLoadObjectStateGroup')] + public function testLoadObjectStateGroups(): void { $repository = $this->getRepository(); @@ -538,13 +501,9 @@ protected function assertObjectsLoadedByIdentifiers(array $expectedIdentifiers, /** * Test for the loadObjectStateGroups() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::loadObjectStateGroups($offset) - * - * @depends testLoadObjectStateGroups */ - public function testLoadObjectStateGroupsWithOffset() + #[Depends('testLoadObjectStateGroups')] + public function testLoadObjectStateGroupsWithOffset(): void { $repository = $this->getRepository(); $objectStateService = $repository->getObjectStateService(); @@ -591,13 +550,9 @@ static function ($group) { /** * Test for the loadObjectStateGroups() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::loadObjectStateGroups($offset, $limit) - * - * @depends testLoadObjectStateGroupsWithOffset */ - public function testLoadObjectStateGroupsWithOffsetAndLimit() + #[Depends('testLoadObjectStateGroupsWithOffset')] + public function testLoadObjectStateGroupsWithOffsetAndLimit(): void { $repository = $this->getRepository(); $objectStateService = $repository->getObjectStateService(); @@ -623,13 +578,9 @@ public function testLoadObjectStateGroupsWithOffsetAndLimit() /** * Test for the loadObjectStates() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::loadObjectStates() - * - * @depends testLoadObjectStateGroup */ - public function testLoadObjectStates() + #[Depends('testLoadObjectStateGroup')] + public function testLoadObjectStates(): void { $repository = $this->getRepository(); @@ -659,11 +610,8 @@ public function testLoadObjectStates() /** * Test for the updateObjectStateGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::updateObjectStateGroup - * - * @depends testLoadObjectStateGroup */ + #[Depends('testLoadObjectStateGroup')] public function testUpdateObjectStateGroup() { $repository = $this->getRepository(); @@ -716,12 +664,9 @@ public function testUpdateObjectStateGroup() /** * Test service method for partially updating object state group. - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::updateObjectStateGroup - * - * @depends testLoadObjectStateGroup */ - public function testUpdateObjectStateGroupChosenFieldsOnly() + #[Depends('testLoadObjectStateGroup')] + public function testUpdateObjectStateGroupChosenFieldsOnly(): void { $repository = $this->getRepository(); $objectStateService = $repository->getObjectStateService(); @@ -757,13 +702,9 @@ public function testUpdateObjectStateGroupChosenFieldsOnly() /** * Test for the updateObjectStateGroup() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::updateObjectStateGroup() - * - * @depends testUpdateObjectStateGroup */ - public function testUpdateObjectStateGroupThrowsInvalidArgumentException() + #[Depends('testUpdateObjectStateGroup')] + public function testUpdateObjectStateGroupThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -811,10 +752,9 @@ public function testUpdateObjectStateGroupThrowsInvalidArgumentException() * testUpdateObjectStateGroupStructValues. * * @param array $testData - * - * @depends testUpdateObjectStateGroup */ - public function testUpdateObjectStateGroupStructValues(array $testData) + #[Depends('testUpdateObjectStateGroup')] + public function testUpdateObjectStateGroupStructValues(array $testData): void { list( $loadedObjectStateGroup, @@ -834,13 +774,9 @@ public function testUpdateObjectStateGroupStructValues(array $testData) /** * Test for the createObjectState() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::createObjectState() - * - * @depends testLoadObjectStateGroup - * @depends testNewObjectStateCreateStruct */ + #[Depends('testLoadObjectStateGroup')] + #[Depends('testNewObjectStateCreateStruct')] public function testCreateObjectState() { $repository = $this->getRepository(); @@ -891,10 +827,8 @@ public function testCreateObjectState() /** * Test service method for creating object state in empty group. - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::createObjectState */ - public function testCreateObjectStateInEmptyGroup() + public function testCreateObjectStateInEmptyGroup(): void { $repository = $this->getRepository(); $objectStateService = $repository->getObjectStateService(); @@ -947,14 +881,10 @@ public function testCreateObjectStateInEmptyGroup() /** * Test for the createObjectState() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::createObjectState() - * - * @depends testLoadObjectStateGroup - * @depends testCreateObjectState */ - public function testCreateObjectStateThrowsInvalidArgumentException() + #[Depends('testLoadObjectStateGroup')] + #[Depends('testCreateObjectState')] + public function testCreateObjectStateThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -994,10 +924,9 @@ public function testCreateObjectStateThrowsInvalidArgumentException() * testCreateObjectStateStructValues. * * @param array $testData - * - * @depends testCreateObjectState */ - public function testCreateObjectStateStructValues(array $testData) + #[Depends('testCreateObjectState')] + public function testCreateObjectStateStructValues(array $testData): void { list( $loadedObjectStateGroup, @@ -1020,12 +949,8 @@ public function testCreateObjectStateStructValues(array $testData) /** * Test for the loadObjectState() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::loadObjectState() - * - * @depends testLoadObjectStateGroup */ + #[Depends('testLoadObjectStateGroup')] public function testLoadObjectState() { $repository = $this->getRepository(); @@ -1048,9 +973,6 @@ public function testLoadObjectState() return $loadedObjectState; } - /** - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::loadObjectStateByIdentifier - */ public function testLoadObjectStateByIdentifier(): void { $repository = $this->getRepository(); @@ -1082,9 +1004,6 @@ public function testLoadObjectStateByIdentifier(): void ); } - /** - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::loadObjectStateByIdentifier - */ public function testLoadObjectStateByIdentifierThrowsNotFoundException(): void { $repository = $this->getRepository(); @@ -1114,10 +1033,9 @@ public function testLoadObjectStateByIdentifierThrowsNotFoundException(): void * testLoadObjectStateStructValues. * * @param \Ibexa\Contracts\Core\Repository\Values\ObjectState\ObjectState $loadedObjectState - * - * @depends testLoadObjectState */ - public function testLoadObjectStateStructValues(ObjectState $loadedObjectState) + #[Depends('testLoadObjectState')] + public function testLoadObjectStateStructValues(ObjectState $loadedObjectState): void { $this->assertPropertiesCorrect( [ @@ -1145,13 +1063,9 @@ public function testLoadObjectStateStructValues(ObjectState $loadedObjectState) /** * Test for the loadObjectState() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::loadObjectState() - * - * @depends testLoadObjectState */ - public function testLoadObjectStateThrowsNotFoundException() + #[Depends('testLoadObjectState')] + public function testLoadObjectStateThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -1174,7 +1088,7 @@ public function testLoadObjectStateThrowsNotFoundException() * * @return array */ - public function getPrioritizedLanguagesList() + public static function getPrioritizedLanguagesList(): array { return [ [[], null], @@ -1190,15 +1104,15 @@ public function getPrioritizedLanguagesList() /** * Test that multi-language logic for loadObjectStateGroups respects prioritized language list. * - * @dataProvider getPrioritizedLanguagesList * * @param string[] $prioritizedLanguages * @param string|null $expectedLanguageCode */ + #[DataProvider('getPrioritizedLanguagesList')] public function testLoadObjectStateGroupsWithPrioritizedLanguagesList( array $prioritizedLanguages, $expectedLanguageCode - ) { + ): void { // cleanup before the actual test $this->deleteExistingObjectStateGroups(); @@ -1231,15 +1145,15 @@ public function testLoadObjectStateGroupsWithPrioritizedLanguagesList( /** * Test that multi-language logic for loadObjectStateGroup respects prioritized language list. * - * @dataProvider getPrioritizedLanguagesList * * @param string[] $prioritizedLanguages * @param string|null $expectedLanguageCode */ + #[DataProvider('getPrioritizedLanguagesList')] public function testLoadObjectStateGroupWithPrioritizedLanguagesList( array $prioritizedLanguages, $expectedLanguageCode - ) { + ): void { $repository = $this->getRepository(); $objectStateService = $repository->getObjectStateService(); @@ -1267,15 +1181,15 @@ public function testLoadObjectStateGroupWithPrioritizedLanguagesList( /** * Test that multi-language logic for loadObjectState respects prioritized language list. * - * @dataProvider getPrioritizedLanguagesList * * @param string[] $prioritizedLanguages * @param string|null $expectedLanguageCode */ + #[DataProvider('getPrioritizedLanguagesList')] public function testLoadObjectStateWithPrioritizedLanguagesList( array $prioritizedLanguages, $expectedLanguageCode - ) { + ): void { $repository = $this->getRepository(); $objectStateService = $repository->getObjectStateService(); @@ -1303,12 +1217,12 @@ public function testLoadObjectStateWithPrioritizedLanguagesList( /** * Test that multi-language logic for loadObjectStates respects prioritized language list. * - * @dataProvider getPrioritizedLanguagesList * * @param string[] $languageCodes * @param string|null $expectedLanguageCode */ - public function testLoadObjectStatesWithPrioritizedLanguagesList($languageCodes, $expectedLanguageCode) + #[DataProvider('getPrioritizedLanguagesList')] + public function testLoadObjectStatesWithPrioritizedLanguagesList($languageCodes, $expectedLanguageCode): void { $repository = $this->getRepository(); $objectStateService = $repository->getObjectStateService(); @@ -1357,11 +1271,8 @@ public function testLoadObjectStatesWithPrioritizedLanguagesList($languageCodes, /** * Test for the updateObjectState() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::updateObjectState - * - * @depends testLoadObjectState */ + #[Depends('testLoadObjectState')] public function testUpdateObjectState() { $repository = $this->getRepository(); @@ -1413,12 +1324,9 @@ public function testUpdateObjectState() /** * Test service method for partially updating object state. - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::updateObjectState - * - * @depends testLoadObjectState */ - public function testUpdateObjectStateChosenFieldsOnly() + #[Depends('testLoadObjectState')] + public function testUpdateObjectStateChosenFieldsOnly(): void { $repository = $this->getRepository(); $objectStateService = $repository->getObjectStateService(); @@ -1460,13 +1368,9 @@ public function testUpdateObjectStateChosenFieldsOnly() /** * Test for the updateObjectState() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::updateObjectState() - * - * @depends testUpdateObjectState */ - public function testUpdateObjectStateThrowsInvalidArgumentException() + #[Depends('testUpdateObjectState')] + public function testUpdateObjectStateThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -1505,10 +1409,9 @@ public function testUpdateObjectStateThrowsInvalidArgumentException() * testUpdateObjectStateStructValues. * * @param array $testData - * - * @depends testUpdateObjectState */ - public function testUpdateObjectStateStructValues(array $testData) + #[Depends('testUpdateObjectState')] + public function testUpdateObjectStateStructValues(array $testData): void { list( $loadedObjectState, @@ -1541,13 +1444,9 @@ public function testUpdateObjectStateStructValues(array $testData) /** * Test for the setPriorityOfObjectState() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::setPriorityOfObjectState - * - * @depends testLoadObjectState */ - public function testSetPriorityOfObjectState() + #[Depends('testLoadObjectState')] + public function testSetPriorityOfObjectState(): void { $repository = $this->getRepository(); @@ -1581,14 +1480,10 @@ public function testSetPriorityOfObjectState() /** * Test for the getContentState() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::getContentState() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContentInfo - * @depends testLoadObjectState */ - public function testGetContentState() + #[DependsExternal(ContentServiceTest::class, 'testLoadContentInfo')] + #[Depends('testLoadObjectState')] + public function testGetContentState(): void { $repository = $this->getRepository(); @@ -1621,12 +1516,10 @@ public function testGetContentState() /** * testGetInitialObjectState. - * - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContentInfo - * @depends testLoadObjectState */ - public function testGetInitialObjectState() + #[DependsExternal(ContentServiceTest::class, 'testLoadContentInfo')] + #[Depends('testLoadObjectState')] + public function testGetInitialObjectState(): void { $repository = $this->getRepository(); $objectStateService = $repository->getObjectStateService(); @@ -1687,14 +1580,10 @@ public function testGetInitialObjectState() /** * Test for the setContentState() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::setContentState() - * - * @depends Ibexa\Tests\Integration\Core\Repository\ContentServiceTest::testLoadContentInfo - * @depends testLoadObjectState */ - public function testSetContentState() + #[DependsExternal(ContentServiceTest::class, 'testLoadContentInfo')] + #[Depends('testLoadObjectState')] + public function testSetContentState(): void { $repository = $this->getRepository(); @@ -1734,12 +1623,9 @@ public function testSetContentState() /** * Test for the setContentState() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::setContentState - * - * @depends testSetContentState */ - public function testSetContentStateThrowsInvalidArgumentException() + #[Depends('testSetContentState')] + public function testSetContentStateThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -1778,13 +1664,9 @@ public function testSetContentStateThrowsInvalidArgumentException() /** * Test for the getContentCount() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::getContentCount() - * - * @depends testLoadObjectState */ - public function testGetContentCount() + #[Depends('testLoadObjectState')] + public function testGetContentCount(): void { $repository = $this->getRepository(); @@ -1803,13 +1685,9 @@ public function testGetContentCount() /** * Test for the deleteObjectState() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::deleteObjectState() - * - * @depends testLoadObjectState */ - public function testDeleteObjectState() + #[Depends('testLoadObjectState')] + public function testDeleteObjectState(): void { $repository = $this->getRepository(); @@ -1837,13 +1715,9 @@ public function testDeleteObjectState() /** * Test for the deleteObjectStateGroup() method. - * - * - * @covers \Ibexa\Contracts\Core\Repository\ObjectStateService::deleteObjectStateGroup() - * - * @depends testLoadObjectStateGroup */ - public function testDeleteObjectStateGroup() + #[Depends('testLoadObjectStateGroup')] + public function testDeleteObjectStateGroup(): void { $repository = $this->getRepository(); diff --git a/tests/integration/Core/Repository/PermissionResolverTest.php b/tests/integration/Core/Repository/PermissionResolverTest.php index fd9bcb5d75..f89a07a5d6 100644 --- a/tests/integration/Core/Repository/PermissionResolverTest.php +++ b/tests/integration/Core/Repository/PermissionResolverTest.php @@ -19,24 +19,26 @@ use Ibexa\Contracts\Core\Repository\Values\User\LookupLimitationResult; use Ibexa\Contracts\Core\Repository\Values\User\LookupPolicyLimitations; use Ibexa\Contracts\Core\Repository\Values\ValueObject; +use Ibexa\Core\Repository\Permission\PermissionResolver; use Ibexa\Core\Repository\Values\User\UserReference; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\DependsExternal; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the PermissionResolver. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver - * - * @group integration - * @group permission */ +#[CoversClass(PermissionResolver::class)] +#[Group('integration')] +#[Group('permission')] class PermissionResolverTest extends BaseTestCase { /** * Test for the getCurrentUserReference() method. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::getCurrentUserReference() */ - public function testGetCurrentUserReferenceReturnsAnonymousUserReference() + public function testGetCurrentUserReferenceReturnsAnonymousUserReference(): void { $repository = $this->getRepository(); $anonymousUserId = $this->generateId('user', 10); @@ -61,12 +63,9 @@ public function testGetCurrentUserReferenceReturnsAnonymousUserReference() /** * Test for the setCurrentUserReference() method. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::setCurrentUserReference() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetUserService */ - public function testSetCurrentUserReference() + #[DependsExternal(RepositoryTest::class, 'testGetUserService')] + public function testSetCurrentUserReference(): void { $repository = $this->getRepository(); $repository->getPermissionResolver()->setCurrentUserReference( @@ -104,12 +103,9 @@ public function testSetCurrentUserReference() /** * Test for the hasAccess() method. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::hasAccess() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetUserService */ - public function testHasAccessWithAnonymousUserNo() + #[DependsExternal(RepositoryTest::class, 'testGetUserService')] + public function testHasAccessWithAnonymousUserNo(): void { $repository = $this->getRepository(); @@ -135,13 +131,10 @@ public function testHasAccessWithAnonymousUserNo() /** * Test for the hasAccess() method. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::hasAccess() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetUserService - * @depends testHasAccessWithAnonymousUserNo */ - public function testHasAccessForCurrentUserNo() + #[DependsExternal(RepositoryTest::class, 'testGetUserService')] + #[Depends('testHasAccessWithAnonymousUserNo')] + public function testHasAccessForCurrentUserNo(): void { $repository = $this->getRepository(); @@ -170,12 +163,9 @@ public function testHasAccessForCurrentUserNo() /** * Test for the hasAccess() method. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::hasAccess() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetUserService */ - public function testHasAccessWithAdministratorUser() + #[DependsExternal(RepositoryTest::class, 'testGetUserService')] + public function testHasAccessWithAdministratorUser(): void { $repository = $this->getRepository(); @@ -199,14 +189,11 @@ public function testHasAccessWithAdministratorUser() /** * Test for the hasAccess() method. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::hasAccess() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetUserService - * @depends testSetCurrentUserReference - * @depends testHasAccessWithAdministratorUser */ - public function testHasAccessForCurrentUserYes() + #[DependsExternal(RepositoryTest::class, 'testGetUserService')] + #[Depends('testSetCurrentUserReference')] + #[Depends('testHasAccessWithAdministratorUser')] + public function testHasAccessForCurrentUserYes(): void { $repository = $this->getRepository(); @@ -233,13 +220,10 @@ public function testHasAccessForCurrentUserYes() /** * Test for the hasAccess() method. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::hasAccess() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetUserService - * @depends testSetCurrentUserReference */ - public function testHasAccessLimited() + #[DependsExternal(RepositoryTest::class, 'testGetUserService')] + #[Depends('testSetCurrentUserReference')] + public function testHasAccessLimited(): void { $repository = $this->getRepository(); @@ -264,14 +248,11 @@ public function testHasAccessLimited() /** * Test for the canUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::canUser() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetUserService - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetContentService - * @depends testHasAccessForCurrentUserNo */ - public function testCanUserForAnonymousUserNo() + #[DependsExternal(RepositoryTest::class, 'testGetUserService')] + #[DependsExternal(RepositoryTest::class, 'testGetContentService')] + #[Depends('testHasAccessForCurrentUserNo')] + public function testCanUserForAnonymousUserNo(): void { $this->expectException(UnauthorizedException::class); @@ -311,14 +292,11 @@ public function testCanUserForAnonymousUserNo() /** * Test for the canUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::canUser() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetUserService - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetContentService - * @depends testHasAccessForCurrentUserYes */ - public function testCanUserForAdministratorUser() + #[DependsExternal(RepositoryTest::class, 'testGetUserService')] + #[DependsExternal(RepositoryTest::class, 'testGetContentService')] + #[Depends('testHasAccessForCurrentUserYes')] + public function testCanUserForAdministratorUser(): void { $this->expectException(NotFoundException::class); @@ -357,14 +335,11 @@ public function testCanUserForAdministratorUser() /** * Test for the canUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::canUser() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetUserService - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetContentService - * @depends testHasAccessLimited */ - public function testCanUserWithLimitationYes() + #[DependsExternal(RepositoryTest::class, 'testGetUserService')] + #[DependsExternal(RepositoryTest::class, 'testGetContentService')] + #[Depends('testHasAccessLimited')] + public function testCanUserWithLimitationYes(): void { $repository = $this->getRepository(); @@ -394,14 +369,11 @@ public function testCanUserWithLimitationYes() /** * Test for the canUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::canUser() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetUserService - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetContentService - * @depends testHasAccessLimited */ - public function testCanUserWithLimitationNo() + #[DependsExternal(RepositoryTest::class, 'testGetUserService')] + #[DependsExternal(RepositoryTest::class, 'testGetContentService')] + #[Depends('testHasAccessLimited')] + public function testCanUserWithLimitationNo(): void { $this->expectException(UnauthorizedException::class); @@ -439,15 +411,12 @@ public function testCanUserWithLimitationNo() /** * Test for the canUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::canUser() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetUserService - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetContentTypeService - * @depends testSetCurrentUserReference - * @depends testHasAccessLimited */ - public function testCanUserThrowsInvalidArgumentException() + #[DependsExternal(RepositoryTest::class, 'testGetUserService')] + #[DependsExternal(RepositoryTest::class, 'testGetContentTypeService')] + #[Depends('testSetCurrentUserReference')] + #[Depends('testHasAccessLimited')] + public function testCanUserThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -479,15 +448,12 @@ public function testCanUserThrowsInvalidArgumentException() /** * Test for the canUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::canUser() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetUserService - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetContentService - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetContentTypeService - * @depends testHasAccessLimited */ - public function testCanUserWithTargetYes() + #[DependsExternal(RepositoryTest::class, 'testGetUserService')] + #[DependsExternal(RepositoryTest::class, 'testGetContentService')] + #[DependsExternal(RepositoryTest::class, 'testGetContentTypeService')] + #[Depends('testHasAccessLimited')] + public function testCanUserWithTargetYes(): void { $repository = $this->getRepository(); @@ -541,15 +507,12 @@ public function testCanUserWithTargetYes() /** * Test for the canUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::canUser() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetUserService - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetContentService - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetContentTypeService - * @depends testHasAccessLimited */ - public function testCanUserWithTargetNo() + #[DependsExternal(RepositoryTest::class, 'testGetUserService')] + #[DependsExternal(RepositoryTest::class, 'testGetContentService')] + #[DependsExternal(RepositoryTest::class, 'testGetContentTypeService')] + #[Depends('testHasAccessLimited')] + public function testCanUserWithTargetNo(): void { $this->expectException(UnauthorizedException::class); @@ -602,15 +565,12 @@ public function testCanUserWithTargetNo() /** * Test for the canUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::canUser() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetUserService - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetContentService - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetContentTypeService - * @depends testHasAccessLimited */ - public function testCanUserWithMultipleTargetsYes() + #[DependsExternal(RepositoryTest::class, 'testGetUserService')] + #[DependsExternal(RepositoryTest::class, 'testGetContentService')] + #[DependsExternal(RepositoryTest::class, 'testGetContentTypeService')] + #[Depends('testHasAccessLimited')] + public function testCanUserWithMultipleTargetsYes(): void { $repository = $this->getRepository(); @@ -665,15 +625,12 @@ public function testCanUserWithMultipleTargetsYes() /** * Test for the canUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::canUser() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetUserService - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetContentService - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetContentTypeService - * @depends testHasAccessLimited */ - public function testCanUserWithMultipleTargetsNo() + #[DependsExternal(RepositoryTest::class, 'testGetUserService')] + #[DependsExternal(RepositoryTest::class, 'testGetContentService')] + #[DependsExternal(RepositoryTest::class, 'testGetContentTypeService')] + #[Depends('testHasAccessLimited')] + public function testCanUserWithMultipleTargetsNo(): void { $this->expectException(UnauthorizedException::class); @@ -727,17 +684,14 @@ public function testCanUserWithMultipleTargetsNo() /** * Test for the canUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::canUser() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetUserService - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetContentService - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetContentTypeService - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetURLAliasService - * @depends testSetCurrentUserReference - * @depends testHasAccessLimited */ - public function testCanUserWithTargetThrowsInvalidArgumentException() + #[DependsExternal(RepositoryTest::class, 'testGetUserService')] + #[DependsExternal(RepositoryTest::class, 'testGetContentService')] + #[DependsExternal(RepositoryTest::class, 'testGetContentTypeService')] + #[DependsExternal(RepositoryTest::class, 'testGetURLAliasService')] + #[Depends('testSetCurrentUserReference')] + #[Depends('testHasAccessLimited')] + public function testCanUserWithTargetThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -777,10 +731,8 @@ public function testCanUserWithTargetThrowsInvalidArgumentException() /** * Test for the canUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::canUser() */ - public function testCanUserThrowsBadStateException() + public function testCanUserThrowsBadStateException(): void { $this->expectException(BadStateException::class); @@ -792,9 +744,7 @@ public function testCanUserThrowsBadStateException() /** * Test PermissionResolver::canUser for Users with different Limitations. * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::canUser * - * @dataProvider getDataForTestCanUserWithLimitations * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation $limitation * @param string $module @@ -806,6 +756,7 @@ public function testCanUserThrowsBadStateException() * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ + #[DataProvider('getDataForTestCanUserWithLimitations')] public function testCanUserWithLimitations( Limitation $limitation, $module, @@ -813,7 +764,7 @@ public function testCanUserWithLimitations( ValueObject $object, array $targets, $expectedResult - ) { + ): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); $roleService = $repository->getRoleService(); @@ -847,9 +798,9 @@ public function testCanUserWithLimitations( * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException */ - public function getDataForTestCanUserWithLimitations() + public static function getDataForTestCanUserWithLimitations(): array { - $repository = $this->getRepository(); + $repository = static::resolveRepository(); $contentService = $repository->getContentService(); $contentTypeService = $repository->getContentTypeService(); @@ -897,13 +848,10 @@ public function getDataForTestCanUserWithLimitations() /** * Test for the lookupLimitations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::lookupLimitations() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetUserService - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetContentService - * @depends Ibexa\Tests\Integration\Core\Repository\PermissionResolverTest::testHasAccessForCurrentUserNo */ + #[DependsExternal(RepositoryTest::class, 'testGetUserService')] + #[DependsExternal(RepositoryTest::class, 'testGetContentService')] + #[DependsExternal(self::class, 'testHasAccessForCurrentUserNo')] public function testLookupLimitationsForAnonymousUserHasNoAccess(): void { $repository = $this->getRepository(); @@ -942,13 +890,10 @@ public function testLookupLimitationsForAnonymousUserHasNoAccess(): void /** * Test for the lookupLimitations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::lookupLimitations() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetUserService - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetContentService - * @depends Ibexa\Tests\Integration\Core\Repository\PermissionResolverTest::testHasAccessForCurrentUserYes */ + #[DependsExternal(RepositoryTest::class, 'testGetUserService')] + #[DependsExternal(RepositoryTest::class, 'testGetContentService')] + #[DependsExternal(self::class, 'testHasAccessForCurrentUserYes')] public function testLookupLimitationsForAdministratorUser(): void { $repository = $this->getRepository(); @@ -985,11 +930,7 @@ public function testLookupLimitationsForAdministratorUser(): void /** * When one of policy pass then all limitation should be returned. * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::lookupLimitations() * - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetUserService - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetContentService - * @depends Ibexa\Tests\Integration\Core\Repository\PermissionResolverTest::testHasAccessForCurrentUserYes * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException @@ -997,6 +938,9 @@ public function testLookupLimitationsForAdministratorUser(): void * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ + #[DependsExternal(RepositoryTest::class, 'testGetUserService')] + #[DependsExternal(RepositoryTest::class, 'testGetContentService')] + #[DependsExternal(self::class, 'testHasAccessForCurrentUserYes')] public function testLookupLimitationsWithLimitations(): void { $repository = $this->getRepository(); @@ -1047,11 +991,7 @@ public function testLookupLimitationsWithLimitations(): void /** * When one of policy pass then only filtered limitation should be returned. * - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::lookupLimitations() * - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetUserService - * @depends Ibexa\Tests\Integration\Core\Repository\RepositoryTest::testGetContentService - * @depends Ibexa\Tests\Integration\Core\Repository\PermissionResolverTest::testHasAccessForCurrentUserYes * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException @@ -1059,6 +999,9 @@ public function testLookupLimitationsWithLimitations(): void * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ + #[DependsExternal(RepositoryTest::class, 'testGetUserService')] + #[DependsExternal(RepositoryTest::class, 'testGetContentService')] + #[DependsExternal(self::class, 'testHasAccessForCurrentUserYes')] public function testLookupLimitationsWithFilteredLimitations(): void { $repository = $this->getRepository(); diff --git a/tests/integration/Core/Repository/Regression/EZP20018LanguageTest.php b/tests/integration/Core/Repository/Regression/EZP20018LanguageTest.php index ba2e71dcbb..891a377b7c 100644 --- a/tests/integration/Core/Repository/Regression/EZP20018LanguageTest.php +++ b/tests/integration/Core/Repository/Regression/EZP20018LanguageTest.php @@ -12,12 +12,14 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\LanguageCode; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; use Ibexa\Tests\Solr\SetupFactory\LegacySetupFactory; +use PHPUnit\Framework\Attributes\CoversClass; /** * Test case for language issues in EZP-20018. * * Issue EZP-20018 */ +#[CoversClass(LanguageCode::class)] class EZP20018LanguageTest extends BaseTestCase { protected function setUp(): void @@ -58,10 +60,7 @@ protected function setUp(): void $this->refreshSearch($repository); } - /** - * @covers \Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\LanguageCode - */ - public function testSearchOnNotExistingLanguageGivesException() + public function testSearchOnNotExistingLanguageGivesException(): void { $this->expectException(NotFoundException::class); @@ -75,10 +74,7 @@ public function testSearchOnNotExistingLanguageGivesException() $this->getRepository()->getSearchService()->findContent($query); } - /** - * @covers \Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\LanguageCode - */ - public function testSearchOnUsedLanguageGivesOneResult() + public function testSearchOnUsedLanguageGivesOneResult(): void { $query = new Query(); $query->filter = new LanguageCode(['por-PT'], false); @@ -88,10 +84,7 @@ public function testSearchOnUsedLanguageGivesOneResult() self::assertCount(1, $results->searchHits); } - /** - * @covers \Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\LanguageCode - */ - public function testSearchOnStandardLanguageGivesManyResult() + public function testSearchOnStandardLanguageGivesManyResult(): void { $query = new Query(); $query->filter = new LanguageCode(['eng-US'], false); @@ -102,10 +95,7 @@ public function testSearchOnStandardLanguageGivesManyResult() self::assertEquals($results->totalCount, count($results->searchHits)); } - /** - * @covers \Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\LanguageCode - */ - public function testSearchOnNotUsedInstalledLanguageGivesNoResult() + public function testSearchOnNotUsedInstalledLanguageGivesNoResult(): void { $query = new Query(); $query->filter = new LanguageCode(['eng-GB'], false); diff --git a/tests/integration/Core/Repository/Regression/EZP20018ObjectStateTest.php b/tests/integration/Core/Repository/Regression/EZP20018ObjectStateTest.php index 64ca334f09..d78403818d 100644 --- a/tests/integration/Core/Repository/Regression/EZP20018ObjectStateTest.php +++ b/tests/integration/Core/Repository/Regression/EZP20018ObjectStateTest.php @@ -10,17 +10,15 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Query; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\ObjectStateId; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; +use PHPUnit\Framework\Attributes\CoversClass; /** * Test case for ObjectState issues in EZP-20018. - * - * @covers \Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\ObjectStateId - * - * Issue EZP-20018 */ +#[CoversClass(ObjectStateId::class)] class EZP20018ObjectStateTest extends BaseTestCase { - public function testSearchForNonUsedObjectState() + public function testSearchForNonUsedObjectState(): void { $repository = $this->getRepository(); @@ -48,7 +46,7 @@ public function testSearchForNonUsedObjectState() self::assertCount($results2->totalCount, $results2->searchHits); } - public function testSearchForUsedObjectState() + public function testSearchForUsedObjectState(): void { $repository = $this->getRepository(); diff --git a/tests/integration/Core/Repository/Regression/EZP20018VisibilityTest.php b/tests/integration/Core/Repository/Regression/EZP20018VisibilityTest.php index 6e50414d79..daf17238f0 100644 --- a/tests/integration/Core/Repository/Regression/EZP20018VisibilityTest.php +++ b/tests/integration/Core/Repository/Regression/EZP20018VisibilityTest.php @@ -10,17 +10,15 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Query; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\Visibility; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; +use PHPUnit\Framework\Attributes\CoversClass; /** * Test case for Visibility issues in EZP-20018. - * - * @covers \Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\Visibility - * - * Issue EZP-20018 */ +#[CoversClass(Visibility::class)] class EZP20018VisibilityTest extends BaseTestCase { - public function testSearchForHiddenContent() + public function testSearchForHiddenContent(): void { $repository = $this->getRepository(); @@ -44,7 +42,7 @@ public function testSearchForHiddenContent() self::assertCount(1, $results2->searchHits); } - public function testSearchForVisibleContent() + public function testSearchForVisibleContent(): void { $repository = $this->getRepository(); diff --git a/tests/integration/Core/Repository/Regression/EZP21069Test.php b/tests/integration/Core/Repository/Regression/EZP21069Test.php index d3afa37238..f9f95e8eea 100644 --- a/tests/integration/Core/Repository/Regression/EZP21069Test.php +++ b/tests/integration/Core/Repository/Regression/EZP21069Test.php @@ -84,7 +84,7 @@ protected function setUp(): void $this->refreshSearch($repository); } - public function testSearchOnPreviousAttributeContentGivesNoResult() + public function testSearchOnPreviousAttributeContentGivesNoResult(): void { $query = new Query(); $query->filter = new Field('name', Operator::EQ, 'TheOriginalNews'); @@ -94,7 +94,7 @@ public function testSearchOnPreviousAttributeContentGivesNoResult() self::assertEmpty($results->searchHits); } - public function testSearchOnCurrentAttributeContentGivesOnesResult() + public function testSearchOnCurrentAttributeContentGivesOnesResult(): void { $query = new Query(); $query->filter = new Field('name', Operator::EQ, 'TheUpdatedNews'); @@ -104,7 +104,7 @@ public function testSearchOnCurrentAttributeContentGivesOnesResult() self::assertCount(1, $results->searchHits); } - public function testSearchOnDraftAttributeContentGivesNoResult() + public function testSearchOnDraftAttributeContentGivesNoResult(): void { $query = new Query(); $query->filter = new Field('name', Operator::EQ, 'TheDraftNews'); diff --git a/tests/integration/Core/Repository/Regression/EZP21089Test.php b/tests/integration/Core/Repository/Regression/EZP21089Test.php index 2e519455ee..861181511e 100644 --- a/tests/integration/Core/Repository/Regression/EZP21089Test.php +++ b/tests/integration/Core/Repository/Regression/EZP21089Test.php @@ -107,7 +107,7 @@ protected function setUp(): void $this->contentType = $contentTypeService->loadContentType($type->id); } - public function testCreateContent() + public function testCreateContent(): void { $repository = $this->getRepository(); diff --git a/tests/integration/Core/Repository/Regression/EZP21109IbexaIntegerTest.php b/tests/integration/Core/Repository/Regression/EZP21109IbexaIntegerTest.php index a2b0e82697..cbc9b05fd9 100644 --- a/tests/integration/Core/Repository/Regression/EZP21109IbexaIntegerTest.php +++ b/tests/integration/Core/Repository/Regression/EZP21109IbexaIntegerTest.php @@ -10,6 +10,7 @@ use Ibexa\Core\FieldType\Integer\Value; use Ibexa\Core\Persistence\Legacy\Exception\TypeNotFound as TypeNotFoundException; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; +use PHPUnit\Framework\Attributes\DataProvider; /** * Regression tests for the issue EZP-21109. @@ -44,9 +45,8 @@ protected function tearDown(): void /** * Assert that it is possible to store any integer value in an integer field with default settings. - * - * @dataProvider validIntegerValues */ + #[DataProvider('validIntegerValues')] public function testIbexaIntegerWithDefaultValues(int $integerValue): void { $repository = $this->getRepository(); @@ -74,7 +74,10 @@ public function testIbexaIntegerWithDefaultValues(int $integerValue): void $contentService->deleteContent($content->versionInfo->contentInfo); } - public function validIntegerValues() + /** + * @return array + */ + public static function validIntegerValues(): array { return [ [0], diff --git a/tests/integration/Core/Repository/Regression/EZP21771IbexaStringTest.php b/tests/integration/Core/Repository/Regression/EZP21771IbexaStringTest.php index dd025ee3cc..4cc994831b 100644 --- a/tests/integration/Core/Repository/Regression/EZP21771IbexaStringTest.php +++ b/tests/integration/Core/Repository/Regression/EZP21771IbexaStringTest.php @@ -22,7 +22,7 @@ class EZP21771IbexaStringTest extends BaseTestCase * It shouldn't throw a fatal error when inserting 11 consecutive digits * into an IbexaString field */ - public function test11NumbersOnIbexaString() + public function test11NumbersOnIbexaString(): void { $repository = $this->getRepository(); $contentService = $repository->getContentService(); diff --git a/tests/integration/Core/Repository/Regression/EZP21906SearchOneContentMultipleLocationsTest.php b/tests/integration/Core/Repository/Regression/EZP21906SearchOneContentMultipleLocationsTest.php index 804dd43113..4d6970e7ed 100644 --- a/tests/integration/Core/Repository/Regression/EZP21906SearchOneContentMultipleLocationsTest.php +++ b/tests/integration/Core/Repository/Regression/EZP21906SearchOneContentMultipleLocationsTest.php @@ -11,6 +11,7 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\SortClause; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; +use PHPUnit\Framework\Attributes\DataProvider; /** * Issue EZP-21906. @@ -61,17 +62,18 @@ protected function setUp(): void $this->refreshSearch($repository); } - /** - * @dataProvider searchContentQueryProvider - */ - public function testSearchContentMultipleLocations(Query $query, $expectedResultCount) + #[DataProvider('searchContentQueryProvider')] + public function testSearchContentMultipleLocations(Query $query, $expectedResultCount): void { $result = $this->getRepository()->getSearchService()->findContent($query); self::assertSame($expectedResultCount, $result->totalCount); self::assertSame($expectedResultCount, count($result->searchHits)); } - public function searchContentQueryProvider() + /** + * @return array + */ + public static function searchContentQueryProvider(): array { return [ [ diff --git a/tests/integration/Core/Repository/Regression/EZP22408DeleteRelatedObjectTest.php b/tests/integration/Core/Repository/Regression/EZP22408DeleteRelatedObjectTest.php index 77613442dc..c230e02ae9 100644 --- a/tests/integration/Core/Repository/Regression/EZP22408DeleteRelatedObjectTest.php +++ b/tests/integration/Core/Repository/Regression/EZP22408DeleteRelatedObjectTest.php @@ -22,7 +22,7 @@ protected function setUp(): void $this->createTestContentType(); } - public function testRelationListIsUpdatedWhenRelatedObjectIsDeleted() + public function testRelationListIsUpdatedWhenRelatedObjectIsDeleted(): void { $targetObject1 = $this->createTargetObject('Relation list target object 1'); $targetObject2 = $this->createTargetObject('Relation list target object 2'); @@ -43,7 +43,7 @@ public function testRelationListIsUpdatedWhenRelatedObjectIsDeleted() self::assertSame([$targetObject2->id], $relationListValue->destinationContentIds); } - public function testSingleRelationIsUpdatedWhenRelatedObjectIsDeleted() + public function testSingleRelationIsUpdatedWhenRelatedObjectIsDeleted(): void { $targetObject = $this->createTargetObject('Single relation target object'); $referenceObject = $this->createReferenceObject( diff --git a/tests/integration/Core/Repository/Regression/EZP22409RelationListTypeStateTest.php b/tests/integration/Core/Repository/Regression/EZP22409RelationListTypeStateTest.php index 2d7b1eeb60..19e130d94a 100644 --- a/tests/integration/Core/Repository/Regression/EZP22409RelationListTypeStateTest.php +++ b/tests/integration/Core/Repository/Regression/EZP22409RelationListTypeStateTest.php @@ -100,12 +100,12 @@ protected function setUp(): void $contentTypeService->publishContentTypeDraft($type); } - public function testCreateObjectWithRelationToContentType() + public function testCreateObjectWithRelationToContentType(): void { $this->createContentWithRelationList(); } - public function testCreateObjectWithRelationToContentTypeWithExistingDraft() + public function testCreateObjectWithRelationToContentTypeWithExistingDraft(): void { $repository = $this->getRepository(); $contentTypeService = $repository->getContentTypeService(); diff --git a/tests/integration/Core/Repository/Regression/EZP22612URLAliasTranslations.php b/tests/integration/Core/Repository/Regression/EZP22612URLAliasTranslationsTest.php similarity index 94% rename from tests/integration/Core/Repository/Regression/EZP22612URLAliasTranslations.php rename to tests/integration/Core/Repository/Regression/EZP22612URLAliasTranslationsTest.php index c374ed5a98..2550b69a8b 100644 --- a/tests/integration/Core/Repository/Regression/EZP22612URLAliasTranslations.php +++ b/tests/integration/Core/Repository/Regression/EZP22612URLAliasTranslationsTest.php @@ -10,7 +10,7 @@ use Ibexa\Contracts\Core\Repository\Values\Content\URLAlias; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; -class EZP22612URLAliasTranslations extends BaseTestCase +class EZP22612URLAliasTranslationsTest extends BaseTestCase { protected function setUp(): void { @@ -50,7 +50,7 @@ private function getFolderCreateStruct($name) /** * Test that alias is found (ie. NotFoundException is not thrown). */ - public function testURLAliasLoadedInRightLanguage() + public function testURLAliasLoadedInRightLanguage(): void { $aliasService = $this->getRepository()->getURLAliasService(); $alias = $aliasService->lookup('common/alias'); diff --git a/tests/integration/Core/Repository/Regression/EZP22840RoleLimitations.php b/tests/integration/Core/Repository/Regression/EZP22840RoleLimitationsTest.php similarity index 94% rename from tests/integration/Core/Repository/Regression/EZP22840RoleLimitations.php rename to tests/integration/Core/Repository/Regression/EZP22840RoleLimitationsTest.php index 34f21aab63..05aa767f7a 100644 --- a/tests/integration/Core/Repository/Regression/EZP22840RoleLimitations.php +++ b/tests/integration/Core/Repository/Regression/EZP22840RoleLimitationsTest.php @@ -15,12 +15,12 @@ /** * Issue EZP-22840. */ -class EZP22840RoleLimitations extends BaseTestCase +class EZP22840RoleLimitationsTest extends BaseTestCase { /** * Test Subtree Role Assignment Limitation against state/assign. */ - public function testSubtreeRoleAssignLimitation() + public function testSubtreeRoleAssignLimitation(): void { $repository = $this->getRepository(); $roleService = $repository->getRoleService(); @@ -66,7 +66,7 @@ public function testSubtreeRoleAssignLimitation() /** * Test Section Role Assignment Limitation against user/login. */ - public function testSectionRoleAssignLimitation() + public function testSectionRoleAssignLimitation(): void { $repository = $this->getRepository(); $permissionResolver = $repository->getPermissionResolver(); diff --git a/tests/integration/Core/Repository/Regression/EZP22958SearchSubtreePathstringFormatTest.php b/tests/integration/Core/Repository/Regression/EZP22958SearchSubtreePathstringFormatTest.php index 7b30d7f514..0fce612300 100644 --- a/tests/integration/Core/Repository/Regression/EZP22958SearchSubtreePathstringFormatTest.php +++ b/tests/integration/Core/Repository/Regression/EZP22958SearchSubtreePathstringFormatTest.php @@ -10,6 +10,7 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Query; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; +use PHPUnit\Framework\Attributes\DataProvider; /** * Issue EZP-21906. @@ -23,10 +24,9 @@ protected function setUp(): void /** * Tests that invalid path string provided for subtree criterion result in exception. - * - * @dataProvider searchContentQueryWithInvalidDataProvider */ - public function testSearchContentSubtreeShouldThrowException($pathString) + #[DataProvider('searchContentQueryWithInvalidDataProvider')] + public function testSearchContentSubtreeShouldThrowException($pathString): void { $this->expectException(\InvalidArgumentException::class); @@ -41,10 +41,9 @@ public function testSearchContentSubtreeShouldThrowException($pathString) /** * Tests that path string provided for subtree criterion is valid. - * - * @dataProvider searchContentQueryProvider */ - public function testSearchContentSubtree($pathString) + #[DataProvider('searchContentQueryProvider')] + public function testSearchContentSubtree($pathString): void { $query = new Query( [ @@ -55,7 +54,10 @@ public function testSearchContentSubtree($pathString) $result = $this->getRepository()->getSearchService()->findContent($query); } - public function searchContentQueryProvider() + /** + * @return array + */ + public static function searchContentQueryProvider(): array { return [ [ @@ -70,7 +72,10 @@ public function searchContentQueryProvider() ]; } - public function searchContentQueryWithInvalidDataProvider() + /** + * @return array + */ + public static function searchContentQueryWithInvalidDataProvider(): array { return [ [ diff --git a/tests/integration/Core/Repository/Regression/EZP26327UrlAliasHistorizationTest.php b/tests/integration/Core/Repository/Regression/EZP26327UrlAliasHistorizationTest.php index 2de3bacaa5..6105e6a1f0 100644 --- a/tests/integration/Core/Repository/Regression/EZP26327UrlAliasHistorizationTest.php +++ b/tests/integration/Core/Repository/Regression/EZP26327UrlAliasHistorizationTest.php @@ -8,15 +8,15 @@ namespace Ibexa\Tests\Integration\Core\Repository\Regression; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; +use PHPUnit\Framework\Attributes\Group; /** * Issue https://issues.ibexa.co/browse/EZP-26327. - * - * @group ezp26327 */ +#[Group('ezp26327')] class EZP26327UrlAliasHistorizationTest extends BaseTestCase { - public function testHistorization() + public function testHistorization(): void { $contentService = $this->getRepository()->getContentService(); $contentTypeService = $this->getRepository()->getContentTypeService(); diff --git a/tests/integration/Core/Repository/Regression/EZP26367UrlAliasHistoryRedirectLoopTest.php b/tests/integration/Core/Repository/Regression/EZP26367UrlAliasHistoryRedirectLoopTest.php index 20383b56f8..7c0bdfb7f0 100644 --- a/tests/integration/Core/Repository/Regression/EZP26367UrlAliasHistoryRedirectLoopTest.php +++ b/tests/integration/Core/Repository/Regression/EZP26367UrlAliasHistoryRedirectLoopTest.php @@ -8,19 +8,19 @@ namespace Ibexa\Tests\Integration\Core\Repository\Regression; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; +use PHPUnit\Framework\Attributes\Group; /** * Issue https://issues.ibexa.co/browse/EZP-26367. - * - * @group regression - * @group ezp26367 - * @group cache - * @group cache-invalidation - * @group cache-spi */ +#[Group('regression')] +#[Group('ezp26367')] +#[Group('cache')] +#[Group('cache-invalidation')] +#[Group('cache-spi')] class EZP26367UrlAliasHistoryRedirectLoopTest extends BaseTestCase { - public function testReverseLookupReturnsHistoryAlias() + public function testReverseLookupReturnsHistoryAlias(): void { $contentService = $this->getRepository()->getContentService(); $contentTypeService = $this->getRepository()->getContentTypeService(); @@ -88,7 +88,7 @@ public function testReverseLookupReturnsHistoryAlias() self::assertFalse($urlAlias->isHistory); } - public function testLookupHistoryUrlReturnsActiveAlias() + public function testLookupHistoryUrlReturnsActiveAlias(): void { $contentService = $this->getRepository()->getContentService(); $contentTypeService = $this->getRepository()->getContentTypeService(); diff --git a/tests/integration/Core/Repository/Regression/EZP26551DeleteContentTypeDraftTest.php b/tests/integration/Core/Repository/Regression/EZP26551DeleteContentTypeDraftTest.php index d9598609b5..f0b0272663 100644 --- a/tests/integration/Core/Repository/Regression/EZP26551DeleteContentTypeDraftTest.php +++ b/tests/integration/Core/Repository/Regression/EZP26551DeleteContentTypeDraftTest.php @@ -9,16 +9,16 @@ use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; +use PHPUnit\Framework\Attributes\Group; /** * @issue https://issues.ibexa.co/browse/EZP-26551 - * - * @group regression - * @group ezp26551 */ +#[Group('regression')] +#[Group('ezp26551')] class EZP26551DeleteContentTypeDraftTest extends BaseTestCase { - public function testDeleteContentTypeGroup() + public function testDeleteContentTypeGroup(): void { $repository = $this->getRepository(); $contentTypeService = $repository->getContentTypeService(); diff --git a/tests/integration/Core/Repository/Regression/EZP28799SubtreeSearchTest.php b/tests/integration/Core/Repository/Regression/EZP28799SubtreeSearchTest.php index 9ae53a8e37..d140009d03 100644 --- a/tests/integration/Core/Repository/Regression/EZP28799SubtreeSearchTest.php +++ b/tests/integration/Core/Repository/Regression/EZP28799SubtreeSearchTest.php @@ -61,7 +61,7 @@ public function createTestContent() return [$leftFolder, $rightFolder, $targetFolder]; } - public function testConflictingConditions() + public function testConflictingConditions(): void { list($leftFolder, $rightFolder, $targetFolder) = $this->createTestContent(); $locationService = $this->getRepository()->getLocationService(); @@ -83,7 +83,7 @@ public function testConflictingConditions() self::assertSame(0, $result->totalCount); } - public function testNegativeSubtree() + public function testNegativeSubtree(): void { list($leftFolder, $rightFolder, $targetFolder) = $this->createTestContent(); $locationService = $this->getRepository()->getLocationService(); diff --git a/tests/integration/Core/Repository/Regression/EnvTest.php b/tests/integration/Core/Repository/Regression/EnvTest.php index d0cd939c8c..ff9a7ca283 100644 --- a/tests/integration/Core/Repository/Regression/EnvTest.php +++ b/tests/integration/Core/Repository/Regression/EnvTest.php @@ -21,7 +21,7 @@ class EnvTest extends BaseTestCase /** * Verify Redis cache is setup if asked for, if not file system. */ - public function testVerifyCacheDriver() + public function testVerifyCacheDriver(): void { $pool = $this->getSetupFactory()->getServiceContainer()->get('ibexa.cache_pool'); diff --git a/tests/integration/Core/Repository/Regression/PureNegativeQueryTest.php b/tests/integration/Core/Repository/Regression/PureNegativeQueryTest.php index 7ba7021cbf..5dbdb6257e 100644 --- a/tests/integration/Core/Repository/Regression/PureNegativeQueryTest.php +++ b/tests/integration/Core/Repository/Regression/PureNegativeQueryTest.php @@ -11,19 +11,23 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Query; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; /** * This test will try to execute search queries that might be interpreted as "pure negative" * by the search backend and hence produce incorrect results. - * - * @group regression */ +#[Group('regression')] class PureNegativeQueryTest extends BaseTestCase { - public function providerForTestMatchAll() + /** + * @return array + */ + public static function providerForTestMatchAll(): array { $query = new Query(['filter' => new Criterion\MatchAll()]); - $result = $this->getRepository()->getSearchService()->findContent($query); + $result = static::resolveRepository()->getSearchService()->findContent($query); // Sanity check self::assertGreaterThan(0, $result->totalCount); $totalCount = $result->totalCount; @@ -214,12 +218,11 @@ public function providerForTestMatchAll() } /** - * @dataProvider providerForTestMatchAll - * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion $criterion * @param int $totalCount */ - public function testMatchAllContentInfoQuery($criterion, $totalCount) + #[DataProvider('providerForTestMatchAll')] + public function testMatchAllContentInfoQuery($criterion, $totalCount): void { $query = new Query( [ @@ -233,12 +236,11 @@ public function testMatchAllContentInfoQuery($criterion, $totalCount) } /** - * @dataProvider providerForTestMatchAll - * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion $criterion * @param int $totalCount */ - public function testMatchAllContentInfoFilter($criterion, $totalCount) + #[DataProvider('providerForTestMatchAll')] + public function testMatchAllContentInfoFilter($criterion, $totalCount): void { $query = new Query( [ @@ -252,12 +254,11 @@ public function testMatchAllContentInfoFilter($criterion, $totalCount) } /** - * @dataProvider providerForTestMatchAll - * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion $criterion * @param int $totalCount */ - public function testMatchAllLocationQuery($criterion, $totalCount) + #[DataProvider('providerForTestMatchAll')] + public function testMatchAllLocationQuery($criterion, $totalCount): void { $query = new LocationQuery( [ @@ -271,12 +272,11 @@ public function testMatchAllLocationQuery($criterion, $totalCount) } /** - * @dataProvider providerForTestMatchAll - * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion $criterion * @param int $totalCount */ - public function testMatchAllLocationFilter($criterion, $totalCount) + #[DataProvider('providerForTestMatchAll')] + public function testMatchAllLocationFilter($criterion, $totalCount): void { $query = new LocationQuery( [ diff --git a/tests/integration/Core/Repository/RepositoryTest.php b/tests/integration/Core/Repository/RepositoryTest.php index 066186872a..78ed759200 100644 --- a/tests/integration/Core/Repository/RepositoryTest.php +++ b/tests/integration/Core/Repository/RepositoryTest.php @@ -16,7 +16,6 @@ use Ibexa\Contracts\Core\Repository\NotificationService; use Ibexa\Contracts\Core\Repository\ObjectStateService; use Ibexa\Contracts\Core\Repository\PermissionResolver; -use Ibexa\Contracts\Core\Repository\Repository; use Ibexa\Contracts\Core\Repository\RoleService; use Ibexa\Contracts\Core\Repository\SearchService; use Ibexa\Contracts\Core\Repository\SectionService; @@ -24,23 +23,23 @@ use Ibexa\Contracts\Core\Repository\URLAliasService; use Ibexa\Contracts\Core\Repository\URLWildcardService; use Ibexa\Contracts\Core\Repository\UserService; +use Ibexa\Core\Repository\Repository; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the Repository using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\Repository - * - * @group integration */ +#[CoversClass(Repository::class)] +#[Group('integration')] class RepositoryTest extends BaseTestCase { /** * Test for the getContentService() method. - * - * @group content - * @group user */ - public function testGetContentService() + #[Group('content')] + #[Group('user')] + public function testGetContentService(): void { $repository = $this->getRepository(); self::assertInstanceOf( @@ -51,12 +50,9 @@ public function testGetContentService() /** * Test for the getContentLanguageService() method. - * - * @group language - * - * @covers \Ibexa\Contracts\Core\Repository\Repository::getContentLanguageService() */ - public function testGetContentLanguageService() + #[Group('language')] + public function testGetContentLanguageService(): void { $repository = $this->getRepository(); self::assertInstanceOf( @@ -67,12 +63,11 @@ public function testGetContentLanguageService() /** * Test for the getContentTypeService() method. - * - * @group content-type - * @group field-type - * @group user */ - public function testGetContentTypeService() + #[Group('content-type')] + #[Group('field-type')] + #[Group('user')] + public function testGetContentTypeService(): void { $repository = $this->getRepository(); self::assertInstanceOf( @@ -83,10 +78,9 @@ public function testGetContentTypeService() /** * Test for the getLocationService() method. - * - * @group location */ - public function testGetLocationService() + #[Group('location')] + public function testGetLocationService(): void { $repository = $this->getRepository(); self::assertInstanceOf( @@ -97,10 +91,9 @@ public function testGetLocationService() /** * Test for the getSectionService() method. - * - * @group section */ - public function testGetSectionService() + #[Group('section')] + public function testGetSectionService(): void { $repository = $this->getRepository(); self::assertInstanceOf( @@ -111,10 +104,9 @@ public function testGetSectionService() /** * Test for the getUserService() method. - * - * @group user */ - public function testGetUserService() + #[Group('user')] + public function testGetUserService(): void { $repository = $this->getRepository(); self::assertInstanceOf( @@ -125,10 +117,9 @@ public function testGetUserService() /** * Test for the getNotificationService() method. - * - * @group user */ - public function testGetNotificationService() + #[Group('user')] + public function testGetNotificationService(): void { $repository = $this->getRepository(); self::assertInstanceOf( @@ -139,10 +130,9 @@ public function testGetNotificationService() /** * Test for the getTrashService() method. - * - * @group trash */ - public function testGetTrashService() + #[Group('trash')] + public function testGetTrashService(): void { $repository = $this->getRepository(); self::assertInstanceOf( @@ -153,10 +143,9 @@ public function testGetTrashService() /** * Test for the getRoleService() method. - * - * @group role */ - public function testGetRoleService() + #[Group('role')] + public function testGetRoleService(): void { $repository = $this->getRepository(); self::assertInstanceOf( @@ -167,10 +156,9 @@ public function testGetRoleService() /** * Test for the getURLAliasService() method. - * - * @group url-alias */ - public function testGetURLAliasService() + #[Group('url-alias')] + public function testGetURLAliasService(): void { $repository = $this->getRepository(); self::assertInstanceOf( @@ -181,10 +169,9 @@ public function testGetURLAliasService() /** * Test for the getUrlWildcardService() method. - * - * @group url-wildcard */ - public function testGetURLWildcardService() + #[Group('url-wildcard')] + public function testGetURLWildcardService(): void { $repository = $this->getRepository(); self::assertInstanceOf( @@ -195,10 +182,9 @@ public function testGetURLWildcardService() /** * Test for the getObjectStateService(). - * - * @group object-state */ - public function testGetObjectStateService() + #[Group('object-state')] + public function testGetObjectStateService(): void { $repository = $this->getRepository(); self::assertInstanceOf( @@ -209,10 +195,9 @@ public function testGetObjectStateService() /** * Test for the getFieldTypeService(). - * - * @group object-state */ - public function testGetFieldTypeService() + #[Group('object-state')] + public function testGetFieldTypeService(): void { $repository = $this->getRepository(); self::assertInstanceOf( @@ -223,10 +208,9 @@ public function testGetFieldTypeService() /** * Test for the getSearchService() method. - * - * @group search */ - public function testGetSearchService() + #[Group('search')] + public function testGetSearchService(): void { $repository = $this->getRepository(); @@ -238,10 +222,9 @@ public function testGetSearchService() /** * Test for the getSearchService() method. - * - * @group permission */ - public function testGetPermissionResolver() + #[Group('permission')] + public function testGetPermissionResolver(): void { $repository = $this->getRepository(); @@ -254,7 +237,7 @@ public function testGetPermissionResolver() /** * Test for the commit() method. */ - public function testCommit() + public function testCommit(): void { $repository = $this->getRepository(); @@ -271,7 +254,7 @@ public function testCommit() /** * Test for the commit() method. */ - public function testCommitThrowsRuntimeException() + public function testCommitThrowsRuntimeException(): void { $this->expectException(\RuntimeException::class); @@ -282,7 +265,7 @@ public function testCommitThrowsRuntimeException() /** * Test for the rollback() method. */ - public function testRollback() + public function testRollback(): void { $repository = $this->getRepository(); $repository->beginTransaction(); @@ -292,7 +275,7 @@ public function testRollback() /** * Test for the rollback() method. */ - public function testRollbackThrowsRuntimeException() + public function testRollbackThrowsRuntimeException(): void { $this->expectException(\RuntimeException::class); diff --git a/tests/integration/Core/Repository/RoleServiceAuthorizationTest.php b/tests/integration/Core/Repository/RoleServiceAuthorizationTest.php index 99c484216b..255c7511d3 100644 --- a/tests/integration/Core/Repository/RoleServiceAuthorizationTest.php +++ b/tests/integration/Core/Repository/RoleServiceAuthorizationTest.php @@ -11,26 +11,25 @@ use Ibexa\Contracts\Core\Repository\Values\User\Limitation\SubtreeLimitation; use Ibexa\Contracts\Core\Repository\Values\User\PolicyDraft; use Ibexa\Contracts\Core\Repository\Values\User\UserRoleAssignment; +use Ibexa\Core\Repository\RoleService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DependsExternal; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the RoleService using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService - * - * @group integration - * @group authorization */ +#[CoversClass(RoleService::class)] +#[Group('integration')] +#[Group('authorization')] class RoleServiceAuthorizationTest extends BaseTestCase { /** * Test for the createRole() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::createRole() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RoleServiceTest::testCreateRole - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testCreateUser */ - public function testCreateRoleThrowsUnauthorizedException() + #[DependsExternal(RoleServiceTest::class, 'testCreateRole')] + #[DependsExternal(UserServiceTest::class, 'testCreateUser')] + public function testCreateRoleThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -56,13 +55,10 @@ public function testCreateRoleThrowsUnauthorizedException() /** * Test for the loadRole() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::loadRole() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RoleServiceTest::testLoadRole - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testCreateUser */ - public function testLoadRoleThrowsUnauthorizedException() + #[DependsExternal(RoleServiceTest::class, 'testLoadRole')] + #[DependsExternal(UserServiceTest::class, 'testCreateUser')] + public function testLoadRoleThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -85,13 +81,10 @@ public function testLoadRoleThrowsUnauthorizedException() /** * Test for the loadRoleByIdentifier() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::loadRoleByIdentifier() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RoleServiceTest::testLoadRoleByIdentifier - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testCreateUser */ - public function testLoadRoleByIdentifierThrowsUnauthorizedException() + #[DependsExternal(RoleServiceTest::class, 'testLoadRoleByIdentifier')] + #[DependsExternal(UserServiceTest::class, 'testCreateUser')] + public function testLoadRoleByIdentifierThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -114,10 +107,8 @@ public function testLoadRoleByIdentifierThrowsUnauthorizedException() /** * Test for the loadRoles() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::loadRoles() */ - public function testLoadRolesLoadsEmptyListForAnonymousUser() + public function testLoadRolesLoadsEmptyListForAnonymousUser(): void { $repository = $this->getRepository(); $permissionResolver = $repository->getPermissionResolver(); @@ -137,10 +128,8 @@ public function testLoadRolesLoadsEmptyListForAnonymousUser() /** * Test for the loadRoles() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::loadRoles() */ - public function testLoadRolesForUserWithSubtreeLimitation() + public function testLoadRolesForUserWithSubtreeLimitation(): void { $repository = $this->getRepository(); $roleService = $repository->getRoleService(); @@ -167,13 +156,10 @@ public function testLoadRolesForUserWithSubtreeLimitation() /** * Test for the deleteRole() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::deleteRole() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RoleServiceTest::testDeleteRole - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testCreateUser */ - public function testDeleteRoleThrowsUnauthorizedException() + #[DependsExternal(RoleServiceTest::class, 'testDeleteRole')] + #[DependsExternal(UserServiceTest::class, 'testCreateUser')] + public function testDeleteRoleThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -196,13 +182,10 @@ public function testDeleteRoleThrowsUnauthorizedException() /** * Test for the updatePolicy() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::updatePolicyByRoleDraft() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RoleServiceTest::testUpdatePolicyByRoleDraft - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testCreateUser */ - public function testUpdatePolicyByRoleDraftThrowsUnauthorizedException() + #[DependsExternal(RoleServiceTest::class, 'testUpdatePolicyByRoleDraft')] + #[DependsExternal(UserServiceTest::class, 'testCreateUser')] + public function testUpdatePolicyByRoleDraftThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -244,13 +227,10 @@ public function testUpdatePolicyByRoleDraftThrowsUnauthorizedException() /** * Test for the removePolicy() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::removePolicy() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RoleServiceTest::testRemovePolicyByRoleDraft - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testCreateUser */ - public function testRemovePolicyThrowsUnauthorizedException() + #[DependsExternal(RoleServiceTest::class, 'testRemovePolicyByRoleDraft')] + #[DependsExternal(UserServiceTest::class, 'testCreateUser')] + public function testRemovePolicyThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -289,13 +269,10 @@ public function testRemovePolicyThrowsUnauthorizedException() /** * Test for the removePolicyByRoleDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::removePolicyByRoleDraft() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RoleServiceTest::testRemovePolicyByRoleDraft - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testCreateUser */ - public function testDeletePolicyThrowsUnauthorizedException() + #[DependsExternal(RoleServiceTest::class, 'testRemovePolicyByRoleDraft')] + #[DependsExternal(UserServiceTest::class, 'testCreateUser')] + public function testDeletePolicyThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -323,13 +300,10 @@ public function testDeletePolicyThrowsUnauthorizedException() /** * Test for the assignRoleToUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::assignRoleToUserGroup() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RoleServiceTest::testAssignRoleToUserGroup - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testCreateUser */ - public function testAssignRoleToUserGroupThrowsUnauthorizedException() + #[DependsExternal(RoleServiceTest::class, 'testAssignRoleToUserGroup')] + #[DependsExternal(UserServiceTest::class, 'testCreateUser')] + public function testAssignRoleToUserGroupThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -358,13 +332,10 @@ public function testAssignRoleToUserGroupThrowsUnauthorizedException() /** * Test for the assignRoleToUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::assignRoleToUserGroup($role, $userGroup, $roleLimitation) - * - * @depends Ibexa\Tests\Integration\Core\Repository\RoleServiceTest::testAssignRoleToUserGroup - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testCreateUser */ - public function testAssignRoleToUserGroupThrowsUnauthorizedExceptionWithRoleLimitationParameter() + #[DependsExternal(RoleServiceTest::class, 'testAssignRoleToUserGroup')] + #[DependsExternal(UserServiceTest::class, 'testCreateUser')] + public function testAssignRoleToUserGroupThrowsUnauthorizedExceptionWithRoleLimitationParameter(): void { $this->expectException(UnauthorizedException::class); @@ -400,13 +371,10 @@ public function testAssignRoleToUserGroupThrowsUnauthorizedExceptionWithRoleLimi /** * Test for the removeRoleAssignment() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::removeRoleAssignment() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RoleServiceTest::testRemoveRoleAssignmentFromUserGroup - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testCreateUser */ - public function testRemoveRoleAssignmentFromUserGroupThrowsUnauthorizedException() + #[DependsExternal(RoleServiceTest::class, 'testRemoveRoleAssignmentFromUserGroup')] + #[DependsExternal(UserServiceTest::class, 'testCreateUser')] + public function testRemoveRoleAssignmentFromUserGroupThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -444,13 +412,10 @@ public function testRemoveRoleAssignmentFromUserGroupThrowsUnauthorizedException /** * Test for the assignRoleToUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::assignRoleToUser() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RoleServiceTest::testAssignRoleToUser - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testCreateUser */ - public function testAssignRoleToUserThrowsUnauthorizedException() + #[DependsExternal(RoleServiceTest::class, 'testAssignRoleToUser')] + #[DependsExternal(UserServiceTest::class, 'testCreateUser')] + public function testAssignRoleToUserThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -473,13 +438,10 @@ public function testAssignRoleToUserThrowsUnauthorizedException() /** * Test for the assignRoleToUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::assignRoleToUser($role, $user, $roleLimitation) - * - * @depends Ibexa\Tests\Integration\Core\Repository\RoleServiceTest::testAssignRoleToUser - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testCreateUser */ - public function testAssignRoleToUserThrowsUnauthorizedExceptionWithRoleLimitationParameter() + #[DependsExternal(RoleServiceTest::class, 'testAssignRoleToUser')] + #[DependsExternal(UserServiceTest::class, 'testCreateUser')] + public function testAssignRoleToUserThrowsUnauthorizedExceptionWithRoleLimitationParameter(): void { $this->expectException(UnauthorizedException::class); @@ -509,13 +471,10 @@ public function testAssignRoleToUserThrowsUnauthorizedExceptionWithRoleLimitatio /** * Test for the removeRoleAssignment() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::removeRoleAssignment() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RoleServiceTest::testRemoveRoleAssignment - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testCreateUser */ - public function testRemoveRoleAssignmentThrowsUnauthorizedException() + #[DependsExternal(RoleServiceTest::class, 'testRemoveRoleAssignment')] + #[DependsExternal(UserServiceTest::class, 'testCreateUser')] + public function testRemoveRoleAssignmentThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -546,13 +505,10 @@ public function testRemoveRoleAssignmentThrowsUnauthorizedException() /** * Test for the getRoleAssignments() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::getRoleAssignments() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RoleServiceTest::testGetRoleAssignments - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testCreateUser */ - public function testGetRoleAssignmentsThrowsUnauthorizedException() + #[DependsExternal(RoleServiceTest::class, 'testGetRoleAssignments')] + #[DependsExternal(UserServiceTest::class, 'testCreateUser')] + public function testGetRoleAssignmentsThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -575,10 +531,8 @@ public function testGetRoleAssignmentsThrowsUnauthorizedException() /** * Test for the getRoleAssignmentsForUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::getRoleAssignmentsForUser() */ - public function testGetRoleAssignmentsForUserLoadsEmptyListForAnonymousUser() + public function testGetRoleAssignmentsForUserLoadsEmptyListForAnonymousUser(): void { $repository = $this->getRepository(); $roleService = $repository->getRoleService(); @@ -597,10 +551,8 @@ public function testGetRoleAssignmentsForUserLoadsEmptyListForAnonymousUser() /** * Test for the getRoleAssignmentsForUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::getRoleAssignmentsForUser() */ - public function testGetRoleAssignmentsForUserWithSubtreeLimitation() + public function testGetRoleAssignmentsForUserWithSubtreeLimitation(): void { $repository = $this->getRepository(); $roleService = $repository->getRoleService(); @@ -627,13 +579,10 @@ public function testGetRoleAssignmentsForUserWithSubtreeLimitation() /** * Test for the getRoleAssignmentsForUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::getRoleAssignmentsForUserGroup() - * - * @depends Ibexa\Tests\Integration\Core\Repository\RoleServiceTest::testGetRoleAssignmentsForUserGroup - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testCreateUser */ - public function testGetRoleAssignmentsForUserGroupThrowsUnauthorizedException() + #[DependsExternal(RoleServiceTest::class, 'testGetRoleAssignmentsForUserGroup')] + #[DependsExternal(UserServiceTest::class, 'testCreateUser')] + public function testGetRoleAssignmentsForUserGroupThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/RoleServiceTest.php b/tests/integration/Core/Repository/RoleServiceTest.php index edea9ec51f..649fdc0ae4 100644 --- a/tests/integration/Core/Repository/RoleServiceTest.php +++ b/tests/integration/Core/Repository/RoleServiceTest.php @@ -30,6 +30,11 @@ use Ibexa\Contracts\Core\Repository\Values\User\User; use Ibexa\Contracts\Core\Repository\Values\User\UserGroupRoleAssignment; use Ibexa\Contracts\Core\Repository\Values\User\UserRoleAssignment; +use Ibexa\Core\Repository\RoleService as CoveredRoleService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the RoleService using in memory storage. @@ -47,19 +52,15 @@ * * *
    - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService - * - * @group role */ +#[CoversClass(CoveredRoleService::class)] +#[Group('role')] class RoleServiceTest extends BaseTestCase { /** * Test for the newRoleCreateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::newRoleCreateStruct() */ - public function testNewRoleCreateStruct() + public function testNewRoleCreateStruct(): void { $repository = $this->getRepository(); @@ -69,9 +70,6 @@ public function testNewRoleCreateStruct() self::assertInstanceOf(RoleCreateStruct::class, $roleCreate); } - /** - * @covers \Ibexa\Contracts\Core\Repository\RoleService::newRoleCopyStruct - */ public function testNewRoleCopyStruct(): void { $repository = $this->getRepository(); @@ -85,12 +83,9 @@ public function testNewRoleCopyStruct(): void /** * Test for the newRoleCreateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::newRoleCreateStruct() - * - * @depends testNewRoleCreateStruct */ - public function testNewRoleCreateStructSetsNamePropertyOnStruct() + #[Depends('testNewRoleCreateStruct')] + public function testNewRoleCreateStructSetsNamePropertyOnStruct(): void { $repository = $this->getRepository(); @@ -106,11 +101,8 @@ public function testNewRoleCreateStructSetsNamePropertyOnStruct() /** * Test for the createRole() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::createRole() - * - * @depends testNewRoleCreateStruct */ + #[Depends('testNewRoleCreateStruct')] public function testCreateRole() { $repository = $this->getRepository(); @@ -140,11 +132,8 @@ public function testCreateRole() /** * Test for the createRole() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::createRole() - * - * @depends testCreateRole */ + #[Depends('testCreateRole')] public function testRoleCreateStructValues(array $data) { $createStruct = $data['createStruct']; @@ -167,11 +156,8 @@ public function testRoleCreateStructValues(array $data) /** * Test for the createRole() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::createRole() - * - * @depends testNewRoleCreateStruct */ + #[Depends('testNewRoleCreateStruct')] public function testCreateRoleWithPolicy() { $repository = $this->getRepository(); @@ -215,11 +201,8 @@ public function testCreateRoleWithPolicy() /** * Test for the createRole() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::createRole() - * - * @depends testCreateRoleWithPolicy */ + #[Depends('testCreateRoleWithPolicy')] public function testRoleCreateStructValuesWithPolicy(array $data) { $createStruct = $data['createStruct']; @@ -246,10 +229,8 @@ public function testRoleCreateStructValuesWithPolicy(array $data) /** * Test creating a role with multiple policies. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::createRole */ - public function testCreateRoleWithMultiplePolicies() + public function testCreateRoleWithMultiplePolicies(): void { $repository = $this->getRepository(); $roleService = $repository->getRoleService(); @@ -337,12 +318,9 @@ public function testCreateRoleWithMultiplePolicies() /** * Test for the createRoleDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::createRoleDraft() - * - * @depends testNewRoleCreateStruct */ - public function testCreateRoleDraft() + #[Depends('testNewRoleCreateStruct')] + public function testCreateRoleDraft(): void { $repository = $this->getRepository(); @@ -369,12 +347,9 @@ public function testCreateRoleDraft() /** * Test for the createRole() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::createRole() - * - * @depends testCreateRole */ - public function testCreateRoleThrowsInvalidArgumentException() + #[Depends('testCreateRole')] + public function testCreateRoleThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -396,12 +371,9 @@ public function testCreateRoleThrowsInvalidArgumentException() /** * Test for the createRoleDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::createRoleDraft() - * - * @depends testCreateRoleDraft */ - public function testCreateRoleDraftThrowsInvalidArgumentException() + #[Depends('testCreateRoleDraft')] + public function testCreateRoleDraftThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -428,10 +400,8 @@ public function testCreateRoleDraftThrowsInvalidArgumentException() /** * Test for the createRole() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::createRole() */ - public function testCreateRoleThrowsLimitationValidationException() + public function testCreateRoleThrowsLimitationValidationException(): void { $this->expectException(LimitationValidationException::class); @@ -468,12 +438,9 @@ public function testCreateRoleThrowsLimitationValidationException() /** * Test for the createRole() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::createRole() - * - * @depends testNewRoleCreateStruct */ - public function testCreateRoleInTransactionWithRollback() + #[Depends('testNewRoleCreateStruct')] + public function testCreateRoleInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -505,12 +472,9 @@ public function testCreateRoleInTransactionWithRollback() /** * Test for the createRoleDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::createRoleDraft() - * - * @depends testNewRoleCreateStruct */ - public function testCreateRoleDraftInTransactionWithRollback() + #[Depends('testNewRoleCreateStruct')] + public function testCreateRoleDraftInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -540,9 +504,9 @@ public function testCreateRoleDraftInTransactionWithRollback() self::fail('Role draft object still exists after rollback.'); } - public function providerForCopyRoleTests(): array + public static function providerForCopyRoleTests(): array { - $repository = $this->getRepository(); + $repository = static::resolveRepository(); $roleService = $repository->getRoleService(); $roleCreateStruct = $roleService->newRoleCreateStruct('newRole'); @@ -581,19 +545,15 @@ public function providerForCopyRoleTests(): array } /** - * @dataProvider providerForCopyRoleTests - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::copyRole - * - * @depends testNewRoleCopyStruct - * @depends testLoadRoleByIdentifier - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\LimitationValidationException */ + #[Depends('testNewRoleCopyStruct')] + #[Depends('testLoadRoleByIdentifier')] + #[DataProvider('providerForCopyRoleTests')] public function testCopyRole(RoleCreateStruct $roleCreateStruct, RoleCopyStruct $roleCopyStruct): void { $repository = $this->getRepository(); @@ -618,12 +578,8 @@ public function testCopyRole(RoleCreateStruct $roleCreateStruct, RoleCopyStruct /** * Test for the copyRole() method with added policies. * - * @dataProvider providerForCopyRoleTests * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::copyRole * - * @depends testNewRoleCopyStruct - * @depends testLoadRoleByIdentifier * * @param \Ibexa\Contracts\Core\Repository\Values\User\PolicyCreateStruct[] $policies * @@ -633,6 +589,9 @@ public function testCopyRole(RoleCreateStruct $roleCreateStruct, RoleCopyStruct * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\LimitationValidationException */ + #[Depends('testNewRoleCopyStruct')] + #[Depends('testLoadRoleByIdentifier')] + #[DataProvider('providerForCopyRoleTests')] public function testCopyRoleWithPolicies( RoleCreateStruct $roleCreateStruct, RoleCopyStruct $roleCopyStruct, @@ -662,12 +621,8 @@ public function testCopyRoleWithPolicies( /** * Test for the copyRole() method with added policies and limitations. * - * @dataProvider providerForCopyRoleTests * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::copyRole * - * @depends testNewRoleCopyStruct - * @depends testLoadRoleByIdentifier * * @param \Ibexa\Contracts\Core\Repository\Values\User\PolicyCreateStruct[] $policies * @@ -677,6 +632,9 @@ public function testCopyRoleWithPolicies( * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\LimitationValidationException */ + #[Depends('testNewRoleCopyStruct')] + #[Depends('testLoadRoleByIdentifier')] + #[DataProvider('providerForCopyRoleTests')] public function testCopyRoleWithPoliciesAndLimitations( RoleCreateStruct $roleCreateStruct, RoleCopyStruct $roleCopyStruct, @@ -718,12 +676,9 @@ public function testCopyRoleWithPoliciesAndLimitations( /** * Test for the loadRole() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::loadRole() - * - * @depends testCreateRole */ - public function testLoadRole() + #[Depends('testCreateRole')] + public function testLoadRole(): void { $repository = $this->getRepository(); @@ -748,10 +703,9 @@ public function testLoadRole() /** * Test for the loadRoleDraft() method. - * - * @depends testCreateRoleDraft */ - public function testLoadRoleDraft() + #[Depends('testCreateRoleDraft')] + public function testLoadRoleDraft(): void { $repository = $this->getRepository(); @@ -773,7 +727,7 @@ public function testLoadRoleDraft() self::assertEquals('roleName', $role->identifier); } - public function testLoadRoleDraftByRoleId() + public function testLoadRoleDraftByRoleId(): void { $repository = $this->getRepository(); @@ -801,12 +755,9 @@ public function testLoadRoleDraftByRoleId() /** * Test for the loadRole() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::loadRole() - * - * @depends testLoadRole */ - public function testLoadRoleThrowsNotFoundException() + #[Depends('testLoadRole')] + public function testLoadRoleThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -825,12 +776,9 @@ public function testLoadRoleThrowsNotFoundException() /** * Test for the loadRoleDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::loadRoleDraft() - * - * @depends testLoadRoleDraft */ - public function testLoadRoleDraftThrowsNotFoundException() + #[Depends('testLoadRoleDraft')] + public function testLoadRoleDraftThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -847,7 +795,7 @@ public function testLoadRoleDraftThrowsNotFoundException() /* END: Use Case */ } - public function testLoadRoleDraftByRoleIdThrowsNotFoundException() + public function testLoadRoleDraftByRoleIdThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -866,12 +814,9 @@ public function testLoadRoleDraftByRoleIdThrowsNotFoundException() /** * Test for the loadRoleByIdentifier() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::loadRoleByIdentifier() - * - * @depends testCreateRole */ - public function testLoadRoleByIdentifier() + #[Depends('testCreateRole')] + public function testLoadRoleByIdentifier(): void { $repository = $this->getRepository(); @@ -896,12 +841,9 @@ public function testLoadRoleByIdentifier() /** * Test for the loadRoleByIdentifier() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::loadRoleByIdentifier() - * - * @depends testLoadRoleByIdentifier */ - public function testLoadRoleByIdentifierThrowsNotFoundException() + #[Depends('testLoadRoleByIdentifier')] + public function testLoadRoleByIdentifierThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -919,12 +861,9 @@ public function testLoadRoleByIdentifierThrowsNotFoundException() /** * Test for the loadRoles() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::loadRoles() - * - * @depends testCreateRole */ - public function testLoadRoles() + #[Depends('testCreateRole')] + public function testLoadRoles(): void { $repository = $this->getRepository(); @@ -956,12 +895,9 @@ public function testLoadRoles() /** * Test for the loadRoles() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::loadRoles() - * - * @depends testLoadRoles */ - public function testLoadRolesReturnsExpectedSetOfDefaultRoles() + #[Depends('testLoadRoles')] + public function testLoadRolesReturnsExpectedSetOfDefaultRoles(): void { $repository = $this->getRepository(); @@ -990,10 +926,8 @@ public function testLoadRolesReturnsExpectedSetOfDefaultRoles() /** * Test for the newRoleUpdateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::newRoleUpdateStruct() */ - public function testNewRoleUpdateStruct() + public function testNewRoleUpdateStruct(): void { $repository = $this->getRepository(); @@ -1007,13 +941,10 @@ public function testNewRoleUpdateStruct() /** * Test for the updateRoleDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::updateRoleDraft() - * - * @depends testNewRoleUpdateStruct - * @depends testLoadRoleDraft */ - public function testUpdateRoleDraft() + #[Depends('testNewRoleUpdateStruct')] + #[Depends('testLoadRoleDraft')] + public function testUpdateRoleDraft(): void { $repository = $this->getRepository(); @@ -1040,12 +971,9 @@ public function testUpdateRoleDraft() /** * Test for the updateRoleDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::updateRoleDraft() - * - * @depends testUpdateRoleDraft */ - public function testUpdateRoleDraftThrowsInvalidArgumentException() + #[Depends('testUpdateRoleDraft')] + public function testUpdateRoleDraftThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -1070,13 +998,10 @@ public function testUpdateRoleDraftThrowsInvalidArgumentException() /** * Test for the deleteRole() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::deleteRole() - * - * @depends testCreateRole - * @depends testLoadRoles */ - public function testDeleteRole() + #[Depends('testCreateRole')] + #[Depends('testLoadRoles')] + public function testDeleteRole(): void { $repository = $this->getRepository(); @@ -1099,12 +1024,9 @@ public function testDeleteRole() /** * Test for the deleteRoleDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::deleteRoleDraft() - * - * @depends testLoadRoleDraft */ - public function testDeleteRoleDraft() + #[Depends('testLoadRoleDraft')] + public function testDeleteRoleDraft(): void { $this->expectException(NotFoundException::class); @@ -1128,10 +1050,8 @@ public function testDeleteRoleDraft() /** * Test for the newPolicyCreateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::newPolicyCreateStruct() */ - public function testNewPolicyCreateStruct() + public function testNewPolicyCreateStruct(): void { $repository = $this->getRepository(); @@ -1145,12 +1065,9 @@ public function testNewPolicyCreateStruct() /** * Test for the newPolicyCreateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::newPolicyCreateStruct() - * - * @depends testNewPolicyCreateStruct */ - public function testNewPolicyCreateStructSetsStructProperties() + #[Depends('testNewPolicyCreateStruct')] + public function testNewPolicyCreateStructSetsStructProperties(): void { $repository = $this->getRepository(); @@ -1167,13 +1084,10 @@ public function testNewPolicyCreateStructSetsStructProperties() /** * Test for the addPolicyByRoleDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::addPolicyByRoleDraft() - * - * @depends testCreateRoleDraft - * @depends testNewPolicyCreateStruct */ - public function testAddPolicyByRoleDraft() + #[Depends('testCreateRoleDraft')] + #[Depends('testNewPolicyCreateStruct')] + public function testAddPolicyByRoleDraft(): void { $repository = $this->getRepository(); @@ -1230,11 +1144,8 @@ static function ($p1, $p2): int { * Test for the addPolicyByRoleDraft() method. * * @return array [\Ibexa\Contracts\Core\Repository\Values\User\RoleDraft, \Ibexa\Contracts\Core\Repository\Values\User\Policy] - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::addPolicyByRoleDraft() - * - * @depends testAddPolicyByRoleDraft */ + #[Depends('testAddPolicyByRoleDraft')] public function testAddPolicyByRoleDraftUpdatesRole() { $repository = $this->getRepository(); @@ -1272,12 +1183,9 @@ public function testAddPolicyByRoleDraftUpdatesRole() * Test for the addPolicyByRoleDraft() method. * * @param array $roleAndPolicy - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::addPolicyByRoleDraft() - * - * @depends testAddPolicyByRoleDraftUpdatesRole */ - public function testAddPolicyByRoleDraftSetsPolicyProperties($roleAndPolicy) + #[Depends('testAddPolicyByRoleDraftUpdatesRole')] + public function testAddPolicyByRoleDraftSetsPolicyProperties($roleAndPolicy): void { list($role, $policy) = $roleAndPolicy; @@ -1289,13 +1197,10 @@ public function testAddPolicyByRoleDraftSetsPolicyProperties($roleAndPolicy) /** * Test for the addPolicyByRoleDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::addPolicyByRoleDraft() - * - * @depends testNewPolicyCreateStruct - * @depends testCreateRoleDraft */ - public function testAddPolicyByRoleDraftThrowsLimitationValidationException() + #[Depends('testNewPolicyCreateStruct')] + #[Depends('testCreateRoleDraft')] + public function testAddPolicyByRoleDraftThrowsLimitationValidationException(): void { $this->expectException(LimitationValidationException::class); @@ -1330,12 +1235,9 @@ public function testAddPolicyByRoleDraftThrowsLimitationValidationException() /** * Test for the createRole() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::createRole() - * - * @depends testAddPolicyByRoleDraftUpdatesRole */ - public function testCreateRoleWithAddPolicy() + #[Depends('testAddPolicyByRoleDraftUpdatesRole')] + public function testCreateRoleWithAddPolicy(): void { $repository = $this->getRepository(); @@ -1391,12 +1293,9 @@ public function testCreateRoleWithAddPolicy() /** * Test for the createRoleDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::createRoleDraft() - * - * @depends testAddPolicyByRoleDraftUpdatesRole */ - public function testCreateRoleDraftWithAddPolicy() + #[Depends('testAddPolicyByRoleDraftUpdatesRole')] + public function testCreateRoleDraftWithAddPolicy(): void { $repository = $this->getRepository(); @@ -1449,10 +1348,8 @@ public function testCreateRoleDraftWithAddPolicy() /** * Test for the newPolicyUpdateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::newPolicyUpdateStruct() */ - public function testNewPolicyUpdateStruct() + public function testNewPolicyUpdateStruct(): void { $repository = $this->getRepository(); @@ -1467,7 +1364,7 @@ public function testNewPolicyUpdateStruct() ); } - public function testUpdatePolicyByRoleDraftNoLimitation() + public function testUpdatePolicyByRoleDraftNoLimitation(): void { $repository = $this->getRepository(); @@ -1523,12 +1420,9 @@ public function testUpdatePolicyByRoleDraftNoLimitation() /** * @return array - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::updatePolicyByRoleDraft() - * - * @depends testAddPolicyByRoleDraft - * @depends testNewPolicyUpdateStruct */ + #[Depends('testAddPolicyByRoleDraft')] + #[Depends('testNewPolicyUpdateStruct')] public function testUpdatePolicyByRoleDraft() { $repository = $this->getRepository(); @@ -1601,11 +1495,8 @@ public function testUpdatePolicyByRoleDraft() /** * @param array $roleAndPolicy - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::testUpdatePolicyByRoleDraft() - * - * @depends testUpdatePolicyByRoleDraft */ + #[Depends('testUpdatePolicyByRoleDraft')] public function testUpdatePolicyUpdatesLimitations($roleAndPolicy) { list($role, $policy) = $roleAndPolicy; @@ -1628,12 +1519,9 @@ public function testUpdatePolicyUpdatesLimitations($roleAndPolicy) * Test for the updatePolicy() method. * * @param \Ibexa\Contracts\Core\Repository\Values\User\Role $role - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::updatePolicyByRoleDraft() - * - * @depends testUpdatePolicyUpdatesLimitations */ - public function testUpdatePolicyUpdatesRole($role) + #[Depends('testUpdatePolicyUpdatesLimitations')] + public function testUpdatePolicyUpdatesRole($role): void { $limitations = []; foreach ($role->getPolicies() as $policy) { @@ -1659,16 +1547,13 @@ public function testUpdatePolicyUpdatesRole($role) /** * Test for the updatePolicy() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::updatePolicyByRoleDraft() - * - * @depends testAddPolicyByRoleDraft - * @depends testNewPolicyCreateStruct - * @depends testNewPolicyUpdateStruct - * @depends testNewRoleCreateStruct - * @depends testCreateRole */ - public function testUpdatePolicyByRoleDraftThrowsLimitationValidationException() + #[Depends('testAddPolicyByRoleDraft')] + #[Depends('testNewPolicyCreateStruct')] + #[Depends('testNewPolicyUpdateStruct')] + #[Depends('testNewRoleCreateStruct')] + #[Depends('testCreateRole')] + public function testUpdatePolicyByRoleDraftThrowsLimitationValidationException(): void { $this->expectException(LimitationValidationException::class); @@ -1733,12 +1618,9 @@ public function testUpdatePolicyByRoleDraftThrowsLimitationValidationException() /** * Test for the removePolicyByRoleDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::removePolicyByRoleDraft() - * - * @depends testAddPolicyByRoleDraft */ - public function testRemovePolicyByRoleDraft() + #[Depends('testAddPolicyByRoleDraft')] + public function testRemovePolicyByRoleDraft(): void { $repository = $this->getRepository(); @@ -1773,10 +1655,8 @@ public function testRemovePolicyByRoleDraft() /** * Test for the addPolicyByRoleDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::addPolicyByRoleDraft() */ - public function testAddPolicyWithRoleAssignment() + public function testAddPolicyWithRoleAssignment(): void { $repository = $this->getRepository(); @@ -1820,8 +1700,6 @@ public function testAddPolicyWithRoleAssignment() * Test loading user/group role assignments. * * @return \Ibexa\Contracts\Core\Repository\Values\User\UserGroupRoleAssignment - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::loadRoleAssignment */ public function testLoadRoleAssignment() { @@ -1870,11 +1748,8 @@ public function testLoadRoleAssignment() * Test for the getRoleAssignments() method. * * @return \Ibexa\Contracts\Core\Repository\Values\User\RoleAssignment[] - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::getRoleAssignments() - * - * @depends testLoadRoleByIdentifier */ + #[Depends('testLoadRoleByIdentifier')] public function testGetRoleAssignments() { $repository = $this->getRepository(); @@ -1907,12 +1782,9 @@ public function testGetRoleAssignments() * Test for the getRoleAssignments() method. * * @param \Ibexa\Contracts\Core\Repository\Values\User\RoleAssignment[] $roleAssignments - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::getRoleAssignments - * - * @depends testGetRoleAssignments */ - public function testGetRoleAssignmentsContainExpectedLimitation(array $roleAssignments) + #[Depends('testGetRoleAssignments')] + public function testGetRoleAssignmentsContainExpectedLimitation(array $roleAssignments): void { self::assertEquals( 'Subtree', @@ -1920,9 +1792,6 @@ public function testGetRoleAssignmentsContainExpectedLimitation(array $roleAssig ); } - /** - * @covers \Ibexa\Contracts\Core\Repository\RoleService::loadRoleAssignments() - */ public function testLoadRoleAssignments(): void { $repository = $this->getRepository(); @@ -1943,9 +1812,6 @@ public function testLoadRoleAssignments(): void self::assertInstanceOf(UserRoleAssignment::class, $roleAssignments[0]); } - /** - * @covers \Ibexa\Contracts\Core\Repository\RoleService::countRoleAssignments() - */ public function testLoadRoleAssignmentsWithDeletedUser(): void { $repository = $this->getRepository(); @@ -2016,12 +1882,9 @@ public function testCountRoleAssignmentsAfterDeletingUser(): void /** * Test for the assignRoleToUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::assignRoleToUser() - * - * @depends testGetRoleAssignments */ - public function testAssignRoleToUser() + #[Depends('testGetRoleAssignments')] + public function testAssignRoleToUser(): void { $repository = $this->getRepository(); $roleService = $repository->getRoleService(); @@ -2045,12 +1908,9 @@ public function testAssignRoleToUser() /** * Test for the assignRoleToUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::assignRoleToUser($role, $user, $roleLimitation) - * - * @depends testAssignRoleToUser */ - public function testAssignRoleToUserWithRoleLimitation() + #[Depends('testAssignRoleToUser')] + public function testAssignRoleToUserWithRoleLimitation(): void { $repository = $this->getRepository(); $roleService = $repository->getRoleService(); @@ -2151,13 +2011,10 @@ public function testAssignRoleToUserWithRoleLimitation() /** * Test for the assignRoleToUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::assignRoleToUser($role, $user, $roleLimitation) - * - * @depends testAssignRoleToUser - * @depends testLoadRoleByIdentifier */ - public function testAssignRoleToUserWithRoleLimitationThrowsLimitationValidationException() + #[Depends('testAssignRoleToUser')] + #[Depends('testLoadRoleByIdentifier')] + public function testAssignRoleToUserWithRoleLimitationThrowsLimitationValidationException(): void { $this->expectException(LimitationValidationException::class); @@ -2193,13 +2050,10 @@ public function testAssignRoleToUserWithRoleLimitationThrowsLimitationValidation * Test for the assignRoleToUser() method. * * Makes sure assigning role several times throws. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::assignRoleToUser($role, $user, $roleLimitation) - * - * @depends testAssignRoleToUser - * @depends testLoadRoleByIdentifier */ - public function testAssignRoleToUserThrowsInvalidArgumentException() + #[Depends('testAssignRoleToUser')] + #[Depends('testLoadRoleByIdentifier')] + public function testAssignRoleToUserThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -2239,13 +2093,10 @@ public function testAssignRoleToUserThrowsInvalidArgumentException() * Test for the assignRoleToUser() method. * * Makes sure assigning role several times with same limitations throws. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::assignRoleToUser($role, $user, $roleLimitation) - * - * @depends testAssignRoleToUser - * @depends testLoadRoleByIdentifier */ - public function testAssignRoleToUserWithRoleLimitationThrowsInvalidArgumentException() + #[Depends('testAssignRoleToUser')] + #[Depends('testLoadRoleByIdentifier')] + public function testAssignRoleToUserWithRoleLimitationThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -2293,12 +2144,9 @@ public function testAssignRoleToUserWithRoleLimitationThrowsInvalidArgumentExcep /** * Test for the removeRoleAssignment() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::removeRoleAssignment() - * - * @depends testAssignRoleToUser */ - public function testRemoveRoleAssignment() + #[Depends('testAssignRoleToUser')] + public function testRemoveRoleAssignment(): void { $repository = $this->getRepository(); $roleService = $repository->getRoleService(); @@ -2329,13 +2177,10 @@ public function testRemoveRoleAssignment() /** * Test for the getRoleAssignmentsForUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::getRoleAssignmentsForUser() - * - * @depends testAssignRoleToUser - * @depends testCreateRoleWithAddPolicy */ - public function testGetRoleAssignmentsForUserDirect() + #[Depends('testAssignRoleToUser')] + #[Depends('testCreateRoleWithAddPolicy')] + public function testGetRoleAssignmentsForUserDirect(): void { $repository = $this->getRepository(); $roleService = $repository->getRoleService(); @@ -2385,13 +2230,10 @@ public function testGetRoleAssignmentsForUserDirect() /** * Test for the getRoleAssignmentsForUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::getRoleAssignmentsForUser() - * - * @depends testAssignRoleToUser - * @depends testCreateRoleWithAddPolicy */ - public function testGetRoleAssignmentsForUserEmpty() + #[Depends('testAssignRoleToUser')] + #[Depends('testCreateRoleWithAddPolicy')] + public function testGetRoleAssignmentsForUserEmpty(): void { $repository = $this->getRepository(); $roleService = $repository->getRoleService(); @@ -2410,13 +2252,10 @@ public function testGetRoleAssignmentsForUserEmpty() /** * Test for the getRoleAssignmentsForUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::getRoleAssignmentsForUser() - * - * @depends testAssignRoleToUser - * @depends testCreateRoleWithAddPolicy */ - public function testGetRoleAssignmentsForUserInherited() + #[Depends('testAssignRoleToUser')] + #[Depends('testCreateRoleWithAddPolicy')] + public function testGetRoleAssignmentsForUserInherited(): void { $repository = $this->getRepository(); $roleService = $repository->getRoleService(); @@ -2439,12 +2278,9 @@ public function testGetRoleAssignmentsForUserInherited() /** * Test for the assignRoleToUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::assignRoleToUserGroup() - * - * @depends testGetRoleAssignments */ - public function testAssignRoleToUserGroup() + #[Depends('testGetRoleAssignments')] + public function testAssignRoleToUserGroup(): void { $repository = $this->getRepository(); $roleService = $repository->getRoleService(); @@ -2470,10 +2306,8 @@ public function testAssignRoleToUserGroup() * Test for the assignRoleToUserGroup() method. * * Related issue: EZP-29113 - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::assignRoleToUserGroup() */ - public function testAssignRoleToUserGroupAffectsRoleAssignmentsForUser() + public function testAssignRoleToUserGroupAffectsRoleAssignmentsForUser(): void { $roleService = $this->getRepository()->getRoleService(); @@ -2498,12 +2332,9 @@ public function testAssignRoleToUserGroupAffectsRoleAssignmentsForUser() /** * Test for the assignRoleToUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::assignRoleToUserGroup($role, $userGroup, $roleLimitation) - * - * @depends testAssignRoleToUserGroup */ - public function testAssignRoleToUserGroupWithRoleLimitation() + #[Depends('testAssignRoleToUserGroup')] + public function testAssignRoleToUserGroupWithRoleLimitation(): void { $repository = $this->getRepository(); $roleService = $repository->getRoleService(); @@ -2600,13 +2431,10 @@ public function testAssignRoleToUserGroupWithRoleLimitation() /** * Test for the assignRoleToUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::assignRoleToUserGroup($role, $userGroup, $roleLimitation) - * - * @depends testLoadRoleByIdentifier - * @depends testAssignRoleToUserGroup */ - public function testAssignRoleToUserGroupWithRoleLimitationThrowsLimitationValidationException() + #[Depends('testLoadRoleByIdentifier')] + #[Depends('testAssignRoleToUserGroup')] + public function testAssignRoleToUserGroupWithRoleLimitationThrowsLimitationValidationException(): void { $this->expectException(LimitationValidationException::class); @@ -2643,13 +2471,10 @@ public function testAssignRoleToUserGroupWithRoleLimitationThrowsLimitationValid * Test for the assignRoleToUserGroup() method. * * Makes sure assigning role several times throws. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::assignRoleToUserGroup($role, $userGroup, $roleLimitation) - * - * @depends testLoadRoleByIdentifier - * @depends testAssignRoleToUserGroup */ - public function testAssignRoleToUserGroupThrowsInvalidArgumentException() + #[Depends('testLoadRoleByIdentifier')] + #[Depends('testAssignRoleToUserGroup')] + public function testAssignRoleToUserGroupThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -2690,13 +2515,10 @@ public function testAssignRoleToUserGroupThrowsInvalidArgumentException() * Test for the assignRoleToUserGroup() method. * * Makes sure assigning role several times with same limitations throws. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::assignRoleToUserGroup($role, $userGroup, $roleLimitation) - * - * @depends testLoadRoleByIdentifier - * @depends testAssignRoleToUserGroup */ - public function testAssignRoleToUserGroupWithRoleLimitationThrowsInvalidArgumentException() + #[Depends('testLoadRoleByIdentifier')] + #[Depends('testAssignRoleToUserGroup')] + public function testAssignRoleToUserGroupWithRoleLimitationThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -2745,12 +2567,9 @@ public function testAssignRoleToUserGroupWithRoleLimitationThrowsInvalidArgument /** * Test for the removeRoleAssignment() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::removeRoleAssignment() - * - * @depends testAssignRoleToUserGroup */ - public function testRemoveRoleAssignmentFromUserGroup() + #[Depends('testAssignRoleToUserGroup')] + public function testRemoveRoleAssignmentFromUserGroup(): void { $repository = $this->getRepository(); $roleService = $repository->getRoleService(); @@ -2783,10 +2602,8 @@ public function testRemoveRoleAssignmentFromUserGroup() /** * Test unassigning role by assignment. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::removeRoleAssignment */ - public function testUnassignRoleByAssignment() + public function testUnassignRoleByAssignment(): void { $repository = $this->getRepository(); $roleService = $repository->getRoleService(); @@ -2810,10 +2627,8 @@ public function testUnassignRoleByAssignment() * Test unassigning role by assignment. * * But on current admin user so he lacks access to read roles. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::removeRoleAssignment */ - public function testUnassignRoleByAssignmentThrowsUnauthorizedException() + public function testUnassignRoleByAssignmentThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -2835,10 +2650,8 @@ public function testUnassignRoleByAssignmentThrowsUnauthorizedException() /** * Test unassigning role by non-existing assignment. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::removeRoleAssignment */ - public function testUnassignRoleByAssignmentThrowsNotFoundException() + public function testUnassignRoleByAssignmentThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -2860,13 +2673,10 @@ public function testUnassignRoleByAssignmentThrowsNotFoundException() /** * Test for the getRoleAssignmentsForUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::getRoleAssignmentsForUserGroup() - * - * @depends testAssignRoleToUserGroup - * @depends testCreateRoleWithAddPolicy */ - public function testGetRoleAssignmentsForUserGroup() + #[Depends('testAssignRoleToUserGroup')] + #[Depends('testCreateRoleWithAddPolicy')] + public function testGetRoleAssignmentsForUserGroup(): void { $repository = $this->getRepository(); $roleService = $repository->getRoleService(); @@ -2911,13 +2721,10 @@ public function testGetRoleAssignmentsForUserGroup() /** * Test for the getRoleAssignmentsForUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::getRoleAssignmentsForUser() - * - * @depends testAssignRoleToUser - * @depends testAssignRoleToUserGroup */ - public function testLoadPoliciesByUserId() + #[Depends('testAssignRoleToUser')] + #[Depends('testAssignRoleToUserGroup')] + public function testLoadPoliciesByUserId(): void { $repository = $this->getRepository(); @@ -2989,12 +2796,9 @@ public function testLoadPoliciesByUserId() /** * Test for the publishRoleDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::publishRoleDraft() - * - * @depends testCreateRoleDraft */ - public function testPublishRoleDraft() + #[Depends('testCreateRoleDraft')] + public function testPublishRoleDraft(): void { $repository = $this->getRepository(); @@ -3027,13 +2831,10 @@ public function testPublishRoleDraft() /** * Test for the publishRoleDraft() method. - * - * @covers \Ibexa\Contracts\Core\Repository\RoleService::publishRoleDraft() - * - * @depends testCreateRoleDraft - * @depends testAddPolicyByRoleDraft */ - public function testPublishRoleDraftAddPolicies() + #[Depends('testCreateRoleDraft')] + #[Depends('testAddPolicyByRoleDraft')] + public function testPublishRoleDraftAddPolicies(): void { $repository = $this->getRepository(); diff --git a/tests/integration/Core/Repository/SearchEngineIndexingTest.php b/tests/integration/Core/Repository/SearchEngineIndexingTest.php index 08497bcb8b..a4c16be3e5 100644 --- a/tests/integration/Core/Repository/SearchEngineIndexingTest.php +++ b/tests/integration/Core/Repository/SearchEngineIndexingTest.php @@ -16,14 +16,16 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Query; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion; use Ibexa\Contracts\Core\Repository\Values\ContentType\ContentType; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\Group; /** * Test case for indexing operations with a search engine. - * - * @group integration - * @group search - * @group indexing */ +#[Group('integration')] +#[Group('search')] +#[Group('indexing')] class SearchEngineIndexingTest extends BaseTestCase { /** @@ -55,11 +57,11 @@ public function testFindContentInfoFullTextIsSearchable() /** * Test that indexing full text data depends on the isSearchable flag on the field definition. * - * @depends testFindContentInfoFullTextIsSearchable * * @param \Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo $contentInfo */ - public function testFindLocationsFullTextIsSearchable(ContentInfo $contentInfo) + #[Depends('testFindContentInfoFullTextIsSearchable')] + public function testFindLocationsFullTextIsSearchable(ContentInfo $contentInfo): void { $searchTerm = 'pamplemousse'; @@ -83,10 +85,9 @@ public function testFindLocationsFullTextIsSearchable(ContentInfo $contentInfo) /** * Test that indexing full text data depends on the isSearchable flag on the field definition. - * - * @depends testFindContentInfoFullTextIsSearchable */ - public function testFindContentInfoFullTextIsNotSearchable() + #[Depends('testFindContentInfoFullTextIsSearchable')] + public function testFindContentInfoFullTextIsNotSearchable(): void { $searchTerm = 'pamplemousse'; $this->createFullTextIsSearchableContent($searchTerm, false); @@ -107,10 +108,9 @@ public function testFindContentInfoFullTextIsNotSearchable() /** * Test that indexing full text data depends on the isSearchable flag on the field definition. - * - * @depends testFindLocationsFullTextIsSearchable */ - public function testFindLocationsFullTextIsNotSearchable() + #[Depends('testFindLocationsFullTextIsSearchable')] + public function testFindLocationsFullTextIsNotSearchable(): void { $searchTerm = 'pamplemousse'; @@ -185,7 +185,7 @@ protected function createFullTextIsSearchableContent($searchText, $isSearchable) /** * EZP-26186: Make sure index is NOT deleted on removal of version draft (affected Solr). */ - public function testDeleteVersion() + public function testDeleteVersion(): void { $repository = $this->getRepository(); $contentService = $repository->getContentService(); @@ -213,7 +213,7 @@ public function testDeleteVersion() /** * EZP-26186: Make sure affected child locations are deleted on content deletion (affected Solr). */ - public function testDeleteContent() + public function testDeleteContent(): void { $repository = $this->getRepository(); $contentService = $repository->getContentService(); @@ -236,7 +236,7 @@ public function testDeleteContent() /** * EZP-26186: Make sure index is deleted on removal of Users (affected Solr). */ - public function testDeleteUser() + public function testDeleteUser(): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); @@ -259,7 +259,7 @@ public function testDeleteUser() /** * EZP-26186: Make sure index is deleted on removal of UserGroups (affected Solr). */ - public function testDeleteUserGroup() + public function testDeleteUserGroup(): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); @@ -282,7 +282,7 @@ public function testDeleteUserGroup() /** * Test that a newly created user is available for search. */ - public function testCreateUser() + public function testCreateUser(): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); @@ -318,7 +318,7 @@ public function testCreateUser() /** * Test that a newly updated user is available for search. */ - public function testUpdateUser() + public function testUpdateUser(): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); @@ -350,7 +350,7 @@ public function testUpdateUser() /** * Test that a newly created user group is available for search. */ - public function testCreateUserGroup() + public function testCreateUserGroup(): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); @@ -380,7 +380,7 @@ public function testCreateUserGroup() /** * Test that a newly created Location is available for search. */ - public function testCreateLocation() + public function testCreateLocation(): void { $repository = $this->getRepository(); $searchService = $repository->getSearchService(); @@ -402,7 +402,7 @@ public function testCreateLocation() /** * Test that hiding a Location makes it unavailable for search. */ - public function testHideSubtree() + public function testHideSubtree(): void { $repository = $this->getRepository(); $searchService = $repository->getSearchService(); @@ -428,7 +428,7 @@ public function testHideSubtree() /** * Test that hiding and revealing a Location makes it available for search. */ - public function testRevealSubtree() + public function testRevealSubtree(): void { $repository = $this->getRepository(); $searchService = $repository->getSearchService(); @@ -456,7 +456,7 @@ public function testRevealSubtree() /** * Test that a copied subtree is available for search. */ - public function testCopySubtree() + public function testCopySubtree(): void { $repository = $this->getRepository(); $locationService = $repository->getLocationService(); @@ -506,7 +506,7 @@ public function testCopySubtree() /** * Test that moved subtree is available for search and found only under a specific parent Location. */ - public function testMoveSubtree() + public function testMoveSubtree(): void { $repository = $this->getRepository(); $locationService = $repository->getLocationService(); @@ -571,7 +571,7 @@ public function testMoveSubtree() * Testing that content is indexed even when containing only fields with values * considered to be empty by the search engine. */ - public function testIndexContentWithNullField() + public function testIndexContentWithNullField(): void { $repository = $this->getRepository(); $contentService = $repository->getContentService(); @@ -627,7 +627,7 @@ public function testIndexContentWithNullField() /** * Test that updated Location is available for search. */ - public function testUpdateLocation() + public function testUpdateLocation(): void { $repository = $this->getRepository(); $locationService = $repository->getLocationService(); @@ -665,7 +665,7 @@ public function testUpdateLocation() * Testing that content will be deleted with all of its subitems but subitems with additional location will stay as * they are. */ - public function testDeleteLocation() + public function testDeleteLocation(): void { $repository = $this->getRepository(); $locationService = $repository->getLocationService(); @@ -700,7 +700,7 @@ public function testDeleteLocation() /** * Test content is available for search after being published. */ - public function testPublishVersion() + public function testPublishVersion(): void { $repository = $this->getRepository(); $searchService = $repository->getSearchService(); @@ -731,7 +731,7 @@ public function testPublishVersion() /** * Test recovered content is available for search. */ - public function testRecoverLocation() + public function testRecoverLocation(): void { $repository = $this->getRepository(); $locationService = $repository->getLocationService(); @@ -761,7 +761,7 @@ public function testRecoverLocation() /** * Test copied content is available for search. */ - public function testCopyContent() + public function testCopyContent(): void { $repository = $this->getRepository(); $searchService = $repository->getSearchService(); @@ -787,7 +787,7 @@ public function testCopyContent() /** * Test that setting object content state to locked and then unlocked does not affect search index. */ - public function testSetContentState() + public function testSetContentState(): void { $repository = $this->getRepository(); $objectStateService = $repository->getObjectStateService(); @@ -816,10 +816,9 @@ public function testSetContentState() * @param string $text Content Item field value text (to be indexed) * @param string $searchForText text based on which Content Item should be found * @param array $ignoreForSetupFactories list of SetupFactories to be ignored - * - * @dataProvider getSpecialFullTextCases */ - public function testIndexingSpecialFullTextCases($text, $searchForText) + #[DataProvider('getSpecialFullTextCases')] + public function testIndexingSpecialFullTextCases($text, $searchForText): void { $repository = $this->getRepository(); $searchService = $repository->getSearchService(); @@ -845,9 +844,8 @@ public function testIndexingSpecialFullTextCases($text, $searchForText) /** * Check if FullText indexing works for email addresses. - * - * @dataProvider getEmailAddressesCases */ + #[DataProvider('getEmailAddressesCases')] public function testIndexingEmailFieldCases(string $email, string $searchForText): void { $repository = $this->getRepository(); @@ -875,7 +873,7 @@ public function testIndexingEmailFieldCases(string $email, string $searchForText /** * Data Provider for {@see testIndexingSpecialFullTextCases()} method. */ - public function getEmailAddressesCases(): array + public static function getEmailAddressesCases(): array { return [ ['test@TEST.com', 'test@test.com'], @@ -891,7 +889,7 @@ public function getEmailAddressesCases(): array * * @return array */ - public function getSpecialFullTextCases() + public static function getSpecialFullTextCases(): array { return [ ['UPPERCASE TEXT', 'uppercase text'], @@ -918,7 +916,7 @@ public function getSpecialFullTextCases() * * @see https://issues.ibexa.co/browse/EZP-27250 */ - public function testUserFullTextSearch() + public function testUserFullTextSearch(): void { $repository = $this->getRepository(); $searchService = $repository->getSearchService(); @@ -940,7 +938,7 @@ public function testUserFullTextSearch() /** * Test updating Content field value with empty value removes it from search index. */ - public function testRemovedContentFieldValueIsNotFound() + public function testRemovedContentFieldValueIsNotFound(): void { $repository = $this->getRepository(); $contentService = $repository->getContentService(); @@ -990,7 +988,7 @@ private function assertSubtreeInvisibleProperty(SearchService $searchService, $p /** * Test that swapping locations affects properly Search Engine Index. */ - public function testSwapLocation() + public function testSwapLocation(): void { $repository = $this->getRepository(); $locationService = $repository->getLocationService(); @@ -1023,7 +1021,7 @@ public function testSwapLocation() /** * Test that updating Content metadata affects properly Search Engine Index. */ - public function testUpdateContentMetadata() + public function testUpdateContentMetadata(): void { $repository = $this->getRepository(); $contentService = $repository->getContentService(); @@ -1074,7 +1072,7 @@ public function testUpdateContentMetadata() /** * Test that updating Content Draft metadata does not affect Search Engine Index. */ - public function testUpdateContentDraftMetadataIsNotIndexed() + public function testUpdateContentDraftMetadataIsNotIndexed(): void { $repository = $this->getRepository(); $contentService = $repository->getContentService(); @@ -1099,7 +1097,7 @@ public function testUpdateContentDraftMetadataIsNotIndexed() /** * Test that assigning section to content object properly affects Search Engine Index. */ - public function testAssignSection() + public function testAssignSection(): void { $repository = $this->getRepository(); $sectionService = $repository->getSectionService(); @@ -1123,7 +1121,7 @@ public function testAssignSection() /** * Test search engine is updated after removal of the translation from all the Versions. */ - public function testDeleteTranslation() + public function testDeleteTranslation(): void { $repository = $this->getRepository(); $searchService = $repository->getSearchService(); diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/AbstractAggregationTestCase.php b/tests/integration/Core/Repository/SearchService/Aggregation/AbstractAggregationTestCase.php index e6db33b624..c6d538da14 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/AbstractAggregationTestCase.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/AbstractAggregationTestCase.php @@ -15,6 +15,7 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\MatchAll; use Ibexa\Contracts\Core\Repository\Values\Content\Search\AggregationResult; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; +use PHPUnit\Framework\Attributes\DataProvider; abstract class AbstractAggregationTestCase extends BaseTestCase { @@ -33,9 +34,7 @@ protected function skipIfAggregationsAreNotSupported(): void } } - /** - * @dataProvider dataProviderForTestFindContentWithAggregation - */ + #[DataProvider('dataProviderForTestFindContentWithAggregation')] public function testFindContentWithAggregation( Aggregation $aggregation, AggregationResult $expectedResult @@ -52,9 +51,7 @@ public function testFindContentWithAggregation( ); } - /** - * @dataProvider dataProviderForTestFindLocationWithAggregation - */ + #[DataProvider('dataProviderForTestFindLocationWithAggregation')] public function testFindLocationWithAggregation( Aggregation $aggregation, AggregationResult $expectedResult @@ -71,16 +68,16 @@ public function testFindLocationWithAggregation( ); } - abstract public function dataProviderForTestFindContentWithAggregation(): iterable; + abstract public static function dataProviderForTestFindContentWithAggregation(): iterable; /** * Overwrite if results for location query are different then content query. * * @return iterable */ - public function dataProviderForTestFindLocationWithAggregation(): iterable + public static function dataProviderForTestFindLocationWithAggregation(): iterable { - yield from $this->dataProviderForTestFindContentWithAggregation(); + yield from static::dataProviderForTestFindContentWithAggregation(); } protected function createFixturesForAggregation(Aggregation $aggregation): void diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/ContentTypeGroupTermAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/ContentTypeGroupTermAggregationTest.php index d20129028d..e11dcf0e11 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/ContentTypeGroupTermAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/ContentTypeGroupTermAggregationTest.php @@ -13,7 +13,7 @@ final class ContentTypeGroupTermAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { $aggregation = new ContentTypeGroupTermAggregation('content_type_group'); @@ -25,7 +25,7 @@ public function dataProviderForTestFindContentWithAggregation(): iterable ]); $builder->setEntryMapper([ - $this->getRepository()->getContentTypeService(), + static::resolveRepository()->getContentTypeService(), 'loadContentTypeGroupByIdentifier', ]); diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/ContentTypeTermAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/ContentTypeTermAggregationTest.php index 1ea75284a9..f9f7f159b6 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/ContentTypeTermAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/ContentTypeTermAggregationTest.php @@ -13,7 +13,7 @@ final class ContentTypeTermAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { $aggregation = new ContentTypeTermAggregation('content_type'); @@ -29,7 +29,7 @@ public function dataProviderForTestFindContentWithAggregation(): iterable ]); $builder->setEntryMapper([ - $this->getRepository()->getContentTypeService(), + static::resolveRepository()->getContentTypeService(), 'loadContentTypeByIdentifier', ]); diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/DateMetadataRangeAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/DateMetadataRangeAggregationTest.php index 60b3950cf8..b372dbe161 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/DateMetadataRangeAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/DateMetadataRangeAggregationTest.php @@ -17,7 +17,7 @@ final class DateMetadataRangeAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { $timezone = new DateTimeZone('+0000'); diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/Field/AuthorTermAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/Field/AuthorTermAggregationTest.php index a929a24cdb..6765b89c8c 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/Field/AuthorTermAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/Field/AuthorTermAggregationTest.php @@ -19,7 +19,7 @@ final class AuthorTermAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { yield [ new AuthorTermAggregation('author_term', 'content_type', 'author'), diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/Field/CheckboxTermAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/Field/CheckboxTermAggregationTest.php index 8e90381269..49c9c2b379 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/Field/CheckboxTermAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/Field/CheckboxTermAggregationTest.php @@ -18,7 +18,7 @@ final class CheckboxTermAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { yield [ new CheckboxTermAggregation('checkbox_term', 'content_type', 'boolean'), diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/Field/CountryTermAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/Field/CountryTermAggregationTest.php index b1bc974d70..25762fd5dc 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/Field/CountryTermAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/Field/CountryTermAggregationTest.php @@ -18,7 +18,7 @@ final class CountryTermAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { yield '::TYPE_NAME' => [ new CountryTermAggregation( diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/Field/DateRangeAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/Field/DateRangeAggregationTest.php index 8d4d705258..63163f22f7 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/Field/DateRangeAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/Field/DateRangeAggregationTest.php @@ -20,7 +20,7 @@ final class DateRangeAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { $timezone = new DateTimeZone('+0000'); diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/Field/DateTimeRangeAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/Field/DateTimeRangeAggregationTest.php index ec3993ac5e..5594fb1734 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/Field/DateTimeRangeAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/Field/DateTimeRangeAggregationTest.php @@ -20,7 +20,7 @@ final class DateTimeRangeAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { $timezone = new DateTimeZone('+0000'); diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/Field/FloatRangeAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/Field/FloatRangeAggregationTest.php index a2fd16aeac..c04b182cf5 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/Field/FloatRangeAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/Field/FloatRangeAggregationTest.php @@ -18,7 +18,7 @@ final class FloatRangeAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { yield [ new FloatRangeAggregation('float_range', 'content_type', 'float_field', [ diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/Field/FloatStatsAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/Field/FloatStatsAggregationTest.php index 397337b3b9..e4d56c040c 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/Field/FloatStatsAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/Field/FloatStatsAggregationTest.php @@ -16,7 +16,7 @@ final class FloatStatsAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { yield [ new FloatStatsAggregation('float_stats', 'content_type', 'float_field_2'), diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/Field/IntegerRangeAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/Field/IntegerRangeAggregationTest.php index f18f6f5ac1..7ce0c0e990 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/Field/IntegerRangeAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/Field/IntegerRangeAggregationTest.php @@ -18,7 +18,7 @@ final class IntegerRangeAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { yield [ new IntegerRangeAggregation('integer_range', 'content_type', 'integer_field', [ diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/Field/IntegerStatsAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/Field/IntegerStatsAggregationTest.php index 8f506c6840..7deadf36e5 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/Field/IntegerStatsAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/Field/IntegerStatsAggregationTest.php @@ -16,7 +16,7 @@ final class IntegerStatsAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { yield [ new IntegerStatsAggregation('integer_stats', 'content_type', 'integer_field'), diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/Field/KeywordTermAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/Field/KeywordTermAggregationTest.php index 4c6b542903..cf92c5a342 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/Field/KeywordTermAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/Field/KeywordTermAggregationTest.php @@ -17,7 +17,7 @@ final class KeywordTermAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { yield [ new KeywordTermAggregation( diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/Field/SelectionTermAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/Field/SelectionTermAggregationTest.php index d7b72e757c..ff647f0cf5 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/Field/SelectionTermAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/Field/SelectionTermAggregationTest.php @@ -18,7 +18,7 @@ final class SelectionTermAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { yield [ new SelectionTermAggregation( diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/Field/TimeRangeAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/Field/TimeRangeAggregationTest.php index 8bcac57835..c75828f29d 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/Field/TimeRangeAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/Field/TimeRangeAggregationTest.php @@ -20,7 +20,7 @@ final class TimeRangeAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { yield [ new TimeRangeAggregation( @@ -28,30 +28,30 @@ public function dataProviderForTestFindContentWithAggregation(): iterable 'content_type', 'time_field', [ - Range::ofInt(null, $this->mktime(7, 0, 0, 0, 0, 0)), + Range::ofInt(null, static::mktime(7, 0, 0, 0, 0, 0)), Range::ofInt( - $this->mktime(7, 0, 0, 0, 0, 0), - $this->mktime(12, 0, 0, 0, 0, 0) + static::mktime(7, 0, 0, 0, 0, 0), + static::mktime(12, 0, 0, 0, 0, 0) ), - Range::ofInt($this->mktime(12, 0, 0, 0, 0, 0), null), + Range::ofInt(static::mktime(12, 0, 0, 0, 0, 0), null), ] ), new RangeAggregationResult( 'time_term', [ new RangeAggregationResultEntry( - Range::ofInt(null, $this->mktime(7, 0, 0, 0, 0, 0)), + Range::ofInt(null, static::mktime(7, 0, 0, 0, 0, 0)), 2 ), new RangeAggregationResultEntry( Range::ofInt( - $this->mktime(7, 0, 0, 0, 0, 0), - $this->mktime(12, 0, 0, 0, 0, 0) + static::mktime(7, 0, 0, 0, 0, 0), + static::mktime(12, 0, 0, 0, 0, 0) ), 2 ), new RangeAggregationResultEntry( - Range::ofInt($this->mktime(12, 0, 0, 0, 0, 0), null), + Range::ofInt(static::mktime(12, 0, 0, 0, 0, 0), null), 3 ), ] @@ -80,7 +80,7 @@ protected function createFixturesForAggregation(Aggregation $aggregation): void $this->refreshSearch($this->getRepository()); } - private function mktime(int $hour, int $minute, int $second, int $month, int $day, int $year): int + private static function mktime(int $hour, int $minute, int $second, int $month, int $day, int $year): int { $timestamp = mktime($hour, $minute, $second, $month, $day, $year); if ($timestamp === false) { diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/LanguageTermAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/LanguageTermAggregationTest.php index 0279aaf31f..efb0eaecad 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/LanguageTermAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/LanguageTermAggregationTest.php @@ -13,7 +13,7 @@ final class LanguageTermAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { $aggregation = new LanguageTermAggregation('language'); @@ -24,7 +24,7 @@ public function dataProviderForTestFindContentWithAggregation(): iterable ]); $builder->setEntryMapper([ - $this->getRepository()->getContentLanguageService(), + static::resolveRepository()->getContentLanguageService(), 'loadLanguage', ]); diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/LocationChildrenTermAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/LocationChildrenTermAggregationTest.php index 413e49b56f..be6af61d96 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/LocationChildrenTermAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/LocationChildrenTermAggregationTest.php @@ -12,12 +12,11 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Query\Aggregation\Location\LocationChildrenTermAggregation; use Ibexa\Contracts\Core\Repository\Values\Content\Search\AggregationResult; use Ibexa\Tests\Integration\Core\Repository\SearchService\Aggregation\DataSetBuilder\TermAggregationDataSetBuilder; +use PHPUnit\Framework\Attributes\DataProvider; final class LocationChildrenTermAggregationTest extends AbstractAggregationTestCase { - /** - * @dataProvider dataProviderForTestFindContentWithAggregation - */ + #[DataProvider('dataProviderForTestFindContentWithAggregation')] public function testFindContentWithAggregation( Aggregation $aggregation, AggregationResult $expectedResult @@ -25,7 +24,7 @@ public function testFindContentWithAggregation( self::markTestSkipped('LocationChildrenTermAggregation is only available for Location search'); } - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { $aggregation = new LocationChildrenTermAggregation('children'); @@ -42,7 +41,7 @@ public function dataProviderForTestFindContentWithAggregation(): iterable ]); $builder->setEntryMapper([ - $this->getRepository()->getLocationService(), + static::resolveRepository()->getLocationService(), 'loadLocation', ]); diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/ObjectStateTermAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/ObjectStateTermAggregationTest.php index 2fe16a5d38..e836eb73f7 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/ObjectStateTermAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/ObjectStateTermAggregationTest.php @@ -14,7 +14,7 @@ final class ObjectStateTermAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { $aggregation = new ObjectStateTermAggregation('object_state', 'ibexa_lock'); @@ -25,8 +25,8 @@ public function dataProviderForTestFindContentWithAggregation(): iterable ]); $builder->setEntryMapper( - function (string $identifier): ObjectState { - $objectStateService = $this->getRepository()->getObjectStateService(); + static function (string $identifier): ObjectState { + $objectStateService = static::resolveRepository()->getObjectStateService(); static $objectStateGroup = null; if ($objectStateGroup === null) { diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/RawRangeAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/RawRangeAggregationTest.php index b516df8349..cdd1b53e95 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/RawRangeAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/RawRangeAggregationTest.php @@ -15,7 +15,7 @@ final class RawRangeAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { yield [ new RawRangeAggregation( diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/RawStatsAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/RawStatsAggregationTest.php index 1a0855a433..4310e00fe9 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/RawStatsAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/RawStatsAggregationTest.php @@ -13,7 +13,7 @@ final class RawStatsAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { yield [ new RawStatsAggregation( diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/RawTermAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/RawTermAggregationTest.php index dde41994ea..64c3c1be76 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/RawTermAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/RawTermAggregationTest.php @@ -14,7 +14,7 @@ final class RawTermAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { yield [ new RawTermAggregation( diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/SectionTermAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/SectionTermAggregationTest.php index f89ddc1cb3..44cc3f5142 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/SectionTermAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/SectionTermAggregationTest.php @@ -13,7 +13,7 @@ final class SectionTermAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { $aggregation = new SectionTermAggregation('section'); @@ -27,7 +27,7 @@ public function dataProviderForTestFindContentWithAggregation(): iterable ]); $builder->setEntryMapper([ - $this->getRepository()->getSectionService(), + static::resolveRepository()->getSectionService(), 'loadSectionByIdentifier', ]); diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/SubtreeTermAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/SubtreeTermAggregationTest.php index bbe865891f..dea7b648ff 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/SubtreeTermAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/SubtreeTermAggregationTest.php @@ -13,7 +13,7 @@ final class SubtreeTermAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { $aggregation = new SubtreeTermAggregation('subtree', '/1/5/'); @@ -25,7 +25,7 @@ public function dataProviderForTestFindContentWithAggregation(): iterable ]); $builder->setEntryMapper([ - $this->getRepository()->getLocationService(), + static::resolveRepository()->getLocationService(), 'loadLocation', ]); diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/UserMetadataTermAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/UserMetadataTermAggregationTest.php index 1ace873878..ec8dbf07a1 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/UserMetadataTermAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/UserMetadataTermAggregationTest.php @@ -13,30 +13,30 @@ final class UserMetadataTermAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { - yield '::OWNER' => $this->createOwnerTermAggregationDataSet(); - yield '::GROUP' => $this->createGroupTermAggregationDataSet(); - yield '::MODIFIER' => $this->createModifierTermAggregationDataSet(); + yield '::OWNER' => self::createOwnerTermAggregationDataSet(); + yield '::GROUP' => self::createGroupTermAggregationDataSet(); + yield '::MODIFIER' => self::createModifierTermAggregationDataSet(); } - public function dataProviderForTestFindLocationWithAggregation(): iterable + public static function dataProviderForTestFindLocationWithAggregation(): iterable { - yield from $this->dataProviderForTestFindContentWithAggregation(); + yield from static::dataProviderForTestFindContentWithAggregation(); } - private function createOwnerTermAggregationDataSet(): array + private static function createOwnerTermAggregationDataSet(): array { $aggregation = new UserMetadataTermAggregation('owner', UserMetadataTermAggregation::OWNER); $builder = new TermAggregationDataSetBuilder($aggregation); $builder->setExpectedEntries(['admin' => 18]); - $builder->setEntryMapper([$this->getRepository()->getUserService(), 'loadUserByLogin']); + $builder->setEntryMapper([static::resolveRepository()->getUserService(), 'loadUserByLogin']); return $builder->build(); } - private function createGroupTermAggregationDataSet(): array + private static function createGroupTermAggregationDataSet(): array { $aggregation = new UserMetadataTermAggregation('user_group', UserMetadataTermAggregation::GROUP); @@ -46,18 +46,18 @@ private function createGroupTermAggregationDataSet(): array 14 => 18, 4 => 18, ]); - $builder->setEntryMapper([$this->getRepository()->getUserService(), 'loadUserGroup']); + $builder->setEntryMapper([static::resolveRepository()->getUserService(), 'loadUserGroup']); return $builder->build(); } - private function createModifierTermAggregationDataSet(): array + private static function createModifierTermAggregationDataSet(): array { $aggregation = new UserMetadataTermAggregation('modifier', UserMetadataTermAggregation::MODIFIER); $builder = new TermAggregationDataSetBuilder($aggregation); $builder->setExpectedEntries(['admin' => 18]); - $builder->setEntryMapper([$this->getRepository()->getUserService(), 'loadUserByLogin']); + $builder->setEntryMapper([static::resolveRepository()->getUserService(), 'loadUserByLogin']); return $builder->build(); } diff --git a/tests/integration/Core/Repository/SearchService/Aggregation/VisibilityTermAggregationTest.php b/tests/integration/Core/Repository/SearchService/Aggregation/VisibilityTermAggregationTest.php index 72681f505d..1761531f29 100644 --- a/tests/integration/Core/Repository/SearchService/Aggregation/VisibilityTermAggregationTest.php +++ b/tests/integration/Core/Repository/SearchService/Aggregation/VisibilityTermAggregationTest.php @@ -13,7 +13,7 @@ final class VisibilityTermAggregationTest extends AbstractAggregationTestCase { - public function dataProviderForTestFindContentWithAggregation(): iterable + public static function dataProviderForTestFindContentWithAggregation(): iterable { $aggregation = new VisibilityTermAggregation('visibility'); diff --git a/tests/integration/Core/Repository/SearchService/DeleteTranslationTest.php b/tests/integration/Core/Repository/SearchService/DeleteTranslationTest.php index 404c51d68e..db80a745e9 100644 --- a/tests/integration/Core/Repository/SearchService/DeleteTranslationTest.php +++ b/tests/integration/Core/Repository/SearchService/DeleteTranslationTest.php @@ -15,16 +15,17 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Search\SearchResult; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\LanguageLimitation; use Ibexa\Contracts\Core\Repository\Values\User\User; +use Ibexa\Core\Repository\SearchService; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; /** * Test case for delete content translation with the SearchService. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService - * - * @group integration - * @group search */ +#[CoversClass(SearchService::class)] +#[Group('integration')] +#[Group('search')] final class DeleteTranslationTest extends BaseTestCase { /** diff --git a/tests/integration/Core/Repository/SearchService/RemoteIdIndexingTest.php b/tests/integration/Core/Repository/SearchService/RemoteIdIndexingTest.php index d60f3b1468..55e18c4953 100644 --- a/tests/integration/Core/Repository/SearchService/RemoteIdIndexingTest.php +++ b/tests/integration/Core/Repository/SearchService/RemoteIdIndexingTest.php @@ -12,6 +12,7 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Query; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; +use PHPUnit\Framework\Attributes\DataProvider; final class RemoteIdIndexingTest extends BaseTestCase { @@ -39,10 +40,9 @@ protected function setUp(): void } /** - * @dataProvider providerForTestIndexingRemoteId - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException */ + #[DataProvider('providerForTestIndexingRemoteId')] public function testIndexingRemoteId(Criterion $criterion): void { $repository = $this->getRepository(false); @@ -77,7 +77,7 @@ public function testIndexingRemoteId(Criterion $criterion): void self::assertSame($contentId, $result->searchHits[0]->valueObject->contentInfo->id); } - private function getRemoteIDs(): array + private static function getRemoteIDs(): array { return [ 'md5sum' => 'dec23f2de27399a4c0561187b805aa74', @@ -94,9 +94,9 @@ private function getRemoteIDs(): array * * @return iterable */ - public function providerForTestIndexingRemoteId(): iterable + public static function providerForTestIndexingRemoteId(): iterable { - foreach ($this->getRemoteIDs() as $description => $remoteId) { + foreach (static::getRemoteIDs() as $description => $remoteId) { yield "Content remote ID = {$description}" => [new Criterion\RemoteId($remoteId)]; yield "Location remote ID = {$description}" => [new Criterion\LocationRemoteId($remoteId)]; } diff --git a/tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php b/tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php index 16493dc0e9..04a3fe1a25 100644 --- a/tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php +++ b/tests/integration/Core/Repository/SearchService/SortClause/ContentTranslatedNameTest.php @@ -13,6 +13,7 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Query; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\SortClause; +use PHPUnit\Framework\Attributes\DataProvider; final class ContentTranslatedNameTest extends AbstractSortClauseTestCase { @@ -29,9 +30,8 @@ protected function setUp(): void * @param string[] $values * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\Exception - * - * @dataProvider dataProviderForTestSortingByContentTranslatedName */ + #[DataProvider('dataProviderForTestSortingByContentTranslatedName')] public function testContentSortingByContentTranslatedName( iterable $inputValues, SortClause $sortClause, @@ -58,9 +58,8 @@ public function testContentSortingByContentTranslatedName( * @param string[] $values * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\Exception - * - * @dataProvider dataProviderForTestSortingByContentTranslatedName */ + #[DataProvider('dataProviderForTestSortingByContentTranslatedName')] public function testLocationSortingByContentTranslatedName( iterable $inputValues, SortClause $sortClause, @@ -83,7 +82,7 @@ public function testLocationSortingByContentTranslatedName( $this->assertSearchResultOrderByRemoteId($expectedOrderedRemoteIds, $actualResults); } - public function dataProviderForTestSortingByContentTranslatedName(): iterable + public static function dataProviderForTestSortingByContentTranslatedName(): iterable { $inputValues = [ 'foo' => [ diff --git a/tests/integration/Core/Repository/SearchService/SortClause/ScoreTest.php b/tests/integration/Core/Repository/SearchService/SortClause/ScoreTest.php index ff22fb7dfc..fda70313ab 100644 --- a/tests/integration/Core/Repository/SearchService/SortClause/ScoreTest.php +++ b/tests/integration/Core/Repository/SearchService/SortClause/ScoreTest.php @@ -13,6 +13,7 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Query; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\SortClause; +use PHPUnit\Framework\Attributes\DataProvider; final class ScoreTest extends AbstractSortClauseTestCase { @@ -30,9 +31,8 @@ protected function setUp(): void * @param string[] $values * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\Exception - * - * @dataProvider dataProviderForTestSortingByScore */ + #[DataProvider('dataProviderForTestSortingByScore')] public function testSortingByScore(iterable $inputValues, Query $query, array $expectedOrderedIds): void { $this->createContentForScoreSortTesting($inputValues); @@ -47,7 +47,7 @@ public function testSortingByScore(iterable $inputValues, Query $query, array $e $this->assertSearchResultOrderByRemoteId($expectedOrderedIds, $actualResults); } - public function dataProviderForTestSortingByScore(): iterable + public static function dataProviderForTestSortingByScore(): iterable { // The following input values for test content guarantee predictable scoring $inputValues = ['foo foo', 'foo', 'foo foo foo']; diff --git a/tests/integration/Core/Repository/SearchServiceAuthorizationTest.php b/tests/integration/Core/Repository/SearchServiceAuthorizationTest.php index b6df7f6314..230da5318d 100644 --- a/tests/integration/Core/Repository/SearchServiceAuthorizationTest.php +++ b/tests/integration/Core/Repository/SearchServiceAuthorizationTest.php @@ -10,28 +10,25 @@ use Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException; use Ibexa\Contracts\Core\Repository\Values\Content\Query; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion; +use Ibexa\Core\Repository\SearchService; use Ibexa\Core\Repository\Values\Content\Content; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DependsExternal; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the SearchService. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService - * - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testLoadUser - * - * @group integration - * @group authorization */ +#[CoversClass(SearchService::class)] +#[Group('integration')] +#[Group('authorization')] class SearchServiceAuthorizationTest extends BaseTestCase { /** * Test for the findContent() method but with anonymous user. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() - * - * @depends Ibexa\Tests\Integration\Core\Repository\SearchServiceTest::testFindContentFiltered */ - public function testFindContent() + #[DependsExternal(SearchServiceTest::class, 'testFindContentFiltered')] + public function testFindContent(): void { $repository = $this->getRepository(); $permissionResolver = $repository->getPermissionResolver(); @@ -57,12 +54,9 @@ public function testFindContent() /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() - * - * @depends Ibexa\Tests\Integration\Core\Repository\SearchServiceTest::testFindContentFiltered */ - public function testFindContentEmptyResult() + #[DependsExternal(SearchServiceTest::class, 'testFindContentFiltered')] + public function testFindContentEmptyResult(): void { $repository = $this->getRepository(); $permissionResolver = $repository->getPermissionResolver(); @@ -91,12 +85,9 @@ public function testFindContentEmptyResult() /** * Test for the findSingle() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findSingle() - * - * @depends Ibexa\Tests\Integration\Core\Repository\SearchServiceTest::testFindSingle */ - public function testFindSingleThrowsNotFoundException() + #[DependsExternal(SearchServiceTest::class, 'testFindSingle')] + public function testFindSingleThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -124,12 +115,9 @@ public function testFindSingleThrowsNotFoundException() /** * Test for the findContent() method, verifying disabling permissions. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::findContent($query, $languageFilter, $filterOnUserPermissions) - * - * @depends Ibexa\Tests\Integration\Core\Repository\SearchServiceAuthorizationTest::testFindContent */ - public function testFindContentWithUserPermissionFilter() + #[DependsExternal(self::class, 'testFindContent')] + public function testFindContentWithUserPermissionFilter(): void { $repository = $this->getRepository(); $permissionResolver = $repository->getPermissionResolver(); @@ -163,12 +151,9 @@ public function testFindContentWithUserPermissionFilter() /** * Test for the findSingle() method disabling permission filtering. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::findSingle($query, $languageFilter, $filterOnUserPermissions) - * - * @depends Ibexa\Tests\Integration\Core\Repository\SearchServiceAuthorizationTest::testFindContent */ - public function testFindSingleWithUserPermissionFilter() + #[DependsExternal(self::class, 'testFindContent')] + public function testFindSingleWithUserPermissionFilter(): void { $repository = $this->getRepository(); $permissionResolver = $repository->getPermissionResolver(); @@ -195,12 +180,9 @@ public function testFindSingleWithUserPermissionFilter() /** * Test for the findSingle() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::findSingle($query, $languageFilter, $filterOnUserPermissions) - * - * @depends Ibexa\Tests\Integration\Core\Repository\SearchServiceAuthorizationTest::testFindContent */ - public function testFindSingleThrowsNotFoundExceptionWithUserPermissionFilter() + #[DependsExternal(self::class, 'testFindContent')] + public function testFindSingleThrowsNotFoundExceptionWithUserPermissionFilter(): void { $this->expectException(NotFoundException::class); diff --git a/tests/integration/Core/Repository/SearchServiceBookmarkTest.php b/tests/integration/Core/Repository/SearchServiceBookmarkTest.php index 89e00fe605..44d78391b8 100644 --- a/tests/integration/Core/Repository/SearchServiceBookmarkTest.php +++ b/tests/integration/Core/Repository/SearchServiceBookmarkTest.php @@ -15,6 +15,7 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Search\SearchHit; use Ibexa\Contracts\Core\Repository\Values\Content\Search\SearchResult; use Ibexa\Tests\Integration\Core\RepositorySearchTestCase; +use PHPUnit\Framework\Attributes\DataProvider; final class SearchServiceBookmarkTest extends RepositorySearchTestCase { @@ -55,11 +56,10 @@ protected function setUp(): void } /** - * @dataProvider provideDataForTestCriterion - * * @param array<\Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion> $criteria * @param array $remoteIds */ + #[DataProvider('provideDataForTestCriterion')] public function testCriterion( int $expectedCount, array $criteria, @@ -76,7 +76,7 @@ public function testCriterion( * array<\Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion> * }> */ - public function provideDataForTestCriterion(): iterable + public static function provideDataForTestCriterion(): iterable { yield 'All bookmarked locations' => [ self::ALL_BOOKMARKED_LOCATIONS, diff --git a/tests/integration/Core/Repository/SearchServiceContentNameTest.php b/tests/integration/Core/Repository/SearchServiceContentNameTest.php index 3b781ee59a..879671bd49 100644 --- a/tests/integration/Core/Repository/SearchServiceContentNameTest.php +++ b/tests/integration/Core/Repository/SearchServiceContentNameTest.php @@ -15,6 +15,7 @@ use Ibexa\Contracts\Core\Repository\Values\ContentType\ContentType; use Ibexa\Core\FieldType\TextLine\Value; use Ibexa\Tests\Integration\Core\RepositorySearchTestCase; +use PHPUnit\Framework\Attributes\DataProvider; final class SearchServiceContentNameTest extends RepositorySearchTestCase { @@ -80,13 +81,12 @@ public function testCriterionFindAllContentItems(): void } /** - * @dataProvider provideDataForTestCriterion - * * @param array $expectedContentItemTitles * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidCriterionArgumentException */ + #[DataProvider('provideDataForTestCriterion')] public function testCriterion( Criterion $criterion, ?string $languageCode, @@ -127,17 +127,17 @@ static function (SearchHit $searchHit) use ($languageCode): ?string { * int, * }> */ - public function provideDataForTestCriterion(): iterable + public static function provideDataForTestCriterion(): iterable { yield 'Content items not found' => [ - $this->createContentNameCriterion('foo'), + static::createContentNameCriterion('foo'), self::LANGUAGE_CODE_ENG, [], 0, ]; yield 'Return content items in default language (English) that contain "car" in name' => [ - $this->createContentNameCriterion('*car*'), + static::createContentNameCriterion('*car*'), null, [ self::CAR_ENG, @@ -147,7 +147,7 @@ public function provideDataForTestCriterion(): iterable ]; yield 'Return content item in default language (English) whose name starts with "car"' => [ - $this->createContentNameCriterion('Car*'), + static::createContentNameCriterion('Car*'), null, [ self::CAR_ENG, @@ -156,7 +156,7 @@ public function provideDataForTestCriterion(): iterable ]; yield 'Return content item in English that contain "Spo*t*" in name' => [ - $this->createContentNameCriterion('Spo*t*'), + static::createContentNameCriterion('Spo*t*'), self::LANGUAGE_CODE_ENG, [ self::SPORTS_CAR_ENG, @@ -165,7 +165,7 @@ public function provideDataForTestCriterion(): iterable ]; yield 'Return content item in English with name "sports car"' => [ - $this->createContentNameCriterion('sports car'), + static::createContentNameCriterion('sports car'), self::LANGUAGE_CODE_ENG, [ self::SPORTS_CAR_ENG, @@ -174,7 +174,7 @@ public function provideDataForTestCriterion(): iterable ]; yield 'Return content item in English that contain "**ruc*" in name' => [ - $this->createContentNameCriterion('**ruc*'), + static::createContentNameCriterion('**ruc*'), self::LANGUAGE_CODE_ENG, [ self::TRUCK_ENG, @@ -183,7 +183,7 @@ public function provideDataForTestCriterion(): iterable ]; yield 'Return content item in German that contain "aut*" in name' => [ - $this->createContentNameCriterion('aut*'), + static::createContentNameCriterion('aut*'), self::LANGUAGE_CODE_GER, [ self::CAR_GER, @@ -192,7 +192,7 @@ public function provideDataForTestCriterion(): iterable ]; yield 'Return content items in German that contain "*wagen" in name' => [ - $this->createContentNameCriterion('*wagen'), + static::createContentNameCriterion('*wagen'), self::LANGUAGE_CODE_GER, [ self::SPORTS_CAR_GER, @@ -202,7 +202,7 @@ public function provideDataForTestCriterion(): iterable ]; yield 'Return content item in German with name "lastwagen"' => [ - $this->createContentNameCriterion('lastwagen'), + static::createContentNameCriterion('lastwagen'), self::LANGUAGE_CODE_GER, [ self::TRUCK_GER, @@ -269,7 +269,7 @@ private function loadContentType(string $contentTypeIdentifier): ContentType ->loadContentTypeByIdentifier($contentTypeIdentifier); } - private function createContentNameCriterion(string $value): Criterion + private static function createContentNameCriterion(string $value): Criterion { return new Criterion\ContentName($value); } diff --git a/tests/integration/Core/Repository/SearchServiceFulltextTest.php b/tests/integration/Core/Repository/SearchServiceFulltextTest.php index a1f36d0f81..c6188dae45 100644 --- a/tests/integration/Core/Repository/SearchServiceFulltextTest.php +++ b/tests/integration/Core/Repository/SearchServiceFulltextTest.php @@ -7,7 +7,6 @@ namespace Ibexa\Tests\Integration\Core\Repository; -use Ibexa\Contracts\Core\Repository\SearchService; use Ibexa\Contracts\Core\Repository\Values\Content\Content; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; use Ibexa\Contracts\Core\Repository\Values\Content\Location; @@ -15,17 +14,20 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Query; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Search\SearchResult; +use Ibexa\Core\Repository\SearchService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\Group; use RuntimeException; /** * Test case for full text search in the SearchService. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService - * - * @group integration - * @group search - * @group fulltext */ +#[CoversClass(SearchService::class)] +#[Group('integration')] +#[Group('search')] +#[Group('fulltext')] class SearchServiceFulltextTest extends BaseTestCase { protected function setUp(): void @@ -100,7 +102,7 @@ public function testPrepareContent() * * @see testPrepareContent */ - public function providerForTestFulltextSearchSolr7(): array + public static function providerForTestFulltextSearchSolr7(): array { return [ [ @@ -180,11 +182,9 @@ public function providerForTestFulltextSearchSolr7(): array * @param string $searchString * @param array $expectedKeys * @param array $idMap - * - * @depends testPrepareContent - * - * @dataProvider providerForTestFulltextSearchSolr7 */ + #[Depends('testPrepareContent')] + #[DataProvider('providerForTestFulltextSearchSolr7')] public function testFulltextContentSearchSolr7(string $searchString, array $expectedKeys, array $idMap): void { if (false === $this->isSolrMajorVersionInRange('7.0.0', '8.0.0')) { @@ -211,11 +211,9 @@ private function doTestFulltextContentSearch(string $searchString, array $expect * @param $searchString * @param array $expectedKeys * @param array $idMap - * - * @depends testPrepareContent - * - * @dataProvider providerForTestFulltextSearchSolr7 */ + #[Depends('testPrepareContent')] + #[DataProvider('providerForTestFulltextSearchSolr7')] public function testFulltextLocationSearchSolr7($searchString, array $expectedKeys, array $idMap): void { if (false === $this->isSolrMajorVersionInRange('7.0.0', '8.0.0')) { diff --git a/tests/integration/Core/Repository/SearchServiceImageTest.php b/tests/integration/Core/Repository/SearchServiceImageTest.php index a18344c23e..bede017ec5 100644 --- a/tests/integration/Core/Repository/SearchServiceImageTest.php +++ b/tests/integration/Core/Repository/SearchServiceImageTest.php @@ -16,6 +16,7 @@ use Ibexa\Core\FieldType\Image\Value as ImageValue; use Ibexa\Core\FieldType\TextLine\Value as TextValue; use Ibexa\Tests\Integration\Core\RepositorySearchTestCase; +use PHPUnit\Framework\Attributes\DataProvider; final class SearchServiceImageTest extends RepositorySearchTestCase { @@ -38,10 +39,8 @@ protected function setUp(): void $this->refreshSearch(); } - /** - * @dataProvider provideDataForTestCriterion - * @dataProvider provideInvalidDataForTestCriterion - */ + #[DataProvider('provideDataForTestCriterion')] + #[DataProvider('provideInvalidDataForTestCriterion')] public function testCriterion( int $expectedCount, Query\Criterion $imageCriterion @@ -72,11 +71,11 @@ public function testCriterion( * \Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion * }> */ - public function provideDataForTestCriterion(): iterable + public static function provideDataForTestCriterion(): iterable { yield 'Dimensions' => [ 3, - $this->createDimensionsCriterion( + static::createDimensionsCriterion( 0, 100, 0, @@ -86,57 +85,57 @@ public function provideDataForTestCriterion(): iterable yield 'FileSize - with numeric values from 0 to 1' => [ 3, - $this->createFileSizeCriterion(0, 1), + static::createFileSizeCriterion(0, 1), ]; yield 'FileSize - with numeric string values from 0.0 to 2.5' => [ 3, - $this->createFileSizeCriterion('0.0', '2.5'), + static::createFileSizeCriterion('0.0', '2.5'), ]; yield 'FileSize - with numeric values from 0.0 to 2.5' => [ 3, - $this->createFileSizeCriterion(0.0, 2.5), + static::createFileSizeCriterion(0.0, 2.5), ]; yield 'FileSize - with numeric values 0.0001 to 0.004' => [ 2, - $this->createFileSizeCriterion(0.001, 0.004), + static::createFileSizeCriterion(0.001, 0.004), ]; yield 'FileSize - with values numeric string 0.0003 and numeric 0.3' => [ 1, - $this->createFileSizeCriterion('0.003', 0.3), + static::createFileSizeCriterion('0.003', 0.3), ]; yield 'FileSize - min value' => [ 2, - $this->createFileSizeCriterion('0.0002'), + static::createFileSizeCriterion('0.0002'), ]; yield 'FileSize - max value' => [ 1, - $this->createFileSizeCriterion(null, '0.0003'), + static::createFileSizeCriterion(null, '0.0003'), ]; yield 'Width' => [ 3, - $this->createWidthCriterion(0, 100), + static::createWidthCriterion(0, 100), ]; yield 'Height' => [ 3, - $this->createHeightCriterion(0, 100), + static::createHeightCriterion(0, 100), ]; yield 'MimeType - single' => [ 2, - $this->createMimeTypeCriterion('image/jpeg'), + static::createMimeTypeCriterion('image/jpeg'), ]; yield 'MimeType - multiple' => [ 3, - $this->createMimeTypeCriterion( + static::createMimeTypeCriterion( [ 'image/jpeg', 'image/png', @@ -146,22 +145,22 @@ public function provideDataForTestCriterion(): iterable yield 'Orientation - landscape' => [ 1, - $this->createOrientationCriterion(Orientation::LANDSCAPE), + static::createOrientationCriterion(Orientation::LANDSCAPE), ]; yield 'Orientation - portrait' => [ 1, - $this->createOrientationCriterion(Orientation::PORTRAIT), + static::createOrientationCriterion(Orientation::PORTRAIT), ]; yield 'Orientation - square' => [ 1, - $this->createOrientationCriterion(Orientation::SQUARE), + static::createOrientationCriterion(Orientation::SQUARE), ]; yield 'Orientation - multiple' => [ 3, - $this->createOrientationCriterion( + static::createOrientationCriterion( [ Orientation::LANDSCAPE, Orientation::PORTRAIT, @@ -206,11 +205,11 @@ public function provideDataForTestCriterion(): iterable * \Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion * }> */ - public function provideInvalidDataForTestCriterion(): iterable + public static function provideInvalidDataForTestCriterion(): iterable { yield 'Dimensions - width and height values too large' => [ 0, - $this->createDimensionsCriterion( + static::createDimensionsCriterion( 101, 200, 101, @@ -220,7 +219,7 @@ public function provideInvalidDataForTestCriterion(): iterable yield 'FileSize - size value too large' => [ 0, - $this->createFileSizeCriterion( + static::createFileSizeCriterion( 1, 2 ), @@ -228,22 +227,22 @@ public function provideInvalidDataForTestCriterion(): iterable yield 'Width - width value to large' => [ 0, - $this->createWidthCriterion(101, 200), + static::createWidthCriterion(101, 200), ]; yield 'Height - height value to large' => [ 0, - $this->createHeightCriterion(101, 300), + static::createHeightCriterion(101, 300), ]; yield 'MimeType - invalid single mime type' => [ 0, - $this->createMimeTypeCriterion('image/invalid'), + static::createMimeTypeCriterion('image/invalid'), ]; yield 'MimeType - invalid multiple mime types' => [ 0, - $this->createMimeTypeCriterion( + static::createMimeTypeCriterion( [ 'image/invalid', 'image/gif', @@ -255,7 +254,7 @@ public function provideInvalidDataForTestCriterion(): iterable /** * @param string|array $value */ - private function createMimeTypeCriterion($value): Query\Criterion\Image\MimeType + private static function createMimeTypeCriterion($value): Query\Criterion\Image\MimeType { return new Query\Criterion\Image\MimeType( self::IMAGE_FIELD_DEF_IDENTIFIER, @@ -267,7 +266,7 @@ private function createMimeTypeCriterion($value): Query\Criterion\Image\MimeType * @param numeric|null $min * @param numeric|null $max */ - private function createFileSizeCriterion( + private static function createFileSizeCriterion( $min = 0, $max = null ): Query\Criterion\Image\FileSize { @@ -278,7 +277,7 @@ private function createFileSizeCriterion( ); } - private function createWidthCriterion( + private static function createWidthCriterion( int $min = 0, ?int $max = null ): Query\Criterion\Image\Width { @@ -289,7 +288,7 @@ private function createWidthCriterion( ); } - private function createHeightCriterion( + private static function createHeightCriterion( int $min = 0, ?int $max = null ): Query\Criterion\Image\Height { @@ -300,7 +299,7 @@ private function createHeightCriterion( ); } - private function createDimensionsCriterion( + private static function createDimensionsCriterion( int $minWidth, int $maxWidth, int $minHeight, @@ -324,7 +323,7 @@ private function createDimensionsCriterion( /** * @param string|array $value */ - private function createOrientationCriterion($value): Query\Criterion\Image\Orientation + private static function createOrientationCriterion($value): Query\Criterion\Image\Orientation { return new Query\Criterion\Image\Orientation( self::IMAGE_FIELD_DEF_IDENTIFIER, diff --git a/tests/integration/Core/Repository/SearchServiceLocationTest.php b/tests/integration/Core/Repository/SearchServiceLocationTest.php index 93a52411d5..f902d62e79 100644 --- a/tests/integration/Core/Repository/SearchServiceLocationTest.php +++ b/tests/integration/Core/Repository/SearchServiceLocationTest.php @@ -16,17 +16,19 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Search\SearchHit; use Ibexa\Contracts\Core\Repository\Values\Content\Search\SearchResult; use Ibexa\Contracts\Core\Test\Repository\SetupFactory\Legacy; +use Ibexa\Core\Repository\SearchService; use Ibexa\Core\Repository\Values\Content\Location; use Ibexa\Tests\Solr\SetupFactory\LegacySetupFactory as LegacySolrSetupFactory; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DependsExternal; +use PHPUnit\Framework\Attributes\Group; /** * Test case for Location operations in the SearchService. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService - * - * @group integration - * @group search */ +#[CoversClass(SearchService::class)] +#[Group('integration')] +#[Group('search')] class SearchServiceLocationTest extends BaseTestCase { public const QUERY_CLASS = LocationQuery::class; @@ -190,10 +192,8 @@ protected function createFolderWithNonPrintableUtf8Characters(): Content /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() */ - public function testFieldIsEmptyInLocation() + public function testFieldIsEmptyInLocation(): void { $testContents = $this->createMovieContent(); @@ -223,10 +223,8 @@ public function testFieldIsEmptyInLocation() /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() */ - public function testFieldIsNotEmptyInLocation() + public function testFieldIsNotEmptyInLocation(): void { $testContents = $this->createMovieContent(); @@ -253,10 +251,8 @@ public function testFieldIsNotEmptyInLocation() /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() */ - public function testFieldCollectionContains() + public function testFieldCollectionContains(): void { $testContent = $this->createMultipleCountriesContent(); @@ -283,12 +279,9 @@ public function testFieldCollectionContains() /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() - * - * @depends Ibexa\Tests\Integration\Core\Repository\SearchServiceTest::testFieldCollectionContains */ - public function testFieldCollectionContainsNoMatch() + #[DependsExternal(SearchServiceTest::class, 'testFieldCollectionContains')] + public function testFieldCollectionContainsNoMatch(): void { $this->createMultipleCountriesContent(); $query = new LocationQuery( @@ -309,8 +302,6 @@ public function testFieldCollectionContainsNoMatch() } /** - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException @@ -340,8 +331,6 @@ public function testNonPrintableUtf8Characters(): void } /** - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations - * * @throws \ErrorException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException @@ -375,7 +364,7 @@ public function testEscapedNonPrintableUtf8Characters(): void self::assertEquals(1, $result->totalCount); } - public function testInvalidFieldIdentifierRange() + public function testInvalidFieldIdentifierRange(): void { $this->expectException(InvalidArgumentException::class); @@ -396,7 +385,7 @@ public function testInvalidFieldIdentifierRange() ); } - public function testInvalidFieldIdentifierIn() + public function testInvalidFieldIdentifierIn(): void { $this->expectException(InvalidArgumentException::class); @@ -417,7 +406,7 @@ public function testInvalidFieldIdentifierIn() ); } - public function testFindLocationsWithNonSearchableField() + public function testFindLocationsWithNonSearchableField(): void { $this->expectException(InvalidArgumentException::class); @@ -453,10 +442,8 @@ static function (SearchHit $searchHit) { /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() */ - public function testQueryCustomField() + public function testQueryCustomField(): void { $query = new LocationQuery( [ @@ -484,10 +471,8 @@ public function testQueryCustomField() * This tests explicitly queries the first_name while user is contained in * the last_name of admin and anonymous. This is done to show the custom * copy field working. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() */ - public function testQueryModifiedField() + public function testQueryModifiedField(): void { // Check using get_class since the others extend SetupFactory\Legacy if ($this->getSetupFactory() instanceof Legacy) { @@ -553,12 +538,9 @@ protected function createTestPlaceContentType() /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() - * - * @group maplocation */ - public function testMapLocationDistanceLessThanOrEqual() + #[Group('maplocation')] + public function testMapLocationDistanceLessThanOrEqual(): void { $contentType = $this->createTestPlaceContentType(); @@ -635,12 +617,9 @@ public function testMapLocationDistanceLessThanOrEqual() /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() - * - * @group maplocation */ - public function testMapLocationDistanceGreaterThanOrEqual() + #[Group('maplocation')] + public function testMapLocationDistanceGreaterThanOrEqual(): void { $contentType = $this->createTestPlaceContentType(); @@ -717,12 +696,9 @@ public function testMapLocationDistanceGreaterThanOrEqual() /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() - * - * @group maplocation */ - public function testMapLocationDistanceBetween() + #[Group('maplocation')] + public function testMapLocationDistanceBetween(): void { $contentType = $this->createTestPlaceContentType(); @@ -815,12 +791,9 @@ public function testMapLocationDistanceBetween() /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() - * - * @group maplocation */ - public function testMapLocationDistanceSortAscending() + #[Group('maplocation')] + public function testMapLocationDistanceSortAscending(): void { $contentType = $this->createTestPlaceContentType(); @@ -934,12 +907,9 @@ public function testMapLocationDistanceSortAscending() /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() - * - * @group maplocation */ - public function testMapLocationDistanceSortDescending() + #[Group('maplocation')] + public function testMapLocationDistanceSortDescending(): void { $contentType = $this->createTestPlaceContentType(); @@ -1053,12 +1023,9 @@ public function testMapLocationDistanceSortDescending() /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() - * - * @group maplocation */ - public function testMapLocationDistanceWithCustomField() + #[Group('maplocation')] + public function testMapLocationDistanceWithCustomField(): void { $contentType = $this->createTestPlaceContentType(); @@ -1138,12 +1105,9 @@ public function testMapLocationDistanceWithCustomField() /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() - * - * @group maplocation */ - public function testMapLocationDistanceWithCustomFieldSort() + #[Group('maplocation')] + public function testMapLocationDistanceWithCustomFieldSort(): void { $contentType = $this->createTestPlaceContentType(); @@ -1260,10 +1224,8 @@ public function testMapLocationDistanceWithCustomFieldSort() /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() */ - public function testVisibilityCriterionWithHiddenContent() + public function testVisibilityCriterionWithHiddenContent(): void { $repository = $this->getRepository(); $contentTypeService = $repository->getContentTypeService(); diff --git a/tests/integration/Core/Repository/SearchServiceManyLanguagesTest.php b/tests/integration/Core/Repository/SearchServiceManyLanguagesTest.php index ee7a564612..39c84465b0 100644 --- a/tests/integration/Core/Repository/SearchServiceManyLanguagesTest.php +++ b/tests/integration/Core/Repository/SearchServiceManyLanguagesTest.php @@ -11,11 +11,10 @@ use Exception; use Ibexa\Contracts\Core\Repository\Values\Content\Query; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion; +use PHPUnit\Framework\Attributes\Group; -/** - * @group integration - * @group search - */ +#[Group('integration')] +#[Group('search')] final class SearchServiceManyLanguagesTest extends BaseTestCase { public function testFindContentWithManyLanguages(): void diff --git a/tests/integration/Core/Repository/SearchServiceTest.php b/tests/integration/Core/Repository/SearchServiceTest.php index 40f7d551ed..d200ba856e 100644 --- a/tests/integration/Core/Repository/SearchServiceTest.php +++ b/tests/integration/Core/Repository/SearchServiceTest.php @@ -10,7 +10,6 @@ use function count; use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException; use Ibexa\Contracts\Core\Repository\Exceptions\NotImplementedException; -use Ibexa\Contracts\Core\Repository\SearchService; use Ibexa\Contracts\Core\Repository\Values\Content\Content; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; use Ibexa\Contracts\Core\Repository\Values\Content\Location; @@ -22,18 +21,21 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Search\SearchHit; use Ibexa\Contracts\Core\Repository\Values\Content\Search\SearchResult; use Ibexa\Contracts\Core\Test\Repository\SetupFactory\Legacy; +use Ibexa\Core\Repository\SearchService; use Ibexa\Tests\Solr\SetupFactory\LegacySetupFactory as LegacySolrSetupFactory; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\Group; use ReflectionProperty; use RuntimeException; /** * Test case for operations in the SearchService. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService - * - * @group integration - * @group search */ +#[CoversClass(SearchService::class)] +#[Group('integration')] +#[Group('search')] class SearchServiceTest extends BaseTestCase { public const QUERY_CLASS = Query::class; @@ -46,9 +48,12 @@ class SearchServiceTest extends BaseTestCase self::FIND_LOCATION_METHOD, ]; - public function getFilterContentSearches() + /** + * @return array + */ + public static function getFilterContentSearches(): array { - $fixtureDir = $this->getFixtureDir(); + $fixtureDir = static::getFixtureDir(); return [ 0 => [ @@ -611,9 +616,12 @@ static function ($a, $b): int { ]; } - public function getContentQuerySearches() + /** + * @return array + */ + public static function getContentQuerySearches(): array { - $fixtureDir = $this->getFixtureDir(); + $fixtureDir = static::getFixtureDir(); return [ [ @@ -846,9 +854,12 @@ public function getContentQuerySearches() ]; } - public function getLocationQuerySearches() + /** + * @return array + */ + public static function getLocationQuerySearches(): array { - $fixtureDir = $this->getFixtureDir(); + $fixtureDir = static::getFixtureDir(); return [ [ @@ -918,12 +929,9 @@ public function getLocationQuerySearches() /** * Test for the findContent() method. - * - * @dataProvider getFilterContentSearches - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() */ - public function testFindContentFiltered($queryData, $fixture, $closure = null) + #[DataProvider('getFilterContentSearches')] + public function testFindContentFiltered($queryData, $fixture, $closure = null): void { $query = new Query($queryData); $this->assertQueryFixture($query, $fixture, $closure); @@ -931,12 +939,9 @@ public function testFindContentFiltered($queryData, $fixture, $closure = null) /** * Test for the findContentInfo() method. - * - * @dataProvider getFilterContentSearches - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContentInfo() */ - public function testFindContentInfoFiltered($queryData, $fixture, $closure = null) + #[DataProvider('getFilterContentSearches')] + public function testFindContentInfoFiltered($queryData, $fixture, $closure = null): void { $query = new Query($queryData); $this->assertQueryFixture($query, $fixture, $this->getContentInfoFixtureClosure($closure), true); @@ -944,12 +949,9 @@ public function testFindContentInfoFiltered($queryData, $fixture, $closure = nul /** * Test for the findLocations() method. - * - * @dataProvider getFilterContentSearches - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() */ - public function testFindLocationsContentFiltered($queryData, $fixture, $closure = null) + #[DataProvider('getFilterContentSearches')] + public function testFindLocationsContentFiltered($queryData, $fixture, $closure = null): void { $query = new LocationQuery($queryData); $this->assertQueryFixture($query, $fixture, $closure); @@ -957,12 +959,9 @@ public function testFindLocationsContentFiltered($queryData, $fixture, $closure /** * Test for the findContent() method. - * - * @dataProvider getContentQuerySearches - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() */ - public function testQueryContent($queryData, $fixture, $closure = null) + #[DataProvider('getContentQuerySearches')] + public function testQueryContent($queryData, $fixture, $closure = null): void { $query = new Query($queryData); $this->assertQueryFixture($query, $fixture, $closure); @@ -970,12 +969,9 @@ public function testQueryContent($queryData, $fixture, $closure = null) /** * Test for the findContentInfo() method. - * - * @dataProvider getContentQuerySearches - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() */ - public function testQueryContentInfo($queryData, $fixture, $closure = null) + #[DataProvider('getContentQuerySearches')] + public function testQueryContentInfo($queryData, $fixture, $closure = null): void { $query = new Query($queryData); $this->assertQueryFixture($query, $fixture, $this->getContentInfoFixtureClosure($closure), true); @@ -983,12 +979,9 @@ public function testQueryContentInfo($queryData, $fixture, $closure = null) /** * Test for the findLocations() method. - * - * @dataProvider getContentQuerySearches - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() */ - public function testQueryContentLocations($queryData, $fixture, $closure = null) + #[DataProvider('getContentQuerySearches')] + public function testQueryContentLocations($queryData, $fixture, $closure = null): void { $query = new LocationQuery($queryData); $this->assertQueryFixture($query, $fixture, $closure); @@ -996,18 +989,18 @@ public function testQueryContentLocations($queryData, $fixture, $closure = null) /** * Test for the findLocations() method. - * - * @dataProvider getLocationQuerySearches - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() */ - public function testQueryLocations($queryData, $fixture, $closure = null) + #[DataProvider('getLocationQuerySearches')] + public function testQueryLocations($queryData, $fixture, $closure = null): void { $query = new LocationQuery($queryData); $this->assertQueryFixture($query, $fixture, $closure); } - public function getCaseInsensitiveSearches() + /** + * @return array + */ + public static function getCaseInsensitiveSearches(): array { return [ [ @@ -1045,12 +1038,9 @@ public function getCaseInsensitiveSearches() /** * Test for the findContent() method. - * - * @dataProvider getCaseInsensitiveSearches - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() */ - public function testFindContentFieldFiltersCaseSensitivity($queryData) + #[DataProvider('getCaseInsensitiveSearches')] + public function testFindContentFieldFiltersCaseSensitivity($queryData): void { $query = new Query($queryData); $this->assertQueryFixture( @@ -1061,12 +1051,9 @@ public function testFindContentFieldFiltersCaseSensitivity($queryData) /** * Test for the findLocations() method. - * - * @dataProvider getCaseInsensitiveSearches - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() */ - public function testFindLocationsFieldFiltersCaseSensitivity($queryData) + #[DataProvider('getCaseInsensitiveSearches')] + public function testFindLocationsFieldFiltersCaseSensitivity($queryData): void { $query = new LocationQuery($queryData); $this->assertQueryFixture( @@ -1075,9 +1062,12 @@ public function testFindLocationsFieldFiltersCaseSensitivity($queryData) ); } - public function getRelationFieldFilterSearches() + /** + * @return array + */ + public static function getRelationFieldFilterSearches(): array { - $fixtureDir = $this->getFixtureDir(); + $fixtureDir = static::getFixtureDir(); return [ 0 => [ @@ -1153,7 +1143,7 @@ public function getRelationFieldFilterSearches() * Purely for creating relation data needed for testFindRelationFieldContentInfoFiltered() * and testFindRelationFieldLocationsFiltered(). */ - public function testRelationContentCreation() + public function testRelationContentCreation(): void { $repository = $this->getRepository(); $galleryType = $repository->getContentTypeService()->loadContentTypeByIdentifier('gallery'); @@ -1179,14 +1169,10 @@ public function testRelationContentCreation() /** * Test for FieldRelation using findContentInfo() method. - * - * @dataProvider getRelationFieldFilterSearches - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContentInfo() - * - * @depends testRelationContentCreation */ - public function testFindRelationFieldContentInfoFiltered($queryData, $fixture) + #[Depends('testRelationContentCreation')] + #[DataProvider('getRelationFieldFilterSearches')] + public function testFindRelationFieldContentInfoFiltered($queryData, $fixture): void { $this->getRepository(false); // To make sure repo is setup w/o removing data from getRelationFieldFilterContentSearches $query = new Query($queryData); @@ -1195,21 +1181,17 @@ public function testFindRelationFieldContentInfoFiltered($queryData, $fixture) /** * Test for FieldRelation using findLocations() method. - * - * @dataProvider getRelationFieldFilterSearches - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() - * - * @depends testRelationContentCreation */ - public function testFindRelationFieldLocationsFiltered($queryData, $fixture) + #[Depends('testRelationContentCreation')] + #[DataProvider('getRelationFieldFilterSearches')] + public function testFindRelationFieldLocationsFiltered($queryData, $fixture): void { $this->getRepository(false); // To make sure repo is setup w/o removing data from getRelationFieldFilterContentSearches $query = new LocationQuery($queryData); $this->assertQueryFixture($query, $fixture, null, true, false, false); } - public function testFindSingle() + public function testFindSingle(): void { $repository = $this->getRepository(); $searchService = $repository->getSearchService(); @@ -1226,7 +1208,7 @@ public function testFindSingle() ); } - public function testFindNoPerformCount() + public function testFindNoPerformCount(): void { $repository = $this->getRepository(); $searchService = $repository->getSearchService(); @@ -1251,7 +1233,7 @@ public function testFindNoPerformCount() } } - public function testFindNoPerformCountException() + public function testFindNoPerformCountException(): void { $this->expectException(RuntimeException::class); @@ -1272,7 +1254,7 @@ public function testFindNoPerformCountException() $searchService->findContent($query); } - public function testFindLocationsNoPerformCount() + public function testFindLocationsNoPerformCount(): void { $repository = $this->getRepository(); $searchService = $repository->getSearchService(); @@ -1297,7 +1279,7 @@ public function testFindLocationsNoPerformCount() } } - public function testFindLocationsNoPerformCountException() + public function testFindLocationsNoPerformCountException(): void { $this->expectException(RuntimeException::class); @@ -1445,8 +1427,6 @@ protected function createMultipleCountriesContent() * Test for the findContent() method. * * @return \Ibexa\Contracts\Core\Repository\Values\Content\Content[] - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() */ public function testFieldIsEmpty() { @@ -1478,10 +1458,8 @@ public function testFieldIsEmpty() /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() */ - public function testFieldIsNotEmpty() + public function testFieldIsNotEmpty(): void { $testContents = $this->createMovieContent(); @@ -1507,10 +1485,8 @@ public function testFieldIsNotEmpty() /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() */ - public function testFieldCollectionContains() + public function testFieldCollectionContains(): void { $testContent = $this->createMultipleCountriesContent(); @@ -1537,12 +1513,9 @@ public function testFieldCollectionContains() /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() - * - * @depends testFieldCollectionContains */ - public function testFieldCollectionContainsNoMatch() + #[Depends('testFieldCollectionContains')] + public function testFieldCollectionContainsNoMatch(): void { $this->createMultipleCountriesContent(); $query = new Query( @@ -1562,7 +1535,7 @@ public function testFieldCollectionContainsNoMatch() self::assertEquals(0, $result->totalCount); } - public function testInvalidFieldIdentifierRange() + public function testInvalidFieldIdentifierRange(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Argument \'$criterion->target\' is invalid: No searchable Fields found for the provided Criterion target \'some_hopefully_unknown_field\''); @@ -1584,7 +1557,7 @@ public function testInvalidFieldIdentifierRange() ); } - public function testInvalidFieldIdentifierIn() + public function testInvalidFieldIdentifierIn(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Argument \'$criterion->target\' is invalid: No searchable Fields found for the provided Criterion target \'some_hopefully_unknown_field\''); @@ -1606,7 +1579,7 @@ public function testInvalidFieldIdentifierIn() ); } - public function testFindContentWithNonSearchableField() + public function testFindContentWithNonSearchableField(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Argument \'$criterion->target\' is invalid: No searchable Fields found for the provided Criterion target \'tag_cloud_url\''); @@ -1628,7 +1601,7 @@ public function testFindContentWithNonSearchableField() ); } - public function testSortFieldWithNonSearchableField() + public function testSortFieldWithNonSearchableField(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Argument \'$sortClause->targetData\' is invalid: No searchable Fields found for the provided Sort Clause target \'title\' on \'template_look\''); @@ -1645,7 +1618,7 @@ public function testSortFieldWithNonSearchableField() ); } - public function testSortMapLocationDistanceWithNonSearchableField() + public function testSortMapLocationDistanceWithNonSearchableField(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Argument \'$sortClause->targetData\' is invalid: No searchable Fields found for the provided Sort Clause target \'title\' on \'template_look\''); @@ -1669,7 +1642,7 @@ public function testSortMapLocationDistanceWithNonSearchableField() ); } - public function testFindSingleFailMultiple() + public function testFindSingleFailMultiple(): void { $this->expectException(InvalidArgumentException::class); @@ -1683,7 +1656,7 @@ public function testFindSingleFailMultiple() ); } - public function testFindSingleWithNonSearchableField() + public function testFindSingleWithNonSearchableField(): void { $this->expectException(InvalidArgumentException::class); @@ -1699,9 +1672,12 @@ public function testFindSingleWithNonSearchableField() ); } - public function getSortedContentSearches() + /** + * @return iterable + */ + public static function getSortedContentSearches(): iterable { - $fixtureDir = $this->getFixtureDir(); + $fixtureDir = static::getFixtureDir(); yield [ [ @@ -1854,7 +1830,7 @@ static function (SearchHit $a, SearchHit $b): int { $fixtureDir . 'SortFieldMultipleTypesSliceReverse.php', ]; - if (!$this->isLegacySearchEngineSetup()) { + if (!static::isLegacySearchEngineSetup()) { yield [ [ 'filter' => new Criterion\ContentTypeId(1), @@ -1870,9 +1846,12 @@ static function (SearchHit $a, SearchHit $b): int { } } - public function getSortedLocationSearches() + /** + * @return array + */ + public static function getSortedLocationSearches(): array { - $fixtureDir = $this->getFixtureDir(); + $fixtureDir = static::getFixtureDir(); return [ [ @@ -2024,7 +2003,10 @@ protected function createMultilingualContent( return $content; } - public function providerForTestMultilingualFieldSort() + /** + * @return array + */ + public static function providerForTestMultilingualFieldSort(): array { return [ 0 => [ @@ -2333,21 +2315,21 @@ public function providerForTestMultilingualFieldSort() /** * Test for the findContent() method. * - * @group rrr * - * @dataProvider providerForTestMultilingualFieldSort * * @param array $contentDataList * @param array $languageSettings * @param \Ibexa\Contracts\Core\Repository\Values\Content\Query\SortClause[] $sortClauses * @param array $expected */ + #[Group('rrr')] + #[DataProvider('providerForTestMultilingualFieldSort')] public function testMultilingualFieldSortContent( array $contentDataList, $languageSettings, array $sortClauses, $expected - ) { + ): void { $this->assertMultilingualFieldSort( $contentDataList, $languageSettings, @@ -2359,21 +2341,21 @@ public function testMultilingualFieldSortContent( /** * Test for the findLocations() method. * - * @group rrr * - * @dataProvider providerForTestMultilingualFieldSort * * @param array $contentDataList * @param array $languageSettings * @param \Ibexa\Contracts\Core\Repository\Values\Content\Query\SortClause[] $sortClauses * @param array $expected */ + #[Group('rrr')] + #[DataProvider('providerForTestMultilingualFieldSort')] public function testMultilingualFieldSortLocation( array $contentDataList, $languageSettings, array $sortClauses, $expected - ) { + ): void { $this->assertMultilingualFieldSort( $contentDataList, $languageSettings, @@ -2461,7 +2443,10 @@ protected function assertMultilingualFieldSort( self::assertEquals($expectedIdList, $this->mapResultContentIds($result)); } - public function providerForTestMultilingualFieldFilter() + /** + * @return array + */ + public static function providerForTestMultilingualFieldFilter(): array { return [ 0 => [ @@ -2623,21 +2608,21 @@ public function providerForTestMultilingualFieldFilter() /** * Test for the findContent() method. * - * @group ttt * - * @dataProvider providerForTestMultilingualFieldFilter * * @param array $contentDataList * @param array $languageSettings * @param \Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion $criterion * @param array $expected */ + #[Group('ttt')] + #[DataProvider('providerForTestMultilingualFieldFilter')] public function testMultilingualFieldFilterContent( array $contentDataList, $languageSettings, Criterion $criterion, $expected - ) { + ): void { $this->assertMultilingualFieldFilter( $contentDataList, $languageSettings, @@ -2649,21 +2634,21 @@ public function testMultilingualFieldFilterContent( /** * Test for the findLocations() method. * - * @group ttt * - * @dataProvider providerForTestMultilingualFieldFilter * * @param array $contentDataList * @param array $languageSettings * @param \Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion $criterion * @param array $expected */ + #[Group('ttt')] + #[DataProvider('providerForTestMultilingualFieldFilter')] public function testMultilingualFieldFilterLocation( array $contentDataList, $languageSettings, Criterion $criterion, $expected - ) { + ): void { $this->assertMultilingualFieldFilter( $contentDataList, $languageSettings, @@ -2777,12 +2762,9 @@ static function (SearchHit $searchHit) { /** * Test for the findContent() method. - * - * @dataProvider getSortedContentSearches - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() */ - public function testFindAndSortContent($queryData, $fixture, $closure = null) + #[DataProvider('getSortedContentSearches')] + public function testFindAndSortContent($queryData, $fixture, $closure = null): void { $query = new Query($queryData); $this->assertQueryFixture($query, $fixture, $closure); @@ -2790,12 +2772,9 @@ public function testFindAndSortContent($queryData, $fixture, $closure = null) /** * Test for the findContentInfo() method. - * - * @dataProvider getSortedContentSearches - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContentInfo() */ - public function testFindAndSortContentInfo($queryData, $fixture, $closure = null) + #[DataProvider('getSortedContentSearches')] + public function testFindAndSortContentInfo($queryData, $fixture, $closure = null): void { $query = new Query($queryData); $this->assertQueryFixture($query, $fixture, $this->getContentInfoFixtureClosure($closure), true); @@ -2803,12 +2782,9 @@ public function testFindAndSortContentInfo($queryData, $fixture, $closure = null /** * Test for the findLocations() method. - * - * @dataProvider getSortedContentSearches - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() */ - public function testFindAndSortContentLocations($queryData, $fixture, $closure = null) + #[DataProvider('getSortedContentSearches')] + public function testFindAndSortContentLocations($queryData, $fixture, $closure = null): void { $query = new LocationQuery($queryData); $this->assertQueryFixture($query, $fixture, $closure); @@ -2816,12 +2792,9 @@ public function testFindAndSortContentLocations($queryData, $fixture, $closure = /** * Test for the findLocations() method. - * - * @dataProvider getSortedLocationSearches - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() */ - public function testFindAndSortLocations($queryData, $fixture, $closure = null) + #[DataProvider('getSortedLocationSearches')] + public function testFindAndSortLocations($queryData, $fixture, $closure = null): void { $query = new LocationQuery($queryData); $this->assertQueryFixture($query, $fixture, $closure); @@ -2829,10 +2802,8 @@ public function testFindAndSortLocations($queryData, $fixture, $closure = null) /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() */ - public function testQueryCustomField() + public function testQueryCustomField(): void { $query = new Query( [ @@ -2858,10 +2829,8 @@ public function testQueryCustomField() * This tests explicitely queries the first_name while user is contained in * the last_name of admin and anonymous. This is done to show the custom * copy field working. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() */ - public function testQueryModifiedField() + public function testQueryModifiedField(): void { // Check using get_class since the others extend SetupFactory\Legacy if ($this->getSetupFactory() instanceof Legacy) { @@ -2899,10 +2868,8 @@ public function testQueryModifiedField() * for all Content instances of 'folder' ContentType. Custom sort field is then set * to the index storage name of folder's 'name' field, in order to show the custom * sort field working. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() */ - public function testSortModifiedField() + public function testSortModifiedField(): void { // Check using get_class since the others extend SetupFactory\Legacy if ($this->getSetupFactory() instanceof Legacy) { @@ -2966,12 +2933,9 @@ protected function createTestPlaceContentType() /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() - * - * @group maplocation */ - public function testMapLocationDistanceLessThanOrEqual() + #[Group('maplocation')] + public function testMapLocationDistanceLessThanOrEqual(): void { $contentType = $this->createTestPlaceContentType(); @@ -3047,12 +3011,9 @@ public function testMapLocationDistanceLessThanOrEqual() /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() - * - * @group maplocation */ - public function testMapLocationDistanceGreaterThanOrEqual() + #[Group('maplocation')] + public function testMapLocationDistanceGreaterThanOrEqual(): void { $contentType = $this->createTestPlaceContentType(); @@ -3128,12 +3089,9 @@ public function testMapLocationDistanceGreaterThanOrEqual() /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() - * - * @group maplocation */ - public function testMapLocationDistanceBetween() + #[Group('maplocation')] + public function testMapLocationDistanceBetween(): void { $contentType = $this->createTestPlaceContentType(); @@ -3233,12 +3191,9 @@ public function testMapLocationDistanceBetween() * * Range between 222km and 350km shows the magnitude of error between great-circle * (always very precise) and flat Earth (very imprecise for this use case) models. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() - * - * @group maplocation */ - public function testMapLocationDistanceBetweenPolar() + #[Group('maplocation')] + public function testMapLocationDistanceBetweenPolar(): void { $contentType = $this->createTestPlaceContentType(); @@ -3298,12 +3253,9 @@ public function testMapLocationDistanceBetweenPolar() /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() - * - * @group maplocation */ - public function testMapLocationDistanceSortAscending() + #[Group('maplocation')] + public function testMapLocationDistanceSortAscending(): void { $contentType = $this->createTestPlaceContentType(); @@ -3416,12 +3368,9 @@ public function testMapLocationDistanceSortAscending() /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() - * - * @group maplocation */ - public function testMapLocationDistanceSortDescending() + #[Group('maplocation')] + public function testMapLocationDistanceSortDescending(): void { $contentType = $this->createTestPlaceContentType(); @@ -3534,12 +3483,9 @@ public function testMapLocationDistanceSortDescending() /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() - * - * @group maplocation */ - public function testMapLocationDistanceWithCustomField() + #[Group('maplocation')] + public function testMapLocationDistanceWithCustomField(): void { $contentType = $this->createTestPlaceContentType(); @@ -3618,12 +3564,9 @@ public function testMapLocationDistanceWithCustomField() /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() - * - * @group maplocation */ - public function testMapLocationDistanceWithCustomFieldSort() + #[Group('maplocation')] + public function testMapLocationDistanceWithCustomFieldSort(): void { $contentType = $this->createTestPlaceContentType(); @@ -3739,10 +3682,8 @@ public function testMapLocationDistanceWithCustomFieldSort() /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() */ - public function testFindMainLocation() + public function testFindMainLocation(): void { $plainSiteLocationId = 56; $designLocationId = 58; @@ -3784,10 +3725,8 @@ public function testFindMainLocation() /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() */ - public function testFindNonMainLocation() + public function testFindNonMainLocation(): void { $designLocationId = 58; $partnersContentId = 59; @@ -3828,10 +3767,8 @@ public function testFindNonMainLocation() /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() */ - public function testSortMainLocationAscending() + public function testSortMainLocationAscending(): void { $plainSiteLocationId = 56; $designLocationId = 58; @@ -3871,10 +3808,8 @@ public function testSortMainLocationAscending() /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() */ - public function testSortMainLocationDescending() + public function testSortMainLocationDescending(): void { $plainSiteLocationId = 56; $designLocationId = 58; @@ -3914,10 +3849,8 @@ public function testSortMainLocationDescending() /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() */ - public function testContentWithMultipleLocations() + public function testContentWithMultipleLocations(): void { $repository = $this->getRepository(); $contentService = $repository->getContentService(); @@ -4017,10 +3950,8 @@ protected function createContentForTestUserMetadataGroupHorizontal() /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() */ - public function testUserMetadataGroupHorizontalFilterContent(?string $queryType = null) + public function testUserMetadataGroupHorizontalFilterContent(?string $queryType = null): void { if ($queryType === null) { $queryType = 'filter'; @@ -4096,20 +4027,16 @@ public function testUserMetadataGroupHorizontalFilterContent(?string $queryType /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() */ - public function testUserMetadataGroupHorizontalQueryContent() + public function testUserMetadataGroupHorizontalQueryContent(): void { $this->testUserMetadataGroupHorizontalFilterContent('query'); } /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() */ - public function testUserMetadataGroupHorizontalFilterLocation($queryType = null) + public function testUserMetadataGroupHorizontalFilterLocation($queryType = null): void { if ($queryType === null) { $queryType = 'filter'; @@ -4197,20 +4124,16 @@ public function testUserMetadataGroupHorizontalFilterLocation($queryType = null) /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() */ - public function testUserMetadataGroupHorizontalQueryLocation() + public function testUserMetadataGroupHorizontalQueryLocation(): void { $this->testUserMetadataGroupHorizontalFilterLocation('query'); } /** * Test for FullText on the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() */ - public function testFullTextOnNewContent() + public function testFullTextOnNewContent(): void { $repository = $this->getRepository(); $contentService = $repository->getContentService(); @@ -4248,10 +4171,8 @@ public function testFullTextOnNewContent() /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() */ - public function testLanguageAnalysisSeparateContent() + public function testLanguageAnalysisSeparateContent(): void { self::markTestSkipped('Language analysis is currently not supported'); @@ -4312,10 +4233,8 @@ public function testLanguageAnalysisSeparateContent() /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() */ - public function testLanguageAnalysisSameContent() + public function testLanguageAnalysisSameContent(): void { self::markTestSkipped('Language analysis is currently not supported'); @@ -4362,10 +4281,8 @@ public function testLanguageAnalysisSameContent() /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() */ - public function testLanguageAnalysisSameContentNotFound() + public function testLanguageAnalysisSameContentNotFound(): void { self::markTestSkipped('Language analysis is currently not supported'); @@ -4413,10 +4330,8 @@ public function testLanguageAnalysisSameContentNotFound() /** * Test for the findContent() method searching for content filtered by languages. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent */ - public function testFindContentWithLanguageFilter() + public function testFindContentWithLanguageFilter(): void { $repository = $this->getRepository(); $searchService = $repository->getSearchService(); @@ -4524,13 +4439,12 @@ public function testFulltextComplex() /** * Test for the findContent() method. * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() * - * @depends testFulltextComplex * * @param array $data */ - public function testFulltextContentSearchComplex(array $data) + #[Depends('testFulltextComplex')] + public function testFulltextContentSearchComplex(array $data): void { // Do not initialize from scratch $repository = $this->getRepository(false); @@ -4570,13 +4484,12 @@ public function testFulltextContentSearchComplex(array $data) /** * Test for the findContent() method. * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() * - * @depends testFulltextComplex * * @param array $data */ - public function testFulltextContentTranslationSearch(array $data) + #[Depends('testFulltextComplex')] + public function testFulltextContentTranslationSearch(array $data): void { $criterion = $data[0]; $query = new Query(['query' => $criterion]); @@ -4587,13 +4500,12 @@ public function testFulltextContentTranslationSearch(array $data) /** * Test for the findLocations() method. * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() * - * @depends testFulltextComplex * * @param array $data */ - public function testFulltextLocationSearchComplex(array $data) + #[Depends('testFulltextComplex')] + public function testFulltextLocationSearchComplex(array $data): void { $setupFactory = $this->getSetupFactory(); if ($setupFactory instanceof LegacySolrSetupFactory && getenv('SOLR_VERSION') === '4.10.4') { @@ -4638,12 +4550,11 @@ public function testFulltextLocationSearchComplex(array $data) /** * Test for the findLocations() method. * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() * - * @depends testFulltextComplex * * @param array $data */ + #[Depends('testFulltextComplex')] public function testFulltextLocationTranslationSearch(array $data): void { $criterion = $data[0]; @@ -4852,7 +4763,7 @@ protected function simplifySearchResult(SearchResult $result) * * @return string */ - protected function getFixtureDir(): string + protected static function getFixtureDir(): string { return __DIR__ . '/_fixtures/' . getenv('fixtureDir') . '/'; } @@ -4884,10 +4795,8 @@ private function getContentInfoFixtureClosure($closure = null) * Test searching using Field Criterion where the given Field Identifier exists in * both searchable and non-searchable Fields. * Number of returned results depends on used storage. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() */ - public function testFieldCriterionForContentsWithIdenticalFieldIdentifiers() + public function testFieldCriterionForContentsWithIdenticalFieldIdentifiers(): void { $this->createContentWithFieldType( 'url', @@ -4965,12 +4874,9 @@ private function createContentWithFieldType( * * There is a slight chance when this test could fail, if by some reason, * we got to same _random_ results, or mt_rand() provides same seed for seed-supported DB implementation. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent() - * - * @dataProvider getSeedsForRandomSortClause */ - public function testRandomSortContent(?int $firstSeed, ?int $secondSeed) + #[DataProvider('getSeedsForRandomSortClause')] + public function testRandomSortContent(?int $firstSeed, ?int $secondSeed): void { if ($firstSeed || $secondSeed) { $this->skipIfSeedNotImplemented(); @@ -5011,12 +4917,9 @@ public function testRandomSortContent(?int $firstSeed, ?int $secondSeed) /** * Test for the findLocations() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations() - * - * @dataProvider getSeedsForRandomSortClause */ - public function testRandomSortLocation(?int $firstSeed, ?int $secondSeed) + #[DataProvider('getSeedsForRandomSortClause')] + public function testRandomSortLocation(?int $firstSeed, ?int $secondSeed): void { if ($firstSeed || $secondSeed) { $this->skipIfSeedNotImplemented(); @@ -5055,7 +4958,10 @@ public function testRandomSortLocation(?int $firstSeed, ?int $secondSeed) } } - public function getSeedsForRandomSortClause() + /** + * @return array + */ + public static function getSeedsForRandomSortClause(): array { $randomSeed = mt_rand(); @@ -5214,12 +5120,11 @@ static function (SearchHit $a, SearchHit $b): int { } /** - * @dataProvider providerForTestSortingByNumericFieldsWithValuesOfDifferentLength - * * @param int[] $expectedOrderedIds * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ + #[DataProvider('providerForTestSortingByNumericFieldsWithValuesOfDifferentLength')] public function testSortingByNumericFieldsWithValuesOfDifferentLength( LocationQuery $query, array $expectedOrderedIds @@ -5242,7 +5147,7 @@ static function (SearchHit $searchHit) { self::assertEquals($expectedOrderedIds, $actualIds); } - public function providerForTestSortingByNumericFieldsWithValuesOfDifferentLength(): iterable + public static function providerForTestSortingByNumericFieldsWithValuesOfDifferentLength(): iterable { yield 'Location ID ASC' => [ new LocationQuery( diff --git a/tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php b/tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php index e98c72e722..9a780963ce 100644 --- a/tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php +++ b/tests/integration/Core/Repository/SearchServiceTranslationLanguageFallbackTest.php @@ -13,22 +13,27 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\SortClause; use Ibexa\Contracts\Core\Repository\Values\Content\Search\SearchHit; +use Ibexa\Core\Repository\SearchService; use Ibexa\Tests\Solr\SetupFactory\LegacySetupFactory as LegacySolrSetupFactory; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\Group; use RuntimeException; /** * Test case for field filtering operations in the SearchService. * - * @covers \Ibexa\Contracts\Core\Repository\SearchService * - * @group integration - * @group search - * @group language_fallback * * @template TSearchHitValueObject * * @phpstan-type TIndexMap array{dedicated: string, shared: string, single: string, cloud: string} */ +#[CoversClass(SearchService::class)] +#[Group('integration')] +#[Group('search')] +#[Group('language_fallback')] class SearchServiceTranslationLanguageFallbackTest extends BaseTestCase { public const SETUP_DEDICATED = 'dedicated'; @@ -194,7 +199,10 @@ public function testCreateTestContent() return $this->createTestContent([2, 12]); } - public function providerForTestFind() + /** + * @return array + */ + public static function providerForTestFind(): array { $data = [ 0 => [ @@ -1474,7 +1482,7 @@ public function providerForTestFind() ], ]; - $setupFactory = $this->getSetupFactory(); + $setupFactory = static::resolveSetupFactory(); if ($setupFactory instanceof LegacySolrSetupFactory) { $data = array_merge( @@ -1717,19 +1725,17 @@ protected function getIndexName(array $indexMap): ?string } /** - * @dataProvider providerForTestFind - * - * @depends testCreateTestContent - * * @param array $languageSettings * @param array $contentDataList * @param array $context */ + #[Depends('testCreateTestContent')] + #[DataProvider('providerForTestFind')] public function testFindContent( array $languageSettings, array $contentDataList, array $context - ) { + ): void { /** @var \Ibexa\Contracts\Core\Repository\Repository $repository */ list($repository, $data) = $context; @@ -1768,19 +1774,17 @@ public function testFindContent( } /** - * @dataProvider providerForTestFind - * - * @depends testCreateTestContent - * * @param array $languageSettings * @param array $contentDataList * @param array $context */ + #[Depends('testCreateTestContent')] + #[DataProvider('providerForTestFind')] public function testFindLocationsSingle( array $languageSettings, array $contentDataList, array $context - ) { + ): void { /** @var \Ibexa\Contracts\Core\Repository\Repository $repository */ list($repository, $data) = $context; @@ -1824,19 +1828,17 @@ public function testFindLocationsSingle( } /** - * @dataProvider providerForTestFind - * - * @depends testCreateTestContent - * * @param array $languageSettings * @param array $contentDataList * @param array $context */ + #[Depends('testCreateTestContent')] + #[DataProvider('providerForTestFind')] public function testFindLocationsMultiple( array $languageSettings, array $contentDataList, array $context - ) { + ): void { /** @var \Ibexa\Contracts\Core\Repository\Repository $repository */ list($repository, $data) = $context; @@ -1910,7 +1912,7 @@ private function assertIndexName(array $indexMap, SearchHit $searchHit): void if ($indexName === null) { self::assertNull($searchHit->index); } else { - self::assertRegExp('~^' . $indexName . '$~', (string)$searchHit->index); + self::assertMatchesRegularExpression('~^' . $indexName . '$~', (string)$searchHit->index); } } diff --git a/tests/integration/Core/Repository/SectionServiceAuthorizationTest.php b/tests/integration/Core/Repository/SectionServiceAuthorizationTest.php index 1eae0aea85..7e43da2b8f 100644 --- a/tests/integration/Core/Repository/SectionServiceAuthorizationTest.php +++ b/tests/integration/Core/Repository/SectionServiceAuthorizationTest.php @@ -9,23 +9,22 @@ use Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException; use Ibexa\Contracts\Core\Repository\Values\User\Limitation; +use Ibexa\Core\Repository\SectionService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the SectionService using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService - * - * @group integration - * @group authorization */ +#[CoversClass(SectionService::class)] +#[Group('integration')] +#[Group('authorization')] class SectionServiceAuthorizationTest extends BaseTestCase { /** * Test for the createSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::createSection() */ - public function testCreateSectionThrowsUnauthorizedException() + public function testCreateSectionThrowsUnauthorizedException(): void { $repository = $this->getRepository(); @@ -52,10 +51,8 @@ public function testCreateSectionThrowsUnauthorizedException() /** * Test for the loadSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::loadSection() */ - public function testLoadSectionThrowsUnauthorizedException() + public function testLoadSectionThrowsUnauthorizedException(): void { $repository = $this->getRepository(); @@ -84,10 +81,8 @@ public function testLoadSectionThrowsUnauthorizedException() /** * Test for the updateSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::updateSection() */ - public function testUpdateSectionThrowsUnauthorizedException() + public function testUpdateSectionThrowsUnauthorizedException(): void { $repository = $this->getRepository(); @@ -120,10 +115,8 @@ public function testUpdateSectionThrowsUnauthorizedException() /** * Test for the loadSections() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::loadSections() */ - public function testLoadSectionsLoadsEmptyListForAnonymousUser() + public function testLoadSectionsLoadsEmptyListForAnonymousUser(): void { $repository = $this->getRepository(); @@ -157,10 +150,8 @@ public function testLoadSectionsLoadsEmptyListForAnonymousUser() /** * Test for the loadSections() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::loadSections() */ - public function testLoadSectionFiltersSections() + public function testLoadSectionFiltersSections(): void { $repository = $this->getRepository(); @@ -202,10 +193,8 @@ public function testLoadSectionFiltersSections() /** * Test for the loadSectionByIdentifier() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::loadSectionByIdentifier() */ - public function testLoadSectionByIdentifierThrowsUnauthorizedException() + public function testLoadSectionByIdentifierThrowsUnauthorizedException(): void { $repository = $this->getRepository(); @@ -234,10 +223,8 @@ public function testLoadSectionByIdentifierThrowsUnauthorizedException() /** * Test for the assignSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::assignSection() */ - public function testAssignSectionThrowsUnauthorizedException() + public function testAssignSectionThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -276,10 +263,8 @@ public function testAssignSectionThrowsUnauthorizedException() /** * Test for the deleteSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::deleteSection() */ - public function testDeleteSectionThrowsUnauthorizedException() + public function testDeleteSectionThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/SectionServiceTest.php b/tests/integration/Core/Repository/SectionServiceTest.php index d458b2ac36..f12e4d0e99 100644 --- a/tests/integration/Core/Repository/SectionServiceTest.php +++ b/tests/integration/Core/Repository/SectionServiceTest.php @@ -15,15 +15,17 @@ use Ibexa\Contracts\Core\Repository\Values\Content\SectionCreateStruct; use Ibexa\Contracts\Core\Repository\Values\Content\SectionUpdateStruct; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\SectionLimitation; +use Ibexa\Core\Repository\SectionService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the SectionService using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService - * - * @group integration - * @group section */ +#[CoversClass(SectionService::class)] +#[Group('integration')] +#[Group('section')] class SectionServiceTest extends BaseTestCase { private const SECTION_UNIQUE_KEY = 'uniqueKey'; @@ -74,10 +76,8 @@ protected function setUp(): void /** * Test for the newSectionCreateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::newSectionCreateStruct() */ - public function testNewSectionCreateStruct() + public function testNewSectionCreateStruct(): void { $repository = $this->getRepository(); @@ -92,12 +92,9 @@ public function testNewSectionCreateStruct() /** * Test for the createSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::createSection() - * - * @depends testNewSectionCreateStruct */ - public function testCreateSection() + #[Depends('testNewSectionCreateStruct')] + public function testCreateSection(): void { $repository = $this->getRepository(); @@ -116,12 +113,9 @@ public function testCreateSection() /** * Test for the createSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::createSection() - * - * @depends testNewSectionCreateStruct */ - public function testCreateSectionForUserWithSectionLimitation() + #[Depends('testNewSectionCreateStruct')] + public function testCreateSectionForUserWithSectionLimitation(): void { $repository = $this->getRepository(); @@ -155,12 +149,9 @@ public function testCreateSectionForUserWithSectionLimitation() /** * Test for the createSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::createSection() - * - * @depends testCreateSection */ - public function testCreateSectionThrowsInvalidArgumentException() + #[Depends('testCreateSection')] + public function testCreateSectionThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -186,12 +177,9 @@ public function testCreateSectionThrowsInvalidArgumentException() /** * Test for the loadSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::loadSection() - * - * @depends testCreateSection */ - public function testLoadSection() + #[Depends('testCreateSection')] + public function testLoadSection(): void { $repository = $this->getRepository(); @@ -209,10 +197,8 @@ public function testLoadSection() /** * Test for the loadSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::loadSection() */ - public function testLoadSectionThrowsNotFoundException() + public function testLoadSectionThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -230,10 +216,8 @@ public function testLoadSectionThrowsNotFoundException() /** * Test for the newSectionUpdateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::newSectionUpdateStruct() */ - public function testNewSectionUpdateStruct() + public function testNewSectionUpdateStruct(): void { $repository = $this->getRepository(); @@ -248,14 +232,11 @@ public function testNewSectionUpdateStruct() /** * Test for the updateSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::updateSection() - * - * @depends testCreateSection - * @depends testLoadSection - * @depends testNewSectionUpdateStruct */ - public function testUpdateSection() + #[Depends('testCreateSection')] + #[Depends('testLoadSection')] + #[Depends('testNewSectionUpdateStruct')] + public function testUpdateSection(): void { $repository = $this->getRepository(); @@ -286,14 +267,11 @@ public function testUpdateSection() /** * Test for the updateSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::updateSection() - * - * @depends testCreateSection - * @depends testLoadSection - * @depends testNewSectionUpdateStruct */ - public function testUpdateSectionForUserWithSectionLimitation() + #[Depends('testCreateSection')] + #[Depends('testLoadSection')] + #[Depends('testNewSectionUpdateStruct')] + public function testUpdateSectionForUserWithSectionLimitation(): void { $repository = $this->getRepository(); $administratorUserId = $this->generateId('user', 14); @@ -344,12 +322,9 @@ public function testUpdateSectionForUserWithSectionLimitation() /** * Test for the updateSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::updateSection() - * - * @depends testUpdateSection */ - public function testUpdateSectionKeepsSectionIdentifierOnNameUpdate() + #[Depends('testUpdateSection')] + public function testUpdateSectionKeepsSectionIdentifierOnNameUpdate(): void { $repository = $this->getRepository(); @@ -372,12 +347,9 @@ public function testUpdateSectionKeepsSectionIdentifierOnNameUpdate() /** * Test for the updateSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::updateSection() - * - * @depends testUpdateSection */ - public function testUpdateSectionWithSectionIdentifierOnNameUpdate() + #[Depends('testUpdateSection')] + public function testUpdateSectionWithSectionIdentifierOnNameUpdate(): void { $repository = $this->getRepository(); @@ -403,12 +375,9 @@ public function testUpdateSectionWithSectionIdentifierOnNameUpdate() /** * Test for the updateSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::updateSection() - * - * @depends testUpdateSection */ - public function testUpdateSectionKeepsSectionNameOnIdentifierUpdate() + #[Depends('testUpdateSection')] + public function testUpdateSectionKeepsSectionNameOnIdentifierUpdate(): void { $repository = $this->getRepository(); @@ -432,12 +401,9 @@ public function testUpdateSectionKeepsSectionNameOnIdentifierUpdate() /** * Test for the updateSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::updateSection() - * - * @depends testUpdateSection */ - public function testUpdateSectionThrowsInvalidArgumentException() + #[Depends('testUpdateSection')] + public function testUpdateSectionThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -470,12 +436,9 @@ public function testUpdateSectionThrowsInvalidArgumentException() /** * Test for the loadSections() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::loadSections() - * - * @depends testCreateSection */ - public function testLoadSections() + #[Depends('testCreateSection')] + public function testLoadSections(): void { $repository = $this->getRepository(); @@ -493,12 +456,9 @@ public function testLoadSections() /** * Test for the loadSections() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::loadSections() - * - * @depends testCreateSection */ - public function testLoadSectionsReturnsDefaultSectionsByDefault() + #[Depends('testCreateSection')] + public function testLoadSectionsReturnsDefaultSectionsByDefault(): void { $repository = $this->getRepository(); @@ -555,12 +515,9 @@ public function testLoadSectionsReturnsDefaultSectionsByDefault() /** * Test for the loadSectionByIdentifier() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::loadSectionByIdentifier() - * - * @depends testCreateSection */ - public function testLoadSectionByIdentifier() + #[Depends('testCreateSection')] + public function testLoadSectionByIdentifier(): void { $repository = $this->getRepository(); @@ -581,10 +538,8 @@ public function testLoadSectionByIdentifier() /** * Test for the loadSectionByIdentifier() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::loadSectionByIdentifier() */ - public function testLoadSectionByIdentifierThrowsNotFoundException() + public function testLoadSectionByIdentifierThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -600,10 +555,8 @@ public function testLoadSectionByIdentifierThrowsNotFoundException() /** * Test for the countAssignedContents() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::countAssignedContents() */ - public function testCountAssignedContents() + public function testCountAssignedContents(): void { $repository = $this->getRepository(); @@ -629,10 +582,8 @@ public function testCountAssignedContents() /** * Test for the isSectionUsed() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::isSectionUsed() */ - public function testIsSectionUsed() + public function testIsSectionUsed(): void { $repository = $this->getRepository(); @@ -658,12 +609,9 @@ public function testIsSectionUsed() /** * Test for the assignSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::assignSection() - * - * @depends testCountAssignedContents */ - public function testAssignSection() + #[Depends('testCountAssignedContents')] + public function testAssignSection(): void { $repository = $this->getRepository(); $sectionService = $repository->getSectionService(); @@ -716,12 +664,9 @@ public function testAssignSection() /** * Test for the assignSectionToSubtree() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::assignSectionToSubtree() - * - * @depends testCreateSection */ - public function testAssignSectionToSubtree() + #[Depends('testCreateSection')] + public function testAssignSectionToSubtree(): void { $repository = $this->getRepository(); $sectionService = $repository->getSectionService(); @@ -769,12 +714,9 @@ public function testAssignSectionToSubtree() /** * Test for the countAssignedContents() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::countAssignedContents() - * - * @depends testCreateSection */ - public function testCountAssignedContentsReturnsZeroByDefault() + #[Depends('testCreateSection')] + public function testCountAssignedContentsReturnsZeroByDefault(): void { $repository = $this->getRepository(); @@ -796,12 +738,9 @@ public function testCountAssignedContentsReturnsZeroByDefault() /** * Test for the isSectionUsed() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::isSectionUsed() - * - * @depends testCreateSection */ - public function testIsSectionUsedReturnsZeroByDefault() + #[Depends('testCreateSection')] + public function testIsSectionUsedReturnsZeroByDefault(): void { $repository = $this->getRepository(); @@ -823,12 +762,9 @@ public function testIsSectionUsedReturnsZeroByDefault() /** * Test for the deleteSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::deleteSection() - * - * @depends testLoadSections */ - public function testDeleteSection() + #[Depends('testLoadSections')] + public function testDeleteSection(): void { $repository = $this->getRepository(); @@ -850,12 +786,9 @@ public function testDeleteSection() /** * Test for the deleteSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::deleteSection() - * - * @depends testDeleteSection */ - public function testDeleteSectionThrowsNotFoundException() + #[Depends('testDeleteSection')] + public function testDeleteSectionThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -880,12 +813,9 @@ public function testDeleteSectionThrowsNotFoundException() /** * Test for the deleteSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::deleteSection() - * - * @depends testAssignSection */ - public function testDeleteSectionThrowsBadStateException() + #[Depends('testAssignSection')] + public function testDeleteSectionThrowsBadStateException(): void { $this->expectException(BadStateException::class); @@ -918,13 +848,10 @@ public function testDeleteSectionThrowsBadStateException() /** * Test for the createSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::createSection() - * - * @depends testCreateSection - * @depends testLoadSectionByIdentifier */ - public function testCreateSectionInTransactionWithRollback() + #[Depends('testCreateSection')] + #[Depends('testLoadSectionByIdentifier')] + public function testCreateSectionInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -964,13 +891,10 @@ public function testCreateSectionInTransactionWithRollback() /** * Test for the createSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::createSection() - * - * @depends testCreateSection - * @depends testLoadSectionByIdentifier */ - public function testCreateSectionInTransactionWithCommit() + #[Depends('testCreateSection')] + #[Depends('testLoadSectionByIdentifier')] + public function testCreateSectionInTransactionWithCommit(): void { $repository = $this->getRepository(); @@ -1006,13 +930,10 @@ public function testCreateSectionInTransactionWithCommit() /** * Test for the createSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::createSection() - * - * @depends testUpdateSection - * @depends testLoadSectionByIdentifier */ - public function testUpdateSectionInTransactionWithRollback() + #[Depends('testUpdateSection')] + #[Depends('testLoadSectionByIdentifier')] + public function testUpdateSectionInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -1050,13 +971,10 @@ public function testUpdateSectionInTransactionWithRollback() /** * Test for the createSection() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SectionService::createSection() - * - * @depends testUpdateSection - * @depends testLoadSectionByIdentifier */ - public function testUpdateSectionInTransactionWithCommit() + #[Depends('testUpdateSection')] + #[Depends('testLoadSectionByIdentifier')] + public function testUpdateSectionInTransactionWithCommit(): void { $repository = $this->getRepository(); diff --git a/tests/integration/Core/Repository/SettingServiceTest.php b/tests/integration/Core/Repository/SettingServiceTest.php index 80f4605e58..f00c7ac482 100644 --- a/tests/integration/Core/Repository/SettingServiceTest.php +++ b/tests/integration/Core/Repository/SettingServiceTest.php @@ -12,15 +12,17 @@ use Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException; use Ibexa\Contracts\Core\Repository\SettingService; use Ibexa\Contracts\Core\Repository\Values\Setting\Setting; +use Ibexa\Core\Repository\SettingService as CoveredSettingService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the SettingService using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\SettingService - * - * @group integration - * @group setting */ +#[CoversClass(CoveredSettingService::class)] +#[Group('integration')] +#[Group('setting')] final class SettingServiceTest extends BaseTestCase { /** @var \Ibexa\Contracts\Core\Repository\PermissionResolver */ @@ -46,11 +48,7 @@ protected function setUp(): void $this->permissionResolver = $repository->getPermissionResolver(); } - /** - * @covers \Ibexa\Contracts\Core\Repository\SettingService::createSetting() - * - * @dataProvider dataProviderForCreateSetting - */ + #[DataProvider('dataProviderForCreateSetting')] public function testCreateSetting(string $identifier, $value): void { $settingService = $this->getSettingService(); @@ -69,7 +67,7 @@ public function testCreateSetting(string $identifier, $value): void ]), $setting); } - public function dataProviderForCreateSetting(): iterable + public static function dataProviderForCreateSetting(): iterable { yield 'null' => [ 'example_null', @@ -107,9 +105,6 @@ public function dataProviderForCreateSetting(): iterable ]; } - /** - * @covers \Ibexa\Contracts\Core\Repository\SettingService::createSetting() - */ public function testCreateSettingThrowsInvalidArgumentException(): void { $settingService = $this->getSettingService(); @@ -131,9 +126,6 @@ public function testCreateSettingThrowsInvalidArgumentException(): void $settingService->createSetting($settingCreateSecond); } - /** - * @covers \Ibexa\Contracts\Core\Repository\SettingService::loadSetting() - */ public function testLoadSetting(): void { $settingService = $this->getSettingService(); @@ -149,9 +141,6 @@ public function testLoadSetting(): void self::assertEquals('test_value', $setting->value); } - /** - * @covers \Ibexa\Contracts\Core\Repository\SettingService::loadSetting() - */ public function testLoadSettingThrowsNotFoundException(): void { $settingService = $this->getSettingService(); @@ -161,9 +150,6 @@ public function testLoadSettingThrowsNotFoundException(): void $settingService->loadSetting('unknown_group', 'unknown_identifier'); } - /** - * @covers \Ibexa\Contracts\Core\Repository\SettingService::updateSetting() - */ public function testUpdateSetting(): void { $settingService = $this->getSettingService(); @@ -184,9 +170,6 @@ public function testUpdateSetting(): void self::assertEquals('updated_value', $updatedSetting->value); } - /** - * @covers \Ibexa\Contracts\Core\Repository\SettingService::deleteSetting() - */ public function testDeleteSetting(): void { $settingService = $this->getSettingService(); @@ -204,9 +187,6 @@ public function testDeleteSetting(): void $settingService->loadSetting('delete_group', 'delete_identifier'); } - /** - * @covers \Ibexa\Contracts\Core\Repository\SettingService::deleteSetting() - */ public function testDeleteSettingThrowsNotFoundException(): void { $settingService = $this->getSettingService(); diff --git a/tests/integration/Core/Repository/TokenServiceTest.php b/tests/integration/Core/Repository/TokenServiceTest.php index 0b723c36e4..67b0b4e28f 100644 --- a/tests/integration/Core/Repository/TokenServiceTest.php +++ b/tests/integration/Core/Repository/TokenServiceTest.php @@ -12,10 +12,11 @@ use Ibexa\Contracts\Core\Repository\Values\Token\Token; use Ibexa\Contracts\Core\Test\IbexaKernelTestCase; use Ibexa\Core\Base\Exceptions\TokenLengthException; +use Ibexa\Core\Repository\TokenService as CoveredTokenService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; -/** - * @covers \Ibexa\Core\Repository\TokenService - */ +#[CoversClass(CoveredTokenService::class)] final class TokenServiceTest extends IbexaKernelTestCase { private const TOKEN_TYPE = 'foo'; @@ -35,10 +36,9 @@ protected function setUp(): void } /** - * @dataProvider provideTokenData - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ + #[DataProvider('provideTokenData')] public function testGenerateToken( string $type, int $tll, @@ -72,10 +72,9 @@ public function testGenerateTokenThrowsTokenLengthException(): void } /** - * @dataProvider provideDataForTestCheckToken - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ + #[DataProvider('provideDataForTestCheckToken')] public function testCheckExistingToken( string $type, int $tll, @@ -104,10 +103,9 @@ public function testCheckNotExistentToken(): void } /** - * @dataProvider provideTokenData - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ + #[DataProvider('provideTokenData')] public function testGetToken( string $type, int $tll, @@ -225,7 +223,7 @@ public function testDeleteToken(): void * ?int * }> */ - public function provideTokenData(): iterable + public static function provideTokenData(): iterable { yield 'Token with default length 64 and custom identifier' => [ self::TOKEN_TYPE, @@ -255,7 +253,7 @@ public function provideTokenData(): iterable * ?string * }> */ - public function provideDataForTestCheckToken(): iterable + public static function provideDataForTestCheckToken(): iterable { yield 'Token with identifier' => [ self::TOKEN_TYPE, diff --git a/tests/integration/Core/Repository/TrashServiceAuthorizationTest.php b/tests/integration/Core/Repository/TrashServiceAuthorizationTest.php index c86cb615f5..e729a011dc 100644 --- a/tests/integration/Core/Repository/TrashServiceAuthorizationTest.php +++ b/tests/integration/Core/Repository/TrashServiceAuthorizationTest.php @@ -11,27 +11,26 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Location; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\LanguageLimitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\ObjectStateLimitation; -use Ibexa\Core\Repository\TrashService; +use Ibexa\Core\Repository\TrashService as CoveredTrashService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\DependsExternal; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the TrashService using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\TrashService - * - * @group integration - * @group authorization */ +#[CoversClass(CoveredTrashService::class)] +#[Group('integration')] +#[Group('authorization')] class TrashServiceAuthorizationTest extends BaseTrashServiceTestCase { /** * Test for the loadTrashItem() method. - * - * @covers \Ibexa\Contracts\Core\Repository\TrashService::loadTrashItem() - * - * @depends Ibexa\Tests\Integration\Core\Repository\TrashServiceTest::testLoadTrashItem - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testLoadUser */ - public function testLoadTrashItemThrowsUnauthorizedException() + #[DependsExternal(TrashServiceTest::class, 'testLoadTrashItem')] + #[DependsExternal(UserServiceTest::class, 'testLoadUser')] + public function testLoadTrashItemThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -57,10 +56,8 @@ public function testLoadTrashItemThrowsUnauthorizedException() /** * Test for the trash() method without proper permissions. - * - * @covers \Ibexa\Contracts\Core\Repository\TrashService::trash */ - public function testTrashThrowsUnauthorizedException() + public function testTrashThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); $this->expectExceptionMessage('The User does not have the \'remove\' \'content\' permission'); @@ -83,8 +80,6 @@ public function testTrashThrowsUnauthorizedException() /** * Test for the trash() method without proper permissions. - * - * @covers \Ibexa\Contracts\Core\Repository\TrashService::trash */ public function testTrashThrowsUnauthorizedExceptionWithLanguageLimitation(): void { @@ -118,12 +113,9 @@ public function testTrashThrowsUnauthorizedExceptionWithLanguageLimitation(): vo /** * Test for the trash() method with proper minimal permission set. - * - * @depends testTrashThrowsUnauthorizedException - * - * @covers \Ibexa\Contracts\Core\Repository\TrashService::trash */ - public function testTrashRequiresContentRemovePolicy() + #[Depends('testTrashThrowsUnauthorizedException')] + public function testTrashRequiresContentRemovePolicy(): void { $repository = $this->getRepository(); $trashService = $repository->getTrashService(); @@ -147,13 +139,10 @@ public function testTrashRequiresContentRemovePolicy() /** * Test for the recover() method. - * - * @covers \Ibexa\Contracts\Core\Repository\TrashService::recover() - * - * @depends Ibexa\Tests\Integration\Core\Repository\TrashServiceTest::testRecover - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testLoadUser */ - public function testRecoverThrowsUnauthorizedException() + #[DependsExternal(TrashServiceTest::class, 'testRecover')] + #[DependsExternal(UserServiceTest::class, 'testLoadUser')] + public function testRecoverThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -179,13 +168,10 @@ public function testRecoverThrowsUnauthorizedException() /** * Test for the recover() method. - * - * @covers \Ibexa\Contracts\Core\Repository\TrashService::recover($trashItem, $newParentLocation) - * - * @depends Ibexa\Tests\Integration\Core\Repository\TrashServiceTest::testRecover - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testLoadUser */ - public function testRecoverThrowsUnauthorizedExceptionWithNewParentLocationParameter() + #[DependsExternal(TrashServiceTest::class, 'testRecover')] + #[DependsExternal(UserServiceTest::class, 'testLoadUser')] + public function testRecoverThrowsUnauthorizedExceptionWithNewParentLocationParameter(): void { $this->expectException(UnauthorizedException::class); @@ -219,13 +205,10 @@ public function testRecoverThrowsUnauthorizedExceptionWithNewParentLocationParam /** * Test for the emptyTrash() method. - * - * @covers \Ibexa\Contracts\Core\Repository\TrashService::emptyTrash() - * - * @depends Ibexa\Tests\Integration\Core\Repository\TrashServiceTest::testEmptyTrash - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testLoadUser */ - public function testEmptyTrashThrowsUnauthorizedException() + #[DependsExternal(TrashServiceTest::class, 'testEmptyTrash')] + #[DependsExternal(UserServiceTest::class, 'testLoadUser')] + public function testEmptyTrashThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -251,13 +234,10 @@ public function testEmptyTrashThrowsUnauthorizedException() /** * Test for the deleteTrashItem() method. - * - * @covers \Ibexa\Contracts\Core\Repository\TrashService::deleteTrashItem() - * - * @depends Ibexa\Tests\Integration\Core\Repository\TrashServiceTest::testDeleteTrashItem - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testLoadUser */ - public function testDeleteTrashItemThrowsUnauthorizedException() + #[DependsExternal(TrashServiceTest::class, 'testDeleteTrashItem')] + #[DependsExternal(UserServiceTest::class, 'testLoadUser')] + public function testDeleteTrashItemThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -281,7 +261,7 @@ public function testDeleteTrashItemThrowsUnauthorizedException() /* END: Use Case */ } - public function testTrashRequiresPremissionsToRemoveAllSubitems() + public function testTrashRequiresPremissionsToRemoveAllSubitems(): void { $this->createRoleWithPolicies('Publisher', [ ['module' => 'content', 'function' => 'read'], diff --git a/tests/integration/Core/Repository/TrashServiceTest.php b/tests/integration/Core/Repository/TrashServiceTest.php index 226b74e845..d17ba89f04 100644 --- a/tests/integration/Core/Repository/TrashServiceTest.php +++ b/tests/integration/Core/Repository/TrashServiceTest.php @@ -22,25 +22,28 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Trash\SearchResult; use Ibexa\Contracts\Core\Repository\Values\Content\TrashItem as APITrashItem; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\SubtreeLimitation; +use Ibexa\Core\Repository\TrashService; use Ibexa\Core\Repository\Values\Content\Location; use Ibexa\Core\Repository\Values\Content\TrashItem; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\DependsExternal; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the TrashService using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\TrashService - * - * @group integration - * @group trash */ +#[CoversClass(TrashService::class)] +#[Group('integration')] +#[Group('trash')] class TrashServiceTest extends BaseTrashServiceTestCase { /** * Test for the trash() method. - * - * @depends Ibexa\Tests\Integration\Core\Repository\LocationServiceTest::testLoadLocationByRemoteId */ - public function testTrash() + #[DependsExternal(LocationServiceTest::class, 'testLoadLocationByRemoteId')] + public function testTrash(): void { /* BEGIN: Use Case */ $trashItem = $this->createTrashItem(); @@ -54,10 +57,9 @@ public function testTrash() /** * Test for the trash() method. - * - * @depends testTrash */ - public function testTrashSetsExpectedTrashItemProperties() + #[Depends('testTrash')] + public function testTrashSetsExpectedTrashItemProperties(): void { $repository = $this->getRepository(); @@ -87,10 +89,9 @@ public function testTrashSetsExpectedTrashItemProperties() /** * Test for the trash() method. - * - * @depends testTrash */ - public function testTrashRemovesLocationFromMainStorage() + #[Depends('testTrash')] + public function testTrashRemovesLocationFromMainStorage(): void { $this->expectException(NotFoundException::class); @@ -112,10 +113,9 @@ public function testTrashRemovesLocationFromMainStorage() /** * Test for the trash() method. - * - * @depends testTrash */ - public function testTrashRemovesChildLocationsFromMainStorage() + #[Depends('testTrash')] + public function testTrashRemovesChildLocationsFromMainStorage(): void { $repository = $this->getRepository(); @@ -147,10 +147,9 @@ public function testTrashRemovesChildLocationsFromMainStorage() /** * Test for the trash() method. - * - * @depends testTrash */ - public function testTrashDecrementsChildCountOnParentLocation() + #[Depends('testTrash')] + public function testTrashDecrementsChildCountOnParentLocation(): void { $repository = $this->getRepository(); $locationService = $repository->getLocationService(); @@ -174,7 +173,7 @@ public function testTrashDecrementsChildCountOnParentLocation() /** * Test sending a location to trash updates Content mainLocation. */ - public function testTrashUpdatesMainLocation() + public function testTrashUpdatesMainLocation(): void { $repository = $this->getRepository(); $contentService = $repository->getContentService(); @@ -202,7 +201,7 @@ public function testTrashUpdatesMainLocation() /** * Test sending a location to trash. */ - public function testTrashReturnsNull() + public function testTrashReturnsNull(): void { $repository = $this->getRepository(); $contentService = $repository->getContentService(); @@ -222,10 +221,9 @@ public function testTrashReturnsNull() /** * Test for the loadTrashItem() method. - * - * @depends testTrash */ - public function testLoadTrashItem() + #[Depends('testTrash')] + public function testLoadTrashItem(): void { $repository = $this->getRepository(); $trashService = $repository->getTrashService(); @@ -271,10 +269,9 @@ public function testLoadTrashItem() /** * Test for the loadTrashItem() method. - * - * @depends testLoadTrashItem */ - public function testLoadTrashItemThrowsNotFoundException() + #[Depends('testLoadTrashItem')] + public function testLoadTrashItemThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -292,10 +289,9 @@ public function testLoadTrashItemThrowsNotFoundException() /** * Test for the recover() method. - * - * @depends testTrash */ - public function testRecover() + #[Depends('testTrash')] + public function testRecover(): void { $repository = $this->getRepository(); $trashService = $repository->getTrashService(); @@ -336,7 +332,7 @@ public function testRecover() /** * Test recovering a non existing trash item results in a NotFoundException. */ - public function testRecoverThrowsNotFoundExceptionForNonExistingTrashItem() + public function testRecoverThrowsNotFoundExceptionForNonExistingTrashItem(): void { $this->expectException(NotFoundException::class); @@ -354,10 +350,9 @@ public function testRecoverThrowsNotFoundExceptionForNonExistingTrashItem() /** * Test for the trash() method. - * - * @depends testTrash */ - public function testNotFoundAliasAfterRemoveIt() + #[Depends('testTrash')] + public function testNotFoundAliasAfterRemoveIt(): void { $this->expectException(NotFoundException::class); @@ -380,10 +375,9 @@ public function testNotFoundAliasAfterRemoveIt() /** * Test for the recover() method. - * - * @depends testTrash */ - public function testAliasesForRemovedItems() + #[Depends('testTrash')] + public function testAliasesForRemovedItems(): void { $mediaRemoteId = '75c715a51699d2d309a924eca6a95145'; @@ -422,10 +416,9 @@ public function testAliasesForRemovedItems() /** * Test for the recover() method. - * - * @depends testRecover */ - public function testRecoverDoesNotRestoreChildLocations() + #[Depends('testRecover')] + public function testRecoverDoesNotRestoreChildLocations(): void { $repository = $this->getRepository(); $trashService = $repository->getTrashService(); @@ -472,11 +465,11 @@ public function testRecoverDoesNotRestoreChildLocations() /** * Test for the recover() method. * - * @depends testRecover * * @todo Fix naming */ - public function testRecoverWithLocationCreateStructParameter() + #[Depends('testRecover')] + public function testRecoverWithLocationCreateStructParameter(): void { $repository = $this->getRepository(); $trashService = $repository->getTrashService(); @@ -522,10 +515,9 @@ public function testRecoverWithLocationCreateStructParameter() /** * Test for the recover() method. - * - * @depends testRecover */ - public function testRecoverIncrementsChildCountOnOriginalParent() + #[Depends('testRecover')] + public function testRecoverIncrementsChildCountOnOriginalParent(): void { $repository = $this->getRepository(); $trashService = $repository->getTrashService(); @@ -561,10 +553,9 @@ public function testRecoverIncrementsChildCountOnOriginalParent() /** * Test for the recover() method. - * - * @depends testRecoverWithLocationCreateStructParameter */ - public function testRecoverWithLocationCreateStructParameterIncrementsChildCountOnNewParent() + #[Depends('testRecoverWithLocationCreateStructParameter')] + public function testRecoverWithLocationCreateStructParameterIncrementsChildCountOnNewParent(): void { $repository = $this->getRepository(); $trashService = $repository->getTrashService(); @@ -607,7 +598,7 @@ public function testRecoverWithLocationCreateStructParameterIncrementsChildCount /** * Test recovering a location from trash to non existing location. */ - public function testRecoverToNonExistingLocation() + public function testRecoverToNonExistingLocation(): void { $this->expectException(NotFoundException::class); @@ -627,9 +618,7 @@ public function testRecoverToNonExistingLocation() $trashService->recover($trashItem, $newParentLocation); } - /** - * @dataProvider trashFiltersProvider - */ + #[DataProvider('trashFiltersProvider')] public function testFindTrashItems( array $filters, int $expectedCount @@ -695,9 +684,7 @@ public function testFindTrashItemsSortedByDateTrashed(): void self::assertEquals($firstTrashedItem->remoteId, $searchResult->items[1]->remoteId); } - /** - * @dataProvider trashSortClausesProvider - */ + #[DataProvider('trashSortClausesProvider')] public function testFindTrashItemsSort(array $sortClausesClasses): void { $repository = $this->getRepository(); @@ -740,10 +727,9 @@ public function testFindTrashItemsSort(array $sortClausesClasses): void /** * Test for the findTrashItems() method for it's result structure. - * - * @depends testTrash */ - public function testFindTrashItemsLimits() + #[Depends('testTrash')] + public function testFindTrashItemsLimits(): void { $repository = $this->getRepository(); $trashService = $repository->getTrashService(); @@ -769,10 +755,9 @@ public function testFindTrashItemsLimits() /** * Test for the findTrashItems() method. - * - * @depends Ibexa\Tests\Integration\Core\Repository\TrashServiceTest::testFindTrashItems */ - public function testFindTrashItemsLimitedAccess() + #[DependsExternal(self::class, 'testFindTrashItems')] + public function testFindTrashItemsLimitedAccess(): void { $repository = $this->getRepository(); $trashService = $repository->getTrashService(); @@ -816,7 +801,7 @@ public function testFindTrashItemsLimitedAccess() /** * Test Section Role Assignment Limitation against user/login. */ - public function testFindTrashItemsSubtreeLimitation() + public function testFindTrashItemsSubtreeLimitation(): void { $repository = $this->getRepository(); $contentService = $repository->getContentService(); @@ -870,10 +855,9 @@ public function testFindTrashItemsSubtreeLimitation() /** * Test for the emptyTrash() method. - * - * @depends testFindTrashItems */ - public function testEmptyTrash() + #[Depends('testFindTrashItems')] + public function testEmptyTrash(): void { $repository = $this->getRepository(); $trashService = $repository->getTrashService(); @@ -901,10 +885,9 @@ public function testEmptyTrash() /** * Test for the emptyTrash() method with user which has subtree limitations. - * - * @depends testFindTrashItems */ - public function testEmptyTrashForUserWithSubtreeLimitation() + #[Depends('testFindTrashItems')] + public function testEmptyTrashForUserWithSubtreeLimitation(): void { $repository = $this->getRepository(); $trashService = $repository->getTrashService(); @@ -945,10 +928,9 @@ public function testEmptyTrashForUserWithSubtreeLimitation() /** * Test for the deleteTrashItem() method. - * - * @depends testFindTrashItems */ - public function testDeleteTrashItem() + #[Depends('testFindTrashItems')] + public function testDeleteTrashItem(): void { $repository = $this->getRepository(); $trashService = $repository->getTrashService(); @@ -997,7 +979,7 @@ static function ($trashItem) { /** * Test deleting a non existing trash item. */ - public function testDeleteThrowsNotFoundExceptionForNonExistingTrashItem() + public function testDeleteThrowsNotFoundExceptionForNonExistingTrashItem(): void { $this->expectException(NotFoundException::class); @@ -1039,7 +1021,7 @@ public function testTrashProperlyAssignsRemovedLocationContentMapToTrashItem(): /** * @return array */ - public function trashFiltersProvider(): array + public static function trashFiltersProvider(): array { return [ [ @@ -1183,7 +1165,7 @@ public function trashFiltersProvider(): array ]; } - public function trashSortClausesProvider(): array + public static function trashSortClausesProvider(): array { return [ [ diff --git a/tests/integration/Core/Repository/URLAliasService/CustomUrlAliasForMultilingualContentTest.php b/tests/integration/Core/Repository/URLAliasService/CustomUrlAliasForMultilingualContentTest.php index fb92a11318..ed99165d8b 100644 --- a/tests/integration/Core/Repository/URLAliasService/CustomUrlAliasForMultilingualContentTest.php +++ b/tests/integration/Core/Repository/URLAliasService/CustomUrlAliasForMultilingualContentTest.php @@ -9,14 +9,16 @@ namespace Ibexa\Tests\Integration\Core\Repository\URLAliasService; use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException; +use Ibexa\Core\Repository\ContentService; +use Ibexa\Core\Repository\URLAliasService; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +#[CoversClass(ContentService::class)] +#[CoversClass(URLAliasService::class)] final class CustomUrlAliasForMultilingualContentTest extends BaseTestCase { /** - * @covers \Ibexa\Contracts\Core\Repository\ContentService::publishVersion - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::createUrlAlias - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException diff --git a/tests/integration/Core/Repository/URLAliasService/UrlAliasLookupTest.php b/tests/integration/Core/Repository/URLAliasService/UrlAliasLookupTest.php index 6e2a6f009f..b207fc3add 100644 --- a/tests/integration/Core/Repository/URLAliasService/UrlAliasLookupTest.php +++ b/tests/integration/Core/Repository/URLAliasService/UrlAliasLookupTest.php @@ -9,11 +9,11 @@ namespace Ibexa\Tests\Integration\Core\Repository\URLAliasService; use Ibexa\Contracts\Core\Repository\URLAliasService; +use Ibexa\Core\Repository\URLAliasService as CoveredURLAliasService; use Ibexa\Tests\Integration\Core\RepositoryTestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService - */ +#[CoversClass(CoveredURLAliasService::class)] final class UrlAliasLookupTest extends RepositoryTestCase { /** diff --git a/tests/integration/Core/Repository/URLAliasServiceAuthorizationTest.php b/tests/integration/Core/Repository/URLAliasServiceAuthorizationTest.php index 9e5f913b6a..8ad4f56bbb 100644 --- a/tests/integration/Core/Repository/URLAliasServiceAuthorizationTest.php +++ b/tests/integration/Core/Repository/URLAliasServiceAuthorizationTest.php @@ -8,17 +8,18 @@ namespace Ibexa\Tests\Integration\Core\Repository; use Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException; +use Ibexa\Core\Repository\URLAliasService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DependsExternal; +#[CoversClass(URLAliasService::class)] class URLAliasServiceAuthorizationTest extends BaseTestCase { /** * Test for the createUrlAlias() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::createUrlAlias() - * - * @depends Ibexa\Tests\Integration\Core\Repository\URLAliasServiceTest::testCreateUrlAlias */ - public function testCreateUrlAliasThrowsUnauthorizedException() + #[DependsExternal(URLAliasServiceTest::class, 'testCreateUrlAlias')] + public function testCreateUrlAliasThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -47,12 +48,9 @@ public function testCreateUrlAliasThrowsUnauthorizedException() /** * Test for the createGlobalUrlAlias() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::createGlobalUrlAlias() - * - * @depends Ibexa\Tests\Integration\Core\Repository\URLAliasServiceTest::testCreateGlobalUrlAlias */ - public function testCreateGlobalUrlAliasThrowsUnauthorizedException() + #[DependsExternal(URLAliasServiceTest::class, 'testCreateGlobalUrlAlias')] + public function testCreateGlobalUrlAliasThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -75,12 +73,9 @@ public function testCreateGlobalUrlAliasThrowsUnauthorizedException() /** * Test for the removeAliases() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::removeAliases() - * - * @depends Ibexa\Tests\Integration\Core\Repository\URLAliasServiceTest::testRemoveAliases */ - public function testRemoveAliasesThrowsUnauthorizedException() + #[DependsExternal(URLAliasServiceTest::class, 'testRemoveAliases')] + public function testRemoveAliasesThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/URLAliasServiceTest.php b/tests/integration/Core/Repository/URLAliasServiceTest.php index e684ffb24d..0e22122942 100644 --- a/tests/integration/Core/Repository/URLAliasServiceTest.php +++ b/tests/integration/Core/Repository/URLAliasServiceTest.php @@ -17,16 +17,18 @@ use Ibexa\Contracts\Core\Repository\Values\Content\URLAlias; use Ibexa\Core\Persistence\Legacy\Content\UrlAlias\Gateway; use Ibexa\Core\Persistence\Legacy\Content\UrlAlias\SlugConverter; +use Ibexa\Core\Repository\URLAliasService; use Ibexa\Tests\Integration\Core\Repository\Common\SlugConverter as TestSlugConverter; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\Group; use RuntimeException; /** * Test case for operations in the URLAliasService using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService - * - * @group url-alias */ +#[CoversClass(URLAliasService::class)] +#[Group('url-alias')] class URLAliasServiceTest extends BaseTestCase { /** @@ -68,8 +70,6 @@ protected function setUp(): void /** * Test for the createUrlAlias() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::createUrlAlias() */ public function testCreateUrlAlias() { @@ -99,13 +99,12 @@ public function testCreateUrlAlias() /** * Test for the createUrlAlias() method. * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::createUrlAlias * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ - public function testCreateSameAliasForDifferentLanguage() + public function testCreateSameAliasForDifferentLanguage(): void { $repository = $this->getRepository(); $locationId = $this->generateId('location', 5); @@ -150,10 +149,9 @@ public function testLoad(): void /** * @param array $testData - * - * @depends testCreateUrlAlias */ - public function testCreateUrlAliasPropertyValues(array $testData) + #[Depends('testCreateUrlAlias')] + public function testCreateUrlAliasPropertyValues(array $testData): void { [$createdUrlAlias, $locationId] = $testData; @@ -176,11 +174,8 @@ public function testCreateUrlAliasPropertyValues(array $testData) /** * Test for the createUrlAlias() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::createUrlAlias($location, $path, $languageCode, $forwarding) - * - * @depends testCreateUrlAliasPropertyValues */ + #[Depends('testCreateUrlAliasPropertyValues')] public function testCreateUrlAliasWithForwarding() { $repository = $this->getRepository(); @@ -208,10 +203,9 @@ public function testCreateUrlAliasWithForwarding() /** * @param array $testData - * - * @depends testCreateUrlAliasWithForwarding */ - public function testCreateUrlAliasPropertyValuesWithForwarding(array $testData) + #[Depends('testCreateUrlAliasWithForwarding')] + public function testCreateUrlAliasPropertyValuesWithForwarding(array $testData): void { [$createdUrlAlias, $locationId] = $testData; @@ -234,8 +228,6 @@ public function testCreateUrlAliasPropertyValuesWithForwarding(array $testData) /** * Test for the createUrlAlias() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::createUrlAlias($location, $path, $languageCode, $forwarding, $alwaysAvailable) */ public function testCreateUrlAliasWithAlwaysAvailable() { @@ -264,10 +256,9 @@ public function testCreateUrlAliasWithAlwaysAvailable() /** * @param array $testData - * - * @depends testCreateUrlAliasWithAlwaysAvailable */ - public function testCreateUrlAliasPropertyValuesWithAlwaysAvailable(array $testData) + #[Depends('testCreateUrlAliasWithAlwaysAvailable')] + public function testCreateUrlAliasPropertyValuesWithAlwaysAvailable(array $testData): void { [$createdUrlAlias, $locationId] = $testData; @@ -290,10 +281,8 @@ public function testCreateUrlAliasPropertyValuesWithAlwaysAvailable(array $testD /** * Test for the createUrlAlias() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::createUrlAlias() */ - public function testCreateUrlAliasThrowsInvalidArgumentException() + public function testCreateUrlAliasThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -317,8 +306,6 @@ public function testCreateUrlAliasThrowsInvalidArgumentException() /** * Test for the createGlobalUrlAlias() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::createGlobalUrlAlias() */ public function testCreateGlobalUrlAlias() { @@ -342,10 +329,8 @@ public function testCreateGlobalUrlAlias() return $createdUrlAlias; } - /** - * @depends testCreateGlobalUrlAlias - */ - public function testCreateGlobalUrlAliasPropertyValues(URLAlias $createdUrlAlias) + #[Depends('testCreateGlobalUrlAlias')] + public function testCreateGlobalUrlAliasPropertyValues(URLAlias $createdUrlAlias): void { self::assertNotNull($createdUrlAlias->id); @@ -366,8 +351,6 @@ public function testCreateGlobalUrlAliasPropertyValues(URLAlias $createdUrlAlias /** * Test for the createGlobalUrlAlias() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::createGlobalUrlAlias($resource, $path, $languageCode, $forward) */ public function testCreateGlobalUrlAliasWithForward() { @@ -392,10 +375,8 @@ public function testCreateGlobalUrlAliasWithForward() return $createdUrlAlias; } - /** - * @depends testCreateGlobalUrlAliasWithForward - */ - public function testCreateGlobalUrlAliasWithForwardPropertyValues(URLAlias $createdUrlAlias) + #[Depends('testCreateGlobalUrlAliasWithForward')] + public function testCreateGlobalUrlAliasWithForwardPropertyValues(URLAlias $createdUrlAlias): void { self::assertNotNull($createdUrlAlias->id); @@ -416,8 +397,6 @@ public function testCreateGlobalUrlAliasWithForwardPropertyValues(URLAlias $crea /** * Test for the createGlobalUrlAlias() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::createGlobalUrlAlias($resource, $path, $languageCode, $forwarding, $alwaysAvailable) */ public function testCreateGlobalUrlAliasWithAlwaysAvailable() { @@ -443,10 +422,8 @@ public function testCreateGlobalUrlAliasWithAlwaysAvailable() return $createdUrlAlias; } - /** - * @depends testCreateGlobalUrlAliasWithAlwaysAvailable - */ - public function testCreateGlobalUrlAliasWithAlwaysAvailablePropertyValues(URLAlias $createdUrlAlias) + #[Depends('testCreateGlobalUrlAliasWithAlwaysAvailable')] + public function testCreateGlobalUrlAliasWithAlwaysAvailablePropertyValues(URLAlias $createdUrlAlias): void { self::assertNotNull($createdUrlAlias->id); @@ -467,8 +444,6 @@ public function testCreateGlobalUrlAliasWithAlwaysAvailablePropertyValues(URLAli /** * Test for the createUrlAlias() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::createGlobalUrlAlias($resource, $path, $languageCode, $forwarding, $alwaysAvailable) */ public function testCreateGlobalUrlAliasForLocation() { @@ -502,8 +477,6 @@ public function testCreateGlobalUrlAliasForLocation() /** * Test for the createUrlAlias() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::createGlobalUrlAlias($resource, $path, $languageCode, $forwarding, $alwaysAvailable) */ public function testCreateGlobalUrlAliasForLocationVariation() { @@ -537,10 +510,9 @@ public function testCreateGlobalUrlAliasForLocationVariation() /** * @param array{\Ibexa\Contracts\Core\Repository\Values\Content\URLAlias, int} $testData - * - * @depends testCreateGlobalUrlAliasForLocation */ - public function testCreateGlobalUrlAliasForLocationPropertyValues($testData) + #[Depends('testCreateGlobalUrlAliasForLocation')] + public function testCreateGlobalUrlAliasForLocationPropertyValues($testData): void { [$createdUrlAlias, $locationId] = $testData; @@ -563,20 +535,17 @@ public function testCreateGlobalUrlAliasForLocationPropertyValues($testData) /** * @param array{\Ibexa\Contracts\Core\Repository\Values\Content\URLAlias, int} $testData - * - * @depends testCreateGlobalUrlAliasForLocationVariation */ - public function testCreateGlobalUrlAliasForLocationVariationPropertyValues($testData) + #[Depends('testCreateGlobalUrlAliasForLocationVariation')] + public function testCreateGlobalUrlAliasForLocationVariationPropertyValues($testData): void { $this->testCreateGlobalUrlAliasForLocationPropertyValues($testData); } /** * Test for the createGlobalUrlAlias() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::createGlobalUrlAlias() */ - public function testCreateGlobalUrlAliasThrowsInvalidArgumentException() + public function testCreateGlobalUrlAliasThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -597,8 +566,6 @@ public function testCreateGlobalUrlAliasThrowsInvalidArgumentException() /** * Test for the listLocationAliases() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::listLocationAliases() */ public function testListLocationAliases() { @@ -630,10 +597,9 @@ public function testListLocationAliases() /** * @param array $testData - * - * @depends testListLocationAliases */ - public function testListLocationAliasesLoadsCorrectly(array $testData) + #[Depends('testListLocationAliases')] + public function testListLocationAliasesLoadsCorrectly(array $testData): void { [$loadedAliases, $location] = $testData; @@ -651,10 +617,8 @@ public function testListLocationAliasesLoadsCorrectly(array $testData) /** * Test for the listLocationAliases() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::listLocationAliases($location, $custom, $languageCode) */ - public function testListLocationAliasesWithCustomFilter() + public function testListLocationAliasesWithCustomFilter(): void { $repository = $this->getRepository(); @@ -680,10 +644,8 @@ public function testListLocationAliasesWithCustomFilter() /** * Test for the listLocationAliases() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::listLocationAliases($location, $custom) */ - public function testListLocationAliasesWithLanguageCodeFilter() + public function testListLocationAliasesWithLanguageCodeFilter(): void { $repository = $this->getRepository(); @@ -708,10 +670,8 @@ public function testListLocationAliasesWithLanguageCodeFilter() /** * Test for the listGlobalAliases() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::listGlobalAliases() */ - public function testListGlobalAliases() + public function testListGlobalAliases(): void { $repository = $this->getRepository(); @@ -758,10 +718,8 @@ private function createGlobalAliases() /** * Test for the listGlobalAliases() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::listGlobalAliases($languageCode) */ - public function testListGlobalAliasesWithLanguageFilter() + public function testListGlobalAliasesWithLanguageFilter(): void { $repository = $this->getRepository(); @@ -781,10 +739,8 @@ public function testListGlobalAliasesWithLanguageFilter() /** * Test for the listGlobalAliases() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::listGlobalAliases($languageCode, $offset) */ - public function testListGlobalAliasesWithOffset() + public function testListGlobalAliasesWithOffset(): void { $repository = $this->getRepository(); @@ -804,10 +760,8 @@ public function testListGlobalAliasesWithOffset() /** * Test for the listGlobalAliases() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::listGlobalAliases($languageCode, $offset, $limit) */ - public function testListGlobalAliasesWithLimit() + public function testListGlobalAliasesWithLimit(): void { $repository = $this->getRepository(); @@ -827,10 +781,8 @@ public function testListGlobalAliasesWithLimit() /** * Test for the removeAliases() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::removeAliases() */ - public function testRemoveAliases() + public function testRemoveAliases(): void { $repository = $this->getRepository(); @@ -868,10 +820,8 @@ public function testRemoveAliases() /** * Test for the removeAliases() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::removeAliases() */ - public function testRemoveAliasesThrowsInvalidArgumentExceptionIfAutogeneratedAliasesAreToBeRemoved() + public function testRemoveAliasesThrowsInvalidArgumentExceptionIfAutogeneratedAliasesAreToBeRemoved(): void { $this->expectException(InvalidArgumentException::class); @@ -897,8 +847,6 @@ public function testRemoveAliasesThrowsInvalidArgumentExceptionIfAutogeneratedAl /** * Test for the lookUp() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::lookUp() */ public function testLookUp() { @@ -920,10 +868,8 @@ public function testLookUp() /** * Test for the lookUp() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::lookUp($url, $languageCode) */ - public function testLookUpWithLanguageFilter() + public function testLookUpWithLanguageFilter(): void { $repository = $this->getRepository(); @@ -948,10 +894,8 @@ public function testLookUpWithLanguageFilter() /** * Test for the lookUp() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::lookUp() */ - public function testLookUpThrowsNotFoundException() + public function testLookUpThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -967,10 +911,8 @@ public function testLookUpThrowsNotFoundException() /** * Test for the lookUp() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::lookUp($url, $languageCode) */ - public function testLookUpThrowsNotFoundExceptionWithLanguageFilter() + public function testLookUpThrowsNotFoundExceptionWithLanguageFilter(): void { $this->expectException(NotFoundException::class); @@ -986,10 +928,8 @@ public function testLookUpThrowsNotFoundExceptionWithLanguageFilter() /** * Test for the lookUp() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::lookUp($url, $languageCode) */ - public function testLookUpThrowsInvalidArgumentException() + public function testLookUpThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -1007,11 +947,8 @@ public function testLookUpThrowsInvalidArgumentException() * Test for the lookUp() method after renaming parent which is a part of the lookup path. * * @see https://issues.ibexa.co/browse/EZP-28046 - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::lookUp - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::listLocationAliases */ - public function testLookupOnRenamedParent() + public function testLookupOnRenamedParent(): void { $urlAliasService = $this->getRepository()->getURLAliasService(); $locationService = $this->getRepository()->getLocationService(); @@ -1132,7 +1069,7 @@ public function testLookupOnMultilingualNestedLocations() * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException * @throws \ErrorException */ - public function testRefreshSystemUrlAliasesForLocationWithChangedSlugConverterConfiguration() + public function testRefreshSystemUrlAliasesForLocationWithChangedSlugConverterConfiguration(): void { [$topFolderLocation, $nestedFolderLocation] = $this->testLookupOnMultilingualNestedLocations(); @@ -1194,7 +1131,7 @@ public function testRefreshSystemUrlAliasesForLocationWithChangedSlugConverterCo * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ - public function testRefreshSystemUrlAliasesForContentsWithUpdatedContentTypes() + public function testRefreshSystemUrlAliasesForContentsWithUpdatedContentTypes(): void { [$topFolderLocation, $nestedFolderLocation] = $this->testLookupOnMultilingualNestedLocations(); /** @var \Ibexa\Contracts\Core\Repository\Values\Content\Location $topFolderLocation */ @@ -1247,7 +1184,7 @@ public function testRefreshSystemUrlAliasesForContentsWithUpdatedContentTypes() * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ - public function testCreateNonLatinNonEmptyUniqueAliases() + public function testCreateNonLatinNonEmptyUniqueAliases(): void { $repository = $this->getRepository(); $urlAliasService = $repository->getURLAliasService(); @@ -1298,7 +1235,7 @@ public function testCreateNonLatinNonEmptyUniqueAliases() * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException * @throws \Exception */ - public function testRefreshSystemUrlAliasesForMissingUrlWithHistory() + public function testRefreshSystemUrlAliasesForMissingUrlWithHistory(): void { $repository = $this->getRepository(); $urlAliasService = $repository->getURLAliasService(); @@ -1397,7 +1334,7 @@ static function (Connection $connection) use ($folderLocation) { * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException * @throws \Exception */ - public function testRefreshSystemUrlAliasesForMovedLocation() + public function testRefreshSystemUrlAliasesForMovedLocation(): void { $repository = $this->getRepository(); $urlAliasService = $repository->getURLAliasService(); @@ -1619,7 +1556,7 @@ protected function updateContentField(ContentInfo $contentInfo, $fieldDefinition * * @throws \ErrorException */ - public function testDeleteCorruptedUrlAliases() + public function testDeleteCorruptedUrlAliases(): void { $repository = $this->getRepository(); $urlAliasService = $repository->getURLAliasService(); @@ -1744,7 +1681,6 @@ private function assertUrlAliasPropertiesCorrect( /** * Insert intentionally broken rows into ibexa_url_alias_ml table to test cleanup API. * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::deleteCorruptedUrlAliases * * @see testDeleteCorruptedUrlAliases * diff --git a/tests/integration/Core/Repository/URLServiceAuthorizationTest.php b/tests/integration/Core/Repository/URLServiceAuthorizationTest.php index 17ebc05d2c..731c407d99 100644 --- a/tests/integration/Core/Repository/URLServiceAuthorizationTest.php +++ b/tests/integration/Core/Repository/URLServiceAuthorizationTest.php @@ -10,15 +10,16 @@ use Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException; use Ibexa\Contracts\Core\Repository\Values\URL\Query\Criterion; use Ibexa\Contracts\Core\Repository\Values\URL\URLQuery; +use Ibexa\Core\Repository\URLService; +use PHPUnit\Framework\Attributes\CoversClass; +#[CoversClass(URLService::class)] class URLServiceAuthorizationTest extends BaseURLServiceTestCase { /** * Test for the findUrls() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::findUrls */ - public function testFindUrlsThrowsUnauthorizedException() + public function testFindUrlsThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -44,10 +45,8 @@ public function testFindUrlsThrowsUnauthorizedException() /** * Test for the updateUrl() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::updateUrl */ - public function testUpdateUrlThrowsUnauthorizedException() + public function testUpdateUrlThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -75,10 +74,8 @@ public function testUpdateUrlThrowsUnauthorizedException() /** * Test for the loadById() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::loadById */ - public function testLoadByIdThrowsUnauthorizedException() + public function testLoadByIdThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -102,10 +99,8 @@ public function testLoadByIdThrowsUnauthorizedException() /** * Test for the loadByUrl() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::loadById */ - public function testLoadByUrlThrowsUnauthorizedException() + public function testLoadByUrlThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/URLServiceTest.php b/tests/integration/Core/Repository/URLServiceTest.php index 413320e05a..155cfe8eba 100644 --- a/tests/integration/Core/Repository/URLServiceTest.php +++ b/tests/integration/Core/Repository/URLServiceTest.php @@ -17,15 +17,18 @@ use Ibexa\Contracts\Core\Repository\Values\URL\URLUpdateStruct; use Ibexa\Contracts\Core\Repository\Values\URL\UsageSearchResult; use Ibexa\Core\Base\Exceptions\InvalidArgumentValue; +use Ibexa\Core\Repository\URLService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the UserService using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService - * - * @group integration - * @group url */ +#[CoversClass(URLService::class)] +#[Group('integration')] +#[Group('url')] class URLServiceTest extends BaseURLServiceTestCase { private const TOTAL_URLS_COUNT = 20; @@ -170,10 +173,8 @@ protected function setUp(): void /** * Test for URLService::findUrls() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::findUrls() */ - public function testFindUrls() + public function testFindUrls(): void { $expectedUrls = [ 'https://www.apache.org/', @@ -206,10 +207,8 @@ public function testFindUrls() /** * Test for URLService::findUrls() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::findUrls() */ - public function testFindUrlsWithoutCounting() + public function testFindUrlsWithoutCounting(): void { $expectedUrls = [ 'https://www.apache.org/', @@ -243,12 +242,9 @@ public function testFindUrlsWithoutCounting() /** * Test for URLService::findUrls() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::findUrls() - * - * @depends testFindUrls */ - public function testFindUrlsUsingMatchNone() + #[Depends('testFindUrls')] + public function testFindUrlsUsingMatchNone(): void { $query = new URLQuery(); $query->filter = new Criterion\MatchNone(); @@ -258,12 +254,9 @@ public function testFindUrlsUsingMatchNone() /** * Test for URLService::findUrls() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::findUrls() - * - * @depends testFindUrls */ - public function testFindUrlsUsingPatternCriterion() + #[Depends('testFindUrls')] + public function testFindUrlsUsingPatternCriterion(): void { $expectedUrls = [ 'https://www.google.de/', @@ -281,12 +274,9 @@ public function testFindUrlsUsingPatternCriterion() /** * Test for URLService::findUrls() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::findUrls() - * - * @depends testFindUrls */ - public function testFindUrlsUsingValidityCriterionValid() + #[Depends('testFindUrls')] + public function testFindUrlsUsingValidityCriterionValid(): void { $expectedUrls = [ 'https://www.google.com/', @@ -318,11 +308,8 @@ public function testFindUrlsUsingValidityCriterionValid() /** * Test for URLService::findUrls() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::findUrls - * - * @depends testFindUrls */ + #[Depends('testFindUrls')] public function testFindUrlsUsingSectionIdCriterion(): void { $expectedUrls = [ @@ -339,11 +326,8 @@ public function testFindUrlsUsingSectionIdCriterion(): void /** * Test for URLService::findUrls() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::findUrls() - * - * @depends testFindUrls */ + #[Depends('testFindUrls')] public function testFindUrlsUsingSectionIdAndValidityCriterionValid(): void { $expectedUrls = [ @@ -363,11 +347,8 @@ public function testFindUrlsUsingSectionIdAndValidityCriterionValid(): void /** * Test for URLService::findUrls() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::findUrls - * - * @depends testFindUrls */ + #[Depends('testFindUrls')] public function testFindUrlsUsingSectionIdentifierCriterion(): void { $expectedUrls = [ @@ -384,11 +365,8 @@ public function testFindUrlsUsingSectionIdentifierCriterion(): void /** * Test for URLService::findUrls() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::findUrls() - * - * @depends testFindUrls */ + #[Depends('testFindUrls')] public function testFindUrlsUsingSectionIdentifierAndValidityCriterionValid(): void { $expectedUrls = [ @@ -410,11 +388,8 @@ public function testFindUrlsUsingSectionIdentifierAndValidityCriterionValid(): v /** * Test for URLService::findUrls() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::findUrls() - * - * @depends testFindUrls */ + #[Depends('testFindUrls')] public function testFindUrlsUsingSectionIdentifierOrSectionIdCriterion(): void { $expectedUrls = [ @@ -436,12 +411,9 @@ public function testFindUrlsUsingSectionIdentifierOrSectionIdCriterion(): void /** * Test for URLService::findUrls() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::findUrls() - * - * @depends testFindUrls */ - public function testFindUrlsUsingValidityCriterionInvalid() + #[Depends('testFindUrls')] + public function testFindUrlsUsingValidityCriterionInvalid(): void { $expectedUrls = [ '/content/view/tagcloud/2', @@ -455,12 +427,9 @@ public function testFindUrlsUsingValidityCriterionInvalid() /** * Test for URLService::findUrls() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::findUrls() - * - * @depends testFindUrls */ - public function testFindUrlsUsingVisibleOnlyCriterion() + #[Depends('testFindUrls')] + public function testFindUrlsUsingVisibleOnlyCriterion(): void { $expectedUrls = [ 'https://vimeo.com/', @@ -513,10 +482,8 @@ public function testFindUrlsUsingVisibleOnlyCriterionReturnsUniqueItems(): void /** * Test for URLService::findUrls() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::findUrls() */ - public function testFindUrlsWithInvalidOffsetThrowsInvalidArgumentException() + public function testFindUrlsWithInvalidOffsetThrowsInvalidArgumentException(): void { $query = new URLQuery(); $query->filter = new Criterion\MatchAll(); @@ -534,10 +501,8 @@ public function testFindUrlsWithInvalidOffsetThrowsInvalidArgumentException() /** * Test for URLService::findUrls() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::findUrls() */ - public function testFindUrlsWithInvalidLimitThrowsInvalidArgumentException() + public function testFindUrlsWithInvalidLimitThrowsInvalidArgumentException(): void { $query = new URLQuery(); $query->filter = new Criterion\MatchAll(); @@ -555,12 +520,9 @@ public function testFindUrlsWithInvalidLimitThrowsInvalidArgumentException() /** * Test for URLService::findUrls() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::findUrls() - * - * @depends testFindUrls */ - public function testFindUrlsWithOffset() + #[Depends('testFindUrls')] + public function testFindUrlsWithOffset(): void { $expectedUrls = [ 'https://www.discuz.net/forum.php', @@ -585,12 +547,9 @@ public function testFindUrlsWithOffset() /** * Test for URLService::findUrls() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::findUrls() - * - * @depends testFindUrls */ - public function testFindUrlsWithOffsetAndLimit() + #[Depends('testFindUrls')] + public function testFindUrlsWithOffsetAndLimit(): void { $expectedUrls = [ 'https://www.discuz.net/forum.php', @@ -609,12 +568,9 @@ public function testFindUrlsWithOffsetAndLimit() /** * Test for URLService::findUrls() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::findUrls() - * - * @depends testFindUrls */ - public function testFindUrlsWithLimitZero() + #[Depends('testFindUrls')] + public function testFindUrlsWithLimitZero(): void { $query = new URLQuery(); $query->filter = new Criterion\MatchAll(); @@ -625,14 +581,10 @@ public function testFindUrlsWithLimitZero() /** * Test for URLService::findUrls() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::findUrls() - * - * @depends testFindUrls - * - * @dataProvider dataProviderForFindUrlsWithSorting */ - public function testFindUrlsWithSorting(SortClause $sortClause, array $expectedUrls) + #[Depends('testFindUrls')] + #[DataProvider('dataProviderForFindUrlsWithSorting')] + public function testFindUrlsWithSorting(SortClause $sortClause, array $expectedUrls): void { $query = new URLQuery(); $query->filter = new Criterion\MatchAll(); @@ -641,7 +593,10 @@ public function testFindUrlsWithSorting(SortClause $sortClause, array $expectedU $this->doTestFindUrls($query, $expectedUrls, count($expectedUrls), false); } - public function dataProviderForFindUrlsWithSorting() + /** + * @return array + */ + public static function dataProviderForFindUrlsWithSorting(): array { $urlsSortedById = [ '/content/view/sitemap/2', @@ -679,10 +634,8 @@ public function dataProviderForFindUrlsWithSorting() /** * Test for URLService::updateUrl() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::updateUrl() */ - public function testUpdateUrl() + public function testUpdateUrl(): void { $repository = $this->getRepository(); @@ -712,10 +665,8 @@ public function testUpdateUrl() /** * Test for URLService::updateUrl() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::updateUrl() */ - public function testUpdateUrlStatus() + public function testUpdateUrlStatus(): void { $repository = $this->getRepository(); @@ -748,12 +699,9 @@ public function testUpdateUrlStatus() /** * Test for URLService::updateUrl() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::updateUrl() - * - * @depends testUpdateUrl */ - public function testUpdateUrlWithNonUniqueUrl() + #[Depends('testUpdateUrl')] + public function testUpdateUrlWithNonUniqueUrl(): void { $this->expectException(InvalidArgumentException::class); @@ -775,10 +723,8 @@ public function testUpdateUrlWithNonUniqueUrl() /** * Test for URLService::loadById() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::loadById */ - public function testLoadById() + public function testLoadById(): void { $repository = $this->getRepository(); @@ -803,12 +749,9 @@ public function testLoadById() /** * Test for URLService::loadById() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::loadById - * - * @depends testLoadById */ - public function testLoadByIdThrowsNotFoundException() + #[Depends('testLoadById')] + public function testLoadByIdThrowsNotFoundException(): void { $repository = $this->getRepository(); @@ -823,10 +766,8 @@ public function testLoadByIdThrowsNotFoundException() /** * Test for URLService::loadByUrl() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::loadByUrl */ - public function testLoadByUrl() + public function testLoadByUrl(): void { $repository = $this->getRepository(); @@ -851,12 +792,9 @@ public function testLoadByUrl() /** * Test for URLService::loadByUrl() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLService::loadByUrl - * - * @depends testLoadByUrl */ - public function testLoadByUrlThrowsNotFoundException() + #[Depends('testLoadByUrl')] + public function testLoadByUrlThrowsNotFoundException(): void { $repository = $this->getRepository(); @@ -872,7 +810,6 @@ public function testLoadByUrlThrowsNotFoundException() /** * Test for URLService::createUpdateStruct() method. * - * @covers \Ibexa\Contracts\Core\Repository\URLService::createUpdateStruct * * @return \Ibexa\Contracts\Core\Repository\Values\URL\URLUpdateStruct */ @@ -894,10 +831,9 @@ public function testCreateUpdateStruct() * Test for URLService::createUpdateStruct() method. * * @param \Ibexa\Contracts\Core\Repository\Values\URL\URLUpdateStruct $updateStruct - * - * @depends testCreateUpdateStruct */ - public function testCreateUpdateStructValues(URLUpdateStruct $updateStruct) + #[Depends('testCreateUpdateStruct')] + public function testCreateUpdateStructValues(URLUpdateStruct $updateStruct): void { $this->assertPropertiesCorrect([ 'url' => null, @@ -908,12 +844,10 @@ public function testCreateUpdateStructValues(URLUpdateStruct $updateStruct) /** * Test for URLService::testFindUsages() method. - * - * @depends testLoadById - * - * @dataProvider dataProviderForFindUsages */ - public function testFindUsages($urlId, $offset, $limit, array $expectedContentInfos, $expectedTotalCount = null) + #[Depends('testLoadById')] + #[DataProvider('dataProviderForFindUsages')] + public function testFindUsages($urlId, $offset, $limit, array $expectedContentInfos, $expectedTotalCount = null): void { $repository = $this->getRepository(); @@ -931,7 +865,10 @@ public function testFindUsages($urlId, $offset, $limit, array $expectedContentIn $this->assertUsagesSearchResultItems($usagesSearchResults, $expectedContentInfos); } - public function dataProviderForFindUsages() + /** + * @return array + */ + public static function dataProviderForFindUsages(): array { return [ // findUsages($url, 0, -1) @@ -943,10 +880,9 @@ public function dataProviderForFindUsages() /** * Test for URLService::testFindUsages() method. - * - * @depends testFindUsages */ - public function testFindUsagesReturnsEmptySearchResults() + #[Depends('testFindUsages')] + public function testFindUsagesReturnsEmptySearchResults(): void { $repository = $this->getRepository(); diff --git a/tests/integration/Core/Repository/URLWildcardService/CriterionTest.php b/tests/integration/Core/Repository/URLWildcardService/CriterionTest.php index 8a188f1c1f..019023ea5e 100644 --- a/tests/integration/Core/Repository/URLWildcardService/CriterionTest.php +++ b/tests/integration/Core/Repository/URLWildcardService/CriterionTest.php @@ -13,15 +13,16 @@ use Ibexa\Contracts\Core\Repository\Values\Content\URLWildcard\SearchResult; use Ibexa\Contracts\Core\Repository\Values\Content\URLWildcard\URLWildcardQuery; use Ibexa\Contracts\Core\Repository\Values\URL\Query\Criterion as CriterionURL; +use Ibexa\Core\Repository\URLWildcardService; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; /** * Test case criterion for URLWildcard. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService - * - * @group url-wildcard */ +#[CoversClass(URLWildcardService::class)] +#[Group('url-wildcard')] class CriterionTest extends BaseTestCase { protected function setUp(): void diff --git a/tests/integration/Core/Repository/URLWildcardServiceAuthorizationTest.php b/tests/integration/Core/Repository/URLWildcardServiceAuthorizationTest.php index 0d76662a62..6d22080efc 100644 --- a/tests/integration/Core/Repository/URLWildcardServiceAuthorizationTest.php +++ b/tests/integration/Core/Repository/URLWildcardServiceAuthorizationTest.php @@ -8,22 +8,20 @@ namespace Ibexa\Tests\Integration\Core\Repository; use Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException; +use Ibexa\Core\Repository\URLWildcardService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DependsExternal; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the URLWildcardService. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService - * - * @group integration - * @group authorization */ +#[CoversClass(URLWildcardService::class)] +#[Group('integration')] +#[Group('authorization')] class URLWildcardServiceAuthorizationTest extends BaseTestCase { - /** - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::create - * - * @depends Ibexa\Tests\Integration\Core\Repository\URLWildcardServiceTest::testCreate - */ + #[DependsExternal(URLWildcardServiceTest::class, 'testCreate')] public function testCreateThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -47,12 +45,9 @@ public function testCreateThrowsUnauthorizedException(): void /** * Test for the remove() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::remove() - * - * @depends Ibexa\Tests\Integration\Core\Repository\URLWildcardServiceTest::testRemove */ - public function testRemoveThrowsUnauthorizedException() + #[DependsExternal(URLWildcardServiceTest::class, 'testRemove')] + public function testRemoveThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/URLWildcardServiceTest.php b/tests/integration/Core/Repository/URLWildcardServiceTest.php index 2d262ef252..743b1ed258 100644 --- a/tests/integration/Core/Repository/URLWildcardServiceTest.php +++ b/tests/integration/Core/Repository/URLWildcardServiceTest.php @@ -13,22 +13,22 @@ use Ibexa\Contracts\Core\Repository\Values\Content\URLWildcard; use Ibexa\Contracts\Core\Repository\Values\Content\URLWildcardTranslationResult; use Ibexa\Contracts\Core\Repository\Values\Content\URLWildcardUpdateStruct; +use Ibexa\Core\Repository\URLWildcardService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the URLWildcardService. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService - * - * @group url-wildcard */ +#[CoversClass(URLWildcardService::class)] +#[Group('url-wildcard')] class URLWildcardServiceTest extends BaseTestCase { /** * Test for the create() method. * * @return \Ibexa\Contracts\Core\Repository\Values\Content\URLWildcard - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::create() */ public function testCreate() { @@ -53,12 +53,9 @@ public function testCreate() * Test for the create() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\URLWildcard $urlWildcard - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::create() - * - * @depends testCreate */ - public function testCreateSetsPropertiesOnURLWildcard(URLWildcard $urlWildcard) + #[Depends('testCreate')] + public function testCreateSetsPropertiesOnURLWildcard(URLWildcard $urlWildcard): void { $this->assertPropertiesCorrect( [ @@ -72,12 +69,9 @@ public function testCreateSetsPropertiesOnURLWildcard(URLWildcard $urlWildcard) /** * Test for the create() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::create() - * - * @depends testCreate */ - public function testCreateWithOptionalForwardParameter() + #[Depends('testCreate')] + public function testCreateWithOptionalForwardParameter(): void { $repository = $this->getRepository(); @@ -100,12 +94,9 @@ public function testCreateWithOptionalForwardParameter() /** * Test for the create() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::create() - * - * @depends testCreate */ - public function testCreateThrowsInvalidArgumentExceptionOnDuplicateSourceUrl() + #[Depends('testCreate')] + public function testCreateThrowsInvalidArgumentExceptionOnDuplicateSourceUrl(): void { $this->expectException(InvalidArgumentException::class); @@ -125,12 +116,9 @@ public function testCreateThrowsInvalidArgumentExceptionOnDuplicateSourceUrl() /** * Test for the create() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::create() - * - * @depends testCreate */ - public function testCreateThrowsContentValidationExceptionWhenPatternsAndPlaceholdersNotMatch() + #[Depends('testCreate')] + public function testCreateThrowsContentValidationExceptionWhenPatternsAndPlaceholdersNotMatch(): void { $this->expectException(ContentValidationException::class); @@ -147,12 +135,9 @@ public function testCreateThrowsContentValidationExceptionWhenPatternsAndPlaceho /** * Test for the create() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::create() - * - * @depends testCreate */ - public function testCreateThrowsContentValidationExceptionWhenPlaceholdersNotValidNumberSequence() + #[Depends('testCreate')] + public function testCreateThrowsContentValidationExceptionWhenPlaceholdersNotValidNumberSequence(): void { $this->expectException(ContentValidationException::class); @@ -171,11 +156,8 @@ public function testCreateThrowsContentValidationExceptionWhenPlaceholdersNotVal * Test for the load() method. * * @return \Ibexa\Contracts\Core\Repository\Values\Content\URLWildcard - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::load() - * - * @depends testCreate */ + #[Depends('testCreate')] public function testLoad() { $repository = $this->getRepository(); @@ -202,12 +184,9 @@ public function testLoad() * Test for the load() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\URLWildcard $urlWildcard - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::load() - * - * @depends testLoad */ - public function testLoadSetsPropertiesOnURLWildcard(URLWildcard $urlWildcard) + #[Depends('testLoad')] + public function testLoadSetsPropertiesOnURLWildcard(URLWildcard $urlWildcard): void { $this->assertPropertiesCorrect( [ @@ -223,12 +202,9 @@ public function testLoadSetsPropertiesOnURLWildcard(URLWildcard $urlWildcard) * Test for the load() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\URLWildcard $urlWildcard - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::load() - * - * @depends testLoad */ - public function testLoadThrowsNotFoundException(URLWildcard $urlWildcard) + #[Depends('testLoad')] + public function testLoadThrowsNotFoundException(URLWildcard $urlWildcard): void { $this->expectException(NotFoundException::class); @@ -243,8 +219,6 @@ public function testLoadThrowsNotFoundException(URLWildcard $urlWildcard) } /** - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::update - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException @@ -288,12 +262,9 @@ public function testUpdate(): void /** * Test for the remove() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::remove() - * - * @depends testLoad */ - public function testRemove() + #[Depends('testLoad')] + public function testRemove(): void { $this->expectException(NotFoundException::class); @@ -318,12 +289,9 @@ public function testRemove() /** * Test for the loadAll() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::loadAll() - * - * @depends testCreate */ - public function testLoadAll() + #[Depends('testCreate')] + public function testLoadAll(): void { $repository = $this->getRepository(); @@ -349,12 +317,9 @@ public function testLoadAll() /** * Test for the loadAll() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::loadAll() - * - * @depends testLoadAll */ - public function testLoadAllWithOffsetParameter() + #[Depends('testLoadAll')] + public function testLoadAllWithOffsetParameter(): void { $repository = $this->getRepository(); @@ -374,12 +339,9 @@ public function testLoadAllWithOffsetParameter() /** * Test for the loadAll() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::loadAll() - * - * @depends testLoadAll */ - public function testLoadAllWithOffsetAndLimitParameter() + #[Depends('testLoadAll')] + public function testLoadAllWithOffsetAndLimitParameter(): void { $repository = $this->getRepository(); @@ -399,12 +361,9 @@ public function testLoadAllWithOffsetAndLimitParameter() /** * Test for the loadAll() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::loadAll() - * - * @depends testLoadAll */ - public function testLoadAllReturnsEmptyArrayByDefault() + #[Depends('testLoadAll')] + public function testLoadAllReturnsEmptyArrayByDefault(): void { $repository = $this->getRepository(); @@ -422,11 +381,8 @@ public function testLoadAllReturnsEmptyArrayByDefault() * Test for the translate() method. * * @return \Ibexa\Contracts\Core\Repository\Values\Content\URLWildcardTranslationResult - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::translate() - * - * @depends testCreate */ + #[Depends('testCreate')] public function testTranslate() { $repository = $this->getRepository(); @@ -453,12 +409,9 @@ public function testTranslate() * Test for the translate() method. * * @param \Ibexa\Contracts\Core\Repository\Values\Content\URLWildcardTranslationResult $result - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::translate() - * - * @depends testTranslate */ - public function testTranslateSetsPropertiesOnTranslationResult(URLWildcardTranslationResult $result) + #[Depends('testTranslate')] + public function testTranslateSetsPropertiesOnTranslationResult(URLWildcardTranslationResult $result): void { $this->assertPropertiesCorrect( [ @@ -471,12 +424,9 @@ public function testTranslateSetsPropertiesOnTranslationResult(URLWildcardTransl /** * Test for the translate() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::translate() - * - * @depends testTranslate */ - public function testTranslateWithForwardSetToTrue() + #[Depends('testTranslate')] + public function testTranslateWithForwardSetToTrue(): void { $repository = $this->getRepository(); @@ -501,12 +451,9 @@ public function testTranslateWithForwardSetToTrue() /** * Test for the translate() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::translate() - * - * @depends testTranslate */ - public function testTranslateReturnsLongestMatchingWildcard() + #[Depends('testTranslate')] + public function testTranslateReturnsLongestMatchingWildcard(): void { $repository = $this->getRepository(); @@ -526,12 +473,9 @@ public function testTranslateReturnsLongestMatchingWildcard() /** * Test for the translate() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::translate() - * - * @depends testTranslate */ - public function testTranslateThrowsNotFoundExceptionWhenNotAliasOrWildcardMatches() + #[Depends('testTranslate')] + public function testTranslateThrowsNotFoundExceptionWhenNotAliasOrWildcardMatches(): void { $this->expectException(NotFoundException::class); diff --git a/tests/integration/Core/Repository/UserPreferenceServiceTest.php b/tests/integration/Core/Repository/UserPreferenceServiceTest.php index 0d14ce7ba5..639070b2a5 100644 --- a/tests/integration/Core/Repository/UserPreferenceServiceTest.php +++ b/tests/integration/Core/Repository/UserPreferenceServiceTest.php @@ -12,18 +12,17 @@ use Ibexa\Contracts\Core\Repository\Values\UserPreference\UserPreference; use Ibexa\Contracts\Core\Repository\Values\UserPreference\UserPreferenceList; use Ibexa\Contracts\Core\Repository\Values\UserPreference\UserPreferenceSetStruct; +use Ibexa\Core\Repository\UserPreferenceService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Depends; /** * Test case for the UserPreferenceService. - * - * @covers \Ibexa\Contracts\Core\Repository\UserPreferenceService */ +#[CoversClass(UserPreferenceService::class)] class UserPreferenceServiceTest extends BaseTestCase { - /** - * @covers \Ibexa\Contracts\Core\Repository\UserPreferenceService::loadUserPreferences() - */ - public function testLoadUserPreferences() + public function testLoadUserPreferences(): void { $repository = $this->getRepository(); @@ -38,10 +37,7 @@ public function testLoadUserPreferences() self::assertEquals(5, $userPreferenceList->totalCount); } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserPreferenceService::getUserPreference() - */ - public function testGetUserPreference() + public function testGetUserPreference(): void { $repository = $this->getRepository(); @@ -57,12 +53,8 @@ public function testGetUserPreference() self::assertEquals($userPreferenceName, $userPreference->name); } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserPreferenceService::setUserPreference() - * - * @depends testGetUserPreference - */ - public function testSetUserPreference() + #[Depends('testGetUserPreference')] + public function testSetUserPreference(): void { $repository = $this->getRepository(); @@ -84,12 +76,8 @@ public function testSetUserPreference() self::assertEquals($userPreferenceName, $userPreference->name); } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserPreferenceService::setUserPreference() - * - * @depends testSetUserPreference - */ - public function testSetUserPreferenceThrowsInvalidArgumentExceptionOnInvalidValue() + #[Depends('testSetUserPreference')] + public function testSetUserPreferenceThrowsInvalidArgumentExceptionOnInvalidValue(): void { $this->expectException(InvalidArgumentException::class); @@ -108,12 +96,8 @@ public function testSetUserPreferenceThrowsInvalidArgumentExceptionOnInvalidValu /* END: Use Case */ } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserPreferenceService::setUserPreference() - * - * @depends testSetUserPreference - */ - public function testSetUserPreferenceThrowsInvalidArgumentExceptionOnEmptyName() + #[Depends('testSetUserPreference')] + public function testSetUserPreferenceThrowsInvalidArgumentExceptionOnEmptyName(): void { $this->expectException(InvalidArgumentException::class); @@ -131,10 +115,7 @@ public function testSetUserPreferenceThrowsInvalidArgumentExceptionOnEmptyName() /* END: Use Case */ } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserPreferenceService::getUserPreferenceCount() - */ - public function testGetUserPreferenceCount() + public function testGetUserPreferenceCount(): void { $repository = $this->getRepository(); diff --git a/tests/integration/Core/Repository/UserServiceAuthorizationTest.php b/tests/integration/Core/Repository/UserServiceAuthorizationTest.php index 108a3e7b2a..eb911320f2 100644 --- a/tests/integration/Core/Repository/UserServiceAuthorizationTest.php +++ b/tests/integration/Core/Repository/UserServiceAuthorizationTest.php @@ -8,25 +8,24 @@ namespace Ibexa\Tests\Integration\Core\Repository; use Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException; +use Ibexa\Core\Repository\UserService; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DependsExternal; +use PHPUnit\Framework\Attributes\Group; /** * Test case for operations in the UserService using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService - * - * @group integration - * @group authorization */ +#[CoversClass(UserService::class)] +#[Group('integration')] +#[Group('authorization')] class UserServiceAuthorizationTest extends BaseTestCase { /** * Test for the loadUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUserGroup() - * - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testLoadUserGroup */ - public function testLoadUserGroupThrowsUnauthorizedException() + #[DependsExternal(UserServiceTest::class, 'testLoadUserGroup')] + public function testLoadUserGroupThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -49,11 +48,8 @@ public function testLoadUserGroupThrowsUnauthorizedException() /** * Test for the loadUserGroupByRemoteId() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUserGroupByRemoteId() - * - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testLoadUserGroupByRemoteId */ + #[DependsExternal(UserServiceTest::class, 'testLoadUserGroupByRemoteId')] public function testLoadUserGroupByRemoteIdThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -75,12 +71,9 @@ public function testLoadUserGroupByRemoteIdThrowsUnauthorizedException(): void /** * Test for the loadSubUserGroups() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadSubUserGroups() - * - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testLoadSubUserGroups */ - public function testLoadSubUserGroupsThrowsUnauthorizedException() + #[DependsExternal(UserServiceTest::class, 'testLoadSubUserGroups')] + public function testLoadSubUserGroupsThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -103,12 +96,9 @@ public function testLoadSubUserGroupsThrowsUnauthorizedException() /** * Test for the createUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::createUserGroup() - * - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testCreateUserGroup */ - public function testCreateUserGroupThrowsUnauthorizedException() + #[DependsExternal(UserServiceTest::class, 'testCreateUserGroup')] + public function testCreateUserGroupThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -138,12 +128,9 @@ public function testCreateUserGroupThrowsUnauthorizedException() /** * Test for the deleteUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::deleteUserGroup() - * - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testDeleteUserGroup */ - public function testDeleteUserGroupThrowsUnauthorizedException() + #[DependsExternal(UserServiceTest::class, 'testDeleteUserGroup')] + public function testDeleteUserGroupThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -166,12 +153,9 @@ public function testDeleteUserGroupThrowsUnauthorizedException() /** * Test for the moveUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::moveUserGroup() - * - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testMoveUserGroup */ - public function testMoveUserGroupThrowsUnauthorizedException() + #[DependsExternal(UserServiceTest::class, 'testMoveUserGroup')] + public function testMoveUserGroupThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -201,12 +185,9 @@ public function testMoveUserGroupThrowsUnauthorizedException() /** * Test for the updateUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUserGroup() - * - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testUpdateUserGroup */ - public function testUpdateUserGroupThrowsUnauthorizedException() + #[DependsExternal(UserServiceTest::class, 'testUpdateUserGroup')] + public function testUpdateUserGroupThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -239,12 +220,9 @@ public function testUpdateUserGroupThrowsUnauthorizedException() /** * Test for the createUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::createUser() - * - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testCreateUser */ - public function testCreateUserThrowsUnauthorizedException() + #[DependsExternal(UserServiceTest::class, 'testCreateUser')] + public function testCreateUserThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -283,12 +261,9 @@ public function testCreateUserThrowsUnauthorizedException() /** * Test for the deleteUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::deleteUser() - * - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testDeleteUser */ - public function testDeleteUserThrowsUnauthorizedException() + #[DependsExternal(UserServiceTest::class, 'testDeleteUser')] + public function testDeleteUserThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -309,10 +284,8 @@ public function testDeleteUserThrowsUnauthorizedException() /** * Test for the updateUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUser() */ - public function testUpdateUserThrowsUnauthorizedException() + public function testUpdateUserThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -335,9 +308,6 @@ public function testUpdateUserThrowsUnauthorizedException() /* END: Use Case */ } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUserPassword - */ public function testUpdateUserPasswordThrowsUnauthorizedException(): void { $repository = $this->getRepository(); @@ -362,12 +332,9 @@ public function testUpdateUserPasswordThrowsUnauthorizedException(): void /** * Test for the assignUserToUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::assignUserToUserGroup() - * - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testAssignUserToUserGroup */ - public function testAssignUserToUserGroupThrowsUnauthorizedException() + #[DependsExternal(UserServiceTest::class, 'testAssignUserToUserGroup')] + public function testAssignUserToUserGroupThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -395,12 +362,9 @@ public function testAssignUserToUserGroupThrowsUnauthorizedException() /** * Test for the unAssignUssrFromUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::unAssignUssrFromUserGroup() - * - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testUnAssignUserFromUserGroup */ - public function testUnAssignUserFromUserGroupThrowsUnauthorizedException() + #[DependsExternal(UserServiceTest::class, 'testUnAssignUserFromUserGroup')] + public function testUnAssignUserFromUserGroupThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -436,12 +400,9 @@ public function testUnAssignUserFromUserGroupThrowsUnauthorizedException() /** * Test for the loadUserGroupsOfUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUserGroupsOfUser() - * - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testLoadUserGroupsOfUser */ - public function testLoadUserGroupsOfUserThrowsUnauthorizedException() + #[DependsExternal(UserServiceTest::class, 'testLoadUserGroupsOfUser')] + public function testLoadUserGroupsOfUserThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -463,12 +424,9 @@ public function testLoadUserGroupsOfUserThrowsUnauthorizedException() /** * Test for the loadUsersOfUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUsersOfUserGroup() - * - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testLoadUsersOfUserGroup */ - public function testLoadUsersOfUserGroupThrowsUnauthorizedException() + #[DependsExternal(UserServiceTest::class, 'testLoadUsersOfUserGroup')] + public function testLoadUsersOfUserGroupThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/UserServiceTest.php b/tests/integration/Core/Repository/UserServiceTest.php index 041bdf967d..f70973f974 100644 --- a/tests/integration/Core/Repository/UserServiceTest.php +++ b/tests/integration/Core/Repository/UserServiceTest.php @@ -32,19 +32,23 @@ use Ibexa\Core\FieldType\User\Type; use Ibexa\Core\FieldType\ValidationError; use Ibexa\Core\Persistence\Legacy\User\Gateway; +use Ibexa\Core\Repository\UserService; use Ibexa\Core\Repository\Values\Content\Content; use Ibexa\Core\Repository\Values\Content\VersionInfo; use Ibexa\Core\Repository\Values\User\UserGroup; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\DependsExternal; +use PHPUnit\Framework\Attributes\Group; use Symfony\Bridge\PhpUnit\ClockMock; /** * Test case for operations in the UserService using in memory storage. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService - * - * @group integration - * @group user */ +#[CoversClass(UserService::class)] +#[Group('integration')] +#[Group('user')] class UserServiceTest extends BaseTestCase { // Example password matching default rules @@ -55,10 +59,8 @@ class UserServiceTest extends BaseTestCase /** * Test for the loadUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUserGroup() */ - public function testLoadUserGroup() + public function testLoadUserGroup(): void { $repository = $this->getRepository(); @@ -81,8 +83,6 @@ public function testLoadUserGroup() /** * Test for the loadUserGroupByRemoteId() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUserGroupByRemoteId() */ public function testLoadUserGroupByRemoteId(): void { @@ -101,10 +101,8 @@ public function testLoadUserGroupByRemoteId(): void /** * Test for the loadUserGroup() method to ensure that DomainUserGroupObject is created properly even if a user * has no access to parent of UserGroup. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUserGroup() */ - public function testLoadUserGroupWithNoAccessToParent() + public function testLoadUserGroupWithNoAccessToParent(): void { $repository = $this->getRepository(); @@ -136,12 +134,9 @@ public function testLoadUserGroupWithNoAccessToParent() /** * Test for the loadUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUserGroup() - * - * @depends testLoadUserGroup */ - public function testLoadUserGroupThrowsNotFoundException() + #[Depends('testLoadUserGroup')] + public function testLoadUserGroupThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -158,11 +153,8 @@ public function testLoadUserGroupThrowsNotFoundException() /** * Test for the loadUserGroupByRemoteId() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUserGroupByRemoteId() - * - * @depends Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testLoadUserGroupByRemoteId */ + #[DependsExternal(self::class, 'testLoadUserGroupByRemoteId')] public function testLoadUserGroupByRemoteIdThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -175,12 +167,9 @@ public function testLoadUserGroupByRemoteIdThrowsNotFoundException(): void /** * Test for the loadSubUserGroups() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadSubUserGroups() - * - * @depends testLoadUserGroup */ - public function testLoadSubUserGroups() + #[Depends('testLoadUserGroup')] + public function testLoadSubUserGroups(): void { $repository = $this->getRepository(); @@ -202,10 +191,8 @@ public function testLoadSubUserGroups() /** * Test loading sub groups throwing NotFoundException. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadSubUserGroups */ - public function testLoadSubUserGroupsThrowsNotFoundException() + public function testLoadSubUserGroupsThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -235,8 +222,6 @@ public function testLoadSubUserGroupsThrowsNotFoundException() * Test for the newUserGroupCreateStruct() method. * * @return \Ibexa\Contracts\Core\Repository\Values\User\UserGroupCreateStruct - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::newUserGroupCreateStruct() */ public function testNewUserGroupCreateStruct() { @@ -260,12 +245,9 @@ public function testNewUserGroupCreateStruct() * Test for the newUserGroupCreateStruct() method. * * @param \Ibexa\Contracts\Core\Repository\Values\User\UserGroupCreateStruct $groupCreate - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::newUserGroupCreateStruct() - * - * @depends testNewUserGroupCreateStruct */ - public function testNewUserGroupCreateStructSetsMainLanguageCode($groupCreate) + #[Depends('testNewUserGroupCreateStruct')] + public function testNewUserGroupCreateStructSetsMainLanguageCode($groupCreate): void { self::assertEquals('eng-US', $groupCreate->mainLanguageCode); } @@ -274,12 +256,9 @@ public function testNewUserGroupCreateStructSetsMainLanguageCode($groupCreate) * Test for the newUserGroupCreateStruct() method. * * @param \Ibexa\Contracts\Core\Repository\Values\User\UserGroupCreateStruct $groupCreate - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::newUserGroupCreateStruct() - * - * @depends testNewUserGroupCreateStruct */ - public function testNewUserGroupCreateStructSetsContentType($groupCreate) + #[Depends('testNewUserGroupCreateStruct')] + public function testNewUserGroupCreateStructSetsContentType($groupCreate): void { self::assertInstanceOf( ContentType::class, @@ -289,12 +268,9 @@ public function testNewUserGroupCreateStructSetsContentType($groupCreate) /** * Test for the newUserGroupCreateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::newUserGroupCreateStruct($mainLanguageCode, $contentType) - * - * @depends testNewUserGroupCreateStruct */ - public function testNewUserGroupCreateStructWithSecondParameter() + #[Depends('testNewUserGroupCreateStruct')] + public function testNewUserGroupCreateStructWithSecondParameter(): void { $repository = $this->getRepository(); @@ -319,12 +295,9 @@ public function testNewUserGroupCreateStructWithSecondParameter() * Test for the createUserGroup() method. * * @return \Ibexa\Contracts\Core\Repository\Values\User\UserGroup - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::createUserGroup() - * - * @depends testNewUserGroupCreateStruct - * @depends testLoadUserGroup */ + #[Depends('testNewUserGroupCreateStruct')] + #[Depends('testLoadUserGroup')] public function testCreateUserGroup() { /* BEGIN: Use Case */ @@ -348,12 +321,9 @@ public function testCreateUserGroup() * Test for the createUserGroup() method. * * @param \Ibexa\Contracts\Core\Repository\Values\User\UserGroup $userGroup - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::createUserGroup() - * - * @depends testCreateUserGroup */ - public function testCreateUserGroupSetsExpectedProperties($userGroup) + #[Depends('testCreateUserGroup')] + public function testCreateUserGroupSetsExpectedProperties($userGroup): void { self::assertEquals( [ @@ -367,12 +337,9 @@ public function testCreateUserGroupSetsExpectedProperties($userGroup) /** * Test for the createUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::createUserGroup() - * - * @depends testCreateUserGroup */ - public function testCreateUserGroupThrowsInvalidArgumentException() + #[Depends('testCreateUserGroup')] + public function testCreateUserGroupThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -403,12 +370,9 @@ public function testCreateUserGroupThrowsInvalidArgumentException() /** * Test for the createUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::createUserGroup() - * - * @depends testCreateUserGroup */ - public function testCreateUserGroupThrowsInvalidArgumentExceptionFieldTypeNotAccept() + #[Depends('testCreateUserGroup')] + public function testCreateUserGroupThrowsInvalidArgumentExceptionFieldTypeNotAccept(): void { $this->expectException(InvalidArgumentException::class); @@ -438,12 +402,9 @@ public function testCreateUserGroupThrowsInvalidArgumentExceptionFieldTypeNotAcc /** * Test for the createUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::createUserGroup() - * - * @depends testCreateUserGroup */ - public function testCreateUserGroupWhenMissingField() + #[Depends('testCreateUserGroup')] + public function testCreateUserGroupWhenMissingField(): void { $this->expectException(ContentFieldValidationException::class); @@ -469,12 +430,9 @@ public function testCreateUserGroupWhenMissingField() /** * Test for the createUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::createUserGroup - * - * @depends testNewUserGroupCreateStruct - * @depends testLoadUserGroup */ + #[Depends('testNewUserGroupCreateStruct')] + #[Depends('testLoadUserGroup')] public function testCreateUserGroupInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -521,12 +479,9 @@ public function testCreateUserGroupInTransactionWithRollback(): void /** * Test for the deleteUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::deleteUserGroup() - * - * @depends testCreateUserGroup */ - public function testDeleteUserGroup() + #[Depends('testCreateUserGroup')] + public function testDeleteUserGroup(): void { $this->expectException(NotFoundException::class); @@ -546,10 +501,8 @@ public function testDeleteUserGroup() /** * Test deleting user group throwing NotFoundException. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::deleteUserGroup */ - public function testDeleteUserGroupThrowsNotFoundException() + public function testDeleteUserGroupThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -573,13 +526,10 @@ public function testDeleteUserGroupThrowsNotFoundException() /** * Test for the moveUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::moveUserGroup() - * - * @depends testCreateUserGroup - * @depends testLoadSubUserGroups */ - public function testMoveUserGroup() + #[Depends('testCreateUserGroup')] + #[Depends('testLoadSubUserGroups')] + public function testMoveUserGroup(): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); @@ -621,10 +571,8 @@ static function ($content) { /** * Test moving a user group below another group throws NotFoundException. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::moveUserGroup */ - public function testMoveUserGroupThrowsNotFoundException() + public function testMoveUserGroupThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -660,10 +608,8 @@ public function testMoveUserGroupThrowsNotFoundException() /** * Test for the newUserGroupUpdateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::newUserGroupUpdateStruct */ - public function testNewUserGroupUpdateStruct() + public function testNewUserGroupUpdateStruct(): void { $repository = $this->getRepository(); @@ -684,13 +630,10 @@ public function testNewUserGroupUpdateStruct() /** * Test for the updateUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUserGroup() - * - * @depends testCreateUserGroup - * @depends testNewUserGroupUpdateStruct */ - public function testUpdateUserGroup() + #[Depends('testCreateUserGroup')] + #[Depends('testNewUserGroupUpdateStruct')] + public function testUpdateUserGroup(): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); @@ -718,12 +661,9 @@ public function testUpdateUserGroup() /** * Test for the updateUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUserGroup() - * - * @depends testUpdateUserGroup */ - public function testUpdateUserGroupWithSubContentUpdateStruct() + #[Depends('testUpdateUserGroup')] + public function testUpdateUserGroupWithSubContentUpdateStruct(): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); @@ -759,12 +699,9 @@ public function testUpdateUserGroupWithSubContentUpdateStruct() /** * Test for the updateUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUserGroup() - * - * @depends testUpdateUserGroup */ - public function testUpdateUserGroupWithSubContentMetadataUpdateStruct() + #[Depends('testUpdateUserGroup')] + public function testUpdateUserGroupWithSubContentMetadataUpdateStruct(): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); @@ -803,12 +740,9 @@ public function testUpdateUserGroupWithSubContentMetadataUpdateStruct() /** * Test for the updateUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUserGroup() - * - * @depends testUpdateUserGroup */ - public function testUpdateUserGroupThrowsInvalidArgumentExceptionOnFieldTypeNotAccept() + #[Depends('testUpdateUserGroup')] + public function testUpdateUserGroupThrowsInvalidArgumentExceptionOnFieldTypeNotAccept(): void { $this->expectException(InvalidArgumentException::class); @@ -838,8 +772,6 @@ public function testUpdateUserGroupThrowsInvalidArgumentExceptionOnFieldTypeNotA /** * Test for the newUserCreateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::newUserCreateStruct() */ public function testNewUserCreateStruct() { @@ -866,10 +798,8 @@ public function testNewUserCreateStruct() /** * Test updating a user group throws ContentFieldValidationException. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUserGroup */ - public function testUpdateUserGroupThrowsContentFieldValidationExceptionOnRequiredFieldEmpty() + public function testUpdateUserGroupThrowsContentFieldValidationExceptionOnRequiredFieldEmpty(): void { $this->expectException(ContentFieldValidationException::class); @@ -889,12 +819,9 @@ public function testUpdateUserGroupThrowsContentFieldValidationExceptionOnRequir * Test for the newUserCreateStruct() method. * * @param \Ibexa\Contracts\Core\Repository\Values\User\UserCreateStruct $userCreate - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::newUserCreateStruct() - * - * @depends testNewUserCreateStruct */ - public function testNewUserCreateStructSetsExpectedProperties($userCreate) + #[Depends('testNewUserCreateStruct')] + public function testNewUserCreateStructSetsExpectedProperties($userCreate): void { self::assertEquals( [ @@ -914,12 +841,9 @@ public function testNewUserCreateStructSetsExpectedProperties($userCreate) /** * Test for the newUserCreateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::newUserCreateStruct($login, $email, $password, $mainLanguageCode, $contentType) - * - * @depends testNewUserCreateStruct */ - public function testNewUserCreateStructWithFifthParameter() + #[Depends('testNewUserCreateStruct')] + public function testNewUserCreateStructWithFifthParameter(): void { $repository = $this->getRepository(); @@ -958,12 +882,9 @@ public function testNewUserWithDomainName(): void * Test for the createUser() method. * * @return \Ibexa\Contracts\Core\Repository\Values\User\User - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::createUser() - * - * @depends testLoadUserGroup - * @depends testNewUserCreateStruct */ + #[Depends('testLoadUserGroup')] + #[Depends('testNewUserCreateStruct')] public function testCreateUser() { /* BEGIN: Use Case */ @@ -982,12 +903,9 @@ public function testCreateUser() * Test for the createUser() method. * * @param \Ibexa\Contracts\Core\Repository\Values\User\User $user - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::createUser() - * - * @depends testCreateUser */ - public function testCreateUserSetsExpectedProperties(User $user) + #[Depends('testCreateUser')] + public function testCreateUserSetsExpectedProperties(User $user): void { self::assertEquals( [ @@ -1005,12 +923,9 @@ public function testCreateUserSetsExpectedProperties(User $user) /** * Test for the createUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::createUser() - * - * @depends testCreateUser */ - public function testCreateUserWhenMissingField() + #[Depends('testCreateUser')] + public function testCreateUserWhenMissingField(): void { $this->expectException(ContentFieldValidationException::class); @@ -1046,12 +961,9 @@ public function testCreateUserWhenMissingField() /** * Test for the createUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::createUser() - * - * @depends testCreateUser */ - public function testCreateUserThrowsInvalidArgumentExceptionOnFieldTypeNotAccept() + #[Depends('testCreateUser')] + public function testCreateUserThrowsInvalidArgumentExceptionOnFieldTypeNotAccept(): void { $this->expectException(InvalidArgumentException::class); @@ -1087,12 +999,9 @@ public function testCreateUserThrowsInvalidArgumentExceptionOnFieldTypeNotAccept /** * Test for the createUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::createUser - * - * @depends testCreateUser */ - public function testCreateUserThrowsInvalidArgumentException() + #[Depends('testCreateUser')] + public function testCreateUserThrowsInvalidArgumentException(): void { $repository = $this->getRepository(); @@ -1136,11 +1045,8 @@ public function testCreateUserThrowsInvalidArgumentException() /** * Test for the createUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::createUser - * - * @depends testCreateUser */ + #[Depends('testCreateUser')] public function testCreateUserWithEmailAlreadyTaken(): void { $repository = $this->getRepository(); @@ -1194,11 +1100,8 @@ public function testCreateUserWithEmailAlreadyTaken(): void /** * Test for the createUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::createUser - * - * @depends testCreateUser */ + #[Depends('testCreateUser')] public function testCreateInvalidFormatUsername(): void { $repository = $this->getRepository(); @@ -1246,12 +1149,9 @@ public function testCreateInvalidFormatUsername(): void /** * Test for the createUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::createUser - * - * @depends testLoadUserGroup - * @depends testNewUserCreateStruct */ + #[Depends('testLoadUserGroup')] + #[Depends('testNewUserCreateStruct')] public function testCreateUserInTransactionWithRollback(): void { $repository = $this->getRepository(); @@ -1283,10 +1183,8 @@ public function testCreateUserInTransactionWithRollback(): void /** * Test creating a user throwing NotFoundException. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::createUser */ - public function testCreateUserThrowsNotFoundException() + public function testCreateUserThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -1316,10 +1214,8 @@ public function testCreateUserThrowsNotFoundException() /** * Test creating a user throwing UserPasswordValidationException when password doesn't follow specific rules. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::createUser */ - public function testCreateUserWithWeakPasswordThrowsUserPasswordValidationException() + public function testCreateUserWithWeakPasswordThrowsUserPasswordValidationException(): void { $userContentType = $this->createUserContentTypeWithStrongPassword(); @@ -1347,10 +1243,8 @@ public function testCreateUserWithWeakPasswordThrowsUserPasswordValidationExcept /** * Opposite test case for testCreateUserWithWeakPasswordThrowsUserPasswordValidationException. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::createUser */ - public function testCreateUserWithStrongPassword() + public function testCreateUserWithStrongPassword(): void { $userContentType = $this->createUserContentTypeWithStrongPassword(); @@ -1362,12 +1256,9 @@ public function testCreateUserWithStrongPassword() } /** - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUser() - * - * @depends testCreateUser - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException */ + #[Depends('testCreateUser')] public function testLoadUser(): void { $repository = $this->getRepository(); @@ -1390,12 +1281,9 @@ public function testLoadUser(): void /** * Test for the loadUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUser() - * - * @depends testLoadUser */ - public function testLoadUserThrowsNotFoundException() + #[Depends('testLoadUser')] + public function testLoadUserThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -1411,11 +1299,7 @@ public function testLoadUserThrowsNotFoundException() /* END: Use Case */ } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserService::checkUserCredentials() - * - * @depends testCreateUser - */ + #[Depends('testCreateUser')] public function testCheckUserCredentialsValid(): void { $repository = $this->getRepository(); @@ -1432,11 +1316,7 @@ public function testCheckUserCredentialsValid(): void self::assertTrue($credentialsValid); } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserService::checkUserCredentials() - * - * @depends testCreateUser - */ + #[Depends('testCreateUser')] public function testCheckUserCredentialsInvalid(): void { $repository = $this->getRepository(); @@ -1455,12 +1335,9 @@ public function testCheckUserCredentialsInvalid(): void /** * Test for the loadUserByLogin() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUserByLogin() - * - * @depends testCreateUser */ - public function testLoadUserByLogin() + #[Depends('testCreateUser')] + public function testLoadUserByLogin(): void { $repository = $this->getRepository(); @@ -1492,12 +1369,9 @@ public function testLoadUserByLogin() /** * Test for the loadUserByLogin() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUserByLogin() - * - * @depends testLoadUserByLogin */ - public function testLoadUserByLoginThrowsNotFoundExceptionForUnknownLogin() + #[Depends('testLoadUserByLogin')] + public function testLoadUserByLoginThrowsNotFoundExceptionForUnknownLogin(): void { $this->expectException(NotFoundException::class); @@ -1516,12 +1390,9 @@ public function testLoadUserByLoginThrowsNotFoundExceptionForUnknownLogin() /** * Test for the loadUserByLogin() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUserByLogin() - * - * @depends testLoadUserByLogin */ - public function testLoadUserByLoginWorksForLoginWithWrongCase() + #[Depends('testLoadUserByLogin')] + public function testLoadUserByLoginWorksForLoginWithWrongCase(): void { $repository = $this->getRepository(); @@ -1555,12 +1426,9 @@ public function testLoadUserByLoginWorksForLoginWithWrongCase() * Test for the loadUserByLogin() method. * * In some cases people use email as login name, make sure system works as exepcted when asking for user by email. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUserByLogin() - * - * @depends testLoadUserByLogin */ - public function testLoadUserByLoginThrowsNotFoundExceptionForUnknownLoginByEmail() + #[Depends('testLoadUserByLogin')] + public function testLoadUserByLoginThrowsNotFoundExceptionForUnknownLoginByEmail(): void { $this->expectException(NotFoundException::class); @@ -1576,11 +1444,7 @@ public function testLoadUserByLoginThrowsNotFoundExceptionForUnknownLoginByEmail /* END: Use Case */ } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUsersByEmail() - * - * @depends testCreateUser - */ + #[Depends('testCreateUser')] public function testLoadUserByEmail(): void { $repository = $this->getRepository(); @@ -1598,12 +1462,9 @@ public function testLoadUserByEmail(): void /** * Test for the loadUsersByEmail() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUsersByEmail() - * - * @depends testLoadUserByEmail */ - public function testLoadUserByEmailReturnsEmptyInUnknownEmail() + #[Depends('testLoadUserByEmail')] + public function testLoadUserByEmailReturnsEmptyInUnknownEmail(): void { $repository = $this->getRepository(); @@ -1622,13 +1483,10 @@ public function testLoadUserByEmailReturnsEmptyInUnknownEmail() /** * Test for the deleteUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::deleteUser() - * - * @depends testCreateUser - * @depends testLoadUser */ - public function testDeleteUser() + #[Depends('testCreateUser')] + #[Depends('testLoadUser')] + public function testDeleteUser(): void { $this->expectException(NotFoundException::class); @@ -1649,13 +1507,10 @@ public function testDeleteUser() /** * Test for the deleteUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::deleteUser() - * - * @depends testCreateUser - * @depends testLoadUser */ - public function testDeleteUserDeletesRelatedBookmarks() + #[Depends('testCreateUser')] + #[Depends('testLoadUser')] + public function testDeleteUserDeletesRelatedBookmarks(): void { $repository = $this->getRepository(); @@ -1685,10 +1540,8 @@ public function testDeleteUserDeletesRelatedBookmarks() /** * Test for the newUserUpdateStruct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::newUserUpdateStruct() */ - public function testNewUserUpdateStruct() + public function testNewUserUpdateStruct(): void { $repository = $this->getRepository(); @@ -1722,12 +1575,9 @@ public function testNewUserUpdateStruct() * Test for the updateUser() method. * * @return \Ibexa\Contracts\Core\Repository\Values\User\User - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUser() - * - * @depends testCreateUser - * @depends testNewUserUpdateStruct */ + #[Depends('testCreateUser')] + #[Depends('testNewUserUpdateStruct')] public function testUpdateUser() { // As \Ibexa\Tests\Integration\Core\Repository\UserServiceTest::testUpdateUserUpdatesExpectedProperties belongs on this test, @@ -1785,12 +1635,8 @@ public function testUpdateUserEmail(): void self::assertInstanceOf(User::class, $users[0]); } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUser - * - * @depends testCreateUser - * @depends testNewUserUpdateStruct - */ + #[Depends('testCreateUser')] + #[Depends('testNewUserUpdateStruct')] public function testUpdateUserNoPassword(): void { $repository = $this->getRepository(); @@ -1836,12 +1682,9 @@ public function testUpdateUserNoPassword(): void * Test for the updateUser() method. * * @param \Ibexa\Contracts\Core\Repository\Values\User\User $user - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUser() - * - * @depends testUpdateUser */ - public function testUpdateUserUpdatesExpectedProperties(User $user) + #[Depends('testUpdateUser')] + public function testUpdateUserUpdatesExpectedProperties(User $user): void { self::assertEquals( [ @@ -1871,12 +1714,9 @@ public function testUpdateUserUpdatesExpectedProperties(User $user) * Test for the updateUser() method. * * @param \Ibexa\Contracts\Core\Repository\Values\User\User $user - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUser() - * - * @depends testUpdateUser */ - public function testUpdateUserReturnsPublishedVersion(User $user) + #[Depends('testUpdateUser')] + public function testUpdateUserReturnsPublishedVersion(User $user): void { self::assertEquals( APIVersionInfo::STATUS_PUBLISHED, @@ -1886,12 +1726,9 @@ public function testUpdateUserReturnsPublishedVersion(User $user) /** * Test for the updateUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUser() - * - * @depends testUpdateUser */ - public function testUpdateUserWithContentMetadataUpdateStruct() + #[Depends('testUpdateUser')] + public function testUpdateUserWithContentMetadataUpdateStruct(): void { $repository = $this->getRepository(); @@ -1925,12 +1762,9 @@ public function testUpdateUserWithContentMetadataUpdateStruct() /** * Test for the updateUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUser() - * - * @depends testUpdateUser */ - public function testUpdateUserWithContentUpdateStruct() + #[Depends('testUpdateUser')] + public function testUpdateUserWithContentUpdateStruct(): void { $repository = $this->getRepository(); @@ -1968,12 +1802,9 @@ public function testUpdateUserWithContentUpdateStruct() /** * Test for the updateUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUser() - * - * @depends testUpdateUser */ - public function testUpdateUserWhenMissingField() + #[Depends('testUpdateUser')] + public function testUpdateUserWhenMissingField(): void { $this->expectException(ContentFieldValidationException::class); @@ -2006,12 +1837,9 @@ public function testUpdateUserWhenMissingField() /** * Test for the updateUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUser() - * - * @depends testUpdateUser */ - public function testUpdateUserThrowsInvalidArgumentExceptionOnFieldTypeNotAccept() + #[Depends('testUpdateUser')] + public function testUpdateUserThrowsInvalidArgumentExceptionOnFieldTypeNotAccept(): void { $this->expectException(InvalidArgumentException::class); @@ -2044,10 +1872,8 @@ public function testUpdateUserThrowsInvalidArgumentExceptionOnFieldTypeNotAccept /** * Test updating a user throwing UserPasswordValidationException when password doesn't follow specified rules. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUser */ - public function testUpdateUserWithWeakPasswordThrowsUserPasswordValidationException() + public function testUpdateUserWithWeakPasswordThrowsUserPasswordValidationException(): void { $userService = $this->getRepository()->getUserService(); @@ -2079,10 +1905,8 @@ public function testUpdateUserWithWeakPasswordThrowsUserPasswordValidationExcept /** * Opposite test case for testUpdateUserWithWeakPasswordThrowsUserPasswordValidationException. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUser */ - public function testUpdateUserWithStrongPassword() + public function testUpdateUserWithStrongPassword(): void { $userService = $this->getRepository()->getUserService(); @@ -2099,9 +1923,6 @@ public function testUpdateUserWithStrongPassword() self::assertInstanceOf(User::class, $user); } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUser - */ public function testUpdateUserByUserWithLimitations(): void { $repository = $this->getRepository(); @@ -2131,9 +1952,6 @@ public function testUpdateUserByUserWithLimitations(): void self::assertInstanceOf(User::class, $user); } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUserPassword - */ public function testUpdateUserPasswordWorksWithUserPasswordRole(): void { $repository = $this->getRepository(); @@ -2186,12 +2004,9 @@ public function testUpdateUserPasswordWithUnsupportedHashType(): void /** * Test for the loadUserGroupsOfUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUserGroupsOfUser - * - * @depends testCreateUser */ - public function testLoadUserGroupsOfUser() + #[Depends('testCreateUser')] + public function testLoadUserGroupsOfUser(): void { $repository = $this->getRepository(); @@ -2213,12 +2028,9 @@ public function testLoadUserGroupsOfUser() /** * Test for the loadUsersOfUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUsersOfUserGroup - * - * @depends testCreateUser */ - public function testLoadUsersOfUserGroup() + #[Depends('testCreateUser')] + public function testLoadUsersOfUserGroup(): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); @@ -2242,12 +2054,9 @@ public function testLoadUsersOfUserGroup() /** * Test for the assignUserToUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::assignUserToUserGroup() - * - * @depends testLoadUserGroupsOfUser */ - public function testAssignUserToUserGroup() + #[Depends('testLoadUserGroupsOfUser')] + public function testAssignUserToUserGroup(): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); @@ -2285,12 +2094,9 @@ public function testAssignUserToUserGroup() /** * Test for the assignUserToUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::assignUserToUserGroup - * - * @depends testAssignUserToUserGroup */ - public function testAssignUserToUserGroupThrowsInvalidArgumentException() + #[Depends('testAssignUserToUserGroup')] + public function testAssignUserToUserGroupThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Argument \'user\' is invalid: User is already in the given User Group'); @@ -2313,9 +2119,6 @@ public function testAssignUserToUserGroupThrowsInvalidArgumentException() /* END: Use Case */ } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserService::assignUserToUserGroup - */ public function testAssignUserToGroupWithLocationsValidation(): void { $repository = $this->getRepository(); @@ -2348,12 +2151,9 @@ public function testAssignUserToGroupWithLocationsValidation(): void /** * Test for the unAssignUssrFromUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::unAssignUssrFromUserGroup() - * - * @depends testLoadUserGroupsOfUser */ - public function testUnAssignUserFromUserGroup() + #[Depends('testLoadUserGroupsOfUser')] + public function testUnAssignUserFromUserGroup(): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); @@ -2391,12 +2191,9 @@ public function testUnAssignUserFromUserGroup() /** * Test for the unAssignUserFromUserGroup() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::unAssignUserFromUserGroup() - * - * @depends testUnAssignUserFromUserGroup */ - public function testUnAssignUserFromUserGroupThrowsInvalidArgumentException() + #[Depends('testUnAssignUserFromUserGroup')] + public function testUnAssignUserFromUserGroupThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -2420,12 +2217,9 @@ public function testUnAssignUserFromUserGroupThrowsInvalidArgumentException() /** * Test for the unAssignUserFromUserGroup() method removing user from the last group. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::unAssignUserFromUserGroup - * - * @depends testUnAssignUserFromUserGroup */ - public function testUnAssignUserFromUserGroupThrowsBadStateArgumentException() + #[Depends('testUnAssignUserFromUserGroup')] + public function testUnAssignUserFromUserGroupThrowsBadStateArgumentException(): void { $this->expectException(BadStateException::class); $this->expectExceptionMessage('Argument \'user\' has a bad state: User only has one User Group, cannot unassign from last group'); @@ -2446,9 +2240,6 @@ public function testUnAssignUserFromUserGroupThrowsBadStateArgumentException() /* END: Use Case */ } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserService::unAssignUserFromUserGroup - */ public function testUnAssignUserToGroupWithLocationValidation(): void { $repository = $this->getRepository(); @@ -2491,17 +2282,16 @@ public function testUnAssignUserToGroupWithLocationValidation(): void /** * Test that multi-language logic for the loadUserGroup method respects prioritized language list. * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUserGroup * - * @dataProvider getPrioritizedLanguageList * * @param string[] $prioritizedLanguages * @param string|null $expectedLanguageCode language code of expected translation */ + #[DataProvider('getPrioritizedLanguageList')] public function testLoadUserGroupWithPrioritizedLanguagesList( array $prioritizedLanguages, $expectedLanguageCode - ) { + ): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); @@ -2525,17 +2315,16 @@ public function testLoadUserGroupWithPrioritizedLanguagesList( /** * Test that multi-language logic works correctly after updating user group main language. * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUserGroup * - * @dataProvider getPrioritizedLanguageList * * @param string[] $prioritizedLanguages * @param string|null $expectedLanguageCode language code of expected translation */ + #[DataProvider('getPrioritizedLanguageList')] public function testLoadUserGroupWithPrioritizedLanguagesListAfterMainLanguageUpdate( array $prioritizedLanguages, $expectedLanguageCode - ) { + ): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); $contentService = $repository->getContentService(); @@ -2566,17 +2355,16 @@ public function testLoadUserGroupWithPrioritizedLanguagesListAfterMainLanguageUp /** * Test that multi-language logic for the loadSubUserGroups method respects prioritized language list. * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadSubUserGroups * - * @dataProvider getPrioritizedLanguageList * * @param string[] $prioritizedLanguages * @param string|null $expectedLanguageCode language code of expected translation */ + #[DataProvider('getPrioritizedLanguageList')] public function testLoadSubUserGroupsWithPrioritizedLanguagesList( array $prioritizedLanguages, $expectedLanguageCode - ) { + ): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); @@ -2608,17 +2396,16 @@ public function testLoadSubUserGroupsWithPrioritizedLanguagesList( /** * Test that multi-language logic for the loadUser method respects prioritized language list. * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUser * - * @dataProvider getPrioritizedLanguageList * * @param string[] $prioritizedLanguages * @param string|null $expectedLanguageCode language code of expected translation */ + #[DataProvider('getPrioritizedLanguageList')] public function testLoadUserWithPrioritizedLanguagesList( array $prioritizedLanguages, $expectedLanguageCode - ) { + ): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); @@ -2646,17 +2433,16 @@ public function testLoadUserWithPrioritizedLanguagesList( * Test that multi-language logic for the loadUser method works correctly after updating * user content main language. * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUserGroup * - * @dataProvider getPrioritizedLanguageList * * @param string[] $prioritizedLanguages * @param string|null $expectedLanguageCode language code of expected translation */ + #[DataProvider('getPrioritizedLanguageList')] public function testLoadUserWithPrioritizedLanguagesListAfterMainLanguageUpdate( array $prioritizedLanguages, $expectedLanguageCode - ) { + ): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); $contentService = $repository->getContentService(); @@ -2691,17 +2477,16 @@ public function testLoadUserWithPrioritizedLanguagesListAfterMainLanguageUpdate( /** * Test that multi-language logic for the loadUserByLogin method respects prioritized language list. * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUserByLogin * - * @dataProvider getPrioritizedLanguageList * * @param string[] $prioritizedLanguages * @param string|null $expectedLanguageCode language code of expected translation */ + #[DataProvider('getPrioritizedLanguageList')] public function testLoadUserByLoginWithPrioritizedLanguagesList( array $prioritizedLanguages, $expectedLanguageCode - ) { + ): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); $user = $this->createMultiLanguageUser(); @@ -2729,17 +2514,16 @@ public function testLoadUserByLoginWithPrioritizedLanguagesList( * Test that multi-language logic for the loadUsersByEmail method respects * prioritized language list. * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUsersByEmail * - * @dataProvider getPrioritizedLanguageList * * @param string[] $prioritizedLanguages * @param string|null $expectedLanguageCode language code of expected translation */ + #[DataProvider('getPrioritizedLanguageList')] public function testLoadUsersByEmailWithPrioritizedLanguagesList( array $prioritizedLanguages, $expectedLanguageCode - ) { + ): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); $user = $this->createMultiLanguageUser(); @@ -2769,17 +2553,16 @@ public function testLoadUsersByEmailWithPrioritizedLanguagesList( * Test that multi-language logic for the loadUserGroupsOfUser method respects * prioritized language list. * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUserGroupsOfUser * - * @dataProvider getPrioritizedLanguageList * * @param string[] $prioritizedLanguages * @param string|null $expectedLanguageCode language code of expected translation */ + #[DataProvider('getPrioritizedLanguageList')] public function testLoadUserGroupsOfUserWithPrioritizedLanguagesList( array $prioritizedLanguages, $expectedLanguageCode - ) { + ): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); $userGroup = $this->createMultiLanguageUserGroup(); @@ -2802,17 +2585,16 @@ public function testLoadUserGroupsOfUserWithPrioritizedLanguagesList( * Test that multi-language logic for the loadUsersOfUserGroup method respects * prioritized language list. * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUsersOfUserGroup * - * @dataProvider getPrioritizedLanguageList * * @param string[] $prioritizedLanguages * @param string|null $expectedLanguageCode language code of expected translation */ + #[DataProvider('getPrioritizedLanguageList')] public function testLoadUsersOfUserGroupWithPrioritizedLanguagesList( array $prioritizedLanguages, $expectedLanguageCode - ) { + ): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); @@ -2853,7 +2635,7 @@ public function testLoadUsersOfUserGroupWithPrioritizedLanguagesList( * * @return array */ - public function getPrioritizedLanguageList() + public static function getPrioritizedLanguageList(): array { return [ [[], null], @@ -2962,8 +2744,6 @@ private function createMultiLanguageUser($userGroupId = 13) /** * Test for the createUser() method. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::createUser() */ public function testCreateUserWithDefaultPasswordHashTypeWhenHashTypeIsUnsupported(): void { @@ -3008,9 +2788,6 @@ public function testCreateUserWithDefaultPasswordHashTypeWhenHashTypeIsUnsupport self::assertEquals(User::DEFAULT_PASSWORD_HASH, $createdUser->hashAlgorithm); } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUserByToken - */ public function testLoadUserByToken(): string { $repository = $this->getRepository(); @@ -3033,13 +2810,12 @@ public function testLoadUserByToken(): string /** * Test updating User Token. * - * @covers \Ibexa\Contracts\Core\Repository\UserService::updateUserToken() * - * @depends testLoadUserByToken * * @param string $originalUserToken */ - public function testUpdateUserToken($originalUserToken) + #[Depends('testLoadUserByToken')] + public function testUpdateUserToken($originalUserToken): void { $repository = $this->getRepository(false); $userService = $repository->getUserService(); @@ -3059,13 +2835,12 @@ public function testUpdateUserToken($originalUserToken) /** * Test invalidating (expiring) User Token. * - * @covers \Ibexa\Contracts\Core\Repository\UserService::expireUserToken() * - * @depends testLoadUserByToken * * @param string $userToken */ - public function testExpireUserToken($userToken) + #[Depends('testLoadUserByToken')] + public function testExpireUserToken($userToken): void { $this->expectException(NotFoundException::class); @@ -3083,8 +2858,6 @@ public function testExpireUserToken($userToken) /** * Test trying to load User by invalid Token. - * - * @covers \Ibexa\Contracts\Core\Repository\UserService::loadUserByToken */ public function testLoadUserByTokenThrowsNotFoundException(): void { @@ -3095,10 +2868,7 @@ public function testLoadUserByTokenThrowsNotFoundException(): void $userService->loadUserByToken('not_existing_token'); } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserService::validatePassword() - */ - public function testValidatePasswordWithDefaultContext() + public function testValidatePasswordWithDefaultContext(): void { $userService = $this->getRepository()->getUserService(); @@ -3109,12 +2879,8 @@ public function testValidatePasswordWithDefaultContext() self::assertEmpty($errors); } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserService::validatePassword() - * - * @dataProvider dataProviderForValidatePassword - */ - public function testValidatePassword(string $password, array $expectedErrors) + #[DataProvider('dataProviderForValidatePassword')] + public function testValidatePassword(string $password, array $expectedErrors): void { $userService = $this->getRepository()->getUserService(); $contentType = $this->createUserContentTypeWithStrongPassword(); @@ -3153,7 +2919,7 @@ public function testValidatePasswordReturnsErrorWhenOldPasswordIsReused(): void ); } - public function getDataForTestPasswordUpdateRespectsAllValidationSettings(): iterable + public static function getDataForTestPasswordUpdateRespectsAllValidationSettings(): iterable { $oldPassword = 'P@blish123!'; @@ -3195,11 +2961,10 @@ public function getDataForTestPasswordUpdateRespectsAllValidationSettings(): ite } /** - * @dataProvider getDataForTestPasswordUpdateRespectsAllValidationSettings - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\Exception * @throws \Exception */ + #[DataProvider('getDataForTestPasswordUpdateRespectsAllValidationSettings')] public function testUpdateUserPasswordPerformsValidation( string $oldPassword, string $newPassword, @@ -3229,7 +2994,7 @@ public function testUpdateUserPasswordPerformsValidation( * * @return array */ - public function dataProviderForValidatePassword(): array + public static function dataProviderForValidatePassword(): array { return [ [ diff --git a/tests/integration/Core/Repository/Values/Content/EmbeddingQueryBuilderTest.php b/tests/integration/Core/Repository/Values/Content/EmbeddingQueryBuilderTest.php index c71ca1ba88..13d0090cb5 100644 --- a/tests/integration/Core/Repository/Values/Content/EmbeddingQueryBuilderTest.php +++ b/tests/integration/Core/Repository/Values/Content/EmbeddingQueryBuilderTest.php @@ -22,8 +22,8 @@ final class EmbeddingQueryBuilderTest extends TestCase { public function testBuilderSetsAllowedProperties(): void { - $embedding = $this->createMock(Embedding::class); - $aggregations = [$this->createMock(Aggregation::class), $this->createMock(Aggregation::class)]; + $embedding = self::createStub(Embedding::class); + $aggregations = [self::createStub(Aggregation::class), self::createStub(Aggregation::class)]; $builder = EmbeddingQueryBuilder::create() ->withEmbedding($embedding) @@ -52,7 +52,7 @@ public function testBuilderSetsAllowedProperties(): void public function testIsValidReturnsTrueForCleanQuery(): void { $query = EmbeddingQueryBuilder::create() - ->withEmbedding($this->createMock(Embedding::class)) + ->withEmbedding(self::createStub(Embedding::class)) ->build(); self::assertTrue($query->isValid()); @@ -61,7 +61,7 @@ public function testIsValidReturnsTrueForCleanQuery(): void public function testSettingSortClausesThenIsValidThrows(): void { $query = EmbeddingQueryBuilder::create() - ->withEmbedding($this->createMock(Embedding::class)) + ->withEmbedding(self::createStub(Embedding::class)) ->build(); $query->sortClauses[] = new ContentName(BaseQuery::SORT_ASC); diff --git a/tests/integration/Core/Repository/Values/User/Limitation/BaseLimitationTestCase.php b/tests/integration/Core/Repository/Values/User/Limitation/BaseLimitationTestCase.php index 00cbeebdd4..406758cfc1 100644 --- a/tests/integration/Core/Repository/Values/User/Limitation/BaseLimitationTestCase.php +++ b/tests/integration/Core/Repository/Values/User/Limitation/BaseLimitationTestCase.php @@ -14,13 +14,13 @@ use Ibexa\Contracts\Core\Repository\Values\User\PolicyCreateStruct; use Ibexa\Contracts\Core\Repository\Values\User\Role; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; +use PHPUnit\Framework\Attributes\Group; /** * Abstract base class for limitation tests. - * - * @group integration - * @group limitation */ +#[Group('integration')] +#[Group('limitation')] abstract class BaseLimitationTestCase extends BaseTestCase { /** diff --git a/tests/integration/Core/Repository/Values/User/Limitation/ChangeOwnerLimitationTest.php b/tests/integration/Core/Repository/Values/User/Limitation/ChangeOwnerLimitationTest.php index 699b97a12d..58487f0fc2 100644 --- a/tests/integration/Core/Repository/Values/User/Limitation/ChangeOwnerLimitationTest.php +++ b/tests/integration/Core/Repository/Values/User/Limitation/ChangeOwnerLimitationTest.php @@ -17,14 +17,14 @@ use Ibexa\Contracts\Core\Repository\Values\User\Role; use Ibexa\Contracts\Core\Repository\Values\User\RoleDraft; use Ibexa\Contracts\Core\Repository\Values\User\User; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; use RuntimeException; -/** - * @covers \Ibexa\Contracts\Core\Repository\Values\User\Limitation\ChangeOwnerLimitation - * - * @group integration - * @group limitation - */ +#[CoversClass(ChangeOwnerLimitation::class)] +#[Group('integration')] +#[Group('limitation')] final class ChangeOwnerLimitationTest extends BaseLimitationTestCase { private PermissionResolver $permissionResolver; @@ -49,7 +49,7 @@ protected function setUp(): void * 2: int[] * }> */ - public function getDataForGrantedAccess(): array + public static function getDataForGrantedAccess(): array { $otherUserId1 = 123; $otherUserId2 = 456; @@ -70,7 +70,7 @@ public function getDataForGrantedAccess(): array * 2: int[] * }> */ - public function getDataForDeniedAccess(): array + public static function getDataForDeniedAccess(): array { $otherUserId1 = 123; $otherUserId2 = 456; @@ -83,10 +83,9 @@ public function getDataForDeniedAccess(): array } /** - * @dataProvider getDataForGrantedAccess - * * @param int[] $limitationValues */ + #[DataProvider('getDataForGrantedAccess')] public function testChangeOwnerLimitationAllowed(?int $ownerId, array $limitationValues): void { $currentUser = $this->createUserVersion1('current_user', null, null, 42); @@ -98,10 +97,9 @@ public function testChangeOwnerLimitationAllowed(?int $ownerId, array $limitatio } /** - * @dataProvider getDataForDeniedAccess - * * @param int[] $limitationValues */ + #[DataProvider('getDataForDeniedAccess')] public function testChangeOwnerLimitationDenied(?int $ownerId, array $limitationValues): void { $currentUser = $this->createUserVersion1('current_user', null, null, 42); diff --git a/tests/integration/Core/Repository/Values/User/Limitation/ContentTypeLimitationTest.php b/tests/integration/Core/Repository/Values/User/Limitation/ContentTypeLimitationTest.php index 8f7e67f82a..9da50b2e5f 100644 --- a/tests/integration/Core/Repository/Values/User/Limitation/ContentTypeLimitationTest.php +++ b/tests/integration/Core/Repository/Values/User/Limitation/ContentTypeLimitationTest.php @@ -9,13 +9,12 @@ use Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\ContentTypeLimitation; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; -/** - * @covers \Ibexa\Contracts\Core\Repository\Values\User\Limitation\ContentTypeLimitation - * - * @group integration - * @group limitation - */ +#[CoversClass(ContentTypeLimitation::class)] +#[Group('integration')] +#[Group('limitation')] class ContentTypeLimitationTest extends BaseLimitationTestCase { /** @@ -23,7 +22,7 @@ class ContentTypeLimitationTest extends BaseLimitationTestCase * * @throws \ErrorException */ - public function testContentTypeLimitationAllow() + public function testContentTypeLimitationAllow(): void { $repository = $this->getRepository(); $permissionResolver = $repository->getPermissionResolver(); @@ -93,7 +92,7 @@ public function testContentTypeLimitationAllow() * * @throws \ErrorException */ - public function testContentTypeLimitationForbid() + public function testContentTypeLimitationForbid(): void { $this->expectException(UnauthorizedException::class); @@ -151,7 +150,7 @@ public function testContentTypeLimitationForbid() /** * @throws \ErrorException */ - public function testContentTypeLimitationForbidVariant() + public function testContentTypeLimitationForbidVariant(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php b/tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php index 2d68931790..8a25e09294 100644 --- a/tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php +++ b/tests/integration/Core/Repository/Values/User/Limitation/LanguageLimitationTest.php @@ -16,17 +16,22 @@ use Ibexa\Contracts\Core\Repository\Values\Content\LocationUpdateStruct; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\LanguageLimitation; use Ibexa\Contracts\Core\Repository\Values\User\User; +use Ibexa\Core\Repository\ContentService as CoveredContentService; +use Ibexa\Core\Repository\Permission\PermissionResolver; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; /** * Test cases for ContentService APIs calls made by user with LanguageLimitation on chosen policies. - * - * @covers \Ibexa\Contracts\Core\Repository\Values\User\Limitation\LanguageLimitation - * - * @group integration - * @group authorization - * @group language-limited-content-mgm */ +#[CoversClass(LanguageLimitation::class)] +#[CoversClass(PermissionResolver::class)] +#[CoversClass(CoveredContentService::class)] +#[Group('integration')] +#[Group('authorization')] +#[Group('language-limited-content-mgm')] class LanguageLimitationTest extends BaseTestCase { /** @var string */ @@ -79,7 +84,7 @@ private function createEditorUserWithLanguageLimitation( * * @see testCreateAndPublishContent */ - public function providerForCreateAndPublishContent(): array + public static function providerForCreateAndPublishContent(): array { // $names (as admin), $allowedTranslationsList (editor limitations) return [ @@ -100,12 +105,11 @@ public function providerForCreateAndPublishContent(): array * @param array $names * @param array $allowedTranslationsList * - * @dataProvider providerForCreateAndPublishContent - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ + #[DataProvider('providerForCreateAndPublishContent')] public function testCreateAndPublishContent(array $names, array $allowedTranslationsList): void { $repository = $this->getRepository(); @@ -124,10 +128,6 @@ public function testCreateAndPublishContent(array $names, array $allowedTranslat } /** - * @covers \Ibexa\Contracts\Core\Repository\PermissionResolver::canUser - * - * @dataProvider providerForCanUserWithLimitationTargets - * * @param array $folderNames names of a folder to create as test content * @param array $allowedTranslationsList a list of language codes of translations a user is allowed to edit * @param \Ibexa\Contracts\Core\Limitation\Target[] $targets @@ -137,6 +137,7 @@ public function testCreateAndPublishContent(array $names, array $allowedTranslat * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ + #[DataProvider('providerForCanUserWithLimitationTargets')] public function testCanUserWithLimitationTargets( string $policyModule, string $policyFunction, @@ -176,7 +177,7 @@ public function testCanUserWithLimitationTargets( * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ - public function providerForCanUserWithLimitationTargets(): array + public static function providerForCanUserWithLimitationTargets(): array { return [ 'Editing a content before translating it' => [ @@ -238,7 +239,7 @@ public function providerForCanUserWithLimitationTargets(): array * @see testPublishVersionIsNotAllowedIfModifiedOtherTranslations * @see testPublishVersion */ - public function providerForPublishVersionWithLanguageLimitation(): array + public static function providerForPublishVersionWithLanguageLimitation(): array { // $names (as admin), $namesToUpdate (as editor), $allowedTranslationsList (editor limitations) return [ @@ -276,17 +277,12 @@ public function providerForPublishVersionWithLanguageLimitation(): array * @param array $namesToUpdate * @param array $allowedTranslationsList * - * @dataProvider providerForPublishVersionWithLanguageLimitation - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContentDraft - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent - * @covers \Ibexa\Contracts\Core\Repository\ContentService::publishVersion - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException * @throws \Exception */ + #[DataProvider('providerForPublishVersionWithLanguageLimitation')] public function testPublishVersion( array $names, array $namesToUpdate, @@ -330,16 +326,11 @@ public function testPublishVersion( * * @param array $names * - * @dataProvider providerForPublishVersionWithLanguageLimitation - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContentDraft - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent - * @covers \Ibexa\Contracts\Core\Repository\ContentService::publishVersion - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ + #[DataProvider('providerForPublishVersionWithLanguageLimitation')] public function testPublishVersionIsNotAllowedIfModifiedOtherTranslations(array $names): void { $repository = $this->getRepository(); @@ -495,13 +486,12 @@ public function testPublishVersionTranslationWhenUserHasNoAccessToAllLanguages() } /** - * @dataProvider providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException */ + #[DataProvider('providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations')] public function testCopyContentWithLanguageLimitationAndDifferentContentTranslations( array $limitationValues, bool $containsAllTranslations @@ -528,14 +518,13 @@ public function testCopyContentWithLanguageLimitationAndDifferentContentTranslat } /** - * @dataProvider providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException */ + #[DataProvider('providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations')] public function testCopySubtreeWithLanguageLimitationAndDifferentContentTranslations( array $limitationValues, bool $containsAllTranslations @@ -566,14 +555,13 @@ public function testCopySubtreeWithLanguageLimitationAndDifferentContentTranslat } /** - * @dataProvider providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException */ + #[DataProvider('providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations')] public function testMoveSubtreeWithLanguageLimitationAndDifferentContentTranslations( array $limitationValues, bool $containsAllTranslations @@ -607,13 +595,12 @@ public function testMoveSubtreeWithLanguageLimitationAndDifferentContentTranslat } /** - * @dataProvider providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException */ + #[DataProvider('providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations')] public function testSwapLocationWithLanguageLimitationAndDifferentContentTranslations( array $limitationValues, bool $containsAllTranslations @@ -646,13 +633,12 @@ public function testSwapLocationWithLanguageLimitationAndDifferentContentTransla } /** - * @dataProvider providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException */ + #[DataProvider('providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations')] public function testHideLocationWithLanguageLimitationAndDifferentContentTranslations( array $limitationValues, bool $containsAllTranslations @@ -683,13 +669,12 @@ public function testHideLocationWithLanguageLimitationAndDifferentContentTransla } /** - * @dataProvider providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException */ + #[DataProvider('providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations')] public function testUnhideLocationWithLanguageLimitationAndDifferentContentTranslations( array $limitationValues, bool $containsAllTranslations @@ -720,13 +705,12 @@ public function testUnhideLocationWithLanguageLimitationAndDifferentContentTrans } /** - * @dataProvider providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException */ + #[DataProvider('providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations')] public function testHideContentWithLanguageLimitationAndDifferentContentTranslations( array $limitationValues, bool $containsAllTranslations @@ -753,13 +737,12 @@ public function testHideContentWithLanguageLimitationAndDifferentContentTranslat } /** - * @dataProvider providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException */ + #[DataProvider('providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations')] public function testRevealContentWithLanguageLimitationAndDifferentContentTranslations( array $limitationValues, bool $containsAllTranslations @@ -786,13 +769,12 @@ public function testRevealContentWithLanguageLimitationAndDifferentContentTransl } /** - * @dataProvider providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException */ + #[DataProvider('providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations')] public function testUpdateLocationWithLanguageLimitationAndDifferentContentTranslations( array $limitationValues, bool $containsAllTranslations @@ -823,13 +805,12 @@ public function testUpdateLocationWithLanguageLimitationAndDifferentContentTrans } /** - * @dataProvider providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ForbiddenException */ + #[DataProvider('providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations')] public function testPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations( array $limitationValues, bool $containsAllTranslations @@ -855,7 +836,7 @@ public function testPrepareDataForTestsWithLanguageLimitationAndDifferentContent /** * @return iterable, bool}> */ - public function providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations(): array + public static function providerForPrepareDataForTestsWithLanguageLimitationAndDifferentContentTranslations(): array { return [ [[self::GER_DE], false], diff --git a/tests/integration/Core/Repository/Values/User/Limitation/LocationLimitationTest.php b/tests/integration/Core/Repository/Values/User/Limitation/LocationLimitationTest.php index f104f35428..6628360157 100644 --- a/tests/integration/Core/Repository/Values/User/Limitation/LocationLimitationTest.php +++ b/tests/integration/Core/Repository/Values/User/Limitation/LocationLimitationTest.php @@ -9,21 +9,18 @@ use Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\LocationLimitation; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; -/** - * @covers \Ibexa\Contracts\Core\Repository\Values\User\Limitation\LocationLimitation - * - * @group integration - * @group limitation - */ +#[CoversClass(LocationLimitation::class)] +#[Group('integration')] +#[Group('limitation')] class LocationLimitationTest extends BaseLimitationTestCase { /** * Tests a LocationLimitation. - * - * @covers \Ibexa\Contracts\Core\Repository\Values\User\Limitation\LocationLimitation */ - public function testLocationLimitationAllow() + public function testLocationLimitationAllow(): void { $repository = $this->getRepository(); $permissionResolver = $repository->getPermissionResolver(); @@ -56,7 +53,7 @@ public function testLocationLimitationAllow() ); } - public function testLocationLimitationForbid() + public function testLocationLimitationForbid(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/Values/User/Limitation/NewObjectStateLimitationTest.php b/tests/integration/Core/Repository/Values/User/Limitation/NewObjectStateLimitationTest.php index 4d7244f068..8ae6194452 100644 --- a/tests/integration/Core/Repository/Values/User/Limitation/NewObjectStateLimitationTest.php +++ b/tests/integration/Core/Repository/Values/User/Limitation/NewObjectStateLimitationTest.php @@ -9,16 +9,15 @@ use Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\NewObjectStateLimitation; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; -/** - * @covers \Ibexa\Contracts\Core\Repository\Values\User\Limitation\NewObjectStateLimitation - * - * @group integration - * @group limitation - */ +#[CoversClass(NewObjectStateLimitation::class)] +#[Group('integration')] +#[Group('limitation')] class NewObjectStateLimitationTest extends BaseLimitationTestCase { - public function testNewObjectStateLimitationAllow() + public function testNewObjectStateLimitationAllow(): void { $repository = $this->getRepository(); $notLockedState = $this->generateId('objectstate', 2); @@ -58,11 +57,10 @@ public function testNewObjectStateLimitationAllow() /** * Tests a NewObjectStateLimitation. * - * @covers \Ibexa\Contracts\Core\Repository\Values\User\Limitation\NewObjectStateLimitation * * @throws \ErrorException if a mandatory test fixture not exists. */ - public function testNewObjectStateLimitationForbid() + public function testNewObjectStateLimitationForbid(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/Values/User/Limitation/NewSectionLimitationTest.php b/tests/integration/Core/Repository/Values/User/Limitation/NewSectionLimitationTest.php index 9e9ce53522..4100bb3d28 100644 --- a/tests/integration/Core/Repository/Values/User/Limitation/NewSectionLimitationTest.php +++ b/tests/integration/Core/Repository/Values/User/Limitation/NewSectionLimitationTest.php @@ -9,16 +9,15 @@ use Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\NewSectionLimitation; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; -/** - * @covers \Ibexa\Contracts\Core\Repository\Values\User\Limitation\NewSectionLimitation - * - * @group integration - * @group limitation - */ +#[CoversClass(NewSectionLimitation::class)] +#[Group('integration')] +#[Group('limitation')] class NewSectionLimitationTest extends BaseLimitationTestCase { - public function testNewSectionLimitationAllow() + public function testNewSectionLimitationAllow(): void { $repository = $this->getRepository(); @@ -69,7 +68,7 @@ public function testNewSectionLimitationAllow() ); } - public function testNewSectionLimitationForbid() + public function testNewSectionLimitationForbid(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/Values/User/Limitation/ObjectStateLimitationTest.php b/tests/integration/Core/Repository/Values/User/Limitation/ObjectStateLimitationTest.php index 38d419e755..2aa1d64620 100644 --- a/tests/integration/Core/Repository/Values/User/Limitation/ObjectStateLimitationTest.php +++ b/tests/integration/Core/Repository/Values/User/Limitation/ObjectStateLimitationTest.php @@ -17,14 +17,14 @@ use Ibexa\Contracts\Core\Repository\Values\ObjectState\ObjectStateGroup; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\ObjectStateLimitation; use Ibexa\Contracts\Core\Repository\Values\User\User; - -/** - * @covers \Ibexa\Contracts\Core\Repository\Values\User\Limitation\ObjectStateLimitation - * @covers \Ibexa\Core\Limitation\ObjectStateLimitationType - * - * @group integration - * @group limitation - */ +use Ibexa\Core\Limitation\ObjectStateLimitationType; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; + +#[CoversClass(ObjectStateLimitation::class)] +#[CoversClass(ObjectStateLimitationType::class)] +#[Group('integration')] +#[Group('limitation')] class ObjectStateLimitationTest extends BaseLimitationTestCase { public const OBJECT_STATE_LOCK_GROUP_ID = 2; diff --git a/tests/integration/Core/Repository/Values/User/Limitation/OwnerLimitationTest.php b/tests/integration/Core/Repository/Values/User/Limitation/OwnerLimitationTest.php index 349629a43b..7a3eb558f4 100644 --- a/tests/integration/Core/Repository/Values/User/Limitation/OwnerLimitationTest.php +++ b/tests/integration/Core/Repository/Values/User/Limitation/OwnerLimitationTest.php @@ -10,16 +10,15 @@ use Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException; use Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\OwnerLimitation; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; -/** - * @covers \Ibexa\Contracts\Core\Repository\Values\User\Limitation\OwnerLimitation - * - * @group integration - * @group limitation - */ +#[CoversClass(OwnerLimitation::class)] +#[Group('integration')] +#[Group('limitation')] class OwnerLimitationTest extends BaseLimitationTestCase { - public function testOwnerLimitationAllow() + public function testOwnerLimitationAllow(): void { $this->expectException(NotFoundException::class); @@ -86,7 +85,7 @@ public function testOwnerLimitationAllow() $contentService->loadContent($content->id); } - public function testOwnerLimitationForbid() + public function testOwnerLimitationForbid(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/Values/User/Limitation/ParentContentTypeLimitationTest.php b/tests/integration/Core/Repository/Values/User/Limitation/ParentContentTypeLimitationTest.php index 1220b0d357..4f03ebbf2e 100644 --- a/tests/integration/Core/Repository/Values/User/Limitation/ParentContentTypeLimitationTest.php +++ b/tests/integration/Core/Repository/Values/User/Limitation/ParentContentTypeLimitationTest.php @@ -10,16 +10,15 @@ use Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\ContentTypeLimitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\ParentContentTypeLimitation; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; -/** - * @covers \Ibexa\Contracts\Core\Repository\Values\User\Limitation\ParentContentTypeLimitation - * - * @group integration - * @group limitation - */ +#[CoversClass(ParentContentTypeLimitation::class)] +#[Group('integration')] +#[Group('limitation')] class ParentContentTypeLimitationTest extends BaseLimitationTestCase { - public function testParentContentTypeLimitationAllow() + public function testParentContentTypeLimitationAllow(): void { $repository = $this->getRepository(); $permissionResolver = $repository->getPermissionResolver(); @@ -67,7 +66,7 @@ public function testParentContentTypeLimitationAllow() ); } - public function testParentContentTypeLimitationForbid() + public function testParentContentTypeLimitationForbid(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/Values/User/Limitation/ParentDepthLimitationTest.php b/tests/integration/Core/Repository/Values/User/Limitation/ParentDepthLimitationTest.php index 16586856f3..6593134955 100644 --- a/tests/integration/Core/Repository/Values/User/Limitation/ParentDepthLimitationTest.php +++ b/tests/integration/Core/Repository/Values/User/Limitation/ParentDepthLimitationTest.php @@ -10,16 +10,16 @@ use Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\ContentTypeLimitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\ParentDepthLimitation; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\Group; -/** - * @covers \Ibexa\Contracts\Core\Repository\Values\User\Limitation\ParentDepthLimitation - * - * @group integration - * @group limitation - */ +#[CoversClass(ParentDepthLimitation::class)] +#[Group('integration')] +#[Group('limitation')] class ParentDepthLimitationTest extends BaseLimitationTestCase { - public function testParentDepthLimitationForbid() + public function testParentDepthLimitationForbid(): void { $this->expectException(UnauthorizedException::class); @@ -59,7 +59,7 @@ public function testParentDepthLimitationForbid() ); } - public function testParentDepthLimitationAllow() + public function testParentDepthLimitationAllow(): void { $repository = $this->getRepository(); $permissionResolver = $repository->getPermissionResolver(); @@ -101,10 +101,9 @@ public function testParentDepthLimitationAllow() /** * Tests a combination of ParentDepthLimitation and ContentTypeLimitation. - * - * @depends testParentDepthLimitationAllow */ - public function testParentDepthLimitationAllowPublish() + #[Depends('testParentDepthLimitationAllow')] + public function testParentDepthLimitationAllowPublish(): void { $repository = $this->getRepository(); $permissionResolver = $repository->getPermissionResolver(); diff --git a/tests/integration/Core/Repository/Values/User/Limitation/ParentOwnerLimitationTest.php b/tests/integration/Core/Repository/Values/User/Limitation/ParentOwnerLimitationTest.php index bd02961255..dffaaabaff 100644 --- a/tests/integration/Core/Repository/Values/User/Limitation/ParentOwnerLimitationTest.php +++ b/tests/integration/Core/Repository/Values/User/Limitation/ParentOwnerLimitationTest.php @@ -9,16 +9,15 @@ use Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\ParentOwnerLimitation; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; -/** - * @covers \Ibexa\Contracts\Core\Repository\Values\User\Limitation\ParentOwnerLimitation - * - * @group integration - * @group limitation - */ +#[CoversClass(ParentOwnerLimitation::class)] +#[Group('integration')] +#[Group('limitation')] class ParentOwnerLimitationTest extends BaseLimitationTestCase { - public function testParentOwnerLimitationAllow() + public function testParentOwnerLimitationAllow(): void { $repository = $this->getRepository(); @@ -61,7 +60,7 @@ public function testParentOwnerLimitationAllow() ); } - public function testParentOwnerLimitationForbid() + public function testParentOwnerLimitationForbid(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/Values/User/Limitation/ParentUserGroupLimitationTest.php b/tests/integration/Core/Repository/Values/User/Limitation/ParentUserGroupLimitationTest.php index 9b9a428049..a9bfaea10e 100644 --- a/tests/integration/Core/Repository/Values/User/Limitation/ParentUserGroupLimitationTest.php +++ b/tests/integration/Core/Repository/Values/User/Limitation/ParentUserGroupLimitationTest.php @@ -9,16 +9,15 @@ use Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\ParentUserGroupLimitation; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; -/** - * @covers \Ibexa\Contracts\Core\Repository\Values\User\Limitation\ParentUserGroupLimitation - * - * @group integration - * @group limitation - */ +#[CoversClass(ParentUserGroupLimitation::class)] +#[Group('integration')] +#[Group('limitation')] class ParentUserGroupLimitationTest extends BaseLimitationTestCase { - public function testParentUserGroupLimitationAllow() + public function testParentUserGroupLimitationAllow(): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); @@ -80,7 +79,7 @@ public function testParentUserGroupLimitationAllow() ); } - public function testParentUserGroupLimitationForbid() + public function testParentUserGroupLimitationForbid(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/Values/User/Limitation/RolePolicyLimitationTest.php b/tests/integration/Core/Repository/Values/User/Limitation/RolePolicyLimitationTest.php index 100e2f75bb..ce8bda9db2 100644 --- a/tests/integration/Core/Repository/Values/User/Limitation/RolePolicyLimitationTest.php +++ b/tests/integration/Core/Repository/Values/User/Limitation/RolePolicyLimitationTest.php @@ -14,16 +14,19 @@ use Ibexa\Contracts\Core\Repository\Values\User\Limitation\SubtreeLimitation; use Ibexa\Contracts\Core\Repository\Values\User\RoleCreateStruct; use Ibexa\Contracts\Core\Repository\Values\User\UserGroup; +use PHPUnit\Framework\Attributes\DataProvider; class RolePolicyLimitationTest extends BaseLimitationTestCase { /** * Data provider for {@see testRolePoliciesWithOverlappingLimitations}. + * + * @return array */ - public function providerForTestRolePoliciesWithOverlappingLimitations() + public static function providerForTestRolePoliciesWithOverlappingLimitations(): array { // get actual locations count for the given subtree when user is (by default) an admin - $actualSubtreeLocationsCount = $this->getSubtreeLocationsCount('/1/2/'); + $actualSubtreeLocationsCount = static::getSubtreeLocationsCountForFreshRepository('/1/2/'); self::assertGreaterThan(0, $actualSubtreeLocationsCount); return [ @@ -38,17 +41,17 @@ public function providerForTestRolePoliciesWithOverlappingLimitations() /** * Test if role with wider policy is not overlapped by limitation (uncovered in EZP-26476). * - * @dataProvider providerForTestRolePoliciesWithOverlappingLimitations * * @param int $expectedSubtreeLocationsCount * @param string $widePolicyModule * @param string $widePolicyFunction */ + #[DataProvider('providerForTestRolePoliciesWithOverlappingLimitations')] public function testRolePoliciesWithOverlappingLimitations( $expectedSubtreeLocationsCount, $widePolicyModule, $widePolicyFunction - ) { + ): void { $repository = $this->getRepository(); $roleService = $repository->getRoleService(); $permissionResolver = $repository->getPermissionResolver(); @@ -114,6 +117,25 @@ protected function getSubtreeLocationsCount($subtreePathString) return $result->totalCount; } + /** + * Same as {@see self::getSubtreeLocationsCount()}, but callable from the static data + * provider: resolves an independent, freshly-initialized Repository rather than reusing + * the test instance's cached one (there is no test instance yet at provider time). + * + * @param string $subtreePathString + * + * @return int|null + */ + protected static function getSubtreeLocationsCountForFreshRepository(string $subtreePathString) + { + $criterion = new Criterion\Subtree($subtreePathString); + $query = new LocationQuery(['filter' => $criterion]); + + $result = static::resolveRepository()->getSearchService()->findLocations($query); + + return $result->totalCount; + } + /** * Create test User in the given User Group. * diff --git a/tests/integration/Core/Repository/Values/User/Limitation/SectionLimitationTest.php b/tests/integration/Core/Repository/Values/User/Limitation/SectionLimitationTest.php index 14830c8d3f..d32d057285 100644 --- a/tests/integration/Core/Repository/Values/User/Limitation/SectionLimitationTest.php +++ b/tests/integration/Core/Repository/Values/User/Limitation/SectionLimitationTest.php @@ -9,16 +9,15 @@ use Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\SectionLimitation; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; -/** - * @covers \Ibexa\Contracts\Core\Repository\Values\User\Limitation\SectionLimitation - * - * @group integration - * @group limitation - */ +#[CoversClass(SectionLimitation::class)] +#[Group('integration')] +#[Group('limitation')] class SectionLimitationTest extends BaseLimitationTestCase { - public function testSectionLimitationAllow() + public function testSectionLimitationAllow(): void { $repository = $this->getRepository(); @@ -76,7 +75,7 @@ public function testSectionLimitationAllow() ); } - public function testSectionLimitationForbid() + public function testSectionLimitationForbid(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/Values/User/Limitation/StatusLimitationTest.php b/tests/integration/Core/Repository/Values/User/Limitation/StatusLimitationTest.php index 9f4b92bd15..e9e1aa979e 100644 --- a/tests/integration/Core/Repository/Values/User/Limitation/StatusLimitationTest.php +++ b/tests/integration/Core/Repository/Values/User/Limitation/StatusLimitationTest.php @@ -10,16 +10,15 @@ use Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException; use Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\StatusLimitation; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; -/** - * @covers \Ibexa\Contracts\Core\Repository\Values\User\Limitation\StatusLimitation - * - * @group integration - * @group limitation - */ +#[CoversClass(StatusLimitation::class)] +#[Group('integration')] +#[Group('limitation')] class StatusLimitationTest extends BaseLimitationTestCase { - public function testStatusLimitationAllow() + public function testStatusLimitationAllow(): void { $repository = $this->getRepository(); $permissionResolver = $repository->getPermissionResolver(); @@ -80,7 +79,7 @@ public function testStatusLimitationAllow() ); } - public function testStatusLimitationForbid() + public function testStatusLimitationForbid(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/Values/User/Limitation/SubtreeLimitationTest.php b/tests/integration/Core/Repository/Values/User/Limitation/SubtreeLimitationTest.php index ff971554da..3a11b02a07 100644 --- a/tests/integration/Core/Repository/Values/User/Limitation/SubtreeLimitationTest.php +++ b/tests/integration/Core/Repository/Values/User/Limitation/SubtreeLimitationTest.php @@ -11,13 +11,12 @@ use Ibexa\Contracts\Core\Repository\Values\User\Limitation\ContentTypeLimitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\SectionLimitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\SubtreeLimitation; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; -/** - * @covers \Ibexa\Contracts\Core\Repository\Values\User\Limitation\SubtreeLimitation - * - * @group integration - * @group limitation - */ +#[CoversClass(SubtreeLimitation::class)] +#[Group('integration')] +#[Group('limitation')] class SubtreeLimitationTest extends BaseLimitationTestCase { /** @@ -28,7 +27,7 @@ class SubtreeLimitationTest extends BaseLimitationTestCase * @see \Ibexa\Contracts\Core\Repository\Values\User\Limitation\SectionLimitation * @see \Ibexa\Contracts\Core\Repository\Values\User\Limitation\SubtreeLimitation */ - public function testSubtreeLimitationAllow() + public function testSubtreeLimitationAllow(): void { $repository = $this->getRepository(); @@ -68,7 +67,7 @@ public function testSubtreeLimitationAllow() * @see \Ibexa\Contracts\Core\Repository\Values\User\Limitation\SectionLimitation * @see \Ibexa\Contracts\Core\Repository\Values\User\Limitation\SubtreeLimitation */ - public function testSubtreeLimitationForbid() + public function testSubtreeLimitationForbid(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/Repository/Values/User/Limitation/UserGroupLimitationTest.php b/tests/integration/Core/Repository/Values/User/Limitation/UserGroupLimitationTest.php index dbd5ed3e34..66bbb122d7 100644 --- a/tests/integration/Core/Repository/Values/User/Limitation/UserGroupLimitationTest.php +++ b/tests/integration/Core/Repository/Values/User/Limitation/UserGroupLimitationTest.php @@ -11,16 +11,15 @@ use Ibexa\Contracts\Core\Repository\Values\User\Limitation\UserGroupLimitation; use Ibexa\Contracts\Core\Repository\Values\User\User; use Ibexa\Contracts\Core\Repository\Values\User\UserGroup; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; -/** - * @covers \Ibexa\Contracts\Core\Repository\Values\User\Limitation\UserGroupLimitation - * - * @group integration - * @group limitation - */ +#[CoversClass(UserGroupLimitation::class)] +#[Group('integration')] +#[Group('limitation')] class UserGroupLimitationTest extends BaseLimitationTestCase { - public function testUserGroupLimitationAllow() + public function testUserGroupLimitationAllow(): void { $repository = $this->getRepository(); $userService = $repository->getUserService(); @@ -44,7 +43,7 @@ public function testUserGroupLimitationAllow() ); } - public function testUserGroupLimitationForbid() + public function testUserGroupLimitationForbid(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/integration/Core/User/UserStorage/UserStorageGatewayTestCase.php b/tests/integration/Core/User/UserStorage/UserStorageGatewayTestCase.php index e2a47c5186..fc4c225241 100644 --- a/tests/integration/Core/User/UserStorage/UserStorageGatewayTestCase.php +++ b/tests/integration/Core/User/UserStorage/UserStorageGatewayTestCase.php @@ -12,6 +12,7 @@ use Ibexa\Core\FieldType\User\UserStorage\Gateway; use Ibexa\Core\Repository\Values\User\User; use Ibexa\Tests\Integration\Core\BaseCoreFieldTypeIntegrationTestCase; +use PHPUnit\Framework\Attributes\DataProvider; /** * User Field Type external storage gateway tests. @@ -20,7 +21,7 @@ abstract class UserStorageGatewayTestCase extends BaseCoreFieldTypeIntegrationTe { abstract protected function getGateway(): Gateway; - public function providerForGetFieldData(): array + public static function providerForGetFieldData(): array { $expectedUserData = [ 10 => [ @@ -55,18 +56,14 @@ public function providerForGetFieldData(): array ]; } - /** - * @dataProvider providerForGetFieldData - */ + #[DataProvider('providerForGetFieldData')] public function testGetFieldData(?int $fieldId, ?int $userId, array $expectedUserData): void { $data = $this->getGateway()->getFieldData($fieldId, $userId); self::assertEquals($expectedUserData, $data); } - /** - * @dataProvider getDataForTestCountUsersWithUnsupportedHashType - */ + #[DataProvider('getDataForTestCountUsersWithUnsupportedHashType')] public function testCountUsersWithUnsupportedHashType( int $expectedCount, ?string $fixtureFilePath @@ -80,7 +77,7 @@ public function testCountUsersWithUnsupportedHashType( self::assertEquals($expectedCount, $actualCount); } - public function getDataForTestCountUsersWithUnsupportedHashType(): iterable + public static function getDataForTestCountUsersWithUnsupportedHashType(): iterable { yield 'no unsupported hashes' => [ 0, diff --git a/tests/lib/Base/Container/Compiler/FieldTypeRegistryPassTest.php b/tests/lib/Base/Container/Compiler/FieldTypeRegistryPassTest.php index 7d30cdcbf2..773f61b1ff 100644 --- a/tests/lib/Base/Container/Compiler/FieldTypeRegistryPassTest.php +++ b/tests/lib/Base/Container/Compiler/FieldTypeRegistryPassTest.php @@ -10,6 +10,7 @@ use Ibexa\Core\Base\Container\Compiler\FieldTypeRegistryPass; use Ibexa\Core\FieldType\FieldTypeRegistry; use Matthias\SymfonyDependencyInjectionTest\PhpUnit\AbstractCompilerPassTestCase; +use PHPUnit\Framework\Attributes\DataProvider; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Definition; use Symfony\Component\DependencyInjection\Reference; @@ -33,10 +34,8 @@ protected function registerCompilerPass(ContainerBuilder $container): void $container->addCompilerPass(new FieldTypeRegistryPass()); } - /** - * @dataProvider tagsProvider - */ - public function testRegisterFieldType(string $tag) + #[DataProvider('tagsProvider')] + public function testRegisterFieldType(string $tag): void { $fieldTypeIdentifier = 'field_type_identifier'; $serviceId = 'service_id'; @@ -54,11 +53,10 @@ public function testRegisterFieldType(string $tag) } /** - * @dataProvider tagsProvider - * * @param string $tag */ - public function testRegisterFieldTypeNoAlias(string $tag) + #[DataProvider('tagsProvider')] + public function testRegisterFieldTypeNoAlias(string $tag): void { $this->expectException(\LogicException::class); @@ -77,7 +75,7 @@ public function testRegisterFieldTypeNoAlias(string $tag) ); } - public function tagsProvider(): array + public static function tagsProvider(): array { return [ [FieldTypeRegistryPass::FIELD_TYPE_SERVICE_TAG], diff --git a/tests/lib/Base/Container/Compiler/Search/FieldTypeRegistryPassTest.php b/tests/lib/Base/Container/Compiler/Search/FieldTypeRegistryPassTest.php index 1efb7e677c..526494fca9 100644 --- a/tests/lib/Base/Container/Compiler/Search/FieldTypeRegistryPassTest.php +++ b/tests/lib/Base/Container/Compiler/Search/FieldTypeRegistryPassTest.php @@ -33,7 +33,7 @@ protected function registerCompilerPass(ContainerBuilder $container): void $container->addCompilerPass(new FieldRegistryPass()); } - public function testRegisterFieldType() + public function testRegisterFieldType(): void { $fieldTypeIdentifier = 'field_type_identifier'; $serviceId = 'service_id'; @@ -50,7 +50,7 @@ public function testRegisterFieldType() ); } - public function testRegisterFieldTypeNoAlias() + public function testRegisterFieldTypeNoAlias(): void { $this->expectException(\LogicException::class); diff --git a/tests/lib/Base/Container/Compiler/Search/Legacy/CriteriaConverterPassTest.php b/tests/lib/Base/Container/Compiler/Search/Legacy/CriteriaConverterPassTest.php index d4b85d14b8..3e6b931665 100644 --- a/tests/lib/Base/Container/Compiler/Search/Legacy/CriteriaConverterPassTest.php +++ b/tests/lib/Base/Container/Compiler/Search/Legacy/CriteriaConverterPassTest.php @@ -10,6 +10,7 @@ use Ibexa\Core\Base\Container\Compiler\Search\Legacy\CriteriaConverterPass; use Ibexa\Core\Persistence\Legacy\URL\Query\CriteriaConverter; use Matthias\SymfonyDependencyInjectionTest\PhpUnit\AbstractCompilerPassTestCase; +use PHPUnit\Framework\Attributes\DataProvider; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Definition; use Symfony\Component\DependencyInjection\Reference; @@ -27,9 +28,7 @@ protected function registerCompilerPass(ContainerBuilder $container): void $container->addCompilerPass(new CriteriaConverterPass()); } - /** - * @dataProvider provideDescribedServiceToTagName - */ + #[DataProvider('provideDescribedServiceToTagName')] public function testAddHandlers(string $serviceId, string $tag): void { $this->setDefinition( @@ -50,9 +49,7 @@ public function testAddHandlers(string $serviceId, string $tag): void ); } - /** - * @dataProvider provideDescribedServiceToTagName - */ + #[DataProvider('provideDescribedServiceToTagName')] public function testAddContentHandlersWithPriority(string $serviceId, string $tag): void { $this->setDefinition( diff --git a/tests/lib/Base/Container/Compiler/Search/Legacy/CriterionFieldValueHandlerRegistryPassTest.php b/tests/lib/Base/Container/Compiler/Search/Legacy/CriterionFieldValueHandlerRegistryPassTest.php index 7cb1b9e5f8..0502c551b9 100644 --- a/tests/lib/Base/Container/Compiler/Search/Legacy/CriterionFieldValueHandlerRegistryPassTest.php +++ b/tests/lib/Base/Container/Compiler/Search/Legacy/CriterionFieldValueHandlerRegistryPassTest.php @@ -36,7 +36,7 @@ protected function registerCompilerPass(ContainerBuilder $container): void $container->addCompilerPass(new CriterionFieldValueHandlerRegistryPass()); } - public function testRegisterValueHandler() + public function testRegisterValueHandler(): void { $fieldTypeIdentifier = 'field_type_identifier'; $serviceId = 'service_id'; @@ -56,7 +56,7 @@ public function testRegisterValueHandler() ); } - public function testRegisterValueHandlerNoAlias() + public function testRegisterValueHandlerNoAlias(): void { $this->expectException(\LogicException::class); diff --git a/tests/lib/Base/Container/Compiler/Search/Legacy/SortClauseConverterPassTest.php b/tests/lib/Base/Container/Compiler/Search/Legacy/SortClauseConverterPassTest.php index 1fa7eb7372..4fe405fcb2 100644 --- a/tests/lib/Base/Container/Compiler/Search/Legacy/SortClauseConverterPassTest.php +++ b/tests/lib/Base/Container/Compiler/Search/Legacy/SortClauseConverterPassTest.php @@ -26,7 +26,7 @@ protected function registerCompilerPass(ContainerBuilder $container): void $container->addCompilerPass(new SortClauseConverterPass()); } - public function testAddContentHandlers() + public function testAddContentHandlers(): void { $this->setDefinition( 'ibexa.search.legacy.gateway.sort_clause_converter.content', @@ -47,7 +47,7 @@ public function testAddContentHandlers() ); } - public function testAddLocationHandlers() + public function testAddLocationHandlers(): void { $this->setDefinition( 'ibexa.search.legacy.gateway.sort_clause_converter.location', @@ -68,7 +68,7 @@ public function testAddLocationHandlers() ); } - public function testAddLocationAndContentHandlers() + public function testAddLocationAndContentHandlers(): void { $this->setDefinition( 'ibexa.search.legacy.gateway.sort_clause_converter.content', diff --git a/tests/lib/Base/Container/Compiler/Storage/ExternalStorageRegistryPassTest.php b/tests/lib/Base/Container/Compiler/Storage/ExternalStorageRegistryPassTest.php index 3711c3b798..e0dfd94d62 100644 --- a/tests/lib/Base/Container/Compiler/Storage/ExternalStorageRegistryPassTest.php +++ b/tests/lib/Base/Container/Compiler/Storage/ExternalStorageRegistryPassTest.php @@ -11,6 +11,7 @@ use Ibexa\Core\Persistence\Legacy\Content\StorageRegistry; use Ibexa\Tests\Core\Base\Container\Compiler\Stubs\GatewayBasedStorageHandler; use Matthias\SymfonyDependencyInjectionTest\PhpUnit\AbstractCompilerPassTestCase; +use PHPUnit\Framework\Attributes\DataProvider; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Definition; use Symfony\Component\DependencyInjection\Reference; @@ -28,10 +29,8 @@ protected function registerCompilerPass(ContainerBuilder $container): void $container->addCompilerPass(new ExternalStorageRegistryPass()); } - /** - * @dataProvider externalStorageHandlerTagsProvider - */ - public function testRegisterExternalStorageHandler(string $tag) + #[DataProvider('externalStorageHandlerTagsProvider')] + public function testRegisterExternalStorageHandler(string $tag): void { $def = new Definition(); $fieldTypeIdentifier = 'field_type_identifier'; @@ -48,10 +47,8 @@ public function testRegisterExternalStorageHandler(string $tag) ); } - /** - * @dataProvider externalStorageHandlerTagsProvider - */ - public function testRegisterExternalStorageHandlerNoAlias(string $tag) + #[DataProvider('externalStorageHandlerTagsProvider')] + public function testRegisterExternalStorageHandlerNoAlias(string $tag): void { $this->expectException(\LogicException::class); @@ -70,10 +67,8 @@ public function testRegisterExternalStorageHandlerNoAlias(string $tag) ); } - /** - * @dataProvider externalStorageHandlerGatewayTagsProvider - */ - public function testRegisterExternalStorageHandlerWithGateway(string $tag) + #[DataProvider('externalStorageHandlerGatewayTagsProvider')] + public function testRegisterExternalStorageHandlerWithGateway(string $tag): void { $handlerDef = new Definition(); $handlerDef->setClass(GatewayBasedStorageHandler::class); @@ -102,10 +97,8 @@ public function testRegisterExternalStorageHandlerWithGateway(string $tag) ); } - /** - * @dataProvider externalStorageHandlerGatewayTagsProvider - */ - public function testRegisterExternalStorageHandlerWithoutRegisteredGateway(string $tag) + #[DataProvider('externalStorageHandlerGatewayTagsProvider')] + public function testRegisterExternalStorageHandlerWithoutRegisteredGateway(string $tag): void { $this->expectException(\LogicException::class); @@ -127,10 +120,8 @@ public function testRegisterExternalStorageHandlerWithoutRegisteredGateway(strin ); } - /** - * @dataProvider externalStorageHandlerGatewayTagsProvider - */ - public function testRegisterExternalStorageHandlerWithGatewayNoAlias(string $tag) + #[DataProvider('externalStorageHandlerGatewayTagsProvider')] + public function testRegisterExternalStorageHandlerWithGatewayNoAlias(string $tag): void { $this->expectException(\LogicException::class); @@ -158,10 +149,8 @@ public function testRegisterExternalStorageHandlerWithGatewayNoAlias(string $tag ); } - /** - * @dataProvider externalStorageHandlerGatewayTagsProvider - */ - public function testRegisterExternalStorageHandlerWithGatewayNoIdentifier(string $tag) + #[DataProvider('externalStorageHandlerGatewayTagsProvider')] + public function testRegisterExternalStorageHandlerWithGatewayNoIdentifier(string $tag): void { $this->expectException(\LogicException::class); @@ -189,14 +178,14 @@ public function testRegisterExternalStorageHandlerWithGatewayNoIdentifier(string ); } - public function externalStorageHandlerTagsProvider(): array + public static function externalStorageHandlerTagsProvider(): array { return [ [ExternalStorageRegistryPass::EXTERNAL_STORAGE_HANDLER_SERVICE_TAG], ]; } - public function externalStorageHandlerGatewayTagsProvider(): array + public static function externalStorageHandlerGatewayTagsProvider(): array { return [ [ExternalStorageRegistryPass::EXTERNAL_STORAGE_HANDLER_GATEWAY_SERVICE_TAG], diff --git a/tests/lib/Base/Container/Compiler/Storage/Legacy/FieldValueConverterRegistryPassTest.php b/tests/lib/Base/Container/Compiler/Storage/Legacy/FieldValueConverterRegistryPassTest.php index 9764a3adbd..2a421d456d 100644 --- a/tests/lib/Base/Container/Compiler/Storage/Legacy/FieldValueConverterRegistryPassTest.php +++ b/tests/lib/Base/Container/Compiler/Storage/Legacy/FieldValueConverterRegistryPassTest.php @@ -33,7 +33,7 @@ protected function registerCompilerPass(ContainerBuilder $container): void $container->addCompilerPass(new FieldValueConverterRegistryPass()); } - public function testRegisterConverterNoLazy() + public function testRegisterConverterNoLazy(): void { $fieldTypeIdentifier = 'fieldtype_identifier'; $serviceId = 'some_service_id'; diff --git a/tests/lib/Base/Container/Compiler/Storage/Legacy/RoleLimitationConverterPassTest.php b/tests/lib/Base/Container/Compiler/Storage/Legacy/RoleLimitationConverterPassTest.php index cb71ba5b9c..011a4af10e 100644 --- a/tests/lib/Base/Container/Compiler/Storage/Legacy/RoleLimitationConverterPassTest.php +++ b/tests/lib/Base/Container/Compiler/Storage/Legacy/RoleLimitationConverterPassTest.php @@ -36,7 +36,7 @@ protected function registerCompilerPass(ContainerBuilder $container): void $container->addCompilerPass(new RoleLimitationConverterPass()); } - public function testRegisterRoleLimitationConverter() + public function testRegisterRoleLimitationConverter(): void { $serviceId = 'service_id'; $def = new Definition(); diff --git a/tests/lib/Base/Container/Compiler/TaggedServiceIdsIterator/DeprecationErrorCollector.php b/tests/lib/Base/Container/Compiler/TaggedServiceIdsIterator/DeprecationErrorCollector.php index 143e244563..7c0408a065 100644 --- a/tests/lib/Base/Container/Compiler/TaggedServiceIdsIterator/DeprecationErrorCollector.php +++ b/tests/lib/Base/Container/Compiler/TaggedServiceIdsIterator/DeprecationErrorCollector.php @@ -18,17 +18,14 @@ final class DeprecationErrorCollector /** @var array */ private $errors = []; - /** @var callable|null */ - private $previousErrorHandler; - public function register(): void { - $this->previousErrorHandler = set_error_handler($this, E_USER_DEPRECATED); + set_error_handler($this, E_USER_DEPRECATED); } public function unregister(): void { - set_error_handler($this->previousErrorHandler); + restore_error_handler(); } public function getErrors(): array diff --git a/tests/lib/Base/Exceptions/ContentFieldValidationExceptionTest.php b/tests/lib/Base/Exceptions/ContentFieldValidationExceptionTest.php index 730b661b23..609d9e7f1d 100644 --- a/tests/lib/Base/Exceptions/ContentFieldValidationExceptionTest.php +++ b/tests/lib/Base/Exceptions/ContentFieldValidationExceptionTest.php @@ -11,10 +11,9 @@ use Ibexa\Core\Base\Exceptions\ContentFieldValidationException; use Ibexa\Core\FieldType\ValidationError; use Ibexa\Tests\Core\Search\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Base\Exceptions\ContentFieldValidationException - */ +#[CoversClass(ContentFieldValidationException::class)] final class ContentFieldValidationExceptionTest extends TestCase { /** diff --git a/tests/lib/Base/Exceptions/UnauthorizedExceptionTest.php b/tests/lib/Base/Exceptions/UnauthorizedExceptionTest.php index 9504b469ae..5e99e99895 100644 --- a/tests/lib/Base/Exceptions/UnauthorizedExceptionTest.php +++ b/tests/lib/Base/Exceptions/UnauthorizedExceptionTest.php @@ -9,17 +9,15 @@ namespace Ibexa\Tests\Core\Base\Exceptions; use Ibexa\Core\Base\Exceptions\UnauthorizedException; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Stringable; -/** - * @covers \Ibexa\Core\Base\Exceptions\UnauthorizedException - */ +#[CoversClass(UnauthorizedException::class)] final class UnauthorizedExceptionTest extends TestCase { - /** - * @dataProvider getDataForTestConstructor - */ + #[DataProvider('getDataForTestConstructor')] public function testConstructor(UnauthorizedException $exception, string $expectedMessage): void { self::assertSame($expectedMessage, $exception->getMessage()); diff --git a/tests/lib/Container/Encore/ConfigurationDumperTest.php b/tests/lib/Container/Encore/ConfigurationDumperTest.php index 8876af9084..9d9abec636 100644 --- a/tests/lib/Container/Encore/ConfigurationDumperTest.php +++ b/tests/lib/Container/Encore/ConfigurationDumperTest.php @@ -9,13 +9,12 @@ namespace Ibexa\Tests\Core\Container\Encore; use Ibexa\Contracts\Core\Container\Encore\ConfigurationDumper; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; use Symfony\Component\DependencyInjection\ContainerInterface; use Symfony\Component\Filesystem\Filesystem; -/** - * @covers \Ibexa\Contracts\Core\Container\Encore\ConfigurationDumper - */ +#[CoversClass(ConfigurationDumper::class)] final class ConfigurationDumperTest extends TestCase { private const string PROJECT_DIR = '/var/io-tests/'; diff --git a/tests/lib/Event/BookmarkServiceTest.php b/tests/lib/Event/BookmarkServiceTest.php index deb2fff3bc..42f11a7b84 100644 --- a/tests/lib/Event/BookmarkServiceTest.php +++ b/tests/lib/Event/BookmarkServiceTest.php @@ -17,7 +17,7 @@ class BookmarkServiceTest extends AbstractServiceTestCase { - public function testCreateBookmarkEvents() + public function testCreateBookmarkEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateBookmarkEvent::class, @@ -25,10 +25,10 @@ public function testCreateBookmarkEvents() ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), ]; - $innerServiceMock = $this->createMock(BookmarkServiceInterface::class); + $innerServiceMock = self::createStub(BookmarkServiceInterface::class); $service = new BookmarkService($innerServiceMock, $traceableEventDispatcher); $service->createBookmark(...$parameters); @@ -42,7 +42,7 @@ public function testCreateBookmarkEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCreateBookmarkStopPropagationInBeforeEvents() + public function testCreateBookmarkStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateBookmarkEvent::class, @@ -50,10 +50,10 @@ public function testCreateBookmarkStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), ]; - $innerServiceMock = $this->createMock(BookmarkServiceInterface::class); + $innerServiceMock = self::createStub(BookmarkServiceInterface::class); $traceableEventDispatcher->addListener(BeforeCreateBookmarkEvent::class, static function (BeforeCreateBookmarkEvent $event) { $event->stopPropagation(); @@ -74,7 +74,7 @@ public function testCreateBookmarkStopPropagationInBeforeEvents() ]); } - public function testDeleteBookmarkEvents() + public function testDeleteBookmarkEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteBookmarkEvent::class, @@ -82,10 +82,10 @@ public function testDeleteBookmarkEvents() ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), ]; - $innerServiceMock = $this->createMock(BookmarkServiceInterface::class); + $innerServiceMock = self::createStub(BookmarkServiceInterface::class); $service = new BookmarkService($innerServiceMock, $traceableEventDispatcher); $service->deleteBookmark(...$parameters); @@ -99,7 +99,7 @@ public function testDeleteBookmarkEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testDeleteBookmarkStopPropagationInBeforeEvents() + public function testDeleteBookmarkStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteBookmarkEvent::class, @@ -107,10 +107,10 @@ public function testDeleteBookmarkStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), ]; - $innerServiceMock = $this->createMock(BookmarkServiceInterface::class); + $innerServiceMock = self::createStub(BookmarkServiceInterface::class); $traceableEventDispatcher->addListener(BeforeDeleteBookmarkEvent::class, static function (BeforeDeleteBookmarkEvent $event) { $event->stopPropagation(); diff --git a/tests/lib/Event/ContentServiceTest.php b/tests/lib/Event/ContentServiceTest.php index 7f462b9d0b..d7086dad6c 100644 --- a/tests/lib/Event/ContentServiceTest.php +++ b/tests/lib/Event/ContentServiceTest.php @@ -47,7 +47,7 @@ class ContentServiceTest extends AbstractServiceTestCase { - public function testDeleteContentEvents() + public function testDeleteContentEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteContentEvent::class, @@ -55,7 +55,7 @@ public function testDeleteContentEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), + self::createStub(ContentInfo::class), ]; $locations = []; @@ -75,7 +75,7 @@ public function testDeleteContentEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnDeleteContentResultInBeforeEvents() + public function testReturnDeleteContentResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteContentEvent::class, @@ -83,7 +83,7 @@ public function testReturnDeleteContentResultInBeforeEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), + self::createStub(ContentInfo::class), ]; $locations = []; @@ -109,7 +109,7 @@ public function testReturnDeleteContentResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testDeleteContentStopPropagationInBeforeEvents() + public function testDeleteContentStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteContentEvent::class, @@ -117,7 +117,7 @@ public function testDeleteContentStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), + self::createStub(ContentInfo::class), ]; $locations = []; @@ -146,7 +146,7 @@ public function testDeleteContentStopPropagationInBeforeEvents() ]); } - public function testCopyContentEvents() + public function testCopyContentEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCopyContentEvent::class, @@ -154,12 +154,12 @@ public function testCopyContentEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(LocationCreateStruct::class), - $this->createMock(VersionInfo::class), + self::createStub(ContentInfo::class), + self::createStub(LocationCreateStruct::class), + self::createStub(VersionInfo::class), ]; - $content = $this->createMock(Content::class); + $content = self::createStub(Content::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('copyContent')->willReturn($content); @@ -176,7 +176,7 @@ public function testCopyContentEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnCopyContentResultInBeforeEvents() + public function testReturnCopyContentResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCopyContentEvent::class, @@ -184,13 +184,13 @@ public function testReturnCopyContentResultInBeforeEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(LocationCreateStruct::class), - $this->createMock(VersionInfo::class), + self::createStub(ContentInfo::class), + self::createStub(LocationCreateStruct::class), + self::createStub(VersionInfo::class), ]; - $content = $this->createMock(Content::class); - $eventContent = $this->createMock(Content::class); + $content = self::createStub(Content::class); + $eventContent = self::createStub(Content::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('copyContent')->willReturn($content); @@ -212,7 +212,7 @@ public function testReturnCopyContentResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCopyContentStopPropagationInBeforeEvents() + public function testCopyContentStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCopyContentEvent::class, @@ -220,13 +220,13 @@ public function testCopyContentStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(LocationCreateStruct::class), - $this->createMock(VersionInfo::class), + self::createStub(ContentInfo::class), + self::createStub(LocationCreateStruct::class), + self::createStub(VersionInfo::class), ]; - $content = $this->createMock(Content::class); - $eventContent = $this->createMock(Content::class); + $content = self::createStub(Content::class); + $eventContent = self::createStub(Content::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('copyContent')->willReturn($content); @@ -251,7 +251,7 @@ public function testCopyContentStopPropagationInBeforeEvents() ]); } - public function testUpdateContentEvents() + public function testUpdateContentEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateContentEvent::class, @@ -259,11 +259,11 @@ public function testUpdateContentEvents() ); $parameters = [ - $this->createMock(VersionInfo::class), - $this->createMock(ContentUpdateStruct::class), + self::createStub(VersionInfo::class), + self::createStub(ContentUpdateStruct::class), ]; - $content = $this->createMock(Content::class); + $content = self::createStub(Content::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('updateContent')->willReturn($content); @@ -280,7 +280,7 @@ public function testUpdateContentEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnUpdateContentResultInBeforeEvents() + public function testReturnUpdateContentResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateContentEvent::class, @@ -288,12 +288,12 @@ public function testReturnUpdateContentResultInBeforeEvents() ); $parameters = [ - $this->createMock(VersionInfo::class), - $this->createMock(ContentUpdateStruct::class), + self::createStub(VersionInfo::class), + self::createStub(ContentUpdateStruct::class), ]; - $content = $this->createMock(Content::class); - $eventContent = $this->createMock(Content::class); + $content = self::createStub(Content::class); + $eventContent = self::createStub(Content::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('updateContent')->willReturn($content); @@ -315,7 +315,7 @@ public function testReturnUpdateContentResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testUpdateContentStopPropagationInBeforeEvents() + public function testUpdateContentStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateContentEvent::class, @@ -323,12 +323,12 @@ public function testUpdateContentStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(VersionInfo::class), - $this->createMock(ContentUpdateStruct::class), + self::createStub(VersionInfo::class), + self::createStub(ContentUpdateStruct::class), ]; - $content = $this->createMock(Content::class); - $eventContent = $this->createMock(Content::class); + $content = self::createStub(Content::class); + $eventContent = self::createStub(Content::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('updateContent')->willReturn($content); @@ -353,7 +353,7 @@ public function testUpdateContentStopPropagationInBeforeEvents() ]); } - public function testDeleteRelationEvents() + public function testDeleteRelationEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteRelationEvent::class, @@ -361,11 +361,11 @@ public function testDeleteRelationEvents() ); $parameters = [ - $this->createMock(VersionInfo::class), - $this->createMock(ContentInfo::class), + self::createStub(VersionInfo::class), + self::createStub(ContentInfo::class), ]; - $innerServiceMock = $this->createMock(ContentServiceInterface::class); + $innerServiceMock = self::createStub(ContentServiceInterface::class); $service = new ContentService($innerServiceMock, $traceableEventDispatcher); $service->deleteRelation(...$parameters); @@ -379,7 +379,7 @@ public function testDeleteRelationEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testDeleteRelationStopPropagationInBeforeEvents() + public function testDeleteRelationStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteRelationEvent::class, @@ -387,11 +387,11 @@ public function testDeleteRelationStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(VersionInfo::class), - $this->createMock(ContentInfo::class), + self::createStub(VersionInfo::class), + self::createStub(ContentInfo::class), ]; - $innerServiceMock = $this->createMock(ContentServiceInterface::class); + $innerServiceMock = self::createStub(ContentServiceInterface::class); $traceableEventDispatcher->addListener(BeforeDeleteRelationEvent::class, static function (BeforeDeleteRelationEvent $event) { $event->stopPropagation(); @@ -412,7 +412,7 @@ public function testDeleteRelationStopPropagationInBeforeEvents() ]); } - public function testCreateContentEvents() + public function testCreateContentEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateContentEvent::class, @@ -420,11 +420,11 @@ public function testCreateContentEvents() ); $parameters = [ - $this->createMock(ContentCreateStruct::class), + self::createStub(ContentCreateStruct::class), [], ]; - $content = $this->createMock(Content::class); + $content = self::createStub(Content::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('createContent')->willReturn($content); @@ -441,7 +441,7 @@ public function testCreateContentEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnCreateContentResultInBeforeEvents() + public function testReturnCreateContentResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateContentEvent::class, @@ -449,12 +449,12 @@ public function testReturnCreateContentResultInBeforeEvents() ); $parameters = [ - $this->createMock(ContentCreateStruct::class), + self::createStub(ContentCreateStruct::class), [], ]; - $content = $this->createMock(Content::class); - $eventContent = $this->createMock(Content::class); + $content = self::createStub(Content::class); + $eventContent = self::createStub(Content::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('createContent')->willReturn($content); @@ -476,7 +476,7 @@ public function testReturnCreateContentResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCreateContentStopPropagationInBeforeEvents() + public function testCreateContentStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateContentEvent::class, @@ -484,12 +484,12 @@ public function testCreateContentStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentCreateStruct::class), + self::createStub(ContentCreateStruct::class), [], ]; - $content = $this->createMock(Content::class); - $eventContent = $this->createMock(Content::class); + $content = self::createStub(Content::class); + $eventContent = self::createStub(Content::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('createContent')->willReturn($content); @@ -514,7 +514,7 @@ public function testCreateContentStopPropagationInBeforeEvents() ]); } - public function testHideContentEvents() + public function testHideContentEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeHideContentEvent::class, @@ -522,10 +522,10 @@ public function testHideContentEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), + self::createStub(ContentInfo::class), ]; - $innerServiceMock = $this->createMock(ContentServiceInterface::class); + $innerServiceMock = self::createStub(ContentServiceInterface::class); $service = new ContentService($innerServiceMock, $traceableEventDispatcher); $service->hideContent(...$parameters); @@ -539,7 +539,7 @@ public function testHideContentEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testHideContentStopPropagationInBeforeEvents() + public function testHideContentStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeHideContentEvent::class, @@ -547,10 +547,10 @@ public function testHideContentStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), + self::createStub(ContentInfo::class), ]; - $innerServiceMock = $this->createMock(ContentServiceInterface::class); + $innerServiceMock = self::createStub(ContentServiceInterface::class); $traceableEventDispatcher->addListener(BeforeHideContentEvent::class, static function (BeforeHideContentEvent $event) { $event->stopPropagation(); @@ -571,7 +571,7 @@ public function testHideContentStopPropagationInBeforeEvents() ]); } - public function testDeleteVersionEvents() + public function testDeleteVersionEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteVersionEvent::class, @@ -579,10 +579,10 @@ public function testDeleteVersionEvents() ); $parameters = [ - $this->createMock(VersionInfo::class), + self::createStub(VersionInfo::class), ]; - $innerServiceMock = $this->createMock(ContentServiceInterface::class); + $innerServiceMock = self::createStub(ContentServiceInterface::class); $service = new ContentService($innerServiceMock, $traceableEventDispatcher); $service->deleteVersion(...$parameters); @@ -596,7 +596,7 @@ public function testDeleteVersionEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testDeleteVersionStopPropagationInBeforeEvents() + public function testDeleteVersionStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteVersionEvent::class, @@ -604,10 +604,10 @@ public function testDeleteVersionStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(VersionInfo::class), + self::createStub(VersionInfo::class), ]; - $innerServiceMock = $this->createMock(ContentServiceInterface::class); + $innerServiceMock = self::createStub(ContentServiceInterface::class); $traceableEventDispatcher->addListener(BeforeDeleteVersionEvent::class, static function (BeforeDeleteVersionEvent $event) { $event->stopPropagation(); @@ -628,7 +628,7 @@ public function testDeleteVersionStopPropagationInBeforeEvents() ]); } - public function testAddRelationEvents() + public function testAddRelationEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeAddRelationEvent::class, @@ -636,11 +636,11 @@ public function testAddRelationEvents() ); $parameters = [ - $this->createMock(VersionInfo::class), - $this->createMock(ContentInfo::class), + self::createStub(VersionInfo::class), + self::createStub(ContentInfo::class), ]; - $relation = $this->createMock(Relation::class); + $relation = self::createStub(Relation::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('addRelation')->willReturn($relation); @@ -657,7 +657,7 @@ public function testAddRelationEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnAddRelationResultInBeforeEvents() + public function testReturnAddRelationResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeAddRelationEvent::class, @@ -665,12 +665,12 @@ public function testReturnAddRelationResultInBeforeEvents() ); $parameters = [ - $this->createMock(VersionInfo::class), - $this->createMock(ContentInfo::class), + self::createStub(VersionInfo::class), + self::createStub(ContentInfo::class), ]; - $relation = $this->createMock(Relation::class); - $eventRelation = $this->createMock(Relation::class); + $relation = self::createStub(Relation::class); + $eventRelation = self::createStub(Relation::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('addRelation')->willReturn($relation); @@ -692,7 +692,7 @@ public function testReturnAddRelationResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testAddRelationStopPropagationInBeforeEvents() + public function testAddRelationStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeAddRelationEvent::class, @@ -700,12 +700,12 @@ public function testAddRelationStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(VersionInfo::class), - $this->createMock(ContentInfo::class), + self::createStub(VersionInfo::class), + self::createStub(ContentInfo::class), ]; - $relation = $this->createMock(Relation::class); - $eventRelation = $this->createMock(Relation::class); + $relation = self::createStub(Relation::class); + $eventRelation = self::createStub(Relation::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('addRelation')->willReturn($relation); @@ -730,7 +730,7 @@ public function testAddRelationStopPropagationInBeforeEvents() ]); } - public function testUpdateContentMetadataEvents() + public function testUpdateContentMetadataEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateContentMetadataEvent::class, @@ -738,11 +738,11 @@ public function testUpdateContentMetadataEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(ContentMetadataUpdateStruct::class), + self::createStub(ContentInfo::class), + self::createStub(ContentMetadataUpdateStruct::class), ]; - $content = $this->createMock(Content::class); + $content = self::createStub(Content::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('updateContentMetadata')->willReturn($content); @@ -759,7 +759,7 @@ public function testUpdateContentMetadataEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnUpdateContentMetadataResultInBeforeEvents() + public function testReturnUpdateContentMetadataResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateContentMetadataEvent::class, @@ -767,12 +767,12 @@ public function testReturnUpdateContentMetadataResultInBeforeEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(ContentMetadataUpdateStruct::class), + self::createStub(ContentInfo::class), + self::createStub(ContentMetadataUpdateStruct::class), ]; - $content = $this->createMock(Content::class); - $eventContent = $this->createMock(Content::class); + $content = self::createStub(Content::class); + $eventContent = self::createStub(Content::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('updateContentMetadata')->willReturn($content); @@ -794,7 +794,7 @@ public function testReturnUpdateContentMetadataResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testUpdateContentMetadataStopPropagationInBeforeEvents() + public function testUpdateContentMetadataStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateContentMetadataEvent::class, @@ -802,12 +802,12 @@ public function testUpdateContentMetadataStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(ContentMetadataUpdateStruct::class), + self::createStub(ContentInfo::class), + self::createStub(ContentMetadataUpdateStruct::class), ]; - $content = $this->createMock(Content::class); - $eventContent = $this->createMock(Content::class); + $content = self::createStub(Content::class); + $eventContent = self::createStub(Content::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('updateContentMetadata')->willReturn($content); @@ -832,7 +832,7 @@ public function testUpdateContentMetadataStopPropagationInBeforeEvents() ]); } - public function testDeleteTranslationEvents() + public function testDeleteTranslationEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteTranslationEvent::class, @@ -840,11 +840,11 @@ public function testDeleteTranslationEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), + self::createStub(ContentInfo::class), 'random_value_5cff79c31a2f31.74205767', ]; - $innerServiceMock = $this->createMock(ContentServiceInterface::class); + $innerServiceMock = self::createStub(ContentServiceInterface::class); $service = new ContentService($innerServiceMock, $traceableEventDispatcher); $service->deleteTranslation(...$parameters); @@ -858,7 +858,7 @@ public function testDeleteTranslationEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testDeleteTranslationStopPropagationInBeforeEvents() + public function testDeleteTranslationStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteTranslationEvent::class, @@ -866,11 +866,11 @@ public function testDeleteTranslationStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), + self::createStub(ContentInfo::class), 'random_value_5cff79c31a2fc0.71971617', ]; - $innerServiceMock = $this->createMock(ContentServiceInterface::class); + $innerServiceMock = self::createStub(ContentServiceInterface::class); $traceableEventDispatcher->addListener(BeforeDeleteTranslationEvent::class, static function (BeforeDeleteTranslationEvent $event) { $event->stopPropagation(); @@ -891,7 +891,7 @@ public function testDeleteTranslationStopPropagationInBeforeEvents() ]); } - public function testPublishVersionEvents() + public function testPublishVersionEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforePublishVersionEvent::class, @@ -899,11 +899,11 @@ public function testPublishVersionEvents() ); $parameters = [ - $this->createMock(VersionInfo::class), + self::createStub(VersionInfo::class), [], ]; - $content = $this->createMock(Content::class); + $content = self::createStub(Content::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('publishVersion')->willReturn($content); @@ -920,7 +920,7 @@ public function testPublishVersionEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnPublishVersionResultInBeforeEvents() + public function testReturnPublishVersionResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforePublishVersionEvent::class, @@ -928,12 +928,12 @@ public function testReturnPublishVersionResultInBeforeEvents() ); $parameters = [ - $this->createMock(VersionInfo::class), + self::createStub(VersionInfo::class), [], ]; - $content = $this->createMock(Content::class); - $eventContent = $this->createMock(Content::class); + $content = self::createStub(Content::class); + $eventContent = self::createStub(Content::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('publishVersion')->willReturn($content); @@ -955,7 +955,7 @@ public function testReturnPublishVersionResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testPublishVersionStopPropagationInBeforeEvents() + public function testPublishVersionStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforePublishVersionEvent::class, @@ -963,12 +963,12 @@ public function testPublishVersionStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(VersionInfo::class), + self::createStub(VersionInfo::class), [], ]; - $content = $this->createMock(Content::class); - $eventContent = $this->createMock(Content::class); + $content = self::createStub(Content::class); + $eventContent = self::createStub(Content::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('publishVersion')->willReturn($content); @@ -993,7 +993,7 @@ public function testPublishVersionStopPropagationInBeforeEvents() ]); } - public function testCreateContentDraftEvents() + public function testCreateContentDraftEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateContentDraftEvent::class, @@ -1001,12 +1001,12 @@ public function testCreateContentDraftEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(VersionInfo::class), - $this->createMock(User::class), + self::createStub(ContentInfo::class), + self::createStub(VersionInfo::class), + self::createStub(User::class), ]; - $contentDraft = $this->createMock(Content::class); + $contentDraft = self::createStub(Content::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('createContentDraft')->willReturn($contentDraft); @@ -1023,7 +1023,7 @@ public function testCreateContentDraftEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnCreateContentDraftResultInBeforeEvents() + public function testReturnCreateContentDraftResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateContentDraftEvent::class, @@ -1031,13 +1031,13 @@ public function testReturnCreateContentDraftResultInBeforeEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(VersionInfo::class), - $this->createMock(User::class), + self::createStub(ContentInfo::class), + self::createStub(VersionInfo::class), + self::createStub(User::class), ]; - $contentDraft = $this->createMock(Content::class); - $eventContentDraft = $this->createMock(Content::class); + $contentDraft = self::createStub(Content::class); + $eventContentDraft = self::createStub(Content::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('createContentDraft')->willReturn($contentDraft); @@ -1059,7 +1059,7 @@ public function testReturnCreateContentDraftResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCreateContentDraftStopPropagationInBeforeEvents() + public function testCreateContentDraftStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateContentDraftEvent::class, @@ -1067,13 +1067,13 @@ public function testCreateContentDraftStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(VersionInfo::class), - $this->createMock(User::class), + self::createStub(ContentInfo::class), + self::createStub(VersionInfo::class), + self::createStub(User::class), ]; - $contentDraft = $this->createMock(Content::class); - $eventContentDraft = $this->createMock(Content::class); + $contentDraft = self::createStub(Content::class); + $eventContentDraft = self::createStub(Content::class); $innerServiceMock = $this->createMock(ContentServiceInterface::class); $innerServiceMock->method('createContentDraft')->willReturn($contentDraft); @@ -1098,7 +1098,7 @@ public function testCreateContentDraftStopPropagationInBeforeEvents() ]); } - public function testRevealContentEvents() + public function testRevealContentEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRevealContentEvent::class, @@ -1106,10 +1106,10 @@ public function testRevealContentEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), + self::createStub(ContentInfo::class), ]; - $innerServiceMock = $this->createMock(ContentServiceInterface::class); + $innerServiceMock = self::createStub(ContentServiceInterface::class); $service = new ContentService($innerServiceMock, $traceableEventDispatcher); $service->revealContent(...$parameters); @@ -1123,7 +1123,7 @@ public function testRevealContentEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testRevealContentStopPropagationInBeforeEvents() + public function testRevealContentStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRevealContentEvent::class, @@ -1131,10 +1131,10 @@ public function testRevealContentStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), + self::createStub(ContentInfo::class), ]; - $innerServiceMock = $this->createMock(ContentServiceInterface::class); + $innerServiceMock = self::createStub(ContentServiceInterface::class); $traceableEventDispatcher->addListener(BeforeRevealContentEvent::class, static function (BeforeRevealContentEvent $event) { $event->stopPropagation(); diff --git a/tests/lib/Event/ContentTypeServiceTest.php b/tests/lib/Event/ContentTypeServiceTest.php index 538b51683c..3f4594b4e7 100644 --- a/tests/lib/Event/ContentTypeServiceTest.php +++ b/tests/lib/Event/ContentTypeServiceTest.php @@ -53,7 +53,7 @@ class ContentTypeServiceTest extends AbstractServiceTestCase { - public function testAddFieldDefinitionEvents() + public function testAddFieldDefinitionEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeAddFieldDefinitionEvent::class, @@ -61,11 +61,11 @@ public function testAddFieldDefinitionEvents() ); $parameters = [ - $this->createMock(ContentTypeDraft::class), - $this->createMock(FieldDefinitionCreateStruct::class), + self::createStub(ContentTypeDraft::class), + self::createStub(FieldDefinitionCreateStruct::class), ]; - $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); + $innerServiceMock = self::createStub(ContentTypeServiceInterface::class); $service = new ContentTypeService($innerServiceMock, $traceableEventDispatcher); $service->addFieldDefinition(...$parameters); @@ -79,7 +79,7 @@ public function testAddFieldDefinitionEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testAddFieldDefinitionStopPropagationInBeforeEvents() + public function testAddFieldDefinitionStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeAddFieldDefinitionEvent::class, @@ -87,11 +87,11 @@ public function testAddFieldDefinitionStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentTypeDraft::class), - $this->createMock(FieldDefinitionCreateStruct::class), + self::createStub(ContentTypeDraft::class), + self::createStub(FieldDefinitionCreateStruct::class), ]; - $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); + $innerServiceMock = self::createStub(ContentTypeServiceInterface::class); $traceableEventDispatcher->addListener(BeforeAddFieldDefinitionEvent::class, static function (BeforeAddFieldDefinitionEvent $event) { $event->stopPropagation(); @@ -112,7 +112,7 @@ public function testAddFieldDefinitionStopPropagationInBeforeEvents() ]); } - public function testDeleteContentTypeGroupEvents() + public function testDeleteContentTypeGroupEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteContentTypeGroupEvent::class, @@ -120,10 +120,10 @@ public function testDeleteContentTypeGroupEvents() ); $parameters = [ - $this->createMock(ContentTypeGroup::class), + self::createStub(ContentTypeGroup::class), ]; - $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); + $innerServiceMock = self::createStub(ContentTypeServiceInterface::class); $service = new ContentTypeService($innerServiceMock, $traceableEventDispatcher); $service->deleteContentTypeGroup(...$parameters); @@ -137,7 +137,7 @@ public function testDeleteContentTypeGroupEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testDeleteContentTypeGroupStopPropagationInBeforeEvents() + public function testDeleteContentTypeGroupStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteContentTypeGroupEvent::class, @@ -145,10 +145,10 @@ public function testDeleteContentTypeGroupStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentTypeGroup::class), + self::createStub(ContentTypeGroup::class), ]; - $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); + $innerServiceMock = self::createStub(ContentTypeServiceInterface::class); $traceableEventDispatcher->addListener(BeforeDeleteContentTypeGroupEvent::class, static function (BeforeDeleteContentTypeGroupEvent $event) { $event->stopPropagation(); @@ -169,7 +169,7 @@ public function testDeleteContentTypeGroupStopPropagationInBeforeEvents() ]); } - public function testCreateContentTypeDraftEvents() + public function testCreateContentTypeDraftEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateContentTypeDraftEvent::class, @@ -177,10 +177,10 @@ public function testCreateContentTypeDraftEvents() ); $parameters = [ - $this->createMock(ContentType::class), + self::createStub(ContentType::class), ]; - $contentTypeDraft = $this->createMock(ContentTypeDraft::class); + $contentTypeDraft = self::createStub(ContentTypeDraft::class); $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); $innerServiceMock->method('createContentTypeDraft')->willReturn($contentTypeDraft); @@ -197,7 +197,7 @@ public function testCreateContentTypeDraftEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnCreateContentTypeDraftResultInBeforeEvents() + public function testReturnCreateContentTypeDraftResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateContentTypeDraftEvent::class, @@ -205,11 +205,11 @@ public function testReturnCreateContentTypeDraftResultInBeforeEvents() ); $parameters = [ - $this->createMock(ContentType::class), + self::createStub(ContentType::class), ]; - $contentTypeDraft = $this->createMock(ContentTypeDraft::class); - $eventContentTypeDraft = $this->createMock(ContentTypeDraft::class); + $contentTypeDraft = self::createStub(ContentTypeDraft::class); + $eventContentTypeDraft = self::createStub(ContentTypeDraft::class); $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); $innerServiceMock->method('createContentTypeDraft')->willReturn($contentTypeDraft); @@ -231,7 +231,7 @@ public function testReturnCreateContentTypeDraftResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCreateContentTypeDraftStopPropagationInBeforeEvents() + public function testCreateContentTypeDraftStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateContentTypeDraftEvent::class, @@ -239,11 +239,11 @@ public function testCreateContentTypeDraftStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentType::class), + self::createStub(ContentType::class), ]; - $contentTypeDraft = $this->createMock(ContentTypeDraft::class); - $eventContentTypeDraft = $this->createMock(ContentTypeDraft::class); + $contentTypeDraft = self::createStub(ContentTypeDraft::class); + $eventContentTypeDraft = self::createStub(ContentTypeDraft::class); $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); $innerServiceMock->method('createContentTypeDraft')->willReturn($contentTypeDraft); @@ -268,7 +268,7 @@ public function testCreateContentTypeDraftStopPropagationInBeforeEvents() ]); } - public function testCreateContentTypeGroupEvents() + public function testCreateContentTypeGroupEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateContentTypeGroupEvent::class, @@ -276,10 +276,10 @@ public function testCreateContentTypeGroupEvents() ); $parameters = [ - $this->createMock(ContentTypeGroupCreateStruct::class), + self::createStub(ContentTypeGroupCreateStruct::class), ]; - $contentTypeGroup = $this->createMock(ContentTypeGroup::class); + $contentTypeGroup = self::createStub(ContentTypeGroup::class); $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); $innerServiceMock->method('createContentTypeGroup')->willReturn($contentTypeGroup); @@ -296,7 +296,7 @@ public function testCreateContentTypeGroupEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnCreateContentTypeGroupResultInBeforeEvents() + public function testReturnCreateContentTypeGroupResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateContentTypeGroupEvent::class, @@ -304,11 +304,11 @@ public function testReturnCreateContentTypeGroupResultInBeforeEvents() ); $parameters = [ - $this->createMock(ContentTypeGroupCreateStruct::class), + self::createStub(ContentTypeGroupCreateStruct::class), ]; - $contentTypeGroup = $this->createMock(ContentTypeGroup::class); - $eventContentTypeGroup = $this->createMock(ContentTypeGroup::class); + $contentTypeGroup = self::createStub(ContentTypeGroup::class); + $eventContentTypeGroup = self::createStub(ContentTypeGroup::class); $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); $innerServiceMock->method('createContentTypeGroup')->willReturn($contentTypeGroup); @@ -330,7 +330,7 @@ public function testReturnCreateContentTypeGroupResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCreateContentTypeGroupStopPropagationInBeforeEvents() + public function testCreateContentTypeGroupStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateContentTypeGroupEvent::class, @@ -338,11 +338,11 @@ public function testCreateContentTypeGroupStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentTypeGroupCreateStruct::class), + self::createStub(ContentTypeGroupCreateStruct::class), ]; - $contentTypeGroup = $this->createMock(ContentTypeGroup::class); - $eventContentTypeGroup = $this->createMock(ContentTypeGroup::class); + $contentTypeGroup = self::createStub(ContentTypeGroup::class); + $eventContentTypeGroup = self::createStub(ContentTypeGroup::class); $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); $innerServiceMock->method('createContentTypeGroup')->willReturn($contentTypeGroup); @@ -367,7 +367,7 @@ public function testCreateContentTypeGroupStopPropagationInBeforeEvents() ]); } - public function testUpdateContentTypeGroupEvents() + public function testUpdateContentTypeGroupEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateContentTypeGroupEvent::class, @@ -375,11 +375,11 @@ public function testUpdateContentTypeGroupEvents() ); $parameters = [ - $this->createMock(ContentTypeGroup::class), - $this->createMock(ContentTypeGroupUpdateStruct::class), + self::createStub(ContentTypeGroup::class), + self::createStub(ContentTypeGroupUpdateStruct::class), ]; - $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); + $innerServiceMock = self::createStub(ContentTypeServiceInterface::class); $service = new ContentTypeService($innerServiceMock, $traceableEventDispatcher); $service->updateContentTypeGroup(...$parameters); @@ -393,7 +393,7 @@ public function testUpdateContentTypeGroupEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testUpdateContentTypeGroupStopPropagationInBeforeEvents() + public function testUpdateContentTypeGroupStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateContentTypeGroupEvent::class, @@ -401,11 +401,11 @@ public function testUpdateContentTypeGroupStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentTypeGroup::class), - $this->createMock(ContentTypeGroupUpdateStruct::class), + self::createStub(ContentTypeGroup::class), + self::createStub(ContentTypeGroupUpdateStruct::class), ]; - $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); + $innerServiceMock = self::createStub(ContentTypeServiceInterface::class); $traceableEventDispatcher->addListener(BeforeUpdateContentTypeGroupEvent::class, static function (BeforeUpdateContentTypeGroupEvent $event) { $event->stopPropagation(); @@ -426,7 +426,7 @@ public function testUpdateContentTypeGroupStopPropagationInBeforeEvents() ]); } - public function testCreateContentTypeEvents() + public function testCreateContentTypeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateContentTypeEvent::class, @@ -434,11 +434,11 @@ public function testCreateContentTypeEvents() ); $parameters = [ - $this->createMock(ContentTypeCreateStruct::class), + self::createStub(ContentTypeCreateStruct::class), [], ]; - $contentTypeDraft = $this->createMock(ContentTypeDraft::class); + $contentTypeDraft = self::createStub(ContentTypeDraft::class); $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); $innerServiceMock->method('createContentType')->willReturn($contentTypeDraft); @@ -455,7 +455,7 @@ public function testCreateContentTypeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnCreateContentTypeResultInBeforeEvents() + public function testReturnCreateContentTypeResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateContentTypeEvent::class, @@ -463,12 +463,12 @@ public function testReturnCreateContentTypeResultInBeforeEvents() ); $parameters = [ - $this->createMock(ContentTypeCreateStruct::class), + self::createStub(ContentTypeCreateStruct::class), [], ]; - $contentTypeDraft = $this->createMock(ContentTypeDraft::class); - $eventContentTypeDraft = $this->createMock(ContentTypeDraft::class); + $contentTypeDraft = self::createStub(ContentTypeDraft::class); + $eventContentTypeDraft = self::createStub(ContentTypeDraft::class); $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); $innerServiceMock->method('createContentType')->willReturn($contentTypeDraft); @@ -490,7 +490,7 @@ public function testReturnCreateContentTypeResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCreateContentTypeStopPropagationInBeforeEvents() + public function testCreateContentTypeStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateContentTypeEvent::class, @@ -498,12 +498,12 @@ public function testCreateContentTypeStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentTypeCreateStruct::class), + self::createStub(ContentTypeCreateStruct::class), [], ]; - $contentTypeDraft = $this->createMock(ContentTypeDraft::class); - $eventContentTypeDraft = $this->createMock(ContentTypeDraft::class); + $contentTypeDraft = self::createStub(ContentTypeDraft::class); + $eventContentTypeDraft = self::createStub(ContentTypeDraft::class); $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); $innerServiceMock->method('createContentType')->willReturn($contentTypeDraft); @@ -528,7 +528,7 @@ public function testCreateContentTypeStopPropagationInBeforeEvents() ]); } - public function testRemoveContentTypeTranslationEvents() + public function testRemoveContentTypeTranslationEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRemoveContentTypeTranslationEvent::class, @@ -536,11 +536,11 @@ public function testRemoveContentTypeTranslationEvents() ); $parameters = [ - $this->createMock(ContentTypeDraft::class), + self::createStub(ContentTypeDraft::class), 'random_value_5cff79c318f864.57583321', ]; - $newContentTypeDraft = $this->createMock(ContentTypeDraft::class); + $newContentTypeDraft = self::createStub(ContentTypeDraft::class); $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); $innerServiceMock->method('removeContentTypeTranslation')->willReturn($newContentTypeDraft); @@ -557,7 +557,7 @@ public function testRemoveContentTypeTranslationEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnRemoveContentTypeTranslationResultInBeforeEvents() + public function testReturnRemoveContentTypeTranslationResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRemoveContentTypeTranslationEvent::class, @@ -565,12 +565,12 @@ public function testReturnRemoveContentTypeTranslationResultInBeforeEvents() ); $parameters = [ - $this->createMock(ContentTypeDraft::class), + self::createStub(ContentTypeDraft::class), 'random_value_5cff79c318f913.11826610', ]; - $newContentTypeDraft = $this->createMock(ContentTypeDraft::class); - $eventNewContentTypeDraft = $this->createMock(ContentTypeDraft::class); + $newContentTypeDraft = self::createStub(ContentTypeDraft::class); + $eventNewContentTypeDraft = self::createStub(ContentTypeDraft::class); $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); $innerServiceMock->method('removeContentTypeTranslation')->willReturn($newContentTypeDraft); @@ -592,7 +592,7 @@ public function testReturnRemoveContentTypeTranslationResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testRemoveContentTypeTranslationStopPropagationInBeforeEvents() + public function testRemoveContentTypeTranslationStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRemoveContentTypeTranslationEvent::class, @@ -600,12 +600,12 @@ public function testRemoveContentTypeTranslationStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentTypeDraft::class), + self::createStub(ContentTypeDraft::class), 'random_value_5cff79c318f983.61112462', ]; - $newContentTypeDraft = $this->createMock(ContentTypeDraft::class); - $eventNewContentTypeDraft = $this->createMock(ContentTypeDraft::class); + $newContentTypeDraft = self::createStub(ContentTypeDraft::class); + $eventNewContentTypeDraft = self::createStub(ContentTypeDraft::class); $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); $innerServiceMock->method('removeContentTypeTranslation')->willReturn($newContentTypeDraft); @@ -630,7 +630,7 @@ public function testRemoveContentTypeTranslationStopPropagationInBeforeEvents() ]); } - public function testUnassignContentTypeGroupEvents() + public function testUnassignContentTypeGroupEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUnassignContentTypeGroupEvent::class, @@ -638,11 +638,11 @@ public function testUnassignContentTypeGroupEvents() ); $parameters = [ - $this->createMock(ContentType::class), - $this->createMock(ContentTypeGroup::class), + self::createStub(ContentType::class), + self::createStub(ContentTypeGroup::class), ]; - $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); + $innerServiceMock = self::createStub(ContentTypeServiceInterface::class); $service = new ContentTypeService($innerServiceMock, $traceableEventDispatcher); $service->unassignContentTypeGroup(...$parameters); @@ -656,7 +656,7 @@ public function testUnassignContentTypeGroupEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testUnassignContentTypeGroupStopPropagationInBeforeEvents() + public function testUnassignContentTypeGroupStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUnassignContentTypeGroupEvent::class, @@ -664,11 +664,11 @@ public function testUnassignContentTypeGroupStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentType::class), - $this->createMock(ContentTypeGroup::class), + self::createStub(ContentType::class), + self::createStub(ContentTypeGroup::class), ]; - $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); + $innerServiceMock = self::createStub(ContentTypeServiceInterface::class); $traceableEventDispatcher->addListener(BeforeUnassignContentTypeGroupEvent::class, static function (BeforeUnassignContentTypeGroupEvent $event) { $event->stopPropagation(); @@ -689,7 +689,7 @@ public function testUnassignContentTypeGroupStopPropagationInBeforeEvents() ]); } - public function testPublishContentTypeDraftEvents() + public function testPublishContentTypeDraftEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforePublishContentTypeDraftEvent::class, @@ -697,10 +697,10 @@ public function testPublishContentTypeDraftEvents() ); $parameters = [ - $this->createMock(ContentTypeDraft::class), + self::createStub(ContentTypeDraft::class), ]; - $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); + $innerServiceMock = self::createStub(ContentTypeServiceInterface::class); $service = new ContentTypeService($innerServiceMock, $traceableEventDispatcher); $service->publishContentTypeDraft(...$parameters); @@ -714,7 +714,7 @@ public function testPublishContentTypeDraftEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testPublishContentTypeDraftStopPropagationInBeforeEvents() + public function testPublishContentTypeDraftStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforePublishContentTypeDraftEvent::class, @@ -722,10 +722,10 @@ public function testPublishContentTypeDraftStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentTypeDraft::class), + self::createStub(ContentTypeDraft::class), ]; - $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); + $innerServiceMock = self::createStub(ContentTypeServiceInterface::class); $traceableEventDispatcher->addListener(BeforePublishContentTypeDraftEvent::class, static function (BeforePublishContentTypeDraftEvent $event) { $event->stopPropagation(); @@ -746,7 +746,7 @@ public function testPublishContentTypeDraftStopPropagationInBeforeEvents() ]); } - public function testUpdateFieldDefinitionEvents() + public function testUpdateFieldDefinitionEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateFieldDefinitionEvent::class, @@ -754,12 +754,12 @@ public function testUpdateFieldDefinitionEvents() ); $parameters = [ - $this->createMock(ContentTypeDraft::class), - $this->createMock(FieldDefinition::class), - $this->createMock(FieldDefinitionUpdateStruct::class), + self::createStub(ContentTypeDraft::class), + self::createStub(FieldDefinition::class), + self::createStub(FieldDefinitionUpdateStruct::class), ]; - $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); + $innerServiceMock = self::createStub(ContentTypeServiceInterface::class); $service = new ContentTypeService($innerServiceMock, $traceableEventDispatcher); $service->updateFieldDefinition(...$parameters); @@ -773,7 +773,7 @@ public function testUpdateFieldDefinitionEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testUpdateFieldDefinitionStopPropagationInBeforeEvents() + public function testUpdateFieldDefinitionStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateFieldDefinitionEvent::class, @@ -781,12 +781,12 @@ public function testUpdateFieldDefinitionStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentTypeDraft::class), - $this->createMock(FieldDefinition::class), - $this->createMock(FieldDefinitionUpdateStruct::class), + self::createStub(ContentTypeDraft::class), + self::createStub(FieldDefinition::class), + self::createStub(FieldDefinitionUpdateStruct::class), ]; - $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); + $innerServiceMock = self::createStub(ContentTypeServiceInterface::class); $traceableEventDispatcher->addListener(BeforeUpdateFieldDefinitionEvent::class, static function (BeforeUpdateFieldDefinitionEvent $event) { $event->stopPropagation(); @@ -807,7 +807,7 @@ public function testUpdateFieldDefinitionStopPropagationInBeforeEvents() ]); } - public function testRemoveFieldDefinitionEvents() + public function testRemoveFieldDefinitionEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRemoveFieldDefinitionEvent::class, @@ -815,11 +815,11 @@ public function testRemoveFieldDefinitionEvents() ); $parameters = [ - $this->createMock(ContentTypeDraft::class), - $this->createMock(FieldDefinition::class), + self::createStub(ContentTypeDraft::class), + self::createStub(FieldDefinition::class), ]; - $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); + $innerServiceMock = self::createStub(ContentTypeServiceInterface::class); $service = new ContentTypeService($innerServiceMock, $traceableEventDispatcher); $service->removeFieldDefinition(...$parameters); @@ -833,7 +833,7 @@ public function testRemoveFieldDefinitionEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testRemoveFieldDefinitionStopPropagationInBeforeEvents() + public function testRemoveFieldDefinitionStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRemoveFieldDefinitionEvent::class, @@ -841,11 +841,11 @@ public function testRemoveFieldDefinitionStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentTypeDraft::class), - $this->createMock(FieldDefinition::class), + self::createStub(ContentTypeDraft::class), + self::createStub(FieldDefinition::class), ]; - $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); + $innerServiceMock = self::createStub(ContentTypeServiceInterface::class); $traceableEventDispatcher->addListener(BeforeRemoveFieldDefinitionEvent::class, static function (BeforeRemoveFieldDefinitionEvent $event) { $event->stopPropagation(); @@ -866,7 +866,7 @@ public function testRemoveFieldDefinitionStopPropagationInBeforeEvents() ]); } - public function testAssignContentTypeGroupEvents() + public function testAssignContentTypeGroupEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeAssignContentTypeGroupEvent::class, @@ -874,11 +874,11 @@ public function testAssignContentTypeGroupEvents() ); $parameters = [ - $this->createMock(ContentType::class), - $this->createMock(ContentTypeGroup::class), + self::createStub(ContentType::class), + self::createStub(ContentTypeGroup::class), ]; - $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); + $innerServiceMock = self::createStub(ContentTypeServiceInterface::class); $service = new ContentTypeService($innerServiceMock, $traceableEventDispatcher); $service->assignContentTypeGroup(...$parameters); @@ -892,7 +892,7 @@ public function testAssignContentTypeGroupEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testAssignContentTypeGroupStopPropagationInBeforeEvents() + public function testAssignContentTypeGroupStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeAssignContentTypeGroupEvent::class, @@ -900,11 +900,11 @@ public function testAssignContentTypeGroupStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentType::class), - $this->createMock(ContentTypeGroup::class), + self::createStub(ContentType::class), + self::createStub(ContentTypeGroup::class), ]; - $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); + $innerServiceMock = self::createStub(ContentTypeServiceInterface::class); $traceableEventDispatcher->addListener(BeforeAssignContentTypeGroupEvent::class, static function (BeforeAssignContentTypeGroupEvent $event) { $event->stopPropagation(); @@ -925,7 +925,7 @@ public function testAssignContentTypeGroupStopPropagationInBeforeEvents() ]); } - public function testUpdateContentTypeDraftEvents() + public function testUpdateContentTypeDraftEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateContentTypeDraftEvent::class, @@ -933,11 +933,11 @@ public function testUpdateContentTypeDraftEvents() ); $parameters = [ - $this->createMock(ContentTypeDraft::class), - $this->createMock(ContentTypeUpdateStruct::class), + self::createStub(ContentTypeDraft::class), + self::createStub(ContentTypeUpdateStruct::class), ]; - $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); + $innerServiceMock = self::createStub(ContentTypeServiceInterface::class); $service = new ContentTypeService($innerServiceMock, $traceableEventDispatcher); $service->updateContentTypeDraft(...$parameters); @@ -951,7 +951,7 @@ public function testUpdateContentTypeDraftEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testUpdateContentTypeDraftStopPropagationInBeforeEvents() + public function testUpdateContentTypeDraftStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateContentTypeDraftEvent::class, @@ -959,11 +959,11 @@ public function testUpdateContentTypeDraftStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentTypeDraft::class), - $this->createMock(ContentTypeUpdateStruct::class), + self::createStub(ContentTypeDraft::class), + self::createStub(ContentTypeUpdateStruct::class), ]; - $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); + $innerServiceMock = self::createStub(ContentTypeServiceInterface::class); $traceableEventDispatcher->addListener(BeforeUpdateContentTypeDraftEvent::class, static function (BeforeUpdateContentTypeDraftEvent $event) { $event->stopPropagation(); @@ -984,7 +984,7 @@ public function testUpdateContentTypeDraftStopPropagationInBeforeEvents() ]); } - public function testDeleteContentTypeEvents() + public function testDeleteContentTypeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteContentTypeEvent::class, @@ -992,10 +992,10 @@ public function testDeleteContentTypeEvents() ); $parameters = [ - $this->createMock(ContentType::class), + self::createStub(ContentType::class), ]; - $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); + $innerServiceMock = self::createStub(ContentTypeServiceInterface::class); $service = new ContentTypeService($innerServiceMock, $traceableEventDispatcher); $service->deleteContentType(...$parameters); @@ -1009,7 +1009,7 @@ public function testDeleteContentTypeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testDeleteContentTypeStopPropagationInBeforeEvents() + public function testDeleteContentTypeStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteContentTypeEvent::class, @@ -1017,10 +1017,10 @@ public function testDeleteContentTypeStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentType::class), + self::createStub(ContentType::class), ]; - $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); + $innerServiceMock = self::createStub(ContentTypeServiceInterface::class); $traceableEventDispatcher->addListener(BeforeDeleteContentTypeEvent::class, static function (BeforeDeleteContentTypeEvent $event) { $event->stopPropagation(); @@ -1041,7 +1041,7 @@ public function testDeleteContentTypeStopPropagationInBeforeEvents() ]); } - public function testCopyContentTypeEvents() + public function testCopyContentTypeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCopyContentTypeEvent::class, @@ -1049,11 +1049,11 @@ public function testCopyContentTypeEvents() ); $parameters = [ - $this->createMock(ContentType::class), - $this->createMock(User::class), + self::createStub(ContentType::class), + self::createStub(User::class), ]; - $contentTypeCopy = $this->createMock(ContentType::class); + $contentTypeCopy = self::createStub(ContentType::class); $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); $innerServiceMock->method('copyContentType')->willReturn($contentTypeCopy); @@ -1070,7 +1070,7 @@ public function testCopyContentTypeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnCopyContentTypeResultInBeforeEvents() + public function testReturnCopyContentTypeResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCopyContentTypeEvent::class, @@ -1078,12 +1078,12 @@ public function testReturnCopyContentTypeResultInBeforeEvents() ); $parameters = [ - $this->createMock(ContentType::class), - $this->createMock(User::class), + self::createStub(ContentType::class), + self::createStub(User::class), ]; - $contentTypeCopy = $this->createMock(ContentType::class); - $eventContentTypeCopy = $this->createMock(ContentType::class); + $contentTypeCopy = self::createStub(ContentType::class); + $eventContentTypeCopy = self::createStub(ContentType::class); $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); $innerServiceMock->method('copyContentType')->willReturn($contentTypeCopy); @@ -1105,7 +1105,7 @@ public function testReturnCopyContentTypeResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCopyContentTypeStopPropagationInBeforeEvents() + public function testCopyContentTypeStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCopyContentTypeEvent::class, @@ -1113,12 +1113,12 @@ public function testCopyContentTypeStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentType::class), - $this->createMock(User::class), + self::createStub(ContentType::class), + self::createStub(User::class), ]; - $contentTypeCopy = $this->createMock(ContentType::class); - $eventContentTypeCopy = $this->createMock(ContentType::class); + $contentTypeCopy = self::createStub(ContentType::class); + $eventContentTypeCopy = self::createStub(ContentType::class); $innerServiceMock = $this->createMock(ContentTypeServiceInterface::class); $innerServiceMock->method('copyContentType')->willReturn($contentTypeCopy); diff --git a/tests/lib/Event/LanguageServiceTest.php b/tests/lib/Event/LanguageServiceTest.php index b17a42c823..c09012bbe2 100644 --- a/tests/lib/Event/LanguageServiceTest.php +++ b/tests/lib/Event/LanguageServiceTest.php @@ -24,7 +24,7 @@ class LanguageServiceTest extends AbstractServiceTestCase { - public function testDeleteLanguageEvents() + public function testDeleteLanguageEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteLanguageEvent::class, @@ -32,10 +32,10 @@ public function testDeleteLanguageEvents() ); $parameters = [ - $this->createMock(Language::class), + self::createStub(Language::class), ]; - $innerServiceMock = $this->createMock(LanguageServiceInterface::class); + $innerServiceMock = self::createStub(LanguageServiceInterface::class); $service = new LanguageService($innerServiceMock, $traceableEventDispatcher); $service->deleteLanguage(...$parameters); @@ -49,7 +49,7 @@ public function testDeleteLanguageEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testDeleteLanguageStopPropagationInBeforeEvents() + public function testDeleteLanguageStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteLanguageEvent::class, @@ -57,10 +57,10 @@ public function testDeleteLanguageStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Language::class), + self::createStub(Language::class), ]; - $innerServiceMock = $this->createMock(LanguageServiceInterface::class); + $innerServiceMock = self::createStub(LanguageServiceInterface::class); $traceableEventDispatcher->addListener(BeforeDeleteLanguageEvent::class, static function (BeforeDeleteLanguageEvent $event) { $event->stopPropagation(); @@ -81,7 +81,7 @@ public function testDeleteLanguageStopPropagationInBeforeEvents() ]); } - public function testCreateLanguageEvents() + public function testCreateLanguageEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateLanguageEvent::class, @@ -89,10 +89,10 @@ public function testCreateLanguageEvents() ); $parameters = [ - $this->createMock(LanguageCreateStruct::class), + self::createStub(LanguageCreateStruct::class), ]; - $language = $this->createMock(Language::class); + $language = self::createStub(Language::class); $innerServiceMock = $this->createMock(LanguageServiceInterface::class); $innerServiceMock->method('createLanguage')->willReturn($language); @@ -109,7 +109,7 @@ public function testCreateLanguageEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnCreateLanguageResultInBeforeEvents() + public function testReturnCreateLanguageResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateLanguageEvent::class, @@ -117,11 +117,11 @@ public function testReturnCreateLanguageResultInBeforeEvents() ); $parameters = [ - $this->createMock(LanguageCreateStruct::class), + self::createStub(LanguageCreateStruct::class), ]; - $language = $this->createMock(Language::class); - $eventLanguage = $this->createMock(Language::class); + $language = self::createStub(Language::class); + $eventLanguage = self::createStub(Language::class); $innerServiceMock = $this->createMock(LanguageServiceInterface::class); $innerServiceMock->method('createLanguage')->willReturn($language); @@ -143,7 +143,7 @@ public function testReturnCreateLanguageResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCreateLanguageStopPropagationInBeforeEvents() + public function testCreateLanguageStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateLanguageEvent::class, @@ -151,11 +151,11 @@ public function testCreateLanguageStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(LanguageCreateStruct::class), + self::createStub(LanguageCreateStruct::class), ]; - $language = $this->createMock(Language::class); - $eventLanguage = $this->createMock(Language::class); + $language = self::createStub(Language::class); + $eventLanguage = self::createStub(Language::class); $innerServiceMock = $this->createMock(LanguageServiceInterface::class); $innerServiceMock->method('createLanguage')->willReturn($language); @@ -180,7 +180,7 @@ public function testCreateLanguageStopPropagationInBeforeEvents() ]); } - public function testUpdateLanguageNameEvents() + public function testUpdateLanguageNameEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateLanguageNameEvent::class, @@ -188,11 +188,11 @@ public function testUpdateLanguageNameEvents() ); $parameters = [ - $this->createMock(Language::class), + self::createStub(Language::class), 'random_value_5cff79c3161276.87987683', ]; - $updatedLanguage = $this->createMock(Language::class); + $updatedLanguage = self::createStub(Language::class); $innerServiceMock = $this->createMock(LanguageServiceInterface::class); $innerServiceMock->method('updateLanguageName')->willReturn($updatedLanguage); @@ -209,7 +209,7 @@ public function testUpdateLanguageNameEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnUpdateLanguageNameResultInBeforeEvents() + public function testReturnUpdateLanguageNameResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateLanguageNameEvent::class, @@ -217,12 +217,12 @@ public function testReturnUpdateLanguageNameResultInBeforeEvents() ); $parameters = [ - $this->createMock(Language::class), + self::createStub(Language::class), 'random_value_5cff79c3161312.94068030', ]; - $updatedLanguage = $this->createMock(Language::class); - $eventUpdatedLanguage = $this->createMock(Language::class); + $updatedLanguage = self::createStub(Language::class); + $eventUpdatedLanguage = self::createStub(Language::class); $innerServiceMock = $this->createMock(LanguageServiceInterface::class); $innerServiceMock->method('updateLanguageName')->willReturn($updatedLanguage); @@ -244,7 +244,7 @@ public function testReturnUpdateLanguageNameResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testUpdateLanguageNameStopPropagationInBeforeEvents() + public function testUpdateLanguageNameStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateLanguageNameEvent::class, @@ -252,12 +252,12 @@ public function testUpdateLanguageNameStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Language::class), + self::createStub(Language::class), 'random_value_5cff79c3161386.01414999', ]; - $updatedLanguage = $this->createMock(Language::class); - $eventUpdatedLanguage = $this->createMock(Language::class); + $updatedLanguage = self::createStub(Language::class); + $eventUpdatedLanguage = self::createStub(Language::class); $innerServiceMock = $this->createMock(LanguageServiceInterface::class); $innerServiceMock->method('updateLanguageName')->willReturn($updatedLanguage); @@ -282,7 +282,7 @@ public function testUpdateLanguageNameStopPropagationInBeforeEvents() ]); } - public function testDisableLanguageEvents() + public function testDisableLanguageEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDisableLanguageEvent::class, @@ -290,10 +290,10 @@ public function testDisableLanguageEvents() ); $parameters = [ - $this->createMock(Language::class), + self::createStub(Language::class), ]; - $disabledLanguage = $this->createMock(Language::class); + $disabledLanguage = self::createStub(Language::class); $innerServiceMock = $this->createMock(LanguageServiceInterface::class); $innerServiceMock->method('disableLanguage')->willReturn($disabledLanguage); @@ -310,7 +310,7 @@ public function testDisableLanguageEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnDisableLanguageResultInBeforeEvents() + public function testReturnDisableLanguageResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDisableLanguageEvent::class, @@ -318,11 +318,11 @@ public function testReturnDisableLanguageResultInBeforeEvents() ); $parameters = [ - $this->createMock(Language::class), + self::createStub(Language::class), ]; - $disabledLanguage = $this->createMock(Language::class); - $eventDisabledLanguage = $this->createMock(Language::class); + $disabledLanguage = self::createStub(Language::class); + $eventDisabledLanguage = self::createStub(Language::class); $innerServiceMock = $this->createMock(LanguageServiceInterface::class); $innerServiceMock->method('disableLanguage')->willReturn($disabledLanguage); @@ -344,7 +344,7 @@ public function testReturnDisableLanguageResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testDisableLanguageStopPropagationInBeforeEvents() + public function testDisableLanguageStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDisableLanguageEvent::class, @@ -352,11 +352,11 @@ public function testDisableLanguageStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Language::class), + self::createStub(Language::class), ]; - $disabledLanguage = $this->createMock(Language::class); - $eventDisabledLanguage = $this->createMock(Language::class); + $disabledLanguage = self::createStub(Language::class); + $eventDisabledLanguage = self::createStub(Language::class); $innerServiceMock = $this->createMock(LanguageServiceInterface::class); $innerServiceMock->method('disableLanguage')->willReturn($disabledLanguage); @@ -381,7 +381,7 @@ public function testDisableLanguageStopPropagationInBeforeEvents() ]); } - public function testEnableLanguageEvents() + public function testEnableLanguageEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeEnableLanguageEvent::class, @@ -389,10 +389,10 @@ public function testEnableLanguageEvents() ); $parameters = [ - $this->createMock(Language::class), + self::createStub(Language::class), ]; - $enabledLanguage = $this->createMock(Language::class); + $enabledLanguage = self::createStub(Language::class); $innerServiceMock = $this->createMock(LanguageServiceInterface::class); $innerServiceMock->method('enableLanguage')->willReturn($enabledLanguage); @@ -409,7 +409,7 @@ public function testEnableLanguageEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnEnableLanguageResultInBeforeEvents() + public function testReturnEnableLanguageResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeEnableLanguageEvent::class, @@ -417,11 +417,11 @@ public function testReturnEnableLanguageResultInBeforeEvents() ); $parameters = [ - $this->createMock(Language::class), + self::createStub(Language::class), ]; - $enabledLanguage = $this->createMock(Language::class); - $eventEnabledLanguage = $this->createMock(Language::class); + $enabledLanguage = self::createStub(Language::class); + $eventEnabledLanguage = self::createStub(Language::class); $innerServiceMock = $this->createMock(LanguageServiceInterface::class); $innerServiceMock->method('enableLanguage')->willReturn($enabledLanguage); @@ -443,7 +443,7 @@ public function testReturnEnableLanguageResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testEnableLanguageStopPropagationInBeforeEvents() + public function testEnableLanguageStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeEnableLanguageEvent::class, @@ -451,11 +451,11 @@ public function testEnableLanguageStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Language::class), + self::createStub(Language::class), ]; - $enabledLanguage = $this->createMock(Language::class); - $eventEnabledLanguage = $this->createMock(Language::class); + $enabledLanguage = self::createStub(Language::class); + $eventEnabledLanguage = self::createStub(Language::class); $innerServiceMock = $this->createMock(LanguageServiceInterface::class); $innerServiceMock->method('enableLanguage')->willReturn($enabledLanguage); diff --git a/tests/lib/Event/LocationServiceTest.php b/tests/lib/Event/LocationServiceTest.php index 97957243e0..0d86219665 100644 --- a/tests/lib/Event/LocationServiceTest.php +++ b/tests/lib/Event/LocationServiceTest.php @@ -32,7 +32,7 @@ class LocationServiceTest extends AbstractServiceTestCase { - public function testCopySubtreeEvents() + public function testCopySubtreeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCopySubtreeEvent::class, @@ -40,11 +40,11 @@ public function testCopySubtreeEvents() ); $parameters = [ - $this->createMock(Location::class), - $this->createMock(Location::class), + self::createStub(Location::class), + self::createStub(Location::class), ]; - $location = $this->createMock(Location::class); + $location = self::createStub(Location::class); $innerServiceMock = $this->createMock(LocationServiceInterface::class); $innerServiceMock->method('copySubtree')->willReturn($location); @@ -61,7 +61,7 @@ public function testCopySubtreeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnCopySubtreeResultInBeforeEvents() + public function testReturnCopySubtreeResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCopySubtreeEvent::class, @@ -69,12 +69,12 @@ public function testReturnCopySubtreeResultInBeforeEvents() ); $parameters = [ - $this->createMock(Location::class), - $this->createMock(Location::class), + self::createStub(Location::class), + self::createStub(Location::class), ]; - $location = $this->createMock(Location::class); - $eventLocation = $this->createMock(Location::class); + $location = self::createStub(Location::class); + $eventLocation = self::createStub(Location::class); $innerServiceMock = $this->createMock(LocationServiceInterface::class); $innerServiceMock->method('copySubtree')->willReturn($location); @@ -96,7 +96,7 @@ public function testReturnCopySubtreeResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCopySubtreeStopPropagationInBeforeEvents() + public function testCopySubtreeStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCopySubtreeEvent::class, @@ -104,12 +104,12 @@ public function testCopySubtreeStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Location::class), - $this->createMock(Location::class), + self::createStub(Location::class), + self::createStub(Location::class), ]; - $location = $this->createMock(Location::class); - $eventLocation = $this->createMock(Location::class); + $location = self::createStub(Location::class); + $eventLocation = self::createStub(Location::class); $innerServiceMock = $this->createMock(LocationServiceInterface::class); $innerServiceMock->method('copySubtree')->willReturn($location); @@ -134,7 +134,7 @@ public function testCopySubtreeStopPropagationInBeforeEvents() ]); } - public function testDeleteLocationEvents() + public function testDeleteLocationEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteLocationEvent::class, @@ -142,10 +142,10 @@ public function testDeleteLocationEvents() ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), ]; - $innerServiceMock = $this->createMock(LocationServiceInterface::class); + $innerServiceMock = self::createStub(LocationServiceInterface::class); $service = new LocationService($innerServiceMock, $traceableEventDispatcher); $service->deleteLocation(...$parameters); @@ -159,7 +159,7 @@ public function testDeleteLocationEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testDeleteLocationStopPropagationInBeforeEvents() + public function testDeleteLocationStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteLocationEvent::class, @@ -167,10 +167,10 @@ public function testDeleteLocationStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), ]; - $innerServiceMock = $this->createMock(LocationServiceInterface::class); + $innerServiceMock = self::createStub(LocationServiceInterface::class); $traceableEventDispatcher->addListener(BeforeDeleteLocationEvent::class, static function (BeforeDeleteLocationEvent $event) { $event->stopPropagation(); @@ -191,7 +191,7 @@ public function testDeleteLocationStopPropagationInBeforeEvents() ]); } - public function testUnhideLocationEvents() + public function testUnhideLocationEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUnhideLocationEvent::class, @@ -199,10 +199,10 @@ public function testUnhideLocationEvents() ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), ]; - $revealedLocation = $this->createMock(Location::class); + $revealedLocation = self::createStub(Location::class); $innerServiceMock = $this->createMock(LocationServiceInterface::class); $innerServiceMock->method('unhideLocation')->willReturn($revealedLocation); @@ -219,7 +219,7 @@ public function testUnhideLocationEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnUnhideLocationResultInBeforeEvents() + public function testReturnUnhideLocationResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUnhideLocationEvent::class, @@ -227,11 +227,11 @@ public function testReturnUnhideLocationResultInBeforeEvents() ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), ]; - $revealedLocation = $this->createMock(Location::class); - $eventRevealedLocation = $this->createMock(Location::class); + $revealedLocation = self::createStub(Location::class); + $eventRevealedLocation = self::createStub(Location::class); $innerServiceMock = $this->createMock(LocationServiceInterface::class); $innerServiceMock->method('unhideLocation')->willReturn($revealedLocation); @@ -253,7 +253,7 @@ public function testReturnUnhideLocationResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testUnhideLocationStopPropagationInBeforeEvents() + public function testUnhideLocationStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUnhideLocationEvent::class, @@ -261,11 +261,11 @@ public function testUnhideLocationStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), ]; - $revealedLocation = $this->createMock(Location::class); - $eventRevealedLocation = $this->createMock(Location::class); + $revealedLocation = self::createStub(Location::class); + $eventRevealedLocation = self::createStub(Location::class); $innerServiceMock = $this->createMock(LocationServiceInterface::class); $innerServiceMock->method('unhideLocation')->willReturn($revealedLocation); @@ -290,7 +290,7 @@ public function testUnhideLocationStopPropagationInBeforeEvents() ]); } - public function testHideLocationEvents() + public function testHideLocationEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeHideLocationEvent::class, @@ -298,10 +298,10 @@ public function testHideLocationEvents() ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), ]; - $hiddenLocation = $this->createMock(Location::class); + $hiddenLocation = self::createStub(Location::class); $innerServiceMock = $this->createMock(LocationServiceInterface::class); $innerServiceMock->method('hideLocation')->willReturn($hiddenLocation); @@ -318,7 +318,7 @@ public function testHideLocationEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnHideLocationResultInBeforeEvents() + public function testReturnHideLocationResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeHideLocationEvent::class, @@ -326,11 +326,11 @@ public function testReturnHideLocationResultInBeforeEvents() ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), ]; - $hiddenLocation = $this->createMock(Location::class); - $eventHiddenLocation = $this->createMock(Location::class); + $hiddenLocation = self::createStub(Location::class); + $eventHiddenLocation = self::createStub(Location::class); $innerServiceMock = $this->createMock(LocationServiceInterface::class); $innerServiceMock->method('hideLocation')->willReturn($hiddenLocation); @@ -352,7 +352,7 @@ public function testReturnHideLocationResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testHideLocationStopPropagationInBeforeEvents() + public function testHideLocationStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeHideLocationEvent::class, @@ -360,11 +360,11 @@ public function testHideLocationStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), ]; - $hiddenLocation = $this->createMock(Location::class); - $eventHiddenLocation = $this->createMock(Location::class); + $hiddenLocation = self::createStub(Location::class); + $eventHiddenLocation = self::createStub(Location::class); $innerServiceMock = $this->createMock(LocationServiceInterface::class); $innerServiceMock->method('hideLocation')->willReturn($hiddenLocation); @@ -389,7 +389,7 @@ public function testHideLocationStopPropagationInBeforeEvents() ]); } - public function testSwapLocationEvents() + public function testSwapLocationEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeSwapLocationEvent::class, @@ -397,11 +397,11 @@ public function testSwapLocationEvents() ); $parameters = [ - $this->createMock(Location::class), - $this->createMock(Location::class), + self::createStub(Location::class), + self::createStub(Location::class), ]; - $innerServiceMock = $this->createMock(LocationServiceInterface::class); + $innerServiceMock = self::createStub(LocationServiceInterface::class); $service = new LocationService($innerServiceMock, $traceableEventDispatcher); $service->swapLocation(...$parameters); @@ -415,7 +415,7 @@ public function testSwapLocationEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testSwapLocationStopPropagationInBeforeEvents() + public function testSwapLocationStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeSwapLocationEvent::class, @@ -423,11 +423,11 @@ public function testSwapLocationStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Location::class), - $this->createMock(Location::class), + self::createStub(Location::class), + self::createStub(Location::class), ]; - $innerServiceMock = $this->createMock(LocationServiceInterface::class); + $innerServiceMock = self::createStub(LocationServiceInterface::class); $traceableEventDispatcher->addListener(BeforeSwapLocationEvent::class, static function (BeforeSwapLocationEvent $event) { $event->stopPropagation(); @@ -448,7 +448,7 @@ public function testSwapLocationStopPropagationInBeforeEvents() ]); } - public function testMoveSubtreeEvents() + public function testMoveSubtreeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeMoveSubtreeEvent::class, @@ -456,11 +456,11 @@ public function testMoveSubtreeEvents() ); $parameters = [ - $this->createMock(Location::class), - $this->createMock(Location::class), + self::createStub(Location::class), + self::createStub(Location::class), ]; - $innerServiceMock = $this->createMock(LocationServiceInterface::class); + $innerServiceMock = self::createStub(LocationServiceInterface::class); $service = new LocationService($innerServiceMock, $traceableEventDispatcher); $service->moveSubtree(...$parameters); @@ -474,7 +474,7 @@ public function testMoveSubtreeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testMoveSubtreeStopPropagationInBeforeEvents() + public function testMoveSubtreeStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeMoveSubtreeEvent::class, @@ -482,11 +482,11 @@ public function testMoveSubtreeStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Location::class), - $this->createMock(Location::class), + self::createStub(Location::class), + self::createStub(Location::class), ]; - $innerServiceMock = $this->createMock(LocationServiceInterface::class); + $innerServiceMock = self::createStub(LocationServiceInterface::class); $traceableEventDispatcher->addListener(BeforeMoveSubtreeEvent::class, static function (BeforeMoveSubtreeEvent $event) { $event->stopPropagation(); @@ -507,7 +507,7 @@ public function testMoveSubtreeStopPropagationInBeforeEvents() ]); } - public function testUpdateLocationEvents() + public function testUpdateLocationEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateLocationEvent::class, @@ -515,11 +515,11 @@ public function testUpdateLocationEvents() ); $parameters = [ - $this->createMock(Location::class), - $this->createMock(LocationUpdateStruct::class), + self::createStub(Location::class), + self::createStub(LocationUpdateStruct::class), ]; - $updatedLocation = $this->createMock(Location::class); + $updatedLocation = self::createStub(Location::class); $innerServiceMock = $this->createMock(LocationServiceInterface::class); $innerServiceMock->method('updateLocation')->willReturn($updatedLocation); @@ -536,7 +536,7 @@ public function testUpdateLocationEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnUpdateLocationResultInBeforeEvents() + public function testReturnUpdateLocationResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateLocationEvent::class, @@ -544,12 +544,12 @@ public function testReturnUpdateLocationResultInBeforeEvents() ); $parameters = [ - $this->createMock(Location::class), - $this->createMock(LocationUpdateStruct::class), + self::createStub(Location::class), + self::createStub(LocationUpdateStruct::class), ]; - $updatedLocation = $this->createMock(Location::class); - $eventUpdatedLocation = $this->createMock(Location::class); + $updatedLocation = self::createStub(Location::class); + $eventUpdatedLocation = self::createStub(Location::class); $innerServiceMock = $this->createMock(LocationServiceInterface::class); $innerServiceMock->method('updateLocation')->willReturn($updatedLocation); @@ -571,7 +571,7 @@ public function testReturnUpdateLocationResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testUpdateLocationStopPropagationInBeforeEvents() + public function testUpdateLocationStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateLocationEvent::class, @@ -579,12 +579,12 @@ public function testUpdateLocationStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Location::class), - $this->createMock(LocationUpdateStruct::class), + self::createStub(Location::class), + self::createStub(LocationUpdateStruct::class), ]; - $updatedLocation = $this->createMock(Location::class); - $eventUpdatedLocation = $this->createMock(Location::class); + $updatedLocation = self::createStub(Location::class); + $eventUpdatedLocation = self::createStub(Location::class); $innerServiceMock = $this->createMock(LocationServiceInterface::class); $innerServiceMock->method('updateLocation')->willReturn($updatedLocation); @@ -609,7 +609,7 @@ public function testUpdateLocationStopPropagationInBeforeEvents() ]); } - public function testCreateLocationEvents() + public function testCreateLocationEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateLocationEvent::class, @@ -617,11 +617,11 @@ public function testCreateLocationEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(LocationCreateStruct::class), + self::createStub(ContentInfo::class), + self::createStub(LocationCreateStruct::class), ]; - $location = $this->createMock(Location::class); + $location = self::createStub(Location::class); $innerServiceMock = $this->createMock(LocationServiceInterface::class); $innerServiceMock->method('createLocation')->willReturn($location); @@ -638,7 +638,7 @@ public function testCreateLocationEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnCreateLocationResultInBeforeEvents() + public function testReturnCreateLocationResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateLocationEvent::class, @@ -646,12 +646,12 @@ public function testReturnCreateLocationResultInBeforeEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(LocationCreateStruct::class), + self::createStub(ContentInfo::class), + self::createStub(LocationCreateStruct::class), ]; - $location = $this->createMock(Location::class); - $eventLocation = $this->createMock(Location::class); + $location = self::createStub(Location::class); + $eventLocation = self::createStub(Location::class); $innerServiceMock = $this->createMock(LocationServiceInterface::class); $innerServiceMock->method('createLocation')->willReturn($location); @@ -673,7 +673,7 @@ public function testReturnCreateLocationResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCreateLocationStopPropagationInBeforeEvents() + public function testCreateLocationStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateLocationEvent::class, @@ -681,12 +681,12 @@ public function testCreateLocationStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(LocationCreateStruct::class), + self::createStub(ContentInfo::class), + self::createStub(LocationCreateStruct::class), ]; - $location = $this->createMock(Location::class); - $eventLocation = $this->createMock(Location::class); + $location = self::createStub(Location::class); + $eventLocation = self::createStub(Location::class); $innerServiceMock = $this->createMock(LocationServiceInterface::class); $innerServiceMock->method('createLocation')->willReturn($location); diff --git a/tests/lib/Event/NotificationServiceTest.php b/tests/lib/Event/NotificationServiceTest.php index 291fd52076..bff889a578 100644 --- a/tests/lib/Event/NotificationServiceTest.php +++ b/tests/lib/Event/NotificationServiceTest.php @@ -30,10 +30,10 @@ public function testCreateNotificationEvents(): void ); $parameters = [ - $this->createMock(CreateStruct::class), + self::createStub(CreateStruct::class), ]; - $notification = $this->createMock(Notification::class); + $notification = self::createStub(Notification::class); $innerServiceMock = $this->createMock(NotificationServiceInterface::class); $innerServiceMock->method('createNotification')->willReturn($notification); @@ -58,11 +58,11 @@ public function testReturnCreateNotificationResultInBeforeEvents(): void ); $parameters = [ - $this->createMock(CreateStruct::class), + self::createStub(CreateStruct::class), ]; - $notification = $this->createMock(Notification::class); - $eventNotification = $this->createMock(Notification::class); + $notification = self::createStub(Notification::class); + $eventNotification = self::createStub(Notification::class); $innerServiceMock = $this->createMock(NotificationServiceInterface::class); $innerServiceMock->method('createNotification')->willReturn($notification); @@ -96,11 +96,11 @@ public function testCreateNotificationStopPropagationInBeforeEvents(): void ); $parameters = [ - $this->createMock(CreateStruct::class), + self::createStub(CreateStruct::class), ]; - $notification = $this->createMock(Notification::class); - $eventNotification = $this->createMock(Notification::class); + $notification = self::createStub(Notification::class); + $eventNotification = self::createStub(Notification::class); $innerServiceMock = $this->createMock(NotificationServiceInterface::class); $innerServiceMock->method('createNotification')->willReturn($notification); @@ -137,10 +137,10 @@ public function testDeleteNotificationEvents(): void ); $parameters = [ - $this->createMock(Notification::class), + self::createStub(Notification::class), ]; - $innerServiceMock = $this->createMock(NotificationServiceInterface::class); + $innerServiceMock = self::createStub(NotificationServiceInterface::class); $service = new NotificationService($innerServiceMock, $traceableEventDispatcher); $service->deleteNotification(...$parameters); @@ -162,10 +162,10 @@ public function testDeleteNotificationStopPropagationInBeforeEvents(): void ); $parameters = [ - $this->createMock(Notification::class), + self::createStub(Notification::class), ]; - $innerServiceMock = $this->createMock(NotificationServiceInterface::class); + $innerServiceMock = self::createStub(NotificationServiceInterface::class); $traceableEventDispatcher->addListener( BeforeDeleteNotificationEvent::class, @@ -198,10 +198,10 @@ public function testMarkNotificationAsReadEvents(): void ); $parameters = [ - $this->createMock(Notification::class), + self::createStub(Notification::class), ]; - $innerServiceMock = $this->createMock(NotificationServiceInterface::class); + $innerServiceMock = self::createStub(NotificationServiceInterface::class); $service = new NotificationService($innerServiceMock, $traceableEventDispatcher); $service->markNotificationAsRead(...$parameters); @@ -223,10 +223,10 @@ public function testMarkNotificationAsUnreadEvents(): void ); $parameters = [ - $this->createMock(Notification::class), + self::createStub(Notification::class), ]; - $innerServiceMock = $this->createMock(NotificationServiceInterface::class); + $innerServiceMock = self::createStub(NotificationServiceInterface::class); $service = new NotificationService($innerServiceMock, $traceableEventDispatcher); $service->markNotificationAsUnread(...$parameters); @@ -248,10 +248,10 @@ public function testMarkNotificationAsReadStopPropagationInBeforeEvents(): void ); $parameters = [ - $this->createMock(Notification::class), + self::createStub(Notification::class), ]; - $innerServiceMock = $this->createMock(NotificationServiceInterface::class); + $innerServiceMock = self::createStub(NotificationServiceInterface::class); $traceableEventDispatcher->addListener( BeforeMarkNotificationAsReadEvent::class, @@ -284,10 +284,10 @@ public function testMarkNotificationAsUnreadStopPropagationInBeforeEvents(): voi ); $parameters = [ - $this->createMock(Notification::class), + self::createStub(Notification::class), ]; - $innerServiceMock = $this->createMock(NotificationServiceInterface::class); + $innerServiceMock = self::createStub(NotificationServiceInterface::class); $traceableEventDispatcher->addListener( BeforeMarkNotificationAsUnreadEvent::class, diff --git a/tests/lib/Event/ObjectStateServiceTest.php b/tests/lib/Event/ObjectStateServiceTest.php index 616d561137..ed7981a517 100644 --- a/tests/lib/Event/ObjectStateServiceTest.php +++ b/tests/lib/Event/ObjectStateServiceTest.php @@ -35,7 +35,7 @@ class ObjectStateServiceTest extends AbstractServiceTestCase { - public function testSetContentStateEvents() + public function testSetContentStateEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeSetContentStateEvent::class, @@ -43,12 +43,12 @@ public function testSetContentStateEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(ObjectStateGroup::class), - $this->createMock(ObjectState::class), + self::createStub(ContentInfo::class), + self::createStub(ObjectStateGroup::class), + self::createStub(ObjectState::class), ]; - $innerServiceMock = $this->createMock(ObjectStateServiceInterface::class); + $innerServiceMock = self::createStub(ObjectStateServiceInterface::class); $service = new ObjectStateService($innerServiceMock, $traceableEventDispatcher); $service->setContentState(...$parameters); @@ -62,7 +62,7 @@ public function testSetContentStateEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testSetContentStateStopPropagationInBeforeEvents() + public function testSetContentStateStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeSetContentStateEvent::class, @@ -70,12 +70,12 @@ public function testSetContentStateStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(ObjectStateGroup::class), - $this->createMock(ObjectState::class), + self::createStub(ContentInfo::class), + self::createStub(ObjectStateGroup::class), + self::createStub(ObjectState::class), ]; - $innerServiceMock = $this->createMock(ObjectStateServiceInterface::class); + $innerServiceMock = self::createStub(ObjectStateServiceInterface::class); $traceableEventDispatcher->addListener(BeforeSetContentStateEvent::class, static function (BeforeSetContentStateEvent $event) { $event->stopPropagation(); @@ -96,7 +96,7 @@ public function testSetContentStateStopPropagationInBeforeEvents() ]); } - public function testCreateObjectStateGroupEvents() + public function testCreateObjectStateGroupEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateObjectStateGroupEvent::class, @@ -104,10 +104,10 @@ public function testCreateObjectStateGroupEvents() ); $parameters = [ - $this->createMock(ObjectStateGroupCreateStruct::class), + self::createStub(ObjectStateGroupCreateStruct::class), ]; - $objectStateGroup = $this->createMock(ObjectStateGroup::class); + $objectStateGroup = self::createStub(ObjectStateGroup::class); $innerServiceMock = $this->createMock(ObjectStateServiceInterface::class); $innerServiceMock->method('createObjectStateGroup')->willReturn($objectStateGroup); @@ -124,7 +124,7 @@ public function testCreateObjectStateGroupEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnCreateObjectStateGroupResultInBeforeEvents() + public function testReturnCreateObjectStateGroupResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateObjectStateGroupEvent::class, @@ -132,11 +132,11 @@ public function testReturnCreateObjectStateGroupResultInBeforeEvents() ); $parameters = [ - $this->createMock(ObjectStateGroupCreateStruct::class), + self::createStub(ObjectStateGroupCreateStruct::class), ]; - $objectStateGroup = $this->createMock(ObjectStateGroup::class); - $eventObjectStateGroup = $this->createMock(ObjectStateGroup::class); + $objectStateGroup = self::createStub(ObjectStateGroup::class); + $eventObjectStateGroup = self::createStub(ObjectStateGroup::class); $innerServiceMock = $this->createMock(ObjectStateServiceInterface::class); $innerServiceMock->method('createObjectStateGroup')->willReturn($objectStateGroup); @@ -158,7 +158,7 @@ public function testReturnCreateObjectStateGroupResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCreateObjectStateGroupStopPropagationInBeforeEvents() + public function testCreateObjectStateGroupStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateObjectStateGroupEvent::class, @@ -166,11 +166,11 @@ public function testCreateObjectStateGroupStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ObjectStateGroupCreateStruct::class), + self::createStub(ObjectStateGroupCreateStruct::class), ]; - $objectStateGroup = $this->createMock(ObjectStateGroup::class); - $eventObjectStateGroup = $this->createMock(ObjectStateGroup::class); + $objectStateGroup = self::createStub(ObjectStateGroup::class); + $eventObjectStateGroup = self::createStub(ObjectStateGroup::class); $innerServiceMock = $this->createMock(ObjectStateServiceInterface::class); $innerServiceMock->method('createObjectStateGroup')->willReturn($objectStateGroup); @@ -195,7 +195,7 @@ public function testCreateObjectStateGroupStopPropagationInBeforeEvents() ]); } - public function testUpdateObjectStateEvents() + public function testUpdateObjectStateEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateObjectStateEvent::class, @@ -203,11 +203,11 @@ public function testUpdateObjectStateEvents() ); $parameters = [ - $this->createMock(ObjectState::class), - $this->createMock(ObjectStateUpdateStruct::class), + self::createStub(ObjectState::class), + self::createStub(ObjectStateUpdateStruct::class), ]; - $updatedObjectState = $this->createMock(ObjectState::class); + $updatedObjectState = self::createStub(ObjectState::class); $innerServiceMock = $this->createMock(ObjectStateServiceInterface::class); $innerServiceMock->method('updateObjectState')->willReturn($updatedObjectState); @@ -224,7 +224,7 @@ public function testUpdateObjectStateEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnUpdateObjectStateResultInBeforeEvents() + public function testReturnUpdateObjectStateResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateObjectStateEvent::class, @@ -232,12 +232,12 @@ public function testReturnUpdateObjectStateResultInBeforeEvents() ); $parameters = [ - $this->createMock(ObjectState::class), - $this->createMock(ObjectStateUpdateStruct::class), + self::createStub(ObjectState::class), + self::createStub(ObjectStateUpdateStruct::class), ]; - $updatedObjectState = $this->createMock(ObjectState::class); - $eventUpdatedObjectState = $this->createMock(ObjectState::class); + $updatedObjectState = self::createStub(ObjectState::class); + $eventUpdatedObjectState = self::createStub(ObjectState::class); $innerServiceMock = $this->createMock(ObjectStateServiceInterface::class); $innerServiceMock->method('updateObjectState')->willReturn($updatedObjectState); @@ -259,7 +259,7 @@ public function testReturnUpdateObjectStateResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testUpdateObjectStateStopPropagationInBeforeEvents() + public function testUpdateObjectStateStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateObjectStateEvent::class, @@ -267,12 +267,12 @@ public function testUpdateObjectStateStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ObjectState::class), - $this->createMock(ObjectStateUpdateStruct::class), + self::createStub(ObjectState::class), + self::createStub(ObjectStateUpdateStruct::class), ]; - $updatedObjectState = $this->createMock(ObjectState::class); - $eventUpdatedObjectState = $this->createMock(ObjectState::class); + $updatedObjectState = self::createStub(ObjectState::class); + $eventUpdatedObjectState = self::createStub(ObjectState::class); $innerServiceMock = $this->createMock(ObjectStateServiceInterface::class); $innerServiceMock->method('updateObjectState')->willReturn($updatedObjectState); @@ -297,7 +297,7 @@ public function testUpdateObjectStateStopPropagationInBeforeEvents() ]); } - public function testCreateObjectStateEvents() + public function testCreateObjectStateEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateObjectStateEvent::class, @@ -305,11 +305,11 @@ public function testCreateObjectStateEvents() ); $parameters = [ - $this->createMock(ObjectStateGroup::class), - $this->createMock(ObjectStateCreateStruct::class), + self::createStub(ObjectStateGroup::class), + self::createStub(ObjectStateCreateStruct::class), ]; - $objectState = $this->createMock(ObjectState::class); + $objectState = self::createStub(ObjectState::class); $innerServiceMock = $this->createMock(ObjectStateServiceInterface::class); $innerServiceMock->method('createObjectState')->willReturn($objectState); @@ -326,7 +326,7 @@ public function testCreateObjectStateEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnCreateObjectStateResultInBeforeEvents() + public function testReturnCreateObjectStateResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateObjectStateEvent::class, @@ -334,12 +334,12 @@ public function testReturnCreateObjectStateResultInBeforeEvents() ); $parameters = [ - $this->createMock(ObjectStateGroup::class), - $this->createMock(ObjectStateCreateStruct::class), + self::createStub(ObjectStateGroup::class), + self::createStub(ObjectStateCreateStruct::class), ]; - $objectState = $this->createMock(ObjectState::class); - $eventObjectState = $this->createMock(ObjectState::class); + $objectState = self::createStub(ObjectState::class); + $eventObjectState = self::createStub(ObjectState::class); $innerServiceMock = $this->createMock(ObjectStateServiceInterface::class); $innerServiceMock->method('createObjectState')->willReturn($objectState); @@ -361,7 +361,7 @@ public function testReturnCreateObjectStateResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCreateObjectStateStopPropagationInBeforeEvents() + public function testCreateObjectStateStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateObjectStateEvent::class, @@ -369,12 +369,12 @@ public function testCreateObjectStateStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ObjectStateGroup::class), - $this->createMock(ObjectStateCreateStruct::class), + self::createStub(ObjectStateGroup::class), + self::createStub(ObjectStateCreateStruct::class), ]; - $objectState = $this->createMock(ObjectState::class); - $eventObjectState = $this->createMock(ObjectState::class); + $objectState = self::createStub(ObjectState::class); + $eventObjectState = self::createStub(ObjectState::class); $innerServiceMock = $this->createMock(ObjectStateServiceInterface::class); $innerServiceMock->method('createObjectState')->willReturn($objectState); @@ -399,7 +399,7 @@ public function testCreateObjectStateStopPropagationInBeforeEvents() ]); } - public function testUpdateObjectStateGroupEvents() + public function testUpdateObjectStateGroupEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateObjectStateGroupEvent::class, @@ -407,11 +407,11 @@ public function testUpdateObjectStateGroupEvents() ); $parameters = [ - $this->createMock(ObjectStateGroup::class), - $this->createMock(ObjectStateGroupUpdateStruct::class), + self::createStub(ObjectStateGroup::class), + self::createStub(ObjectStateGroupUpdateStruct::class), ]; - $updatedObjectStateGroup = $this->createMock(ObjectStateGroup::class); + $updatedObjectStateGroup = self::createStub(ObjectStateGroup::class); $innerServiceMock = $this->createMock(ObjectStateServiceInterface::class); $innerServiceMock->method('updateObjectStateGroup')->willReturn($updatedObjectStateGroup); @@ -428,7 +428,7 @@ public function testUpdateObjectStateGroupEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnUpdateObjectStateGroupResultInBeforeEvents() + public function testReturnUpdateObjectStateGroupResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateObjectStateGroupEvent::class, @@ -436,12 +436,12 @@ public function testReturnUpdateObjectStateGroupResultInBeforeEvents() ); $parameters = [ - $this->createMock(ObjectStateGroup::class), - $this->createMock(ObjectStateGroupUpdateStruct::class), + self::createStub(ObjectStateGroup::class), + self::createStub(ObjectStateGroupUpdateStruct::class), ]; - $updatedObjectStateGroup = $this->createMock(ObjectStateGroup::class); - $eventUpdatedObjectStateGroup = $this->createMock(ObjectStateGroup::class); + $updatedObjectStateGroup = self::createStub(ObjectStateGroup::class); + $eventUpdatedObjectStateGroup = self::createStub(ObjectStateGroup::class); $innerServiceMock = $this->createMock(ObjectStateServiceInterface::class); $innerServiceMock->method('updateObjectStateGroup')->willReturn($updatedObjectStateGroup); @@ -463,7 +463,7 @@ public function testReturnUpdateObjectStateGroupResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testUpdateObjectStateGroupStopPropagationInBeforeEvents() + public function testUpdateObjectStateGroupStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateObjectStateGroupEvent::class, @@ -471,12 +471,12 @@ public function testUpdateObjectStateGroupStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ObjectStateGroup::class), - $this->createMock(ObjectStateGroupUpdateStruct::class), + self::createStub(ObjectStateGroup::class), + self::createStub(ObjectStateGroupUpdateStruct::class), ]; - $updatedObjectStateGroup = $this->createMock(ObjectStateGroup::class); - $eventUpdatedObjectStateGroup = $this->createMock(ObjectStateGroup::class); + $updatedObjectStateGroup = self::createStub(ObjectStateGroup::class); + $eventUpdatedObjectStateGroup = self::createStub(ObjectStateGroup::class); $innerServiceMock = $this->createMock(ObjectStateServiceInterface::class); $innerServiceMock->method('updateObjectStateGroup')->willReturn($updatedObjectStateGroup); @@ -501,7 +501,7 @@ public function testUpdateObjectStateGroupStopPropagationInBeforeEvents() ]); } - public function testSetPriorityOfObjectStateEvents() + public function testSetPriorityOfObjectStateEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeSetPriorityOfObjectStateEvent::class, @@ -509,11 +509,11 @@ public function testSetPriorityOfObjectStateEvents() ); $parameters = [ - $this->createMock(ObjectState::class), + self::createStub(ObjectState::class), 100, ]; - $innerServiceMock = $this->createMock(ObjectStateServiceInterface::class); + $innerServiceMock = self::createStub(ObjectStateServiceInterface::class); $service = new ObjectStateService($innerServiceMock, $traceableEventDispatcher); $service->setPriorityOfObjectState(...$parameters); @@ -527,7 +527,7 @@ public function testSetPriorityOfObjectStateEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testSetPriorityOfObjectStateStopPropagationInBeforeEvents() + public function testSetPriorityOfObjectStateStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeSetPriorityOfObjectStateEvent::class, @@ -535,11 +535,11 @@ public function testSetPriorityOfObjectStateStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ObjectState::class), + self::createStub(ObjectState::class), 100, ]; - $innerServiceMock = $this->createMock(ObjectStateServiceInterface::class); + $innerServiceMock = self::createStub(ObjectStateServiceInterface::class); $traceableEventDispatcher->addListener(BeforeSetPriorityOfObjectStateEvent::class, static function (BeforeSetPriorityOfObjectStateEvent $event) { $event->stopPropagation(); @@ -560,7 +560,7 @@ public function testSetPriorityOfObjectStateStopPropagationInBeforeEvents() ]); } - public function testDeleteObjectStateGroupEvents() + public function testDeleteObjectStateGroupEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteObjectStateGroupEvent::class, @@ -568,10 +568,10 @@ public function testDeleteObjectStateGroupEvents() ); $parameters = [ - $this->createMock(ObjectStateGroup::class), + self::createStub(ObjectStateGroup::class), ]; - $innerServiceMock = $this->createMock(ObjectStateServiceInterface::class); + $innerServiceMock = self::createStub(ObjectStateServiceInterface::class); $service = new ObjectStateService($innerServiceMock, $traceableEventDispatcher); $service->deleteObjectStateGroup(...$parameters); @@ -585,7 +585,7 @@ public function testDeleteObjectStateGroupEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testDeleteObjectStateGroupStopPropagationInBeforeEvents() + public function testDeleteObjectStateGroupStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteObjectStateGroupEvent::class, @@ -593,10 +593,10 @@ public function testDeleteObjectStateGroupStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ObjectStateGroup::class), + self::createStub(ObjectStateGroup::class), ]; - $innerServiceMock = $this->createMock(ObjectStateServiceInterface::class); + $innerServiceMock = self::createStub(ObjectStateServiceInterface::class); $traceableEventDispatcher->addListener(BeforeDeleteObjectStateGroupEvent::class, static function (BeforeDeleteObjectStateGroupEvent $event) { $event->stopPropagation(); @@ -617,7 +617,7 @@ public function testDeleteObjectStateGroupStopPropagationInBeforeEvents() ]); } - public function testDeleteObjectStateEvents() + public function testDeleteObjectStateEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteObjectStateEvent::class, @@ -625,10 +625,10 @@ public function testDeleteObjectStateEvents() ); $parameters = [ - $this->createMock(ObjectState::class), + self::createStub(ObjectState::class), ]; - $innerServiceMock = $this->createMock(ObjectStateServiceInterface::class); + $innerServiceMock = self::createStub(ObjectStateServiceInterface::class); $service = new ObjectStateService($innerServiceMock, $traceableEventDispatcher); $service->deleteObjectState(...$parameters); @@ -642,7 +642,7 @@ public function testDeleteObjectStateEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testDeleteObjectStateStopPropagationInBeforeEvents() + public function testDeleteObjectStateStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteObjectStateEvent::class, @@ -650,10 +650,10 @@ public function testDeleteObjectStateStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ObjectState::class), + self::createStub(ObjectState::class), ]; - $innerServiceMock = $this->createMock(ObjectStateServiceInterface::class); + $innerServiceMock = self::createStub(ObjectStateServiceInterface::class); $traceableEventDispatcher->addListener(BeforeDeleteObjectStateEvent::class, static function (BeforeDeleteObjectStateEvent $event) { $event->stopPropagation(); diff --git a/tests/lib/Event/RoleServiceTest.php b/tests/lib/Event/RoleServiceTest.php index 1538ecc5dc..c73293fd88 100644 --- a/tests/lib/Event/RoleServiceTest.php +++ b/tests/lib/Event/RoleServiceTest.php @@ -47,7 +47,7 @@ class RoleServiceTest extends AbstractServiceTestCase { - public function testPublishRoleDraftEvents() + public function testPublishRoleDraftEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforePublishRoleDraftEvent::class, @@ -55,10 +55,10 @@ public function testPublishRoleDraftEvents() ); $parameters = [ - $this->createMock(RoleDraft::class), + self::createStub(RoleDraft::class), ]; - $innerServiceMock = $this->createMock(RoleServiceInterface::class); + $innerServiceMock = self::createStub(RoleServiceInterface::class); $service = new RoleService($innerServiceMock, $traceableEventDispatcher); $service->publishRoleDraft(...$parameters); @@ -72,7 +72,7 @@ public function testPublishRoleDraftEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testPublishRoleDraftStopPropagationInBeforeEvents() + public function testPublishRoleDraftStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforePublishRoleDraftEvent::class, @@ -80,10 +80,10 @@ public function testPublishRoleDraftStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(RoleDraft::class), + self::createStub(RoleDraft::class), ]; - $innerServiceMock = $this->createMock(RoleServiceInterface::class); + $innerServiceMock = self::createStub(RoleServiceInterface::class); $traceableEventDispatcher->addListener(BeforePublishRoleDraftEvent::class, static function (BeforePublishRoleDraftEvent $event) { $event->stopPropagation(); @@ -104,7 +104,7 @@ public function testPublishRoleDraftStopPropagationInBeforeEvents() ]); } - public function testAssignRoleToUserEvents() + public function testAssignRoleToUserEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeAssignRoleToUserEvent::class, @@ -112,12 +112,12 @@ public function testAssignRoleToUserEvents() ); $parameters = [ - $this->createMock(Role::class), - $this->createMock(User::class), - $this->createMock(RoleLimitation::class), + self::createStub(Role::class), + self::createStub(User::class), + self::createStub(RoleLimitation::class), ]; - $innerServiceMock = $this->createMock(RoleServiceInterface::class); + $innerServiceMock = self::createStub(RoleServiceInterface::class); $service = new RoleService($innerServiceMock, $traceableEventDispatcher); $service->assignRoleToUser(...$parameters); @@ -131,7 +131,7 @@ public function testAssignRoleToUserEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testAssignRoleToUserStopPropagationInBeforeEvents() + public function testAssignRoleToUserStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeAssignRoleToUserEvent::class, @@ -139,12 +139,12 @@ public function testAssignRoleToUserStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Role::class), - $this->createMock(User::class), - $this->createMock(RoleLimitation::class), + self::createStub(Role::class), + self::createStub(User::class), + self::createStub(RoleLimitation::class), ]; - $innerServiceMock = $this->createMock(RoleServiceInterface::class); + $innerServiceMock = self::createStub(RoleServiceInterface::class); $traceableEventDispatcher->addListener(BeforeAssignRoleToUserEvent::class, static function (BeforeAssignRoleToUserEvent $event) { $event->stopPropagation(); @@ -165,7 +165,7 @@ public function testAssignRoleToUserStopPropagationInBeforeEvents() ]); } - public function testUpdateRoleDraftEvents() + public function testUpdateRoleDraftEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateRoleDraftEvent::class, @@ -173,11 +173,11 @@ public function testUpdateRoleDraftEvents() ); $parameters = [ - $this->createMock(RoleDraft::class), - $this->createMock(RoleUpdateStruct::class), + self::createStub(RoleDraft::class), + self::createStub(RoleUpdateStruct::class), ]; - $updatedRoleDraft = $this->createMock(RoleDraft::class); + $updatedRoleDraft = self::createStub(RoleDraft::class); $innerServiceMock = $this->createMock(RoleServiceInterface::class); $innerServiceMock->method('updateRoleDraft')->willReturn($updatedRoleDraft); @@ -194,7 +194,7 @@ public function testUpdateRoleDraftEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnUpdateRoleDraftResultInBeforeEvents() + public function testReturnUpdateRoleDraftResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateRoleDraftEvent::class, @@ -202,12 +202,12 @@ public function testReturnUpdateRoleDraftResultInBeforeEvents() ); $parameters = [ - $this->createMock(RoleDraft::class), - $this->createMock(RoleUpdateStruct::class), + self::createStub(RoleDraft::class), + self::createStub(RoleUpdateStruct::class), ]; - $updatedRoleDraft = $this->createMock(RoleDraft::class); - $eventUpdatedRoleDraft = $this->createMock(RoleDraft::class); + $updatedRoleDraft = self::createStub(RoleDraft::class); + $eventUpdatedRoleDraft = self::createStub(RoleDraft::class); $innerServiceMock = $this->createMock(RoleServiceInterface::class); $innerServiceMock->method('updateRoleDraft')->willReturn($updatedRoleDraft); @@ -229,7 +229,7 @@ public function testReturnUpdateRoleDraftResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testUpdateRoleDraftStopPropagationInBeforeEvents() + public function testUpdateRoleDraftStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateRoleDraftEvent::class, @@ -237,12 +237,12 @@ public function testUpdateRoleDraftStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(RoleDraft::class), - $this->createMock(RoleUpdateStruct::class), + self::createStub(RoleDraft::class), + self::createStub(RoleUpdateStruct::class), ]; - $updatedRoleDraft = $this->createMock(RoleDraft::class); - $eventUpdatedRoleDraft = $this->createMock(RoleDraft::class); + $updatedRoleDraft = self::createStub(RoleDraft::class); + $eventUpdatedRoleDraft = self::createStub(RoleDraft::class); $innerServiceMock = $this->createMock(RoleServiceInterface::class); $innerServiceMock->method('updateRoleDraft')->willReturn($updatedRoleDraft); @@ -267,7 +267,7 @@ public function testUpdateRoleDraftStopPropagationInBeforeEvents() ]); } - public function testAssignRoleToUserGroupEvents() + public function testAssignRoleToUserGroupEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeAssignRoleToUserGroupEvent::class, @@ -275,12 +275,12 @@ public function testAssignRoleToUserGroupEvents() ); $parameters = [ - $this->createMock(Role::class), - $this->createMock(UserGroup::class), - $this->createMock(RoleLimitation::class), + self::createStub(Role::class), + self::createStub(UserGroup::class), + self::createStub(RoleLimitation::class), ]; - $innerServiceMock = $this->createMock(RoleServiceInterface::class); + $innerServiceMock = self::createStub(RoleServiceInterface::class); $service = new RoleService($innerServiceMock, $traceableEventDispatcher); $service->assignRoleToUserGroup(...$parameters); @@ -294,7 +294,7 @@ public function testAssignRoleToUserGroupEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testAssignRoleToUserGroupStopPropagationInBeforeEvents() + public function testAssignRoleToUserGroupStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeAssignRoleToUserGroupEvent::class, @@ -302,12 +302,12 @@ public function testAssignRoleToUserGroupStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Role::class), - $this->createMock(UserGroup::class), - $this->createMock(RoleLimitation::class), + self::createStub(Role::class), + self::createStub(UserGroup::class), + self::createStub(RoleLimitation::class), ]; - $innerServiceMock = $this->createMock(RoleServiceInterface::class); + $innerServiceMock = self::createStub(RoleServiceInterface::class); $traceableEventDispatcher->addListener(BeforeAssignRoleToUserGroupEvent::class, static function (BeforeAssignRoleToUserGroupEvent $event) { $event->stopPropagation(); @@ -328,7 +328,7 @@ public function testAssignRoleToUserGroupStopPropagationInBeforeEvents() ]); } - public function testUpdatePolicyByRoleDraftEvents() + public function testUpdatePolicyByRoleDraftEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdatePolicyByRoleDraftEvent::class, @@ -336,12 +336,12 @@ public function testUpdatePolicyByRoleDraftEvents() ); $parameters = [ - $this->createMock(RoleDraft::class), - $this->createMock(PolicyDraft::class), - $this->createMock(PolicyUpdateStruct::class), + self::createStub(RoleDraft::class), + self::createStub(PolicyDraft::class), + self::createStub(PolicyUpdateStruct::class), ]; - $updatedPolicyDraft = $this->createMock(PolicyDraft::class); + $updatedPolicyDraft = self::createStub(PolicyDraft::class); $innerServiceMock = $this->createMock(RoleServiceInterface::class); $innerServiceMock->method('updatePolicyByRoleDraft')->willReturn($updatedPolicyDraft); @@ -358,7 +358,7 @@ public function testUpdatePolicyByRoleDraftEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnUpdatePolicyByRoleDraftResultInBeforeEvents() + public function testReturnUpdatePolicyByRoleDraftResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdatePolicyByRoleDraftEvent::class, @@ -366,13 +366,13 @@ public function testReturnUpdatePolicyByRoleDraftResultInBeforeEvents() ); $parameters = [ - $this->createMock(RoleDraft::class), - $this->createMock(PolicyDraft::class), - $this->createMock(PolicyUpdateStruct::class), + self::createStub(RoleDraft::class), + self::createStub(PolicyDraft::class), + self::createStub(PolicyUpdateStruct::class), ]; - $updatedPolicyDraft = $this->createMock(PolicyDraft::class); - $eventUpdatedPolicyDraft = $this->createMock(PolicyDraft::class); + $updatedPolicyDraft = self::createStub(PolicyDraft::class); + $eventUpdatedPolicyDraft = self::createStub(PolicyDraft::class); $innerServiceMock = $this->createMock(RoleServiceInterface::class); $innerServiceMock->method('updatePolicyByRoleDraft')->willReturn($updatedPolicyDraft); @@ -394,7 +394,7 @@ public function testReturnUpdatePolicyByRoleDraftResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testUpdatePolicyByRoleDraftStopPropagationInBeforeEvents() + public function testUpdatePolicyByRoleDraftStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdatePolicyByRoleDraftEvent::class, @@ -402,13 +402,13 @@ public function testUpdatePolicyByRoleDraftStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(RoleDraft::class), - $this->createMock(PolicyDraft::class), - $this->createMock(PolicyUpdateStruct::class), + self::createStub(RoleDraft::class), + self::createStub(PolicyDraft::class), + self::createStub(PolicyUpdateStruct::class), ]; - $updatedPolicyDraft = $this->createMock(PolicyDraft::class); - $eventUpdatedPolicyDraft = $this->createMock(PolicyDraft::class); + $updatedPolicyDraft = self::createStub(PolicyDraft::class); + $eventUpdatedPolicyDraft = self::createStub(PolicyDraft::class); $innerServiceMock = $this->createMock(RoleServiceInterface::class); $innerServiceMock->method('updatePolicyByRoleDraft')->willReturn($updatedPolicyDraft); @@ -433,7 +433,7 @@ public function testUpdatePolicyByRoleDraftStopPropagationInBeforeEvents() ]); } - public function testCreateRoleEvents() + public function testCreateRoleEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateRoleEvent::class, @@ -441,10 +441,10 @@ public function testCreateRoleEvents() ); $parameters = [ - $this->createMock(RoleCreateStruct::class), + self::createStub(RoleCreateStruct::class), ]; - $roleDraft = $this->createMock(RoleDraft::class); + $roleDraft = self::createStub(RoleDraft::class); $innerServiceMock = $this->createMock(RoleServiceInterface::class); $innerServiceMock->method('createRole')->willReturn($roleDraft); @@ -461,7 +461,7 @@ public function testCreateRoleEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnCreateRoleResultInBeforeEvents() + public function testReturnCreateRoleResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateRoleEvent::class, @@ -469,11 +469,11 @@ public function testReturnCreateRoleResultInBeforeEvents() ); $parameters = [ - $this->createMock(RoleCreateStruct::class), + self::createStub(RoleCreateStruct::class), ]; - $roleDraft = $this->createMock(RoleDraft::class); - $eventRoleDraft = $this->createMock(RoleDraft::class); + $roleDraft = self::createStub(RoleDraft::class); + $eventRoleDraft = self::createStub(RoleDraft::class); $innerServiceMock = $this->createMock(RoleServiceInterface::class); $innerServiceMock->method('createRole')->willReturn($roleDraft); @@ -495,7 +495,7 @@ public function testReturnCreateRoleResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCreateRoleStopPropagationInBeforeEvents() + public function testCreateRoleStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateRoleEvent::class, @@ -503,11 +503,11 @@ public function testCreateRoleStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(RoleCreateStruct::class), + self::createStub(RoleCreateStruct::class), ]; - $roleDraft = $this->createMock(RoleDraft::class); - $eventRoleDraft = $this->createMock(RoleDraft::class); + $roleDraft = self::createStub(RoleDraft::class); + $eventRoleDraft = self::createStub(RoleDraft::class); $innerServiceMock = $this->createMock(RoleServiceInterface::class); $innerServiceMock->method('createRole')->willReturn($roleDraft); @@ -532,7 +532,7 @@ public function testCreateRoleStopPropagationInBeforeEvents() ]); } - public function testRemovePolicyByRoleDraftEvents() + public function testRemovePolicyByRoleDraftEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRemovePolicyByRoleDraftEvent::class, @@ -540,11 +540,11 @@ public function testRemovePolicyByRoleDraftEvents() ); $parameters = [ - $this->createMock(RoleDraft::class), - $this->createMock(PolicyDraft::class), + self::createStub(RoleDraft::class), + self::createStub(PolicyDraft::class), ]; - $updatedRoleDraft = $this->createMock(RoleDraft::class); + $updatedRoleDraft = self::createStub(RoleDraft::class); $innerServiceMock = $this->createMock(RoleServiceInterface::class); $innerServiceMock->method('removePolicyByRoleDraft')->willReturn($updatedRoleDraft); @@ -561,7 +561,7 @@ public function testRemovePolicyByRoleDraftEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnRemovePolicyByRoleDraftResultInBeforeEvents() + public function testReturnRemovePolicyByRoleDraftResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRemovePolicyByRoleDraftEvent::class, @@ -569,12 +569,12 @@ public function testReturnRemovePolicyByRoleDraftResultInBeforeEvents() ); $parameters = [ - $this->createMock(RoleDraft::class), - $this->createMock(PolicyDraft::class), + self::createStub(RoleDraft::class), + self::createStub(PolicyDraft::class), ]; - $updatedRoleDraft = $this->createMock(RoleDraft::class); - $eventUpdatedRoleDraft = $this->createMock(RoleDraft::class); + $updatedRoleDraft = self::createStub(RoleDraft::class); + $eventUpdatedRoleDraft = self::createStub(RoleDraft::class); $innerServiceMock = $this->createMock(RoleServiceInterface::class); $innerServiceMock->method('removePolicyByRoleDraft')->willReturn($updatedRoleDraft); @@ -596,7 +596,7 @@ public function testReturnRemovePolicyByRoleDraftResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testRemovePolicyByRoleDraftStopPropagationInBeforeEvents() + public function testRemovePolicyByRoleDraftStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRemovePolicyByRoleDraftEvent::class, @@ -604,12 +604,12 @@ public function testRemovePolicyByRoleDraftStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(RoleDraft::class), - $this->createMock(PolicyDraft::class), + self::createStub(RoleDraft::class), + self::createStub(PolicyDraft::class), ]; - $updatedRoleDraft = $this->createMock(RoleDraft::class); - $eventUpdatedRoleDraft = $this->createMock(RoleDraft::class); + $updatedRoleDraft = self::createStub(RoleDraft::class); + $eventUpdatedRoleDraft = self::createStub(RoleDraft::class); $innerServiceMock = $this->createMock(RoleServiceInterface::class); $innerServiceMock->method('removePolicyByRoleDraft')->willReturn($updatedRoleDraft); @@ -634,7 +634,7 @@ public function testRemovePolicyByRoleDraftStopPropagationInBeforeEvents() ]); } - public function testAddPolicyByRoleDraftEvents() + public function testAddPolicyByRoleDraftEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeAddPolicyByRoleDraftEvent::class, @@ -642,11 +642,11 @@ public function testAddPolicyByRoleDraftEvents() ); $parameters = [ - $this->createMock(RoleDraft::class), - $this->createMock(PolicyCreateStruct::class), + self::createStub(RoleDraft::class), + self::createStub(PolicyCreateStruct::class), ]; - $updatedRoleDraft = $this->createMock(RoleDraft::class); + $updatedRoleDraft = self::createStub(RoleDraft::class); $innerServiceMock = $this->createMock(RoleServiceInterface::class); $innerServiceMock->method('addPolicyByRoleDraft')->willReturn($updatedRoleDraft); @@ -663,7 +663,7 @@ public function testAddPolicyByRoleDraftEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnAddPolicyByRoleDraftResultInBeforeEvents() + public function testReturnAddPolicyByRoleDraftResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeAddPolicyByRoleDraftEvent::class, @@ -671,12 +671,12 @@ public function testReturnAddPolicyByRoleDraftResultInBeforeEvents() ); $parameters = [ - $this->createMock(RoleDraft::class), - $this->createMock(PolicyCreateStruct::class), + self::createStub(RoleDraft::class), + self::createStub(PolicyCreateStruct::class), ]; - $updatedRoleDraft = $this->createMock(RoleDraft::class); - $eventUpdatedRoleDraft = $this->createMock(RoleDraft::class); + $updatedRoleDraft = self::createStub(RoleDraft::class); + $eventUpdatedRoleDraft = self::createStub(RoleDraft::class); $innerServiceMock = $this->createMock(RoleServiceInterface::class); $innerServiceMock->method('addPolicyByRoleDraft')->willReturn($updatedRoleDraft); @@ -698,7 +698,7 @@ public function testReturnAddPolicyByRoleDraftResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testAddPolicyByRoleDraftStopPropagationInBeforeEvents() + public function testAddPolicyByRoleDraftStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeAddPolicyByRoleDraftEvent::class, @@ -706,12 +706,12 @@ public function testAddPolicyByRoleDraftStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(RoleDraft::class), - $this->createMock(PolicyCreateStruct::class), + self::createStub(RoleDraft::class), + self::createStub(PolicyCreateStruct::class), ]; - $updatedRoleDraft = $this->createMock(RoleDraft::class); - $eventUpdatedRoleDraft = $this->createMock(RoleDraft::class); + $updatedRoleDraft = self::createStub(RoleDraft::class); + $eventUpdatedRoleDraft = self::createStub(RoleDraft::class); $innerServiceMock = $this->createMock(RoleServiceInterface::class); $innerServiceMock->method('addPolicyByRoleDraft')->willReturn($updatedRoleDraft); @@ -736,7 +736,7 @@ public function testAddPolicyByRoleDraftStopPropagationInBeforeEvents() ]); } - public function testDeleteRoleEvents() + public function testDeleteRoleEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteRoleEvent::class, @@ -744,10 +744,10 @@ public function testDeleteRoleEvents() ); $parameters = [ - $this->createMock(Role::class), + self::createStub(Role::class), ]; - $innerServiceMock = $this->createMock(RoleServiceInterface::class); + $innerServiceMock = self::createStub(RoleServiceInterface::class); $service = new RoleService($innerServiceMock, $traceableEventDispatcher); $service->deleteRole(...$parameters); @@ -761,7 +761,7 @@ public function testDeleteRoleEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testDeleteRoleStopPropagationInBeforeEvents() + public function testDeleteRoleStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteRoleEvent::class, @@ -769,10 +769,10 @@ public function testDeleteRoleStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Role::class), + self::createStub(Role::class), ]; - $innerServiceMock = $this->createMock(RoleServiceInterface::class); + $innerServiceMock = self::createStub(RoleServiceInterface::class); $traceableEventDispatcher->addListener(BeforeDeleteRoleEvent::class, static function (BeforeDeleteRoleEvent $event) { $event->stopPropagation(); @@ -793,7 +793,7 @@ public function testDeleteRoleStopPropagationInBeforeEvents() ]); } - public function testDeleteRoleDraftEvents() + public function testDeleteRoleDraftEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteRoleDraftEvent::class, @@ -801,10 +801,10 @@ public function testDeleteRoleDraftEvents() ); $parameters = [ - $this->createMock(RoleDraft::class), + self::createStub(RoleDraft::class), ]; - $innerServiceMock = $this->createMock(RoleServiceInterface::class); + $innerServiceMock = self::createStub(RoleServiceInterface::class); $service = new RoleService($innerServiceMock, $traceableEventDispatcher); $service->deleteRoleDraft(...$parameters); @@ -818,7 +818,7 @@ public function testDeleteRoleDraftEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testDeleteRoleDraftStopPropagationInBeforeEvents() + public function testDeleteRoleDraftStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteRoleDraftEvent::class, @@ -826,10 +826,10 @@ public function testDeleteRoleDraftStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(RoleDraft::class), + self::createStub(RoleDraft::class), ]; - $innerServiceMock = $this->createMock(RoleServiceInterface::class); + $innerServiceMock = self::createStub(RoleServiceInterface::class); $traceableEventDispatcher->addListener(BeforeDeleteRoleDraftEvent::class, static function (BeforeDeleteRoleDraftEvent $event) { $event->stopPropagation(); @@ -850,7 +850,7 @@ public function testDeleteRoleDraftStopPropagationInBeforeEvents() ]); } - public function testRemoveRoleAssignmentEvents() + public function testRemoveRoleAssignmentEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRemoveRoleAssignmentEvent::class, @@ -858,10 +858,10 @@ public function testRemoveRoleAssignmentEvents() ); $parameters = [ - $this->createMock(RoleAssignment::class), + self::createStub(RoleAssignment::class), ]; - $innerServiceMock = $this->createMock(RoleServiceInterface::class); + $innerServiceMock = self::createStub(RoleServiceInterface::class); $service = new RoleService($innerServiceMock, $traceableEventDispatcher); $service->removeRoleAssignment(...$parameters); @@ -875,7 +875,7 @@ public function testRemoveRoleAssignmentEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testRemoveRoleAssignmentStopPropagationInBeforeEvents() + public function testRemoveRoleAssignmentStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRemoveRoleAssignmentEvent::class, @@ -883,10 +883,10 @@ public function testRemoveRoleAssignmentStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(RoleAssignment::class), + self::createStub(RoleAssignment::class), ]; - $innerServiceMock = $this->createMock(RoleServiceInterface::class); + $innerServiceMock = self::createStub(RoleServiceInterface::class); $traceableEventDispatcher->addListener(BeforeRemoveRoleAssignmentEvent::class, static function (BeforeRemoveRoleAssignmentEvent $event) { $event->stopPropagation(); @@ -907,7 +907,7 @@ public function testRemoveRoleAssignmentStopPropagationInBeforeEvents() ]); } - public function testCreateRoleDraftEvents() + public function testCreateRoleDraftEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateRoleDraftEvent::class, @@ -915,10 +915,10 @@ public function testCreateRoleDraftEvents() ); $parameters = [ - $this->createMock(Role::class), + self::createStub(Role::class), ]; - $roleDraft = $this->createMock(RoleDraft::class); + $roleDraft = self::createStub(RoleDraft::class); $innerServiceMock = $this->createMock(RoleServiceInterface::class); $innerServiceMock->method('createRoleDraft')->willReturn($roleDraft); @@ -935,7 +935,7 @@ public function testCreateRoleDraftEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnCreateRoleDraftResultInBeforeEvents() + public function testReturnCreateRoleDraftResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateRoleDraftEvent::class, @@ -943,11 +943,11 @@ public function testReturnCreateRoleDraftResultInBeforeEvents() ); $parameters = [ - $this->createMock(Role::class), + self::createStub(Role::class), ]; - $roleDraft = $this->createMock(RoleDraft::class); - $eventRoleDraft = $this->createMock(RoleDraft::class); + $roleDraft = self::createStub(RoleDraft::class); + $eventRoleDraft = self::createStub(RoleDraft::class); $innerServiceMock = $this->createMock(RoleServiceInterface::class); $innerServiceMock->method('createRoleDraft')->willReturn($roleDraft); @@ -969,7 +969,7 @@ public function testReturnCreateRoleDraftResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCreateRoleDraftStopPropagationInBeforeEvents() + public function testCreateRoleDraftStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateRoleDraftEvent::class, @@ -977,11 +977,11 @@ public function testCreateRoleDraftStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Role::class), + self::createStub(Role::class), ]; - $roleDraft = $this->createMock(RoleDraft::class); - $eventRoleDraft = $this->createMock(RoleDraft::class); + $roleDraft = self::createStub(RoleDraft::class); + $eventRoleDraft = self::createStub(RoleDraft::class); $innerServiceMock = $this->createMock(RoleServiceInterface::class); $innerServiceMock->method('createRoleDraft')->willReturn($roleDraft); diff --git a/tests/lib/Event/SectionServiceTest.php b/tests/lib/Event/SectionServiceTest.php index 1b1784f60f..92b29d8027 100644 --- a/tests/lib/Event/SectionServiceTest.php +++ b/tests/lib/Event/SectionServiceTest.php @@ -27,7 +27,7 @@ class SectionServiceTest extends AbstractServiceTestCase { - public function testAssignSectionEvents() + public function testAssignSectionEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeAssignSectionEvent::class, @@ -35,11 +35,11 @@ public function testAssignSectionEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(Section::class), + self::createStub(ContentInfo::class), + self::createStub(Section::class), ]; - $innerServiceMock = $this->createMock(SectionServiceInterface::class); + $innerServiceMock = self::createStub(SectionServiceInterface::class); $service = new SectionService($innerServiceMock, $traceableEventDispatcher); $service->assignSection(...$parameters); @@ -53,7 +53,7 @@ public function testAssignSectionEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testAssignSectionStopPropagationInBeforeEvents() + public function testAssignSectionStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeAssignSectionEvent::class, @@ -61,11 +61,11 @@ public function testAssignSectionStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(Section::class), + self::createStub(ContentInfo::class), + self::createStub(Section::class), ]; - $innerServiceMock = $this->createMock(SectionServiceInterface::class); + $innerServiceMock = self::createStub(SectionServiceInterface::class); $traceableEventDispatcher->addListener(BeforeAssignSectionEvent::class, static function (BeforeAssignSectionEvent $event) { $event->stopPropagation(); @@ -86,7 +86,7 @@ public function testAssignSectionStopPropagationInBeforeEvents() ]); } - public function testUpdateSectionEvents() + public function testUpdateSectionEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateSectionEvent::class, @@ -94,11 +94,11 @@ public function testUpdateSectionEvents() ); $parameters = [ - $this->createMock(Section::class), - $this->createMock(SectionUpdateStruct::class), + self::createStub(Section::class), + self::createStub(SectionUpdateStruct::class), ]; - $updatedSection = $this->createMock(Section::class); + $updatedSection = self::createStub(Section::class); $innerServiceMock = $this->createMock(SectionServiceInterface::class); $innerServiceMock->method('updateSection')->willReturn($updatedSection); @@ -115,7 +115,7 @@ public function testUpdateSectionEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnUpdateSectionResultInBeforeEvents() + public function testReturnUpdateSectionResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateSectionEvent::class, @@ -123,12 +123,12 @@ public function testReturnUpdateSectionResultInBeforeEvents() ); $parameters = [ - $this->createMock(Section::class), - $this->createMock(SectionUpdateStruct::class), + self::createStub(Section::class), + self::createStub(SectionUpdateStruct::class), ]; - $updatedSection = $this->createMock(Section::class); - $eventUpdatedSection = $this->createMock(Section::class); + $updatedSection = self::createStub(Section::class); + $eventUpdatedSection = self::createStub(Section::class); $innerServiceMock = $this->createMock(SectionServiceInterface::class); $innerServiceMock->method('updateSection')->willReturn($updatedSection); @@ -150,7 +150,7 @@ public function testReturnUpdateSectionResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testUpdateSectionStopPropagationInBeforeEvents() + public function testUpdateSectionStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateSectionEvent::class, @@ -158,12 +158,12 @@ public function testUpdateSectionStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Section::class), - $this->createMock(SectionUpdateStruct::class), + self::createStub(Section::class), + self::createStub(SectionUpdateStruct::class), ]; - $updatedSection = $this->createMock(Section::class); - $eventUpdatedSection = $this->createMock(Section::class); + $updatedSection = self::createStub(Section::class); + $eventUpdatedSection = self::createStub(Section::class); $innerServiceMock = $this->createMock(SectionServiceInterface::class); $innerServiceMock->method('updateSection')->willReturn($updatedSection); @@ -188,7 +188,7 @@ public function testUpdateSectionStopPropagationInBeforeEvents() ]); } - public function testAssignSectionToSubtreeEvents() + public function testAssignSectionToSubtreeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeAssignSectionToSubtreeEvent::class, @@ -196,11 +196,11 @@ public function testAssignSectionToSubtreeEvents() ); $parameters = [ - $this->createMock(Location::class), - $this->createMock(Section::class), + self::createStub(Location::class), + self::createStub(Section::class), ]; - $innerServiceMock = $this->createMock(SectionServiceInterface::class); + $innerServiceMock = self::createStub(SectionServiceInterface::class); $service = new SectionService($innerServiceMock, $traceableEventDispatcher); $service->assignSectionToSubtree(...$parameters); @@ -214,7 +214,7 @@ public function testAssignSectionToSubtreeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testAssignSectionToSubtreeStopPropagationInBeforeEvents() + public function testAssignSectionToSubtreeStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeAssignSectionToSubtreeEvent::class, @@ -222,11 +222,11 @@ public function testAssignSectionToSubtreeStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Location::class), - $this->createMock(Section::class), + self::createStub(Location::class), + self::createStub(Section::class), ]; - $innerServiceMock = $this->createMock(SectionServiceInterface::class); + $innerServiceMock = self::createStub(SectionServiceInterface::class); $traceableEventDispatcher->addListener(BeforeAssignSectionToSubtreeEvent::class, static function (BeforeAssignSectionToSubtreeEvent $event) { $event->stopPropagation(); @@ -247,7 +247,7 @@ public function testAssignSectionToSubtreeStopPropagationInBeforeEvents() ]); } - public function testDeleteSectionEvents() + public function testDeleteSectionEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteSectionEvent::class, @@ -255,10 +255,10 @@ public function testDeleteSectionEvents() ); $parameters = [ - $this->createMock(Section::class), + self::createStub(Section::class), ]; - $innerServiceMock = $this->createMock(SectionServiceInterface::class); + $innerServiceMock = self::createStub(SectionServiceInterface::class); $service = new SectionService($innerServiceMock, $traceableEventDispatcher); $service->deleteSection(...$parameters); @@ -272,7 +272,7 @@ public function testDeleteSectionEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testDeleteSectionStopPropagationInBeforeEvents() + public function testDeleteSectionStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteSectionEvent::class, @@ -280,10 +280,10 @@ public function testDeleteSectionStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Section::class), + self::createStub(Section::class), ]; - $innerServiceMock = $this->createMock(SectionServiceInterface::class); + $innerServiceMock = self::createStub(SectionServiceInterface::class); $traceableEventDispatcher->addListener(BeforeDeleteSectionEvent::class, static function (BeforeDeleteSectionEvent $event) { $event->stopPropagation(); @@ -304,7 +304,7 @@ public function testDeleteSectionStopPropagationInBeforeEvents() ]); } - public function testCreateSectionEvents() + public function testCreateSectionEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateSectionEvent::class, @@ -312,10 +312,10 @@ public function testCreateSectionEvents() ); $parameters = [ - $this->createMock(SectionCreateStruct::class), + self::createStub(SectionCreateStruct::class), ]; - $section = $this->createMock(Section::class); + $section = self::createStub(Section::class); $innerServiceMock = $this->createMock(SectionServiceInterface::class); $innerServiceMock->method('createSection')->willReturn($section); @@ -332,7 +332,7 @@ public function testCreateSectionEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnCreateSectionResultInBeforeEvents() + public function testReturnCreateSectionResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateSectionEvent::class, @@ -340,11 +340,11 @@ public function testReturnCreateSectionResultInBeforeEvents() ); $parameters = [ - $this->createMock(SectionCreateStruct::class), + self::createStub(SectionCreateStruct::class), ]; - $section = $this->createMock(Section::class); - $eventSection = $this->createMock(Section::class); + $section = self::createStub(Section::class); + $eventSection = self::createStub(Section::class); $innerServiceMock = $this->createMock(SectionServiceInterface::class); $innerServiceMock->method('createSection')->willReturn($section); @@ -366,7 +366,7 @@ public function testReturnCreateSectionResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCreateSectionStopPropagationInBeforeEvents() + public function testCreateSectionStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateSectionEvent::class, @@ -374,11 +374,11 @@ public function testCreateSectionStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(SectionCreateStruct::class), + self::createStub(SectionCreateStruct::class), ]; - $section = $this->createMock(Section::class); - $eventSection = $this->createMock(Section::class); + $section = self::createStub(Section::class); + $eventSection = self::createStub(Section::class); $innerServiceMock = $this->createMock(SectionServiceInterface::class); $innerServiceMock->method('createSection')->willReturn($section); diff --git a/tests/lib/Event/SettingServiceTest.php b/tests/lib/Event/SettingServiceTest.php index f74c5c3860..200804afac 100644 --- a/tests/lib/Event/SettingServiceTest.php +++ b/tests/lib/Event/SettingServiceTest.php @@ -28,7 +28,7 @@ public function testUpdateSettingEvents(): void BeforeUpdateSettingEvent::class, UpdateSettingEvent::class ); - $updatedSetting = $this->createMock(Setting::class); + $updatedSetting = self::createStub(Setting::class); $result = $this->updateSetting($updatedSetting, $traceableEventDispatcher); @@ -53,7 +53,7 @@ public function testReturnUpdateSettingResultInBeforeEvents(): void BeforeUpdateSettingEvent::class, UpdateSettingEvent::class ); - $eventUpdatedSetting = $this->createMock(Setting::class); + $eventUpdatedSetting = self::createStub(Setting::class); $traceableEventDispatcher->addListener( BeforeUpdateSettingEvent::class, @@ -62,7 +62,7 @@ static function (BeforeUpdateSettingEvent $event) use ($eventUpdatedSetting) { }, 10 ); - $updatedSetting = $this->createMock(Setting::class); + $updatedSetting = self::createStub(Setting::class); $result = $this->updateSetting($updatedSetting, $traceableEventDispatcher); @@ -88,7 +88,7 @@ public function testUpdateSettingStopPropagationInBeforeEvents(): void BeforeUpdateSettingEvent::class, UpdateSettingEvent::class ); - $eventUpdatedSetting = $this->createMock(Setting::class); + $eventUpdatedSetting = self::createStub(Setting::class); $traceableEventDispatcher->addListener( BeforeUpdateSettingEvent::class, static function (BeforeUpdateSettingEvent $event) use ($eventUpdatedSetting) { @@ -97,7 +97,7 @@ static function (BeforeUpdateSettingEvent $event) use ($eventUpdatedSetting) { }, 10 ); - $updatedSetting = $this->createMock(Setting::class); + $updatedSetting = self::createStub(Setting::class); $result = $this->updateSetting($updatedSetting, $traceableEventDispatcher); @@ -132,10 +132,10 @@ public function testDeleteSettingEvents(): void ); $parameters = [ - $this->createMock(Setting::class), + self::createStub(Setting::class), ]; - $innerServiceMock = $this->createMock(SettingServiceInterface::class); + $innerServiceMock = self::createStub(SettingServiceInterface::class); $service = new SettingService($innerServiceMock, $traceableEventDispatcher); $service->deleteSetting(...$parameters); @@ -162,10 +162,10 @@ public function testDeleteSettingStopPropagationInBeforeEvents(): void ); $parameters = [ - $this->createMock(Setting::class), + self::createStub(Setting::class), ]; - $innerServiceMock = $this->createMock(SettingServiceInterface::class); + $innerServiceMock = self::createStub(SettingServiceInterface::class); $traceableEventDispatcher->addListener( BeforeDeleteSettingEvent::class, @@ -206,7 +206,7 @@ public function testCreateSettingEvents(): void BeforeCreateSettingEvent::class, CreateSettingEvent::class ); - $setting = $this->createMock(Setting::class); + $setting = self::createStub(Setting::class); $result = $this->createSetting($setting, $traceableEventDispatcher); @@ -231,8 +231,8 @@ public function testReturnCreateSettingResultInBeforeEvents(): void BeforeCreateSettingEvent::class, CreateSettingEvent::class ); - $eventSetting = $this->createMock(Setting::class); - $setting = $this->createMock(Setting::class); + $eventSetting = self::createStub(Setting::class); + $setting = self::createStub(Setting::class); $traceableEventDispatcher->addListener( BeforeCreateSettingEvent::class, static function (BeforeCreateSettingEvent $event) use ($eventSetting) { @@ -265,8 +265,8 @@ public function testCreateSettingStopPropagationInBeforeEvents(): void BeforeCreateSettingEvent::class, CreateSettingEvent::class ); - $eventSetting = $this->createMock(Setting::class); - $setting = $this->createMock(Setting::class); + $eventSetting = self::createStub(Setting::class); + $setting = self::createStub(Setting::class); $traceableEventDispatcher->addListener( BeforeCreateSettingEvent::class, static function (BeforeCreateSettingEvent $event) use ($eventSetting) { @@ -306,7 +306,7 @@ private function createSetting( TraceableEventDispatcher $traceableEventDispatcher ): Setting { $parameters = [ - $this->createMock(SettingCreateStruct::class), + self::createStub(SettingCreateStruct::class), ]; $innerServiceMock = $this->createMock(SettingServiceInterface::class); $innerServiceMock->method('createSetting')->willReturn($setting); @@ -320,8 +320,8 @@ private function updateSetting( TraceableEventDispatcher $traceableEventDispatcher ): Setting { $parameters = [ - $this->createMock(Setting::class), - $this->createMock(SettingUpdateStruct::class), + self::createStub(Setting::class), + self::createStub(SettingUpdateStruct::class), ]; $innerServiceMock = $this->createMock(SettingServiceInterface::class); $innerServiceMock->method('updateSetting')->willReturn($updatedSetting); diff --git a/tests/lib/Event/TrashServiceTest.php b/tests/lib/Event/TrashServiceTest.php index c4e2580c53..056924f816 100644 --- a/tests/lib/Event/TrashServiceTest.php +++ b/tests/lib/Event/TrashServiceTest.php @@ -24,7 +24,7 @@ class TrashServiceTest extends AbstractServiceTestCase { - public function testEmptyTrashEvents() + public function testEmptyTrashEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeEmptyTrashEvent::class, @@ -34,7 +34,7 @@ public function testEmptyTrashEvents() $parameters = [ ]; - $resultList = $this->createMock(TrashItemDeleteResultList::class); + $resultList = self::createStub(TrashItemDeleteResultList::class); $innerServiceMock = $this->createMock(TrashServiceInterface::class); $innerServiceMock->method('emptyTrash')->willReturn($resultList); @@ -51,7 +51,7 @@ public function testEmptyTrashEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnEmptyTrashResultInBeforeEvents() + public function testReturnEmptyTrashResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeEmptyTrashEvent::class, @@ -61,8 +61,8 @@ public function testReturnEmptyTrashResultInBeforeEvents() $parameters = [ ]; - $resultList = $this->createMock(TrashItemDeleteResultList::class); - $eventResultList = $this->createMock(TrashItemDeleteResultList::class); + $resultList = self::createStub(TrashItemDeleteResultList::class); + $eventResultList = self::createStub(TrashItemDeleteResultList::class); $innerServiceMock = $this->createMock(TrashServiceInterface::class); $innerServiceMock->method('emptyTrash')->willReturn($resultList); @@ -84,7 +84,7 @@ public function testReturnEmptyTrashResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testEmptyTrashStopPropagationInBeforeEvents() + public function testEmptyTrashStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeEmptyTrashEvent::class, @@ -94,8 +94,8 @@ public function testEmptyTrashStopPropagationInBeforeEvents() $parameters = [ ]; - $resultList = $this->createMock(TrashItemDeleteResultList::class); - $eventResultList = $this->createMock(TrashItemDeleteResultList::class); + $resultList = self::createStub(TrashItemDeleteResultList::class); + $eventResultList = self::createStub(TrashItemDeleteResultList::class); $innerServiceMock = $this->createMock(TrashServiceInterface::class); $innerServiceMock->method('emptyTrash')->willReturn($resultList); @@ -120,7 +120,7 @@ public function testEmptyTrashStopPropagationInBeforeEvents() ]); } - public function testTrashEvents() + public function testTrashEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeTrashEvent::class, @@ -128,10 +128,10 @@ public function testTrashEvents() ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), ]; - $trashItem = $this->createMock(TrashItem::class); + $trashItem = self::createStub(TrashItem::class); $innerServiceMock = $this->createMock(TrashServiceInterface::class); $innerServiceMock->method('trash')->willReturn($trashItem); @@ -148,7 +148,7 @@ public function testTrashEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnTrashResultInBeforeEvents() + public function testReturnTrashResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeTrashEvent::class, @@ -156,11 +156,11 @@ public function testReturnTrashResultInBeforeEvents() ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), ]; - $trashItem = $this->createMock(TrashItem::class); - $eventTrashItem = $this->createMock(TrashItem::class); + $trashItem = self::createStub(TrashItem::class); + $eventTrashItem = self::createStub(TrashItem::class); $innerServiceMock = $this->createMock(TrashServiceInterface::class); $innerServiceMock->method('trash')->willReturn($trashItem); @@ -182,7 +182,7 @@ public function testReturnTrashResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testTrashStopPropagationInBeforeEvents() + public function testTrashStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeTrashEvent::class, @@ -190,11 +190,11 @@ public function testTrashStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), ]; - $trashItem = $this->createMock(TrashItem::class); - $eventTrashItem = $this->createMock(TrashItem::class); + $trashItem = self::createStub(TrashItem::class); + $eventTrashItem = self::createStub(TrashItem::class); $innerServiceMock = $this->createMock(TrashServiceInterface::class); $innerServiceMock->method('trash')->willReturn($trashItem); @@ -227,7 +227,7 @@ public function testTrashStopPropagationInBeforeEventsSetsNullResult(): void ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), ]; $innerServiceMock = $this->createMock(TrashServiceInterface::class); @@ -254,7 +254,7 @@ public function testTrashStopPropagationInBeforeEventsSetsNullResult(): void ]); } - public function testRecoverEvents() + public function testRecoverEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRecoverEvent::class, @@ -262,11 +262,11 @@ public function testRecoverEvents() ); $parameters = [ - $this->createMock(TrashItem::class), - $this->createMock(Location::class), + self::createStub(TrashItem::class), + self::createStub(Location::class), ]; - $location = $this->createMock(Location::class); + $location = self::createStub(Location::class); $innerServiceMock = $this->createMock(TrashServiceInterface::class); $innerServiceMock->method('recover')->willReturn($location); @@ -283,7 +283,7 @@ public function testRecoverEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnRecoverResultInBeforeEvents() + public function testReturnRecoverResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRecoverEvent::class, @@ -291,12 +291,12 @@ public function testReturnRecoverResultInBeforeEvents() ); $parameters = [ - $this->createMock(TrashItem::class), - $this->createMock(Location::class), + self::createStub(TrashItem::class), + self::createStub(Location::class), ]; - $location = $this->createMock(Location::class); - $eventLocation = $this->createMock(Location::class); + $location = self::createStub(Location::class); + $eventLocation = self::createStub(Location::class); $innerServiceMock = $this->createMock(TrashServiceInterface::class); $innerServiceMock->method('recover')->willReturn($location); @@ -318,7 +318,7 @@ public function testReturnRecoverResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testRecoverStopPropagationInBeforeEvents() + public function testRecoverStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRecoverEvent::class, @@ -326,12 +326,12 @@ public function testRecoverStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(TrashItem::class), - $this->createMock(Location::class), + self::createStub(TrashItem::class), + self::createStub(Location::class), ]; - $location = $this->createMock(Location::class); - $eventLocation = $this->createMock(Location::class); + $location = self::createStub(Location::class); + $eventLocation = self::createStub(Location::class); $innerServiceMock = $this->createMock(TrashServiceInterface::class); $innerServiceMock->method('recover')->willReturn($location); @@ -356,7 +356,7 @@ public function testRecoverStopPropagationInBeforeEvents() ]); } - public function testDeleteTrashItemEvents() + public function testDeleteTrashItemEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteTrashItemEvent::class, @@ -364,10 +364,10 @@ public function testDeleteTrashItemEvents() ); $parameters = [ - $this->createMock(TrashItem::class), + self::createStub(TrashItem::class), ]; - $result = $this->createMock(TrashItemDeleteResult::class); + $result = self::createStub(TrashItemDeleteResult::class); $innerServiceMock = $this->createMock(TrashServiceInterface::class); $innerServiceMock->method('deleteTrashItem')->willReturn($result); @@ -384,7 +384,7 @@ public function testDeleteTrashItemEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnDeleteTrashItemResultInBeforeEvents() + public function testReturnDeleteTrashItemResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteTrashItemEvent::class, @@ -392,11 +392,11 @@ public function testReturnDeleteTrashItemResultInBeforeEvents() ); $parameters = [ - $this->createMock(TrashItem::class), + self::createStub(TrashItem::class), ]; - $result = $this->createMock(TrashItemDeleteResult::class); - $eventResult = $this->createMock(TrashItemDeleteResult::class); + $result = self::createStub(TrashItemDeleteResult::class); + $eventResult = self::createStub(TrashItemDeleteResult::class); $innerServiceMock = $this->createMock(TrashServiceInterface::class); $innerServiceMock->method('deleteTrashItem')->willReturn($result); @@ -418,7 +418,7 @@ public function testReturnDeleteTrashItemResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testDeleteTrashItemStopPropagationInBeforeEvents() + public function testDeleteTrashItemStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteTrashItemEvent::class, @@ -426,11 +426,11 @@ public function testDeleteTrashItemStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(TrashItem::class), + self::createStub(TrashItem::class), ]; - $result = $this->createMock(TrashItemDeleteResult::class); - $eventResult = $this->createMock(TrashItemDeleteResult::class); + $result = self::createStub(TrashItemDeleteResult::class); + $eventResult = self::createStub(TrashItemDeleteResult::class); $innerServiceMock = $this->createMock(TrashServiceInterface::class); $innerServiceMock->method('deleteTrashItem')->willReturn($result); diff --git a/tests/lib/Event/URLAliasServiceTest.php b/tests/lib/Event/URLAliasServiceTest.php index 10b916c0cb..725611a1dc 100644 --- a/tests/lib/Event/URLAliasServiceTest.php +++ b/tests/lib/Event/URLAliasServiceTest.php @@ -22,7 +22,7 @@ class URLAliasServiceTest extends AbstractServiceTestCase { - public function testCreateGlobalUrlAliasEvents() + public function testCreateGlobalUrlAliasEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateGlobalUrlAliasEvent::class, @@ -37,7 +37,7 @@ public function testCreateGlobalUrlAliasEvents() 'random_value_5cff79c31834c3.69513526', ]; - $urlAlias = $this->createMock(URLAlias::class); + $urlAlias = self::createStub(URLAlias::class); $innerServiceMock = $this->createMock(URLAliasServiceInterface::class); $innerServiceMock->method('createGlobalUrlAlias')->willReturn($urlAlias); @@ -54,7 +54,7 @@ public function testCreateGlobalUrlAliasEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnCreateGlobalUrlAliasResultInBeforeEvents() + public function testReturnCreateGlobalUrlAliasResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateGlobalUrlAliasEvent::class, @@ -69,8 +69,8 @@ public function testReturnCreateGlobalUrlAliasResultInBeforeEvents() 'random_value_5cff79c31839d9.22502123', ]; - $urlAlias = $this->createMock(URLAlias::class); - $eventUrlAlias = $this->createMock(URLAlias::class); + $urlAlias = self::createStub(URLAlias::class); + $eventUrlAlias = self::createStub(URLAlias::class); $innerServiceMock = $this->createMock(URLAliasServiceInterface::class); $innerServiceMock->method('createGlobalUrlAlias')->willReturn($urlAlias); @@ -92,7 +92,7 @@ public function testReturnCreateGlobalUrlAliasResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCreateGlobalUrlAliasStopPropagationInBeforeEvents() + public function testCreateGlobalUrlAliasStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateGlobalUrlAliasEvent::class, @@ -107,8 +107,8 @@ public function testCreateGlobalUrlAliasStopPropagationInBeforeEvents() 'random_value_5cff79c3183a85.16422549', ]; - $urlAlias = $this->createMock(URLAlias::class); - $eventUrlAlias = $this->createMock(URLAlias::class); + $urlAlias = self::createStub(URLAlias::class); + $eventUrlAlias = self::createStub(URLAlias::class); $innerServiceMock = $this->createMock(URLAliasServiceInterface::class); $innerServiceMock->method('createGlobalUrlAlias')->willReturn($urlAlias); @@ -133,7 +133,7 @@ public function testCreateGlobalUrlAliasStopPropagationInBeforeEvents() ]); } - public function testRefreshSystemUrlAliasesForLocationEvents() + public function testRefreshSystemUrlAliasesForLocationEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRefreshSystemUrlAliasesForLocationEvent::class, @@ -141,10 +141,10 @@ public function testRefreshSystemUrlAliasesForLocationEvents() ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), ]; - $innerServiceMock = $this->createMock(URLAliasServiceInterface::class); + $innerServiceMock = self::createStub(URLAliasServiceInterface::class); $service = new URLAliasService($innerServiceMock, $traceableEventDispatcher); $service->refreshSystemUrlAliasesForLocation(...$parameters); @@ -158,7 +158,7 @@ public function testRefreshSystemUrlAliasesForLocationEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testRefreshSystemUrlAliasesForLocationStopPropagationInBeforeEvents() + public function testRefreshSystemUrlAliasesForLocationStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRefreshSystemUrlAliasesForLocationEvent::class, @@ -166,10 +166,10 @@ public function testRefreshSystemUrlAliasesForLocationStopPropagationInBeforeEve ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), ]; - $innerServiceMock = $this->createMock(URLAliasServiceInterface::class); + $innerServiceMock = self::createStub(URLAliasServiceInterface::class); $traceableEventDispatcher->addListener(BeforeRefreshSystemUrlAliasesForLocationEvent::class, static function (BeforeRefreshSystemUrlAliasesForLocationEvent $event) { $event->stopPropagation(); @@ -190,7 +190,7 @@ public function testRefreshSystemUrlAliasesForLocationStopPropagationInBeforeEve ]); } - public function testCreateUrlAliasEvents() + public function testCreateUrlAliasEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateUrlAliasEvent::class, @@ -198,14 +198,14 @@ public function testCreateUrlAliasEvents() ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), 'random_value_5cff79c3184f05.03459159', 'random_value_5cff79c3184f14.18292216', 'random_value_5cff79c3184f24.01158164', 'random_value_5cff79c3184f32.03833593', ]; - $urlAlias = $this->createMock(URLAlias::class); + $urlAlias = self::createStub(URLAlias::class); $innerServiceMock = $this->createMock(URLAliasServiceInterface::class); $innerServiceMock->method('createUrlAlias')->willReturn($urlAlias); @@ -222,7 +222,7 @@ public function testCreateUrlAliasEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnCreateUrlAliasResultInBeforeEvents() + public function testReturnCreateUrlAliasResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateUrlAliasEvent::class, @@ -230,15 +230,15 @@ public function testReturnCreateUrlAliasResultInBeforeEvents() ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), 'random_value_5cff79c3184fd7.07408772', 'random_value_5cff79c3184fe2.98616568', 'random_value_5cff79c3184ff0.62652505', 'random_value_5cff79c3185003.87499400', ]; - $urlAlias = $this->createMock(URLAlias::class); - $eventUrlAlias = $this->createMock(URLAlias::class); + $urlAlias = self::createStub(URLAlias::class); + $eventUrlAlias = self::createStub(URLAlias::class); $innerServiceMock = $this->createMock(URLAliasServiceInterface::class); $innerServiceMock->method('createUrlAlias')->willReturn($urlAlias); @@ -260,7 +260,7 @@ public function testReturnCreateUrlAliasResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCreateUrlAliasStopPropagationInBeforeEvents() + public function testCreateUrlAliasStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateUrlAliasEvent::class, @@ -268,15 +268,15 @@ public function testCreateUrlAliasStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), 'random_value_5cff79c3185072.24449261', 'random_value_5cff79c3185080.62311461', 'random_value_5cff79c3185095.31877612', 'random_value_5cff79c31850a4.20254218', ]; - $urlAlias = $this->createMock(URLAlias::class); - $eventUrlAlias = $this->createMock(URLAlias::class); + $urlAlias = self::createStub(URLAlias::class); + $eventUrlAlias = self::createStub(URLAlias::class); $innerServiceMock = $this->createMock(URLAliasServiceInterface::class); $innerServiceMock->method('createUrlAlias')->willReturn($urlAlias); @@ -301,7 +301,7 @@ public function testCreateUrlAliasStopPropagationInBeforeEvents() ]); } - public function testRemoveAliasesEvents() + public function testRemoveAliasesEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRemoveAliasesEvent::class, @@ -312,7 +312,7 @@ public function testRemoveAliasesEvents() [], ]; - $innerServiceMock = $this->createMock(URLAliasServiceInterface::class); + $innerServiceMock = self::createStub(URLAliasServiceInterface::class); $service = new URLAliasService($innerServiceMock, $traceableEventDispatcher); $service->removeAliases(...$parameters); @@ -326,7 +326,7 @@ public function testRemoveAliasesEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testRemoveAliasesStopPropagationInBeforeEvents() + public function testRemoveAliasesStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRemoveAliasesEvent::class, @@ -337,7 +337,7 @@ public function testRemoveAliasesStopPropagationInBeforeEvents() [], ]; - $innerServiceMock = $this->createMock(URLAliasServiceInterface::class); + $innerServiceMock = self::createStub(URLAliasServiceInterface::class); $traceableEventDispatcher->addListener(BeforeRemoveAliasesEvent::class, static function (BeforeRemoveAliasesEvent $event) { $event->stopPropagation(); diff --git a/tests/lib/Event/URLServiceTest.php b/tests/lib/Event/URLServiceTest.php index 8aea966dcc..33c84641fd 100644 --- a/tests/lib/Event/URLServiceTest.php +++ b/tests/lib/Event/URLServiceTest.php @@ -16,7 +16,7 @@ class URLServiceTest extends AbstractServiceTestCase { - public function testUpdateUrlEvents() + public function testUpdateUrlEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateUrlEvent::class, @@ -24,11 +24,11 @@ public function testUpdateUrlEvents() ); $parameters = [ - $this->createMock(URL::class), - $this->createMock(URLUpdateStruct::class), + self::createStub(URL::class), + self::createStub(URLUpdateStruct::class), ]; - $updatedUrl = $this->createMock(URL::class); + $updatedUrl = self::createStub(URL::class); $innerServiceMock = $this->createMock(URLServiceInterface::class); $innerServiceMock->method('updateUrl')->willReturn($updatedUrl); @@ -45,7 +45,7 @@ public function testUpdateUrlEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnUpdateUrlResultInBeforeEvents() + public function testReturnUpdateUrlResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateUrlEvent::class, @@ -53,12 +53,12 @@ public function testReturnUpdateUrlResultInBeforeEvents() ); $parameters = [ - $this->createMock(URL::class), - $this->createMock(URLUpdateStruct::class), + self::createStub(URL::class), + self::createStub(URLUpdateStruct::class), ]; - $updatedUrl = $this->createMock(URL::class); - $eventUpdatedUrl = $this->createMock(URL::class); + $updatedUrl = self::createStub(URL::class); + $eventUpdatedUrl = self::createStub(URL::class); $innerServiceMock = $this->createMock(URLServiceInterface::class); $innerServiceMock->method('updateUrl')->willReturn($updatedUrl); @@ -80,7 +80,7 @@ public function testReturnUpdateUrlResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testUpdateUrlStopPropagationInBeforeEvents() + public function testUpdateUrlStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateUrlEvent::class, @@ -88,12 +88,12 @@ public function testUpdateUrlStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(URL::class), - $this->createMock(URLUpdateStruct::class), + self::createStub(URL::class), + self::createStub(URLUpdateStruct::class), ]; - $updatedUrl = $this->createMock(URL::class); - $eventUpdatedUrl = $this->createMock(URL::class); + $updatedUrl = self::createStub(URL::class); + $eventUpdatedUrl = self::createStub(URL::class); $innerServiceMock = $this->createMock(URLServiceInterface::class); $innerServiceMock->method('updateUrl')->willReturn($updatedUrl); diff --git a/tests/lib/Event/URLWildcardServiceTest.php b/tests/lib/Event/URLWildcardServiceTest.php index 5ad3ca9023..593bba2ba3 100644 --- a/tests/lib/Event/URLWildcardServiceTest.php +++ b/tests/lib/Event/URLWildcardServiceTest.php @@ -26,7 +26,7 @@ class URLWildcardServiceTest extends AbstractServiceTestCase /** * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ - public function testRemoveEvents() + public function testRemoveEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRemoveEvent::class, @@ -34,10 +34,10 @@ public function testRemoveEvents() ); $parameters = [ - $this->createMock(URLWildcard::class), + self::createStub(URLWildcard::class), ]; - $innerServiceMock = $this->createMock(URLWildcardServiceInterface::class); + $innerServiceMock = self::createStub(URLWildcardServiceInterface::class); $service = new URLWildcardService($innerServiceMock, $traceableEventDispatcher); $service->remove(...$parameters); @@ -54,7 +54,7 @@ public function testRemoveEvents() /** * @throws \Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException */ - public function testRemoveStopPropagationInBeforeEvents() + public function testRemoveStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeRemoveEvent::class, @@ -62,10 +62,10 @@ public function testRemoveStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(URLWildcard::class), + self::createStub(URLWildcard::class), ]; - $innerServiceMock = $this->createMock(URLWildcardServiceInterface::class); + $innerServiceMock = self::createStub(URLWildcardServiceInterface::class); $traceableEventDispatcher->addListener(BeforeRemoveEvent::class, static function (BeforeRemoveEvent $event) { $event->stopPropagation(); @@ -99,11 +99,11 @@ public function testUpdateEvents(): void UpdateEvent::class ); - $innerServiceMock = $this->createMock(URLWildcardServiceInterface::class); + $innerServiceMock = self::createStub(URLWildcardServiceInterface::class); $service = new URLWildcardService($innerServiceMock, $traceableEventDispatcher); $service->update( - $this->createMock(URLWildcard::class), + self::createStub(URLWildcard::class), new URLWildcardUpdateStruct() ); @@ -126,7 +126,7 @@ public function testUpdateStopPropagationInBeforeEvents(): void UpdateEvent::class ); - $innerServiceMock = $this->createMock(URLWildcardServiceInterface::class); + $innerServiceMock = self::createStub(URLWildcardServiceInterface::class); $traceableEventDispatcher->addListener( BeforeUpdateEvent::class, @@ -138,7 +138,7 @@ static function (BeforeUpdateEvent $event) { $service = new URLWildcardService($innerServiceMock, $traceableEventDispatcher); $service->update( - $this->createMock(URLWildcard::class), + self::createStub(URLWildcard::class), new URLWildcardUpdateStruct() ); @@ -159,7 +159,7 @@ static function (BeforeUpdateEvent $event) { ]); } - public function testCreateEvents() + public function testCreateEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateEvent::class, @@ -172,7 +172,7 @@ public function testCreateEvents() 'random_value_5cff79c316c237.08397355', ]; - $urlWildcard = $this->createMock(URLWildcard::class); + $urlWildcard = self::createStub(URLWildcard::class); $innerServiceMock = $this->createMock(URLWildcardServiceInterface::class); $innerServiceMock->method('create')->willReturn($urlWildcard); @@ -189,7 +189,7 @@ public function testCreateEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnCreateResultInBeforeEvents() + public function testReturnCreateResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateEvent::class, @@ -202,8 +202,8 @@ public function testReturnCreateResultInBeforeEvents() 'random_value_5cff79c316c2f8.59874187', ]; - $urlWildcard = $this->createMock(URLWildcard::class); - $eventUrlWildcard = $this->createMock(URLWildcard::class); + $urlWildcard = self::createStub(URLWildcard::class); + $eventUrlWildcard = self::createStub(URLWildcard::class); $innerServiceMock = $this->createMock(URLWildcardServiceInterface::class); $innerServiceMock->method('create')->willReturn($urlWildcard); @@ -225,7 +225,7 @@ public function testReturnCreateResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCreateStopPropagationInBeforeEvents() + public function testCreateStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateEvent::class, @@ -238,8 +238,8 @@ public function testCreateStopPropagationInBeforeEvents() 'random_value_5cff79c316c374.82657815', ]; - $urlWildcard = $this->createMock(URLWildcard::class); - $eventUrlWildcard = $this->createMock(URLWildcard::class); + $urlWildcard = self::createStub(URLWildcard::class); + $eventUrlWildcard = self::createStub(URLWildcard::class); $innerServiceMock = $this->createMock(URLWildcardServiceInterface::class); $innerServiceMock->method('create')->willReturn($urlWildcard); @@ -264,7 +264,7 @@ public function testCreateStopPropagationInBeforeEvents() ]); } - public function testTranslateEvents() + public function testTranslateEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeTranslateEvent::class, @@ -275,7 +275,7 @@ public function testTranslateEvents() 'random_value_5cff79c316cfa7.72466150', ]; - $result = $this->createMock(URLWildcardTranslationResult::class); + $result = self::createStub(URLWildcardTranslationResult::class); $innerServiceMock = $this->createMock(URLWildcardServiceInterface::class); $innerServiceMock->method('translate')->willReturn($result); @@ -292,7 +292,7 @@ public function testTranslateEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnTranslateResultInBeforeEvents() + public function testReturnTranslateResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeTranslateEvent::class, @@ -303,8 +303,8 @@ public function testReturnTranslateResultInBeforeEvents() 'random_value_5cff79c316d370.25863709', ]; - $result = $this->createMock(URLWildcardTranslationResult::class); - $eventResult = $this->createMock(URLWildcardTranslationResult::class); + $result = self::createStub(URLWildcardTranslationResult::class); + $eventResult = self::createStub(URLWildcardTranslationResult::class); $innerServiceMock = $this->createMock(URLWildcardServiceInterface::class); $innerServiceMock->method('translate')->willReturn($result); @@ -326,7 +326,7 @@ public function testReturnTranslateResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testTranslateStopPropagationInBeforeEvents() + public function testTranslateStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeTranslateEvent::class, @@ -337,8 +337,8 @@ public function testTranslateStopPropagationInBeforeEvents() 'random_value_5cff79c316d3f9.73226122', ]; - $result = $this->createMock(URLWildcardTranslationResult::class); - $eventResult = $this->createMock(URLWildcardTranslationResult::class); + $result = self::createStub(URLWildcardTranslationResult::class); + $eventResult = self::createStub(URLWildcardTranslationResult::class); $innerServiceMock = $this->createMock(URLWildcardServiceInterface::class); $innerServiceMock->method('translate')->willReturn($result); diff --git a/tests/lib/Event/UserPreferenceServiceTest.php b/tests/lib/Event/UserPreferenceServiceTest.php index f0ea11b649..9cdc3a72b1 100644 --- a/tests/lib/Event/UserPreferenceServiceTest.php +++ b/tests/lib/Event/UserPreferenceServiceTest.php @@ -14,7 +14,7 @@ class UserPreferenceServiceTest extends AbstractServiceTestCase { - public function testSetUserPreferenceEvents() + public function testSetUserPreferenceEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeSetUserPreferenceEvent::class, @@ -25,7 +25,7 @@ public function testSetUserPreferenceEvents() [], ]; - $innerServiceMock = $this->createMock(UserPreferenceServiceInterface::class); + $innerServiceMock = self::createStub(UserPreferenceServiceInterface::class); $service = new UserPreferenceService($innerServiceMock, $traceableEventDispatcher); $service->setUserPreference(...$parameters); @@ -39,7 +39,7 @@ public function testSetUserPreferenceEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testSetUserPreferenceStopPropagationInBeforeEvents() + public function testSetUserPreferenceStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeSetUserPreferenceEvent::class, @@ -50,7 +50,7 @@ public function testSetUserPreferenceStopPropagationInBeforeEvents() [], ]; - $innerServiceMock = $this->createMock(UserPreferenceServiceInterface::class); + $innerServiceMock = self::createStub(UserPreferenceServiceInterface::class); $traceableEventDispatcher->addListener(BeforeSetUserPreferenceEvent::class, static function (BeforeSetUserPreferenceEvent $event) { $event->stopPropagation(); diff --git a/tests/lib/Event/UserServiceTest.php b/tests/lib/Event/UserServiceTest.php index 50605257d4..3a173108b9 100644 --- a/tests/lib/Event/UserServiceTest.php +++ b/tests/lib/Event/UserServiceTest.php @@ -39,7 +39,7 @@ class UserServiceTest extends AbstractServiceTestCase { - public function testUpdateUserGroupEvents() + public function testUpdateUserGroupEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateUserGroupEvent::class, @@ -47,11 +47,11 @@ public function testUpdateUserGroupEvents() ); $parameters = [ - $this->createMock(UserGroup::class), - $this->createMock(UserGroupUpdateStruct::class), + self::createStub(UserGroup::class), + self::createStub(UserGroupUpdateStruct::class), ]; - $updatedUserGroup = $this->createMock(UserGroup::class); + $updatedUserGroup = self::createStub(UserGroup::class); $innerServiceMock = $this->createMock(UserServiceInterface::class); $innerServiceMock->method('updateUserGroup')->willReturn($updatedUserGroup); @@ -68,7 +68,7 @@ public function testUpdateUserGroupEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnUpdateUserGroupResultInBeforeEvents() + public function testReturnUpdateUserGroupResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateUserGroupEvent::class, @@ -76,12 +76,12 @@ public function testReturnUpdateUserGroupResultInBeforeEvents() ); $parameters = [ - $this->createMock(UserGroup::class), - $this->createMock(UserGroupUpdateStruct::class), + self::createStub(UserGroup::class), + self::createStub(UserGroupUpdateStruct::class), ]; - $updatedUserGroup = $this->createMock(UserGroup::class); - $eventUpdatedUserGroup = $this->createMock(UserGroup::class); + $updatedUserGroup = self::createStub(UserGroup::class); + $eventUpdatedUserGroup = self::createStub(UserGroup::class); $innerServiceMock = $this->createMock(UserServiceInterface::class); $innerServiceMock->method('updateUserGroup')->willReturn($updatedUserGroup); @@ -103,7 +103,7 @@ public function testReturnUpdateUserGroupResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testUpdateUserGroupStopPropagationInBeforeEvents() + public function testUpdateUserGroupStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateUserGroupEvent::class, @@ -111,12 +111,12 @@ public function testUpdateUserGroupStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(UserGroup::class), - $this->createMock(UserGroupUpdateStruct::class), + self::createStub(UserGroup::class), + self::createStub(UserGroupUpdateStruct::class), ]; - $updatedUserGroup = $this->createMock(UserGroup::class); - $eventUpdatedUserGroup = $this->createMock(UserGroup::class); + $updatedUserGroup = self::createStub(UserGroup::class); + $eventUpdatedUserGroup = self::createStub(UserGroup::class); $innerServiceMock = $this->createMock(UserServiceInterface::class); $innerServiceMock->method('updateUserGroup')->willReturn($updatedUserGroup); @@ -141,7 +141,7 @@ public function testUpdateUserGroupStopPropagationInBeforeEvents() ]); } - public function testUpdateUserEvents() + public function testUpdateUserEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateUserEvent::class, @@ -149,11 +149,11 @@ public function testUpdateUserEvents() ); $parameters = [ - $this->createMock(User::class), - $this->createMock(UserUpdateStruct::class), + self::createStub(User::class), + self::createStub(UserUpdateStruct::class), ]; - $updatedUser = $this->createMock(User::class); + $updatedUser = self::createStub(User::class); $innerServiceMock = $this->createMock(UserServiceInterface::class); $innerServiceMock->method('updateUser')->willReturn($updatedUser); @@ -170,7 +170,7 @@ public function testUpdateUserEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnUpdateUserResultInBeforeEvents() + public function testReturnUpdateUserResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateUserEvent::class, @@ -178,12 +178,12 @@ public function testReturnUpdateUserResultInBeforeEvents() ); $parameters = [ - $this->createMock(User::class), - $this->createMock(UserUpdateStruct::class), + self::createStub(User::class), + self::createStub(UserUpdateStruct::class), ]; - $updatedUser = $this->createMock(User::class); - $eventUpdatedUser = $this->createMock(User::class); + $updatedUser = self::createStub(User::class); + $eventUpdatedUser = self::createStub(User::class); $innerServiceMock = $this->createMock(UserServiceInterface::class); $innerServiceMock->method('updateUser')->willReturn($updatedUser); @@ -205,7 +205,7 @@ public function testReturnUpdateUserResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testUpdateUserStopPropagationInBeforeEvents() + public function testUpdateUserStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateUserEvent::class, @@ -213,12 +213,12 @@ public function testUpdateUserStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(User::class), - $this->createMock(UserUpdateStruct::class), + self::createStub(User::class), + self::createStub(UserUpdateStruct::class), ]; - $updatedUser = $this->createMock(User::class); - $eventUpdatedUser = $this->createMock(User::class); + $updatedUser = self::createStub(User::class); + $eventUpdatedUser = self::createStub(User::class); $innerServiceMock = $this->createMock(UserServiceInterface::class); $innerServiceMock->method('updateUser')->willReturn($updatedUser); @@ -243,7 +243,7 @@ public function testUpdateUserStopPropagationInBeforeEvents() ]); } - public function testUnAssignUserFromUserGroupEvents() + public function testUnAssignUserFromUserGroupEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUnAssignUserFromUserGroupEvent::class, @@ -251,11 +251,11 @@ public function testUnAssignUserFromUserGroupEvents() ); $parameters = [ - $this->createMock(User::class), - $this->createMock(UserGroup::class), + self::createStub(User::class), + self::createStub(UserGroup::class), ]; - $innerServiceMock = $this->createMock(UserServiceInterface::class); + $innerServiceMock = self::createStub(UserServiceInterface::class); $service = new UserService($innerServiceMock, $traceableEventDispatcher); $service->unAssignUserFromUserGroup(...$parameters); @@ -269,7 +269,7 @@ public function testUnAssignUserFromUserGroupEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testUnAssignUserFromUserGroupStopPropagationInBeforeEvents() + public function testUnAssignUserFromUserGroupStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUnAssignUserFromUserGroupEvent::class, @@ -277,11 +277,11 @@ public function testUnAssignUserFromUserGroupStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(User::class), - $this->createMock(UserGroup::class), + self::createStub(User::class), + self::createStub(UserGroup::class), ]; - $innerServiceMock = $this->createMock(UserServiceInterface::class); + $innerServiceMock = self::createStub(UserServiceInterface::class); $traceableEventDispatcher->addListener(BeforeUnAssignUserFromUserGroupEvent::class, static function (BeforeUnAssignUserFromUserGroupEvent $event) { $event->stopPropagation(); @@ -302,7 +302,7 @@ public function testUnAssignUserFromUserGroupStopPropagationInBeforeEvents() ]); } - public function testDeleteUserGroupEvents() + public function testDeleteUserGroupEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteUserGroupEvent::class, @@ -310,7 +310,7 @@ public function testDeleteUserGroupEvents() ); $parameters = [ - $this->createMock(UserGroup::class), + self::createStub(UserGroup::class), ]; $locations = []; @@ -330,7 +330,7 @@ public function testDeleteUserGroupEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnDeleteUserGroupResultInBeforeEvents() + public function testReturnDeleteUserGroupResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteUserGroupEvent::class, @@ -338,7 +338,7 @@ public function testReturnDeleteUserGroupResultInBeforeEvents() ); $parameters = [ - $this->createMock(UserGroup::class), + self::createStub(UserGroup::class), ]; $locations = []; @@ -364,7 +364,7 @@ public function testReturnDeleteUserGroupResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testDeleteUserGroupStopPropagationInBeforeEvents() + public function testDeleteUserGroupStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteUserGroupEvent::class, @@ -372,7 +372,7 @@ public function testDeleteUserGroupStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(UserGroup::class), + self::createStub(UserGroup::class), ]; $locations = []; @@ -401,7 +401,7 @@ public function testDeleteUserGroupStopPropagationInBeforeEvents() ]); } - public function testAssignUserToUserGroupEvents() + public function testAssignUserToUserGroupEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeAssignUserToUserGroupEvent::class, @@ -409,11 +409,11 @@ public function testAssignUserToUserGroupEvents() ); $parameters = [ - $this->createMock(User::class), - $this->createMock(UserGroup::class), + self::createStub(User::class), + self::createStub(UserGroup::class), ]; - $innerServiceMock = $this->createMock(UserServiceInterface::class); + $innerServiceMock = self::createStub(UserServiceInterface::class); $service = new UserService($innerServiceMock, $traceableEventDispatcher); $service->assignUserToUserGroup(...$parameters); @@ -427,7 +427,7 @@ public function testAssignUserToUserGroupEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testAssignUserToUserGroupStopPropagationInBeforeEvents() + public function testAssignUserToUserGroupStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeAssignUserToUserGroupEvent::class, @@ -435,11 +435,11 @@ public function testAssignUserToUserGroupStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(User::class), - $this->createMock(UserGroup::class), + self::createStub(User::class), + self::createStub(UserGroup::class), ]; - $innerServiceMock = $this->createMock(UserServiceInterface::class); + $innerServiceMock = self::createStub(UserServiceInterface::class); $traceableEventDispatcher->addListener(BeforeAssignUserToUserGroupEvent::class, static function (BeforeAssignUserToUserGroupEvent $event) { $event->stopPropagation(); @@ -460,7 +460,7 @@ public function testAssignUserToUserGroupStopPropagationInBeforeEvents() ]); } - public function testDeleteUserEvents() + public function testDeleteUserEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteUserEvent::class, @@ -468,7 +468,7 @@ public function testDeleteUserEvents() ); $parameters = [ - $this->createMock(User::class), + self::createStub(User::class), ]; $locations = []; @@ -488,7 +488,7 @@ public function testDeleteUserEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnDeleteUserResultInBeforeEvents() + public function testReturnDeleteUserResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteUserEvent::class, @@ -496,7 +496,7 @@ public function testReturnDeleteUserResultInBeforeEvents() ); $parameters = [ - $this->createMock(User::class), + self::createStub(User::class), ]; $locations = []; @@ -522,7 +522,7 @@ public function testReturnDeleteUserResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testDeleteUserStopPropagationInBeforeEvents() + public function testDeleteUserStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeDeleteUserEvent::class, @@ -530,7 +530,7 @@ public function testDeleteUserStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(User::class), + self::createStub(User::class), ]; $locations = []; @@ -559,7 +559,7 @@ public function testDeleteUserStopPropagationInBeforeEvents() ]); } - public function testMoveUserGroupEvents() + public function testMoveUserGroupEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeMoveUserGroupEvent::class, @@ -567,11 +567,11 @@ public function testMoveUserGroupEvents() ); $parameters = [ - $this->createMock(UserGroup::class), - $this->createMock(UserGroup::class), + self::createStub(UserGroup::class), + self::createStub(UserGroup::class), ]; - $innerServiceMock = $this->createMock(UserServiceInterface::class); + $innerServiceMock = self::createStub(UserServiceInterface::class); $service = new UserService($innerServiceMock, $traceableEventDispatcher); $service->moveUserGroup(...$parameters); @@ -585,7 +585,7 @@ public function testMoveUserGroupEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testMoveUserGroupStopPropagationInBeforeEvents() + public function testMoveUserGroupStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeMoveUserGroupEvent::class, @@ -593,11 +593,11 @@ public function testMoveUserGroupStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(UserGroup::class), - $this->createMock(UserGroup::class), + self::createStub(UserGroup::class), + self::createStub(UserGroup::class), ]; - $innerServiceMock = $this->createMock(UserServiceInterface::class); + $innerServiceMock = self::createStub(UserServiceInterface::class); $traceableEventDispatcher->addListener(BeforeMoveUserGroupEvent::class, static function (BeforeMoveUserGroupEvent $event) { $event->stopPropagation(); @@ -618,7 +618,7 @@ public function testMoveUserGroupStopPropagationInBeforeEvents() ]); } - public function testCreateUserEvents() + public function testCreateUserEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateUserEvent::class, @@ -626,11 +626,11 @@ public function testCreateUserEvents() ); $parameters = [ - $this->createMock(UserCreateStruct::class), + self::createStub(UserCreateStruct::class), [], ]; - $user = $this->createMock(User::class); + $user = self::createStub(User::class); $innerServiceMock = $this->createMock(UserServiceInterface::class); $innerServiceMock->method('createUser')->willReturn($user); @@ -647,7 +647,7 @@ public function testCreateUserEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnCreateUserResultInBeforeEvents() + public function testReturnCreateUserResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateUserEvent::class, @@ -655,12 +655,12 @@ public function testReturnCreateUserResultInBeforeEvents() ); $parameters = [ - $this->createMock(UserCreateStruct::class), + self::createStub(UserCreateStruct::class), [], ]; - $user = $this->createMock(User::class); - $eventUser = $this->createMock(User::class); + $user = self::createStub(User::class); + $eventUser = self::createStub(User::class); $innerServiceMock = $this->createMock(UserServiceInterface::class); $innerServiceMock->method('createUser')->willReturn($user); @@ -682,7 +682,7 @@ public function testReturnCreateUserResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCreateUserStopPropagationInBeforeEvents() + public function testCreateUserStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateUserEvent::class, @@ -690,12 +690,12 @@ public function testCreateUserStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(UserCreateStruct::class), + self::createStub(UserCreateStruct::class), [], ]; - $user = $this->createMock(User::class); - $eventUser = $this->createMock(User::class); + $user = self::createStub(User::class); + $eventUser = self::createStub(User::class); $innerServiceMock = $this->createMock(UserServiceInterface::class); $innerServiceMock->method('createUser')->willReturn($user); @@ -720,7 +720,7 @@ public function testCreateUserStopPropagationInBeforeEvents() ]); } - public function testCreateUserGroupEvents() + public function testCreateUserGroupEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateUserGroupEvent::class, @@ -728,11 +728,11 @@ public function testCreateUserGroupEvents() ); $parameters = [ - $this->createMock(UserGroupCreateStruct::class), - $this->createMock(UserGroup::class), + self::createStub(UserGroupCreateStruct::class), + self::createStub(UserGroup::class), ]; - $userGroup = $this->createMock(UserGroup::class); + $userGroup = self::createStub(UserGroup::class); $innerServiceMock = $this->createMock(UserServiceInterface::class); $innerServiceMock->method('createUserGroup')->willReturn($userGroup); @@ -749,7 +749,7 @@ public function testCreateUserGroupEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnCreateUserGroupResultInBeforeEvents() + public function testReturnCreateUserGroupResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateUserGroupEvent::class, @@ -757,12 +757,12 @@ public function testReturnCreateUserGroupResultInBeforeEvents() ); $parameters = [ - $this->createMock(UserGroupCreateStruct::class), - $this->createMock(UserGroup::class), + self::createStub(UserGroupCreateStruct::class), + self::createStub(UserGroup::class), ]; - $userGroup = $this->createMock(UserGroup::class); - $eventUserGroup = $this->createMock(UserGroup::class); + $userGroup = self::createStub(UserGroup::class); + $eventUserGroup = self::createStub(UserGroup::class); $innerServiceMock = $this->createMock(UserServiceInterface::class); $innerServiceMock->method('createUserGroup')->willReturn($userGroup); @@ -784,7 +784,7 @@ public function testReturnCreateUserGroupResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testCreateUserGroupStopPropagationInBeforeEvents() + public function testCreateUserGroupStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeCreateUserGroupEvent::class, @@ -792,12 +792,12 @@ public function testCreateUserGroupStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(UserGroupCreateStruct::class), - $this->createMock(UserGroup::class), + self::createStub(UserGroupCreateStruct::class), + self::createStub(UserGroup::class), ]; - $userGroup = $this->createMock(UserGroup::class); - $eventUserGroup = $this->createMock(UserGroup::class); + $userGroup = self::createStub(UserGroup::class); + $eventUserGroup = self::createStub(UserGroup::class); $innerServiceMock = $this->createMock(UserServiceInterface::class); $innerServiceMock->method('createUserGroup')->willReturn($userGroup); @@ -822,7 +822,7 @@ public function testCreateUserGroupStopPropagationInBeforeEvents() ]); } - public function testUpdateUserTokenEvents() + public function testUpdateUserTokenEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateUserTokenEvent::class, @@ -830,11 +830,11 @@ public function testUpdateUserTokenEvents() ); $parameters = [ - $this->createMock(User::class), - $this->createMock(UserTokenUpdateStruct::class), + self::createStub(User::class), + self::createStub(UserTokenUpdateStruct::class), ]; - $updatedUser = $this->createMock(User::class); + $updatedUser = self::createStub(User::class); $innerServiceMock = $this->createMock(UserServiceInterface::class); $innerServiceMock->method('updateUserToken')->willReturn($updatedUser); @@ -851,7 +851,7 @@ public function testUpdateUserTokenEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testReturnUpdateUserTokenResultInBeforeEvents() + public function testReturnUpdateUserTokenResultInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateUserTokenEvent::class, @@ -859,12 +859,12 @@ public function testReturnUpdateUserTokenResultInBeforeEvents() ); $parameters = [ - $this->createMock(User::class), - $this->createMock(UserTokenUpdateStruct::class), + self::createStub(User::class), + self::createStub(UserTokenUpdateStruct::class), ]; - $updatedUser = $this->createMock(User::class); - $eventUpdatedUser = $this->createMock(User::class); + $updatedUser = self::createStub(User::class); + $eventUpdatedUser = self::createStub(User::class); $innerServiceMock = $this->createMock(UserServiceInterface::class); $innerServiceMock->method('updateUserToken')->willReturn($updatedUser); @@ -886,7 +886,7 @@ public function testReturnUpdateUserTokenResultInBeforeEvents() self::assertSame([], $traceableEventDispatcher->getNotCalledListeners()); } - public function testUpdateUserTokenStopPropagationInBeforeEvents() + public function testUpdateUserTokenStopPropagationInBeforeEvents(): void { $traceableEventDispatcher = $this->getEventDispatcher( BeforeUpdateUserTokenEvent::class, @@ -894,12 +894,12 @@ public function testUpdateUserTokenStopPropagationInBeforeEvents() ); $parameters = [ - $this->createMock(User::class), - $this->createMock(UserTokenUpdateStruct::class), + self::createStub(User::class), + self::createStub(UserTokenUpdateStruct::class), ]; - $updatedUser = $this->createMock(User::class); - $eventUpdatedUser = $this->createMock(User::class); + $updatedUser = self::createStub(User::class); + $eventUpdatedUser = self::createStub(User::class); $innerServiceMock = $this->createMock(UserServiceInterface::class); $innerServiceMock->method('updateUserToken')->willReturn($updatedUser); diff --git a/tests/lib/FieldType/APIFieldTypeTest.php b/tests/lib/FieldType/APIFieldTypeTest.php index 8f5fbd89cf..2924f3a710 100644 --- a/tests/lib/FieldType/APIFieldTypeTest.php +++ b/tests/lib/FieldType/APIFieldTypeTest.php @@ -29,7 +29,7 @@ protected function setUp(): void $this->fieldType = new FieldType($this->innerFieldType); } - public function testValidateValidatorConfigurationNoError() + public function testValidateValidatorConfigurationNoError(): void { $validatorConfig = ['foo' => 'bar']; $validationErrors = []; @@ -42,13 +42,13 @@ public function testValidateValidatorConfigurationNoError() self::assertSame($validationErrors, $this->fieldType->validateValidatorConfiguration($validatorConfig)); } - public function testValidateValidatorConfiguration() + public function testValidateValidatorConfiguration(): void { $validatorConfig = ['foo' => 'bar']; $validationErrors = [ - $this->createMock(ValidationError::class), - $this->createMock(ValidationError::class), - $this->createMock(ValidationError::class), + self::createStub(ValidationError::class), + self::createStub(ValidationError::class), + self::createStub(ValidationError::class), ]; $this->innerFieldType ->expects(self::once()) @@ -59,7 +59,7 @@ public function testValidateValidatorConfiguration() self::assertSame($validationErrors, $this->fieldType->validateValidatorConfiguration($validatorConfig)); } - public function testValidateFieldSettingsNoError() + public function testValidateFieldSettingsNoError(): void { $fieldSettings = ['foo' => 'bar']; $validationErrors = []; @@ -72,13 +72,13 @@ public function testValidateFieldSettingsNoError() self::assertSame($validationErrors, $this->fieldType->validateFieldSettings($fieldSettings)); } - public function testValidateFieldSettings() + public function testValidateFieldSettings(): void { $fieldSettings = ['foo' => 'bar']; $validationErrors = [ - $this->createMock(ValidationError::class), - $this->createMock(ValidationError::class), - $this->createMock(ValidationError::class), + self::createStub(ValidationError::class), + self::createStub(ValidationError::class), + self::createStub(ValidationError::class), ]; $this->innerFieldType ->expects(self::once()) @@ -89,7 +89,7 @@ public function testValidateFieldSettings() self::assertSame($validationErrors, $this->fieldType->validateFieldSettings($fieldSettings)); } - public function testValidateValueNoError() + public function testValidateValueNoError(): void { $fieldDefinition = $this->getMockForAbstractClass(APIFieldDefinition::class); $value = $this->getMockForAbstractClass(Value::class); @@ -103,14 +103,14 @@ public function testValidateValueNoError() self::assertSame($validationErrors, $this->fieldType->validateValue($fieldDefinition, $value)); } - public function testValidateValue() + public function testValidateValue(): void { $fieldDefinition = $this->getMockForAbstractClass(APIFieldDefinition::class); $value = $this->getMockForAbstractClass(Value::class); $validationErrors = [ - $this->createMock(ValidationError::class), - $this->createMock(ValidationError::class), - $this->createMock(ValidationError::class), + self::createStub(ValidationError::class), + self::createStub(ValidationError::class), + self::createStub(ValidationError::class), ]; $this->innerFieldType ->expects(self::once()) diff --git a/tests/lib/FieldType/AuthorTest.php b/tests/lib/FieldType/AuthorTest.php index c9528a517e..c1b38ff86c 100644 --- a/tests/lib/FieldType/AuthorTest.php +++ b/tests/lib/FieldType/AuthorTest.php @@ -13,11 +13,12 @@ use Ibexa\Core\FieldType\Author\Type as AuthorType; use Ibexa\Core\FieldType\Author\Value as AuthorValue; use Ibexa\Core\FieldType\Value; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; -/** - * @group fieldType - * @group ibexa_author - */ +#[CoversClass(AuthorCollection::class)] +#[Group('fieldType')] +#[Group('ibexa_author')] class AuthorTest extends FieldTypeTestCase { /** @var \Ibexa\Core\FieldType\Author\Author[] */ @@ -61,7 +62,7 @@ protected function getEmptyValueExpectation(): AuthorValue return new AuthorValue(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { return [ [ @@ -79,7 +80,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'empty array' => [ [], @@ -111,7 +112,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { return [ [ @@ -143,7 +144,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { return [ [ @@ -175,7 +176,7 @@ public function provideInputForFromHash(): iterable ]; } - public function provideValidFieldSettings(): iterable + public static function provideValidFieldSettings(): iterable { return [ [ @@ -194,7 +195,7 @@ public function provideValidFieldSettings(): iterable ]; } - public function provideInValidFieldSettings(): array + public static function provideInValidFieldSettings(): array { return [ [ @@ -232,7 +233,7 @@ public function testAcceptValueInvalidType(): void $ft = $this->createFieldTypeUnderTest(); $this->expectException(InvalidArgumentException::class); - $ft->acceptValue($this->createMock(Value::class)); + $ft->acceptValue(self::createStub(Value::class)); } public function testAcceptValueInvalidFormat(): void @@ -301,8 +302,6 @@ public function testAddAuthor(): void } /** - * @covers \Ibexa\Core\FieldType\Author\AuthorCollection::removeAuthorsById - * * @throws \Random\RandomException */ public function testRemoveAuthors(): void @@ -328,7 +327,7 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_author'; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { $authorList = new AuthorValue( [ @@ -338,7 +337,7 @@ public function provideDataForGetName(): array ); return [ - [$this->getEmptyValueExpectation(), '', [], 'en_GB'], + [new AuthorValue(), '', [], 'en_GB'], [$authorList, 'Boba Fett', [], 'en_GB'], ]; } diff --git a/tests/lib/FieldType/BaseFieldTypeTestCase.php b/tests/lib/FieldType/BaseFieldTypeTestCase.php index 68b92b036a..53b64b078a 100644 --- a/tests/lib/FieldType/BaseFieldTypeTestCase.php +++ b/tests/lib/FieldType/BaseFieldTypeTestCase.php @@ -11,6 +11,7 @@ use Ibexa\Contracts\Core\FieldType\ValidationError; use Ibexa\Contracts\Core\FieldType\Value as FieldTypeValue; use Ibexa\Contracts\Core\Repository\Values\ContentType\FieldDefinition as APIFieldDefinition; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; @@ -79,7 +80,7 @@ abstract protected function getEmptyValueExpectation(): FieldTypeValue; * class-string<\Throwable> * }> */ - abstract public function provideInvalidInputForAcceptValue(): iterable; + abstract public static function provideInvalidInputForAcceptValue(): iterable; /** * Data provider for valid input to acceptValue(). @@ -107,7 +108,7 @@ abstract public function provideInvalidInputForAcceptValue(): iterable; * * @phpstan-return iterable */ - abstract public function provideValidInputForAcceptValue(): iterable; + abstract public static function provideValidInputForAcceptValue(): iterable; /** * Provide input for the toHash() method. @@ -142,7 +143,7 @@ abstract public function provideValidInputForAcceptValue(): iterable; * * @phpstan-return iterable */ - abstract public function provideInputForToHash(): iterable; + abstract public static function provideInputForToHash(): iterable; /** * Provide input to fromHash() method. @@ -176,7 +177,7 @@ abstract public function provideInputForToHash(): iterable; * * @phpstan-return iterable */ - abstract public function provideInputForFromHash(): iterable; + abstract public static function provideInputForFromHash(): iterable; /** * Provides data for the getName() test. @@ -188,7 +189,7 @@ abstract public function provideInputForFromHash(): iterable; * 3?: string * }> */ - abstract public function provideDataForGetName(): array; + abstract public static function provideDataForGetName(): array; /** * Provide data sets with field settings which are considered invalid by the @@ -216,7 +217,7 @@ abstract public function provideDataForGetName(): array; * * @phpstan-return array */ - public function provideInValidFieldSettings(): array + public static function provideInValidFieldSettings(): array { return [ [ @@ -246,7 +247,7 @@ public function provideInValidFieldSettings(): array * * @phpstan-return iterable */ - public function provideValidFieldSettings(): iterable + public static function provideValidFieldSettings(): iterable { return [ [ @@ -286,7 +287,7 @@ public function provideValidFieldSettings(): iterable * * @phpstan-return array */ - public function provideValidValidatorConfiguration(): array + public static function provideValidValidatorConfiguration(): array { return [ [ @@ -330,7 +331,7 @@ public function provideValidValidatorConfiguration(): array * * @phpstan-return array */ - public function provideInvalidValidatorConfiguration(): array + public static function provideInvalidValidatorConfiguration(): array { return [ [ @@ -381,11 +382,16 @@ public function provideInvalidValidatorConfiguration(): array * * @phpstan-return iterable, \Ibexa\Contracts\Core\FieldType\Value}> */ - public function provideValidDataForValidate(): iterable + public static function provideValidDataForValidate(): iterable { yield 'empty field definition data' => [ [], - $this->createMock(FieldTypeValue::class), + new class() implements FieldTypeValue { + public function __toString(): string + { + return ''; + } + }, ]; } @@ -454,11 +460,16 @@ public function provideValidDataForValidate(): iterable * array<\Ibexa\Contracts\Core\FieldType\ValidationError> * }> */ - public function provideInvalidDataForValidate(): iterable + public static function provideInvalidDataForValidate(): iterable { yield 'invalid field definition data with no errors' => [ [], - $this->createMock(FieldTypeValue::class), + new class() implements FieldTypeValue { + public function __toString(): string + { + return ''; + } + }, [], ]; } @@ -486,10 +497,9 @@ public function testGetFieldTypeIdentifier(): void } /** - * @dataProvider provideDataForGetName - * * @param array $fieldSettings */ + #[DataProvider('provideDataForGetName')] public function testGetName( FieldTypeValue $value, string $expected, @@ -537,10 +547,9 @@ public function testEmptyValue(): void } /** - * @dataProvider provideValidInputForAcceptValue - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ + #[DataProvider('provideValidInputForAcceptValue')] public function testAcceptValue(mixed $inputValue, FieldTypeValue $expectedOutputValue): void { $fieldType = $this->getFieldTypeUnderTest(); @@ -574,12 +583,11 @@ public function testAcceptGetEmptyValue(): void } /** - * @dataProvider provideInvalidInputForAcceptValue - * * @phpstan-param class-string<\Throwable> $expectedException * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ + #[DataProvider('provideInvalidInputForAcceptValue')] public function testAcceptValueFailsOnInvalidValues( mixed $inputValue, string $expectedException @@ -590,9 +598,7 @@ public function testAcceptValueFailsOnInvalidValues( $fieldType->acceptValue($inputValue); } - /** - * @dataProvider provideInputForToHash - */ + #[DataProvider('provideInputForToHash')] public function testToHash(FieldTypeValue $inputValue, mixed $expectedResult): void { $fieldType = $this->getFieldTypeUnderTest(); @@ -617,10 +623,9 @@ public function testToHash(FieldTypeValue $inputValue, mixed $expectedResult): v } /** - * @dataProvider provideInputForFromHash - * * @param array|null $inputHash */ + #[DataProvider('provideInputForFromHash')] public function testFromHash(mixed $inputHash, mixed $expectedResult): void { $this->assertIsValidHashValue($inputHash); @@ -653,9 +658,7 @@ public function testEmptyValueIsEmpty(): void ); } - /** - * @dataProvider provideValidFieldSettings - */ + #[DataProvider('provideValidFieldSettings')] public function testValidateFieldSettingsValid(mixed $inputSettings): void { $fieldType = $this->getFieldTypeUnderTest(); @@ -673,9 +676,7 @@ public function testValidateFieldSettingsValid(mixed $inputSettings): void ); } - /** - * @dataProvider provideInvalidFieldSettings - */ + #[DataProvider('provideInvalidFieldSettings')] public function testValidateFieldSettingsInvalid(mixed $inputSettings): void { $fieldType = $this->getFieldTypeUnderTest(); @@ -702,9 +703,7 @@ public function testValidateFieldSettingsInvalid(mixed $inputSettings): void } } - /** - * @dataProvider provideValidValidatorConfiguration - */ + #[DataProvider('provideValidValidatorConfiguration')] public function testValidateValidatorConfigurationValid(mixed $inputConfiguration): void { $fieldType = $this->getFieldTypeUnderTest(); @@ -722,9 +721,7 @@ public function testValidateValidatorConfigurationValid(mixed $inputConfiguratio ); } - /** - * @dataProvider provideInvalidValidatorConfiguration - */ + #[DataProvider('provideInvalidValidatorConfiguration')] public function testValidateValidatorConfigurationInvalid(mixed $inputConfiguration): void { $fieldType = $this->getFieldTypeUnderTest(); @@ -751,9 +748,7 @@ public function testValidateValidatorConfigurationInvalid(mixed $inputConfigurat } } - /** - * @dataProvider provideValidFieldSettings - */ + #[DataProvider('provideValidFieldSettings')] public function testFieldSettingsToHash(mixed $inputSettings): void { $fieldType = $this->getFieldTypeUnderTest(); @@ -763,9 +758,7 @@ public function testFieldSettingsToHash(mixed $inputSettings): void $this->assertIsValidHashValue($hash); } - /** - * @dataProvider provideValidValidatorConfiguration - */ + #[DataProvider('provideValidValidatorConfiguration')] public function testValidatorConfigurationToHash(mixed $inputConfiguration): void { $fieldType = $this->getFieldTypeUnderTest(); @@ -775,9 +768,7 @@ public function testValidatorConfigurationToHash(mixed $inputConfiguration): voi $this->assertIsValidHashValue($hash); } - /** - * @dataProvider provideValidFieldSettings - */ + #[DataProvider('provideValidFieldSettings')] public function testFieldSettingsFromHash(mixed $inputSettings): void { $fieldType = $this->getFieldTypeUnderTest(); @@ -788,9 +779,7 @@ public function testFieldSettingsFromHash(mixed $inputSettings): void self::assertEquals($inputSettings, $restoredSettings); } - /** - * @dataProvider provideValidValidatorConfiguration - */ + #[DataProvider('provideValidValidatorConfiguration')] public function testValidatorConfigurationFromHash(mixed $inputConfiguration): void { $fieldType = $this->getFieldTypeUnderTest(); @@ -839,14 +828,17 @@ protected function assertIsValidHashValue(mixed $actualHash, array $keyChain = [ } /** - * @dataProvider provideValidDataForValidate - * * @param array $fieldDefinitionData * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ + #[DataProvider('provideValidDataForValidate')] public function testValidateValid(array $fieldDefinitionData, FieldTypeValue $value): void { + if (isset($fieldDefinitionData['__no_data__'])) { + self::markTestSkipped($fieldDefinitionData['__no_data__']); + } + $validationErrors = $this->doValidate($fieldDefinitionData, $value); self::assertIsArray($validationErrors); @@ -854,15 +846,18 @@ public function testValidateValid(array $fieldDefinitionData, FieldTypeValue $va } /** - * @dataProvider provideInvalidDataForValidate - * * @param array $fieldDefinitionData * @param \Ibexa\Contracts\Core\FieldType\ValidationError[] $errors * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ + #[DataProvider('provideInvalidDataForValidate')] public function testValidateInvalid(array $fieldDefinitionData, FieldTypeValue $value, array $errors): void { + if (isset($fieldDefinitionData['__no_data__'])) { + self::markTestSkipped($fieldDefinitionData['__no_data__']); + } + $validationErrors = $this->doValidate($fieldDefinitionData, $value); self::assertIsArray($validationErrors); diff --git a/tests/lib/FieldType/BinaryBaseTestCase.php b/tests/lib/FieldType/BinaryBaseTestCase.php index aa48bd279f..829cc4d499 100644 --- a/tests/lib/FieldType/BinaryBaseTestCase.php +++ b/tests/lib/FieldType/BinaryBaseTestCase.php @@ -11,17 +11,17 @@ use Ibexa\Core\Base\Exceptions\InvalidArgumentException; use Ibexa\Core\FieldType\Validator\FileExtensionBlackListValidator; use Ibexa\Core\FieldType\Value; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\MockObject\MockObject; /** * Base class for binary field types. - * - * @group fieldType */ +#[Group('fieldType')] abstract class BinaryBaseTestCase extends FieldTypeTestCase { /** @var string[] */ - protected array $blackListedExtensions = [ + protected const array BLACK_LISTED_EXTENSIONS = [ 'php', 'php3', 'phar', @@ -31,6 +31,9 @@ abstract class BinaryBaseTestCase extends FieldTypeTestCase 'pgif', ]; + /** @var string[] */ + protected array $blackListedExtensions = self::BLACK_LISTED_EXTENSIONS; + protected function getValidatorConfigurationSchemaExpectation(): array { return [ @@ -66,10 +69,15 @@ protected function getSettingsSchemaExpectation(): array return []; } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { yield [ - $this->getMockForAbstractClass(Value::class), + new class() extends Value { + public function __toString(): string + { + return ''; + } + }, InvalidArgumentException::class, ]; @@ -79,7 +87,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidValidatorConfiguration(): array + public static function provideValidValidatorConfiguration(): array { return [ [ @@ -102,7 +110,7 @@ public function provideValidValidatorConfiguration(): array ]; } - public function provideInvalidValidatorConfiguration(): array + public static function provideInvalidValidatorConfiguration(): array { return [ [ diff --git a/tests/lib/FieldType/BinaryFileTest.php b/tests/lib/FieldType/BinaryFileTest.php index 2e66cc93f3..3169ea7556 100644 --- a/tests/lib/FieldType/BinaryFileTest.php +++ b/tests/lib/FieldType/BinaryFileTest.php @@ -12,13 +12,12 @@ use Ibexa\Core\FieldType\BinaryFile\Type as BinaryFileType; use Ibexa\Core\FieldType\BinaryFile\Value as BinaryFileValue; use Ibexa\Core\FieldType\ValidationError; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; -/** - * @group fieldType - * @group ibexa_binaryfile - * - * @covers \Ibexa\Core\FieldType\BinaryFile\Type - */ +#[CoversClass(BinaryFileType::class)] +#[Group('fieldType')] +#[Group('ibexa_binaryfile')] class BinaryFileTest extends BinaryBaseTestCase { protected function createFieldTypeUnderTest(): BinaryFileType @@ -37,7 +36,7 @@ protected function getEmptyValueExpectation(): BinaryFileValue return new BinaryFileValue(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { yield from parent::provideInvalidInputForAcceptValue(); @@ -47,7 +46,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'null input' => [ null, @@ -152,7 +151,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { return [ [ @@ -299,7 +298,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { return [ [ @@ -422,7 +421,7 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_binaryfile'; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ [new BinaryFileValue(), '', [], 'en_GB'], @@ -430,7 +429,7 @@ public function provideDataForGetName(): array ]; } - public function provideValidDataForValidate(): iterable + public static function provideValidDataForValidate(): iterable { yield 'valid file size' => [ [ @@ -452,7 +451,7 @@ public function provideValidDataForValidate(): iterable ]; } - public function provideInvalidDataForValidate(): iterable + public static function provideInvalidDataForValidate(): iterable { yield 'file too large' => [ [ @@ -504,7 +503,7 @@ public function provideInvalidDataForValidate(): iterable new ValidationError( 'A valid file is required. The following file extensions are not allowed: %extensionsBlackList%', null, - ['%extensionsBlackList%' => implode(', ', $this->blackListedExtensions)], + ['%extensionsBlackList%' => implode(', ', self::BLACK_LISTED_EXTENSIONS)], 'fileExtensionBlackList' ), ], @@ -531,7 +530,7 @@ public function provideInvalidDataForValidate(): iterable new ValidationError( 'A valid file is required. The following file extensions are not allowed: %extensionsBlackList%', null, - ['%extensionsBlackList%' => implode(', ', $this->blackListedExtensions)], + ['%extensionsBlackList%' => implode(', ', self::BLACK_LISTED_EXTENSIONS)], 'fileExtensionBlackList' ), ], diff --git a/tests/lib/FieldType/CheckboxTest.php b/tests/lib/FieldType/CheckboxTest.php index 5f44f17f03..1e465d4bee 100644 --- a/tests/lib/FieldType/CheckboxTest.php +++ b/tests/lib/FieldType/CheckboxTest.php @@ -10,11 +10,11 @@ use Ibexa\Core\Base\Exceptions\InvalidArgumentException; use Ibexa\Core\FieldType\Checkbox\Type as Checkbox; use Ibexa\Core\FieldType\Checkbox\Value as CheckboxValue; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; -/** - * @group fieldType - * @group ibexa_boolean - */ +#[Group('fieldType')] +#[Group('ibexa_boolean')] class CheckboxTest extends FieldTypeTestCase { protected function createFieldTypeUnderTest(): Checkbox @@ -40,7 +40,7 @@ protected function getEmptyValueExpectation(): CheckboxValue return new CheckboxValue(false); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { return [ [ @@ -55,7 +55,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'false value' => [ false, @@ -68,7 +68,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { return [ [ @@ -82,7 +82,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { return [ [ @@ -131,7 +131,7 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_boolean'; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ [new CheckboxValue(true), '1', [], 'en_GB'], @@ -139,9 +139,7 @@ public function provideDataForGetName(): array ]; } - /** - * @dataProvider provideForValueIsNeverEmpty - */ + #[DataProvider('provideForValueIsNeverEmpty')] public function testValueIsNeverEmpty(CheckboxValue $value): void { $fieldType = $this->getFieldTypeUnderTest(); @@ -154,7 +152,7 @@ public function testValueIsNeverEmpty(CheckboxValue $value): void * \Ibexa\Core\FieldType\Checkbox\Value, * }> */ - public function provideForValueIsNeverEmpty(): iterable + public static function provideForValueIsNeverEmpty(): iterable { yield [new CheckboxValue(true)]; yield [new CheckboxValue(false)]; diff --git a/tests/lib/FieldType/CountryTest.php b/tests/lib/FieldType/CountryTest.php index bff98c93e8..ea0a18677a 100644 --- a/tests/lib/FieldType/CountryTest.php +++ b/tests/lib/FieldType/CountryTest.php @@ -12,11 +12,10 @@ use Ibexa\Core\FieldType\Country\Type as Country; use Ibexa\Core\FieldType\Country\Value as CountryValue; use Ibexa\Core\FieldType\ValidationError; +use PHPUnit\Framework\Attributes\Group; -/** - * @group fieldType - * @group ibexa_country - */ +#[Group('fieldType')] +#[Group('ibexa_country')] class CountryTest extends FieldTypeTestCase { protected function provideFieldTypeIdentifier(): string @@ -91,7 +90,7 @@ protected function getEmptyValueExpectation(): CountryValue return new CountryValue(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { yield [ 'LegoLand', @@ -111,7 +110,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'multiple countries by alpha2' => [ ['BE', 'FR'], @@ -176,7 +175,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { yield [ new CountryValue( @@ -212,7 +211,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { yield [ ['BE'], @@ -248,7 +247,7 @@ public function provideInputForFromHash(): iterable ]; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ [new CountryValue(), '', [], 'en_GB'], @@ -262,7 +261,7 @@ public function provideDataForGetName(): array ]; } - public function provideValidDataForValidate(): iterable + public static function provideValidDataForValidate(): iterable { yield 'empty value multiple' => [ [ @@ -290,7 +289,7 @@ public function provideValidDataForValidate(): iterable ]; } - public function provideInvalidDataForValidate(): iterable + public static function provideInvalidDataForValidate(): iterable { yield 'multiple countries when multiple not allowed' => [ [ diff --git a/tests/lib/FieldType/DateAndTimeTest.php b/tests/lib/FieldType/DateAndTimeTest.php index 9f327df861..5308f6770c 100644 --- a/tests/lib/FieldType/DateAndTimeTest.php +++ b/tests/lib/FieldType/DateAndTimeTest.php @@ -11,12 +11,12 @@ use Ibexa\Core\Base\Exceptions\InvalidArgumentException; use Ibexa\Core\FieldType\DateAndTime\Type as DateAndTime; use Ibexa\Core\FieldType\DateAndTime\Value as DateAndTimeValue; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; use stdClass; -/** - * @group fieldType - * @group ibexa_datetime - */ +#[Group('fieldType')] +#[Group('ibexa_datetime')] class DateAndTimeTest extends FieldTypeTestCase { protected function createFieldTypeUnderTest(): DateAndTime @@ -55,7 +55,7 @@ protected function getEmptyValueExpectation(): DateAndTimeValue return new DateAndTimeValue(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { return [ [ @@ -65,7 +65,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'null input' => [ null, @@ -88,7 +88,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { return [ [ @@ -106,10 +106,9 @@ public function provideInputForToHash(): iterable } /** - * @dataProvider provideInputForFromHash - * * @param \Ibexa\Core\FieldType\DateAndTime\Value $expectedResult */ + #[DataProvider('provideInputForFromHash')] public function testFromHash(mixed $inputHash, mixed $expectedResult): void { $this->assertIsValidHashValue($inputHash); @@ -134,7 +133,7 @@ public function testFromHash(mixed $inputHash, mixed $expectedResult): void } } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { $date = new \DateTime('Tue, 28 Aug 2012 12:20:00 +0200'); @@ -160,10 +159,9 @@ public function provideInputForFromHash(): iterable } /** - * @dataProvider provideInputForTimeStringFromHash - * * @throws \DateMalformedIntervalStringException */ + #[DataProvider('provideInputForTimeStringFromHash')] public function testTimeStringFromHash(mixed $inputHash, string $intervalSpec): void { $this->assertIsValidHashValue($inputHash); @@ -203,7 +201,7 @@ public function testTimeStringFromHash(mixed $inputHash, string $intervalSpec): * * @phpstan-return array */ - public function provideInputForTimeStringFromHash(): array + public static function provideInputForTimeStringFromHash(): array { return [ [ @@ -227,7 +225,7 @@ public function provideInputForTimeStringFromHash(): array ]; } - public function provideValidFieldSettings(): iterable + public static function provideValidFieldSettings(): iterable { return [ [ @@ -255,7 +253,7 @@ public function provideValidFieldSettings(): iterable ]; } - public function provideInValidFieldSettings(): array + public static function provideInValidFieldSettings(): array { return [ [ @@ -292,10 +290,10 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_datetime'; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ - [$this->getEmptyValueExpectation(), '', [], 'en_GB'], + [new DateAndTimeValue(), '', [], 'en_GB'], [DateAndTimeValue::fromTimestamp(438512400), 'Thu 1983-24-11 09:00:00', [], 'en_GB'], ]; } diff --git a/tests/lib/FieldType/DateTest.php b/tests/lib/FieldType/DateTest.php index 5076d5cbd5..26ac1476d0 100644 --- a/tests/lib/FieldType/DateTest.php +++ b/tests/lib/FieldType/DateTest.php @@ -12,11 +12,10 @@ use Ibexa\Core\Base\Exceptions\InvalidArgumentException; use Ibexa\Core\FieldType\Date\Type as Date; use Ibexa\Core\FieldType\Date\Value as DateValue; +use PHPUnit\Framework\Attributes\Group; -/** - * @group fieldType - * @group ibexa_date - */ +#[Group('fieldType')] +#[Group('ibexa_date')] class DateTest extends FieldTypeTestCase { protected function createFieldTypeUnderTest(): Date @@ -47,7 +46,7 @@ protected function getEmptyValueExpectation(): DateValue return new DateValue(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { return [ [ @@ -57,7 +56,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'null input' => [ null, @@ -87,7 +86,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { return [ [ @@ -104,7 +103,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { $dateTime = new DateTime(); @@ -134,7 +133,7 @@ public function provideInputForFromHash(): iterable ]; } - public function provideValidFieldSettings(): iterable + public static function provideValidFieldSettings(): iterable { return [ [ @@ -153,7 +152,7 @@ public function provideValidFieldSettings(): iterable ]; } - public function provideInValidFieldSettings(): array + public static function provideInValidFieldSettings(): array { return [ [ @@ -176,10 +175,10 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_date'; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ - [$this->getEmptyValueExpectation(), '', [], 'en_GB'], + [new DateValue(), '', [], 'en_GB'], [new DateValue(new DateTime('11/24/1983')), 'Thursday 24 November 1983', [], 'en_GB'], ]; } diff --git a/tests/lib/FieldType/EmailAddressTest.php b/tests/lib/FieldType/EmailAddressTest.php index 35ab8ebc7c..94e3a5b55c 100644 --- a/tests/lib/FieldType/EmailAddressTest.php +++ b/tests/lib/FieldType/EmailAddressTest.php @@ -11,11 +11,10 @@ use Ibexa\Core\FieldType\EmailAddress\Type as EmailAddressType; use Ibexa\Core\FieldType\EmailAddress\Value as EmailAddressValue; use Ibexa\Core\FieldType\ValidationError; +use PHPUnit\Framework\Attributes\Group; -/** - * @group fieldType - * @group ibexa_email - */ +#[Group('fieldType')] +#[Group('ibexa_email')] class EmailAddressTest extends FieldTypeTestCase { protected function createFieldTypeUnderTest(): EmailAddressType @@ -54,7 +53,7 @@ protected function getEmptyValueExpectation(): EmailAddressValue return new EmailAddressValue(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { return [ [ @@ -69,7 +68,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'null input' => [ null, @@ -87,7 +86,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { return [ [ @@ -101,7 +100,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { return [ [ @@ -119,7 +118,7 @@ public function provideInputForFromHash(): iterable ]; } - public function provideValidValidatorConfiguration(): array + public static function provideValidValidatorConfiguration(): array { return [ [ @@ -140,7 +139,7 @@ public function provideValidValidatorConfiguration(): array ]; } - public function provideInvalidValidatorConfiguration(): array + public static function provideInvalidValidatorConfiguration(): array { return [ [ @@ -177,7 +176,7 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_email'; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ [new EmailAddressValue('john.doe@example.com'), 'john.doe@example.com', [], 'en_GB'], @@ -185,7 +184,7 @@ public function provideDataForGetName(): array ]; } - public function provideValidDataForValidate(): iterable + public static function provideValidDataForValidate(): iterable { yield 'valid email address' => [ [ @@ -195,7 +194,7 @@ public function provideValidDataForValidate(): iterable ]; } - public function provideInvalidDataForValidate(): iterable + public static function provideInvalidDataForValidate(): iterable { yield 'invalid email format' => [ [ diff --git a/tests/lib/FieldType/EmailAddressValidatorTest.php b/tests/lib/FieldType/EmailAddressValidatorTest.php index 6bb24f9657..8a31e0c64b 100644 --- a/tests/lib/FieldType/EmailAddressValidatorTest.php +++ b/tests/lib/FieldType/EmailAddressValidatorTest.php @@ -10,16 +10,16 @@ use Ibexa\Core\FieldType\EmailAddress\Value as EmailAddressValue; use Ibexa\Core\FieldType\Validator; use Ibexa\Core\FieldType\Validator\EmailAddressValidator; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; /** * @todo add more tests, like on validateConstraints method - * - * @group fieldType - * @group validator - * - * @covers \Ibexa\Core\FieldType\Validator\EmailAddressValidator */ +#[CoversClass(EmailAddressValidator::class)] +#[Group('fieldType')] +#[Group('validator')] class EmailAddressValidatorTest extends TestCase { public function testConstructor(): void diff --git a/tests/lib/FieldType/FieldTypeMockTest.php b/tests/lib/FieldType/FieldTypeMockTest.php index 3ad0eeb9cf..ec462fcbe0 100644 --- a/tests/lib/FieldType/FieldTypeMockTest.php +++ b/tests/lib/FieldType/FieldTypeMockTest.php @@ -9,8 +9,11 @@ use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException; use Ibexa\Core\FieldType\FieldType; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; +#[CoversClass(FieldType::class)] class FieldTypeMockTest extends TestCase { public function testApplyDefaultSettingsThrowsInvalidArgumentException(): void @@ -30,11 +33,7 @@ public function testApplyDefaultSettingsThrowsInvalidArgumentException(): void $stub->applyDefaultSettings($fieldSettings); } - /** - * @dataProvider providerForTestApplyDefaultSettings - * - * @covers \Ibexa\Core\FieldType\FieldType::applyDefaultSettings - */ + #[DataProvider('providerForTestApplyDefaultSettings')] public function testApplyDefaultSettings(mixed $initialSettings, mixed $expectedSettings): void { /** @var \Ibexa\Core\FieldType\FieldType|\PHPUnit\Framework\MockObject\MockObject $stub */ @@ -209,10 +208,9 @@ public function testApplyDefaultValidatorConfigurationEmpty(): void } /** - * @dataProvider providerForTestApplyDefaultValidatorConfiguration - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ + #[DataProvider('providerForTestApplyDefaultValidatorConfiguration')] public function testApplyDefaultValidatorConfiguration(mixed $initialConfiguration, mixed $expectedConfiguration): void { /** @var \Ibexa\Core\FieldType\FieldType|\PHPUnit\Framework\MockObject\MockObject $stub */ @@ -255,7 +253,7 @@ public function testApplyDefaultValidatorConfiguration(mixed $initialConfigurati * array * }> */ - public function providerForTestApplyDefaultValidatorConfiguration(): iterable + public static function providerForTestApplyDefaultValidatorConfiguration(): iterable { $defaultConfiguration = [ 'TestValidator' => [ diff --git a/tests/lib/FieldType/FieldTypeTestCase.php b/tests/lib/FieldType/FieldTypeTestCase.php index c7bf807e81..8ec2c8dbf0 100644 --- a/tests/lib/FieldType/FieldTypeTestCase.php +++ b/tests/lib/FieldType/FieldTypeTestCase.php @@ -11,6 +11,7 @@ use Ibexa\Contracts\Core\FieldType\FieldType; use Ibexa\Contracts\Core\FieldType\Value as SPIValue; use Ibexa\Core\Persistence\TransformationProcessor; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\MockObject\MockObject; abstract class FieldTypeTestCase extends BaseFieldTypeTestCase @@ -33,9 +34,9 @@ protected function getTransformationProcessorMock(): TransformationProcessor & M /** * @phpstan-return iterable */ - public function provideInputForValuesEqual(): iterable + public static function provideInputForValuesEqual(): iterable { - yield from $this->provideInputForFromHash(); + yield from static::provideInputForFromHash(); } abstract protected function createFieldTypeUnderTest(): FieldType & Comparable; @@ -49,9 +50,7 @@ protected function getFieldTypeUnderTest(): FieldType & Comparable return $this->fieldTypeUnderTest; } - /** - * @dataProvider provideInputForValuesEqual - */ + #[DataProvider('provideInputForValuesEqual')] public function testValuesEqual(mixed $inputValue1Hash, SPIValue $inputValue2): void { $fieldType = $this->getFieldTypeUnderTest(); diff --git a/tests/lib/FieldType/FileSizeValidatorTest.php b/tests/lib/FieldType/FileSizeValidatorTest.php index 9dbb25c6bd..9d5c5db685 100644 --- a/tests/lib/FieldType/FileSizeValidatorTest.php +++ b/tests/lib/FieldType/FileSizeValidatorTest.php @@ -11,17 +11,18 @@ use Ibexa\Contracts\Core\Repository\Values\Translation\Message; use Ibexa\Core\FieldType\Validator; use Ibexa\Core\FieldType\Validator\FileSizeValidator; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; -/** - * @group fieldType - * @group validator - * - * @covers \Ibexa\Core\FieldType\Validator\FileSizeValidator - */ +#[CoversClass(FileSizeValidator::class)] +#[CoversClass(Validator::class)] +#[Group('fieldType')] +#[Group('validator')] class FileSizeValidatorTest extends TestCase { - protected function getMaxFileSize(): int + protected static function getMaxFileSize(): int { return 4096; } @@ -104,13 +105,9 @@ public function testGetBadConstraint(): void * Tests validating a correct value. * * @param int $size - * - * @dataProvider providerForValidateOK - * - * @covers \Ibexa\Core\FieldType\Validator\FileSizeValidator::validate - * @covers \Ibexa\Core\FieldType\Validator::getMessage */ - public function testValidateCorrectValues($size) + #[DataProvider('providerForValidateOK')] + public function testValidateCorrectValues($size): void { self::markTestSkipped('BinaryFile field type does not use this validator anymore.'); $validator = new FileSizeValidator(); @@ -133,7 +130,10 @@ protected function getBinaryFileValue($size) return $value; } - public function providerForValidateOK() + /** + * @return array + */ + public static function providerForValidateOK(): array { return [ [0], @@ -144,12 +144,9 @@ public function providerForValidateOK() /** * Tests validating a wrong value. - * - * @dataProvider providerForValidateKO - * - * @covers \Ibexa\Core\FieldType\Validator\FileSizeValidator::validate */ - public function testValidateWrongValues($size, $message, $values) + #[DataProvider('providerForValidateKO')] + public function testValidateWrongValues($size, $message, $values): void { self::markTestSkipped('BinaryFile field type does not use this validator anymore.'); $validator = new FileSizeValidator(); @@ -179,7 +176,10 @@ public function testValidateWrongValues($size, $message, $values) ); } - public function providerForValidateKO() + /** + * @return array + */ + public static function providerForValidateKO(): array { return [ [ @@ -188,7 +188,7 @@ public function providerForValidateKO() 'The file size cannot exceed %size% byte.', 'The file size cannot exceed %size% bytes.', ], - ['%size%' => $this->getMaxFileSize()], + ['%size%' => self::getMaxFileSize()], ], ]; } @@ -196,10 +196,10 @@ public function providerForValidateKO() /** * Tests validation of constraints. * - * @dataProvider providerForValidateConstraintsOK * * @param array $constraints */ + #[DataProvider('providerForValidateConstraintsOK')] public function testValidateConstraintsCorrectValues(array $constraints): void { $validator = new FileSizeValidator(); @@ -212,7 +212,7 @@ public function testValidateConstraintsCorrectValues(array $constraints): void /** * @return array */ - public function providerForValidateConstraintsOK(): array + public static function providerForValidateConstraintsOK(): array { return [ [ @@ -226,12 +226,11 @@ public function providerForValidateConstraintsOK(): array } /** - * @dataProvider providerForValidateConstraintsKO - * * @param array $constraints * @param string[] $expectedMessages * @param array $values */ + #[DataProvider('providerForValidateConstraintsKO')] public function testValidateConstraintsWrongValues(array $constraints, array $expectedMessages, array $values): void { $validator = new FileSizeValidator(); @@ -254,7 +253,7 @@ public function testValidateConstraintsWrongValues(array $constraints, array $ex /** * @return array, string[], array}> */ - public function providerForValidateConstraintsKO(): array + public static function providerForValidateConstraintsKO(): array { return [ [ diff --git a/tests/lib/FieldType/FloatTest.php b/tests/lib/FieldType/FloatTest.php index 343f735897..478b48ad07 100644 --- a/tests/lib/FieldType/FloatTest.php +++ b/tests/lib/FieldType/FloatTest.php @@ -11,11 +11,10 @@ use Ibexa\Core\FieldType\Float\Type as FloatType; use Ibexa\Core\FieldType\Float\Value as FloatValue; use Ibexa\Core\FieldType\ValidationError; +use PHPUnit\Framework\Attributes\Group; -/** - * @group fieldType - * @group ibexa_float - */ +#[Group('fieldType')] +#[Group('ibexa_float')] class FloatTest extends FieldTypeTestCase { protected function createFieldTypeUnderTest(): FloatType @@ -52,7 +51,7 @@ protected function getEmptyValueExpectation(): FloatValue return new FloatValue(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { return [ [ @@ -70,7 +69,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'null input' => [ null, @@ -103,7 +102,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { return [ [ @@ -117,7 +116,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { return [ [ @@ -131,7 +130,7 @@ public function provideInputForFromHash(): iterable ]; } - public function provideValidValidatorConfiguration(): array + public static function provideValidValidatorConfiguration(): array { return [ [ @@ -176,7 +175,7 @@ public function provideValidValidatorConfiguration(): array ]; } - public function provideInvalidValidatorConfiguration(): array + public static function provideInvalidValidatorConfiguration(): array { return [ [ @@ -213,15 +212,15 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_float'; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ - [$this->getEmptyValueExpectation(), '', [], 'en_GB'], + [new FloatValue(), '', [], 'en_GB'], [new FloatValue(23.42), '23.42', [], 'en_GB'], ]; } - public function provideValidDataForValidate(): iterable + public static function provideValidDataForValidate(): iterable { yield 'value within range' => [ [ @@ -236,7 +235,7 @@ public function provideValidDataForValidate(): iterable ]; } - public function provideInvalidDataForValidate(): iterable + public static function provideInvalidDataForValidate(): iterable { yield 'value below minimum' => [ [ diff --git a/tests/lib/FieldType/Generic/GenericTest.php b/tests/lib/FieldType/Generic/GenericTest.php index cd997c6d76..7f881b1950 100644 --- a/tests/lib/FieldType/Generic/GenericTest.php +++ b/tests/lib/FieldType/Generic/GenericTest.php @@ -16,6 +16,7 @@ use Ibexa\Tests\Core\FieldType\BaseFieldTypeTestCase; use Ibexa\Tests\Core\FieldType\Generic\Stubs\Type as GenericFieldTypeStub; use Ibexa\Tests\Core\FieldType\Generic\Stubs\Value as GenericFieldValueStub; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\MockObject\MockObject; use Symfony\Component\Validator\ConstraintViolation; use Symfony\Component\Validator\ConstraintViolationList; @@ -37,25 +38,23 @@ protected function setUp(): void } /** - * @dataProvider provideValidDataForValidate - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ + #[DataProvider('provideValidDataForValidate')] public function testValidateValid(array $fieldDefinitionData, Value $value): void { $this->validator ->method('validate') ->with($value, null) - ->willReturn($this->createMock(ConstraintViolationListInterface::class)); + ->willReturn(self::createStub(ConstraintViolationListInterface::class)); parent::testValidateValid($fieldDefinitionData, $value); } /** - * @dataProvider provideInvalidDataForValidate - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ + #[DataProvider('provideInvalidDataForValidate')] public function testValidateInvalid(array $fieldDefinitionData, FieldTypeValue $value, array $errors): void { $constraintViolationList = new ConstraintViolationList( @@ -105,7 +104,7 @@ protected function getEmptyValueExpectation(): GenericFieldValueStub return new GenericFieldValueStub(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { return [ [ @@ -115,7 +114,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'null' => [ null, @@ -131,7 +130,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { return [ [ @@ -145,7 +144,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { return [ [ @@ -159,7 +158,7 @@ public function provideInputForFromHash(): iterable ]; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ [new GenericFieldValueStub('This is a generic value.'), 'This is a generic value.', [], 'en_GB'], diff --git a/tests/lib/FieldType/Generic/ValueSerializer/SymfonySerializerAdapterTest.php b/tests/lib/FieldType/Generic/ValueSerializer/SymfonySerializerAdapterTest.php index f564441e91..be19653116 100644 --- a/tests/lib/FieldType/Generic/ValueSerializer/SymfonySerializerAdapterTest.php +++ b/tests/lib/FieldType/Generic/ValueSerializer/SymfonySerializerAdapterTest.php @@ -54,7 +54,7 @@ protected function setUp(): void public function testNormalize(): void { - $value = $this->createMock(Value::class); + $value = self::createStub(Value::class); $data = ['value' => 'test']; $this->normalizer @@ -69,7 +69,7 @@ public function testNormalize(): void public function testDenormalize(): void { $data = ['value' => 'test']; - $value = $this->createMock(Value::class); + $value = self::createStub(Value::class); $this->denomalizer ->expects(self::once()) diff --git a/tests/lib/FieldType/ISBNTest.php b/tests/lib/FieldType/ISBNTest.php index b2c45eb8cb..5da6a2ec6c 100644 --- a/tests/lib/FieldType/ISBNTest.php +++ b/tests/lib/FieldType/ISBNTest.php @@ -11,11 +11,10 @@ use Ibexa\Core\FieldType\ISBN\Type as ISBN; use Ibexa\Core\FieldType\ISBN\Value as ISBNValue; use Ibexa\Core\FieldType\ValidationError; +use PHPUnit\Framework\Attributes\Group; -/** - * @group fieldType - * @group ibexa_isbn - */ +#[Group('fieldType')] +#[Group('ibexa_isbn')] class ISBNTest extends FieldTypeTestCase { protected function createFieldTypeUnderTest(): ISBN @@ -46,7 +45,7 @@ protected function getEmptyValueExpectation(): ISBNValue return new ISBNValue(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { return [ [ @@ -68,7 +67,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'ISBN-13 standard' => [ '9789722514095', @@ -86,7 +85,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { return [ [ @@ -96,7 +95,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { return [ [ @@ -111,15 +110,15 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_isbn'; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ - [$this->getEmptyValueExpectation(), '', [], 'en_GB'], + [new ISBNValue(), '', [], 'en_GB'], [new ISBNValue('9789722514095'), '9789722514095', [], 'en_GB'], ]; } - public function provideValidDataForValidate(): iterable + public static function provideValidDataForValidate(): iterable { yield 'empty value with ISBN-13' => [ [ @@ -158,7 +157,7 @@ public function provideValidDataForValidate(): iterable ]; } - public function provideInvalidDataForValidate(): iterable + public static function provideInvalidDataForValidate(): iterable { yield 'ISBN-13 when ISBN-10 required' => [ [ diff --git a/tests/lib/FieldType/Image/IO/LegacyTest.php b/tests/lib/FieldType/Image/IO/LegacyTest.php index 682c2f8948..f7d340636f 100644 --- a/tests/lib/FieldType/Image/IO/LegacyTest.php +++ b/tests/lib/FieldType/Image/IO/LegacyTest.php @@ -15,12 +15,11 @@ use Ibexa\Core\IO\IOServiceInterface; use Ibexa\Core\IO\Values\BinaryFile; use Ibexa\Core\IO\Values\BinaryFileCreateStruct; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\FieldType\Image\IO\Legacy - */ +#[CoversClass(LegacyIOService::class)] final class LegacyTest extends TestCase { protected LegacyIOService $service; diff --git a/tests/lib/FieldType/Image/PathGenerator/LegacyPathGeneratorTest.php b/tests/lib/FieldType/Image/PathGenerator/LegacyPathGeneratorTest.php index 807839ab92..2649aeff19 100644 --- a/tests/lib/FieldType/Image/PathGenerator/LegacyPathGeneratorTest.php +++ b/tests/lib/FieldType/Image/PathGenerator/LegacyPathGeneratorTest.php @@ -8,21 +8,20 @@ namespace Ibexa\Tests\Core\FieldType\Image\PathGenerator; use Ibexa\Core\FieldType\Image\PathGenerator\LegacyPathGenerator; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; -/** - * @group fieldType - * @group ibexa_image - */ +#[Group('fieldType')] +#[Group('ibexa_image')] class LegacyPathGeneratorTest extends TestCase { /** * @param mixed $data * @param mixed $expectedPath - * - * @dataProvider provideStoragePathForFieldData */ - public function testGetStoragePathForField($data, $expectedPath) + #[DataProvider('provideStoragePathForFieldData')] + public function testGetStoragePathForField($data, $expectedPath): void { $pathGenerator = new LegacyPathGenerator(); @@ -36,7 +35,10 @@ public function testGetStoragePathForField($data, $expectedPath) ); } - public function provideStoragePathForFieldData() + /** + * @return array + */ + public static function provideStoragePathForFieldData(): array { return [ [ diff --git a/tests/lib/FieldType/ImageAsset/AssetMapperTest.php b/tests/lib/FieldType/ImageAsset/AssetMapperTest.php index 3cfdcb09ec..5c7aba9931 100644 --- a/tests/lib/FieldType/ImageAsset/AssetMapperTest.php +++ b/tests/lib/FieldType/ImageAsset/AssetMapperTest.php @@ -23,6 +23,7 @@ use Ibexa\Core\Repository\Values\Content\VersionInfo; use Ibexa\Core\Repository\Values\ContentType\ContentType; use Ibexa\Core\Repository\Values\ContentType\FieldDefinition; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; class AssetMapperTest extends TestCase @@ -82,15 +83,19 @@ public function testCreateAsset(): void ->with($contentType, $languageCode) ->willReturn($contentCreateStruct); + $matcher = self::exactly(2); $contentCreateStruct - ->expects(self::at(0)) + ->expects($matcher) ->method('setField') - ->with($this->mappings['name_field_identifier'], $name); - - $contentCreateStruct - ->expects(self::at(1)) - ->method('setField') - ->with($this->mappings['content_field_identifier'], $value); + ->willReturnCallback(function (string $fieldDefIdentifier, mixed $actualValue, ?string $language = null) use ($matcher, $name, $value): void { + if ($matcher->numberOfInvocations() === 1) { + self::assertSame($this->mappings['name_field_identifier'], $fieldDefIdentifier); + self::assertSame($name, $actualValue); + } else { + self::assertSame($this->mappings['content_field_identifier'], $fieldDefIdentifier); + self::assertSame($value, $actualValue); + } + }); $this->locationService ->expects(self::once()) @@ -208,9 +213,7 @@ public function testGetAssetValueThrowsInvalidArgumentException(): void $mapper->getAssetField($content); } - /** - * @dataProvider dataProviderForIsAsset - */ + #[DataProvider('dataProviderForIsAsset')] public function testIsAsset(int $contentContentTypeId, int $assetContentTypeId, bool $expected): void { $assetContentType = new ContentType([ @@ -230,7 +233,7 @@ public function testIsAsset(int $contentContentTypeId, int $assetContentTypeId, self::assertEquals($expected, $actual); } - public function dataProviderForIsAsset(): array + public static function dataProviderForIsAsset(): array { return [ [487, 487, true], @@ -280,7 +283,7 @@ private function createMapper(): AssetMapper private function createPartialMapper(array $methods = []): AssetMapper { - return $this + $builder = $this ->getMockBuilder(AssetMapper::class) ->setConstructorArgs([ $this->contentService, @@ -290,9 +293,12 @@ private function createPartialMapper(array $methods = []): AssetMapper ]) ->disableOriginalClone() ->disableArgumentCloning() - ->disallowMockingUnknownTypes() - ->setMethods($methods) - ->getMock(); + ->disallowMockingUnknownTypes(); + if ($methods !== []) { + $builder->onlyMethods(array_values($methods)); + } + + return $builder->getMock(); } private function createContentWithId(int $id): Content diff --git a/tests/lib/FieldType/ImageAssetTest.php b/tests/lib/FieldType/ImageAssetTest.php index 430fcda201..10714580aa 100644 --- a/tests/lib/FieldType/ImageAssetTest.php +++ b/tests/lib/FieldType/ImageAssetTest.php @@ -20,13 +20,16 @@ use Ibexa\Core\Base\Exceptions\InvalidArgumentException; use Ibexa\Core\FieldType\Image\Value; use Ibexa\Core\FieldType\ImageAsset; +use Ibexa\Core\FieldType\Relation\Type; use Ibexa\Core\FieldType\ValidationError; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\MockObject\MockObject; -/** - * @group fieldType - * @group ibexa_image_asset - */ +#[CoversClass(Type::class)] +#[Group('fieldType')] +#[Group('ibexa_image_asset')] class ImageAssetTest extends FieldTypeTestCase { private const int DESTINATION_CONTENT_ID = 14; @@ -103,7 +106,7 @@ protected function getEmptyValueExpectation(): ImageAsset\Value return new ImageAsset\Value(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { return [ [ @@ -113,13 +116,13 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { $destinationContentId = 7; yield 'null input' => [ null, - $this->getEmptyValueExpectation(), + new ImageAsset\Value(), ]; yield 'content id' => [ @@ -135,7 +138,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { $destinationContentId = 7; $alternativeText = 'The alternative text for image'; @@ -165,7 +168,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { $destinationContentId = 7; $alternativeText = 'The alternative text for image'; @@ -192,9 +195,13 @@ public function provideInputForFromHash(): iterable ]; } - public function provideInvalidDataForValidate(): iterable + public static function provideInvalidDataForValidate(): iterable { - yield from []; + yield 'no invalid data sets defined' => [ + ['__no_data__' => 'No invalid data sets for validate() defined for this FieldType.'], + new ImageAsset\Value(), + [], + ]; } public function testValidateNonAsset(): void @@ -240,25 +247,24 @@ public function testValidateNonAsset(): void ], $validationErrors); } - public function provideValidDataForValidate(): iterable + public static function provideValidDataForValidate(): iterable { yield 'empty value' => [ [], - $this->getEmptyValueExpectation(), + new ImageAsset\Value(), ]; } /** - * @dataProvider provideDataForTestValidateValidNonEmptyAssetValue - * * @param array<\Ibexa\Core\FieldType\ValidationError> $expectedValidationErrors */ + #[DataProvider('provideDataForTestValidateValidNonEmptyAssetValue')] public function testValidateValidNonEmptyAssetValue( int $fileSize, array $expectedValidationErrors ): void { $destinationContentId = 7; - $destinationContent = $this->createMock(Content::class); + $destinationContent = self::createStub(Content::class); $this->contentServiceMock ->expects(self::once()) @@ -311,7 +317,7 @@ public function testValidateValidNonEmptyAssetValue( * array<\Ibexa\Core\FieldType\ValidationError>, * }> */ - public function provideDataForTestValidateValidNonEmptyAssetValue(): iterable + public static function provideDataForTestValidateValidNonEmptyAssetValue(): iterable { yield 'No validation errors' => [ 123456, @@ -333,11 +339,11 @@ public function provideDataForTestValidateValidNonEmptyAssetValue(): iterable ]; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ 'empty_destination_content_id' => [ - $this->getEmptyValueExpectation(), + new ImageAsset\Value(), '', [], 'en_GB', @@ -351,9 +357,7 @@ public function provideDataForGetName(): array ]; } - /** - * @dataProvider provideDataForGetName - */ + #[DataProvider('provideDataForGetName')] public function testGetName( SPIValue $value, string $expected, @@ -375,8 +379,6 @@ public function testIsSearchable(): void } /** - * @covers \Ibexa\Core\FieldType\Relation\Type::getRelations - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ public function testGetRelations(): void diff --git a/tests/lib/FieldType/ImageTest.php b/tests/lib/FieldType/ImageTest.php index f806ea6fa3..984c83b6d6 100644 --- a/tests/lib/FieldType/ImageTest.php +++ b/tests/lib/FieldType/ImageTest.php @@ -16,12 +16,12 @@ use Ibexa\Core\FieldType\ValidationError; use Ibexa\Core\FieldType\Validator\FileExtensionBlackListValidator; use Ibexa\Core\FieldType\Validator\ImageValidator; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\MockObject\MockObject; -/** - * @group fieldType - * @group ibexa_float - */ +#[Group('fieldType')] +#[Group('ibexa_float')] class ImageTest extends FieldTypeTestCase { /** @var string[] */ @@ -32,7 +32,7 @@ class ImageTest extends FieldTypeTestCase ]; /** @var string[] */ - protected array $blackListedExtensions = [ + protected const array BLACK_LISTED_EXTENSIONS = [ 'php', 'php3', 'phar', @@ -42,9 +42,12 @@ class ImageTest extends FieldTypeTestCase 'pgif', ]; + /** @var string[] */ + protected array $blackListedExtensions = self::BLACK_LISTED_EXTENSIONS; + private MimeTypeDetector & MockObject $mimeTypeDetectorMock; - public function getImageInputPath(): string + public static function getImageInputPath(): string { return __DIR__ . '/../_fixtures/squirrel-developers.jpg'; } @@ -124,7 +127,7 @@ protected function getEmptyValueExpectation(): ImageValue return new ImageValue(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { return [ [ @@ -172,7 +175,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'null input' => [ null, @@ -190,12 +193,12 @@ public function provideValidInputForAcceptValue(): iterable ]; yield 'file path string' => [ - $this->getImageInputPath(), + self::getImageInputPath(), new ImageValue( [ - 'inputUri' => $this->getImageInputPath(), - 'fileName' => basename($this->getImageInputPath()), - 'fileSize' => filesize($this->getImageInputPath()), + 'inputUri' => self::getImageInputPath(), + 'fileName' => basename(self::getImageInputPath()), + 'fileSize' => filesize(self::getImageInputPath()), 'alternativeText' => null, ] ), @@ -203,40 +206,40 @@ public function provideValidInputForAcceptValue(): iterable yield 'array with all fields' => [ [ - 'id' => $this->getImageInputPath(), + 'id' => self::getImageInputPath(), 'fileName' => 'Sindelfingen-Squirrels.jpg', 'fileSize' => 23, 'alternativeText' => 'This is so Sindelfingen!', - 'uri' => 'http://' . $this->getImageInputPath(), + 'uri' => 'http://' . self::getImageInputPath(), ], new ImageValue( [ - 'id' => $this->getImageInputPath(), + 'id' => self::getImageInputPath(), 'fileName' => 'Sindelfingen-Squirrels.jpg', 'fileSize' => 23, 'alternativeText' => 'This is so Sindelfingen!', - 'uri' => 'http://' . $this->getImageInputPath(), + 'uri' => 'http://' . self::getImageInputPath(), ] ), ]; yield 'array with inputUri and custom fields' => [ [ - 'inputUri' => $this->getImageInputPath(), + 'inputUri' => self::getImageInputPath(), 'fileName' => 'My Fancy Filename', 'fileSize' => 123, ], new ImageValue( [ - 'inputUri' => $this->getImageInputPath(), + 'inputUri' => self::getImageInputPath(), 'fileName' => 'My Fancy Filename', - 'fileSize' => filesize($this->getImageInputPath()), + 'fileSize' => filesize(self::getImageInputPath()), ] ), ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { return [ [ @@ -246,24 +249,24 @@ public function provideInputForToHash(): iterable [ new ImageValue( [ - 'id' => $this->getImageInputPath(), + 'id' => self::getImageInputPath(), 'fileName' => 'Sindelfingen-Squirrels.jpg', 'fileSize' => 23, 'alternativeText' => 'This is so Sindelfingen!', 'imageId' => '123-12345', - 'uri' => 'http://' . $this->getImageInputPath(), + 'uri' => 'http://' . self::getImageInputPath(), 'width' => 123, 'height' => 456, 'mime' => 'image/jpeg', ] ), [ - 'id' => $this->getImageInputPath(), + 'id' => self::getImageInputPath(), 'fileName' => 'Sindelfingen-Squirrels.jpg', 'fileSize' => 23, 'alternativeText' => 'This is so Sindelfingen!', 'imageId' => '123-12345', - 'uri' => 'http://' . $this->getImageInputPath(), + 'uri' => 'http://' . self::getImageInputPath(), 'inputUri' => null, 'width' => 123, 'height' => 456, @@ -274,12 +277,12 @@ public function provideInputForToHash(): iterable [ new ImageValue( [ - 'inputUri' => $this->getImageInputPath(), + 'inputUri' => self::getImageInputPath(), 'fileName' => 'Sindelfingen-Squirrels.jpg', 'fileSize' => 23, 'alternativeText' => 'This is so Sindelfingen!', 'imageId' => '123-12345', - 'uri' => 'http://' . $this->getImageInputPath(), + 'uri' => 'http://' . self::getImageInputPath(), 'mime' => null, ] ), @@ -289,8 +292,8 @@ public function provideInputForToHash(): iterable 'fileSize' => 23, 'alternativeText' => 'This is so Sindelfingen!', 'imageId' => '123-12345', - 'uri' => 'http://' . $this->getImageInputPath(), - 'inputUri' => $this->getImageInputPath(), + 'uri' => 'http://' . self::getImageInputPath(), + 'inputUri' => self::getImageInputPath(), 'width' => null, 'height' => null, 'additionalData' => [], @@ -300,7 +303,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { return [ [ @@ -309,38 +312,38 @@ public function provideInputForFromHash(): iterable ], [ [ - 'id' => $this->getImageInputPath(), + 'id' => self::getImageInputPath(), 'fileName' => 'Sindelfingen-Squirrels.jpg', 'fileSize' => 23, 'alternativeText' => 'This is so Sindelfingen!', - 'uri' => 'http://' . $this->getImageInputPath(), + 'uri' => 'http://' . self::getImageInputPath(), ], new ImageValue( [ - 'id' => $this->getImageInputPath(), + 'id' => self::getImageInputPath(), 'fileName' => 'Sindelfingen-Squirrels.jpg', 'fileSize' => 23, 'alternativeText' => 'This is so Sindelfingen!', - 'uri' => 'http://' . $this->getImageInputPath(), + 'uri' => 'http://' . self::getImageInputPath(), ] ), ], // BC with 5.0 (EZP-20948). Path can be used as input instead of ID. [ [ - 'inputUri' => $this->getImageInputPath(), + 'inputUri' => self::getImageInputPath(), 'fileName' => 'Sindelfingen-Squirrels.jpg', 'fileSize' => 23, 'alternativeText' => 'This is so Sindelfingen!', - 'uri' => 'http://' . $this->getImageInputPath(), + 'uri' => 'http://' . self::getImageInputPath(), ], new ImageValue( [ - 'inputUri' => $this->getImageInputPath(), + 'inputUri' => self::getImageInputPath(), 'fileName' => 'Sindelfingen-Squirrels.jpg', 'fileSize' => 23, 'alternativeText' => 'This is so Sindelfingen!', - 'uri' => 'http://' . $this->getImageInputPath(), + 'uri' => 'http://' . self::getImageInputPath(), ] ), ], @@ -351,7 +354,7 @@ public function provideInputForFromHash(): iterable /** * @phpstan-return iterable, mixed, mixed}> */ - public function provideDataForFromPersistenceValue(): iterable + public static function provideDataForFromPersistenceValue(): iterable { yield 'width and height as empty string are converted to null' => [ [ @@ -389,9 +392,8 @@ public function provideDataForFromPersistenceValue(): iterable /** * @param array $data - * - * @dataProvider provideDataForFromPersistenceValue */ + #[DataProvider('provideDataForFromPersistenceValue')] public function testFromPersistenceValue(array $data, mixed $expectedWidth, mixed $expectedHeight): void { $fieldType = $this->getFieldTypeUnderTest(); @@ -409,10 +411,10 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_image'; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ - [$this->getEmptyValueExpectation(), '', [], 'en_GB'], + [new ImageValue(), '', [], 'en_GB'], [ new ImageValue(['fileName' => 'Sindelfingen-Squirrels.jpg']), 'Sindelfingen-Squirrels.jpg', @@ -445,7 +447,7 @@ public function provideDataForGetName(): array ]; } - public function provideValidDataForValidate(): iterable + public static function provideValidDataForValidate(): iterable { yield 'valid image within size limit' => [ [ @@ -457,9 +459,9 @@ public function provideValidDataForValidate(): iterable ], new ImageValue( [ - 'id' => $this->getImageInputPath(), - 'fileName' => basename($this->getImageInputPath()), - 'fileSize' => filesize($this->getImageInputPath()), + 'id' => self::getImageInputPath(), + 'fileName' => basename(self::getImageInputPath()), + 'fileSize' => filesize(self::getImageInputPath()), 'alternativeText' => null, 'uri' => '', ] @@ -467,7 +469,7 @@ public function provideValidDataForValidate(): iterable ]; } - public function provideInvalidDataForValidate(): iterable + public static function provideInvalidDataForValidate(): iterable { yield 'file too large' => [ [ @@ -479,9 +481,9 @@ public function provideInvalidDataForValidate(): iterable ], new ImageValue( [ - 'id' => $this->getImageInputPath(), - 'fileName' => basename($this->getImageInputPath()), - 'fileSize' => filesize($this->getImageInputPath()), + 'id' => self::getImageInputPath(), + 'fileName' => basename(self::getImageInputPath()), + 'fileSize' => filesize(self::getImageInputPath()), 'alternativeText' => null, 'uri' => '', ] @@ -519,7 +521,7 @@ public function provideInvalidDataForValidate(): iterable new ValidationError( 'A valid file is required. The following file extensions are not allowed: %extensionsBlackList%', null, - ['%extensionsBlackList%' => implode(', ', $this->blackListedExtensions)], + ['%extensionsBlackList%' => implode(', ', self::BLACK_LISTED_EXTENSIONS)], 'fileExtensionBlackList' ), new ValidationError( @@ -552,7 +554,7 @@ public function provideInvalidDataForValidate(): iterable new ValidationError( 'A valid file is required. The following file extensions are not allowed: %extensionsBlackList%', null, - ['%extensionsBlackList%' => implode(', ', $this->blackListedExtensions)], + ['%extensionsBlackList%' => implode(', ', self::BLACK_LISTED_EXTENSIONS)], 'fileExtensionBlackList' ), new ValidationError('A valid image file is required.', null, [], 'id'), @@ -588,7 +590,7 @@ public function provideInvalidDataForValidate(): iterable new ValidationError( 'A valid file is required. The following file extensions are not allowed: %extensionsBlackList%', null, - ['%extensionsBlackList%' => implode(', ', $this->blackListedExtensions)], + ['%extensionsBlackList%' => implode(', ', self::BLACK_LISTED_EXTENSIONS)], 'fileExtensionBlackList' ), new ValidationError( @@ -621,7 +623,7 @@ public function provideInvalidDataForValidate(): iterable new ValidationError( 'A valid file is required. The following file extensions are not allowed: %extensionsBlackList%', null, - ['%extensionsBlackList%' => implode(', ', $this->blackListedExtensions)], + ['%extensionsBlackList%' => implode(', ', self::BLACK_LISTED_EXTENSIONS)], 'fileExtensionBlackList' ), new ValidationError( @@ -643,9 +645,9 @@ public function provideInvalidDataForValidate(): iterable ], new ImageValue( [ - 'id' => $this->getImageInputPath(), - 'fileName' => basename($this->getImageInputPath()), - 'fileSize' => filesize($this->getImageInputPath()), + 'id' => self::getImageInputPath(), + 'fileName' => basename(self::getImageInputPath()), + 'fileSize' => filesize(self::getImageInputPath()), 'alternativeText' => null, 'uri' => '', ] @@ -670,9 +672,9 @@ public function provideInvalidDataForValidate(): iterable ], new ImageValue( [ - 'id' => $this->getImageInputPath(), - 'fileName' => basename($this->getImageInputPath()), - 'fileSize' => filesize($this->getImageInputPath()), + 'id' => self::getImageInputPath(), + 'fileName' => basename(self::getImageInputPath()), + 'fileSize' => filesize(self::getImageInputPath()), 'alternativeText' => '', 'uri' => '', ] @@ -698,9 +700,9 @@ public function provideInvalidDataForValidate(): iterable ], new ImageValue( [ - 'id' => $this->getImageInputPath(), - 'fileName' => basename($this->getImageInputPath()), - 'fileSize' => filesize($this->getImageInputPath()), + 'id' => self::getImageInputPath(), + 'fileName' => basename(self::getImageInputPath()), + 'fileSize' => filesize(self::getImageInputPath()), 'alternativeText' => '', 'uri' => '', ] @@ -722,27 +724,27 @@ public function provideInvalidDataForValidate(): iterable /** * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ - public function provideInputForValuesEqual(): iterable + public static function provideInputForValuesEqual(): iterable { yield [ [ - 'id' => $this->getImageInputPath(), + 'id' => self::getImageInputPath(), 'fileName' => 'Sindelfingen-Squirrels.jpg', 'fileSize' => 23, 'alternativeText' => 'This is so Sindelfingen!', 'imageId' => '123-12345', - 'uri' => 'http://' . $this->getImageInputPath(), + 'uri' => 'http://' . self::getImageInputPath(), 'width' => 123, 'height' => 456, ], new ImageValue( [ - 'id' => $this->getImageInputPath(), + 'id' => self::getImageInputPath(), 'fileName' => 'Sindelfingen-Squirrels.jpg', 'fileSize' => 23, 'alternativeText' => 'This is so Sindelfingen!', 'imageId' => '123-12317', - 'uri' => 'http://' . $this->getImageInputPath(), + 'uri' => 'http://' . self::getImageInputPath(), 'inputUri' => null, 'width' => 123, 'height' => 456, diff --git a/tests/lib/FieldType/IntegerTest.php b/tests/lib/FieldType/IntegerTest.php index c732a9917c..67bd6b481f 100644 --- a/tests/lib/FieldType/IntegerTest.php +++ b/tests/lib/FieldType/IntegerTest.php @@ -11,11 +11,10 @@ use Ibexa\Core\FieldType\Integer\Type as IntegerType; use Ibexa\Core\FieldType\Integer\Value as IntegerValue; use Ibexa\Core\FieldType\ValidationError; +use PHPUnit\Framework\Attributes\Group; -/** - * @group fieldType - * @group ibexa_integer - */ +#[Group('fieldType')] +#[Group('ibexa_integer')] class IntegerTest extends FieldTypeTestCase { protected function createFieldTypeUnderTest(): IntegerType @@ -52,7 +51,7 @@ protected function getEmptyValueExpectation(): IntegerValue return new IntegerValue(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { return [ [ @@ -70,7 +69,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'null input' => [ null, @@ -93,7 +92,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { return [ [ @@ -107,7 +106,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { return [ [ @@ -121,7 +120,7 @@ public function provideInputForFromHash(): iterable ]; } - public function provideValidValidatorConfiguration(): array + public static function provideValidValidatorConfiguration(): array { return [ [ @@ -166,7 +165,7 @@ public function provideValidValidatorConfiguration(): array ]; } - public function provideInvalidValidatorConfiguration(): array + public static function provideInvalidValidatorConfiguration(): array { return [ [ @@ -203,15 +202,15 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_integer'; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ - [$this->getEmptyValueExpectation(), '', [], 'en_GB'], + [new IntegerValue(), '', [], 'en_GB'], [new IntegerValue(42), '42', [], 'en_GB'], ]; } - public function provideValidDataForValidate(): iterable + public static function provideValidDataForValidate(): iterable { yield 'value within range' => [ [ @@ -226,7 +225,7 @@ public function provideValidDataForValidate(): iterable ]; } - public function provideInvalidDataForValidate(): iterable + public static function provideInvalidDataForValidate(): iterable { yield 'value below minimum' => [ [ diff --git a/tests/lib/FieldType/KeywordTest.php b/tests/lib/FieldType/KeywordTest.php index e0214b812c..b63c079264 100644 --- a/tests/lib/FieldType/KeywordTest.php +++ b/tests/lib/FieldType/KeywordTest.php @@ -11,11 +11,10 @@ use Ibexa\Core\FieldType\Keyword\Type as KeywordType; use Ibexa\Core\FieldType\Keyword\Value as KeywordValue; use Ibexa\Core\FieldType\ValidationError; +use PHPUnit\Framework\Attributes\Group; -/** - * @group fieldType - * @group ibexa_integer - */ +#[Group('fieldType')] +#[Group('ibexa_integer')] class KeywordTest extends FieldTypeTestCase { protected function createFieldTypeUnderTest(): KeywordType @@ -41,7 +40,7 @@ protected function getEmptyValueExpectation(): KeywordValue return new KeywordValue([]); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { return [ [ @@ -51,7 +50,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'null input' => [ null, @@ -79,7 +78,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { return [ [ @@ -93,7 +92,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { return [ [ @@ -112,10 +111,10 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_keyword'; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ - [$this->getEmptyValueExpectation(), '', [], 'en_GB'], + [new KeywordValue([]), '', [], 'en_GB'], [new KeywordValue(['foo', 'bar']), 'foo, bar', [], 'en_GB'], ]; } @@ -123,7 +122,7 @@ public function provideDataForGetName(): array /** * @return iterable, 1: \Ibexa\Core\FieldType\Keyword\Value}> */ - public function provideValidDataForValidate(): iterable + public static function provideValidDataForValidate(): iterable { yield 'multiple keywords' => [ [], @@ -148,7 +147,7 @@ public function provideValidDataForValidate(): iterable * 2: array<\Ibexa\Contracts\Core\FieldType\ValidationError> * }> */ - public function provideInvalidDataForValidate(): iterable + public static function provideInvalidDataForValidate(): iterable { $maxLen = KeywordType::MAX_KEYWORD_LENGTH; diff --git a/tests/lib/FieldType/MapLocationTest.php b/tests/lib/FieldType/MapLocationTest.php index d0b16cb9a3..6ed764065f 100644 --- a/tests/lib/FieldType/MapLocationTest.php +++ b/tests/lib/FieldType/MapLocationTest.php @@ -35,7 +35,7 @@ protected function getEmptyValueExpectation(): MapLocation\Value return new MapLocation\Value(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { return [ [ @@ -72,7 +72,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'null input' => [ null, @@ -137,7 +137,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { return [ [ @@ -161,7 +161,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { return [ [ @@ -190,10 +190,10 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_gmap_location'; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ - [$this->getEmptyValueExpectation(), '', [], 'en_GB'], + [new MapLocation\Value(), '', [], 'en_GB'], [new MapLocation\Value(['address' => 'Bag End, The Shire']), 'Bag End, The Shire', [], 'en_GB'], ]; } diff --git a/tests/lib/FieldType/MediaTest.php b/tests/lib/FieldType/MediaTest.php index fbc79691ca..3952d1ebda 100644 --- a/tests/lib/FieldType/MediaTest.php +++ b/tests/lib/FieldType/MediaTest.php @@ -12,11 +12,10 @@ use Ibexa\Core\FieldType\Media\Type as MediaType; use Ibexa\Core\FieldType\Media\Value as MediaValue; use Ibexa\Core\FieldType\ValidationError; +use PHPUnit\Framework\Attributes\Group; -/** - * @group fieldType - * @group ibexa_binaryfile - */ +#[Group('fieldType')] +#[Group('ibexa_binaryfile')] class MediaTest extends BinaryBaseTestCase { protected function createFieldTypeUnderTest(): MediaType @@ -42,7 +41,7 @@ protected function getSettingsSchemaExpectation(): array ]; } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { yield from parent::provideInvalidInputForAcceptValue(); @@ -72,7 +71,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'null input' => [ null, @@ -278,7 +277,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { return [ [ @@ -411,7 +410,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { return [ [ @@ -504,7 +503,7 @@ public function provideInputForFromHash(): iterable ]; } - public function provideValidFieldSettings(): iterable + public static function provideValidFieldSettings(): iterable { return [ [ @@ -523,7 +522,7 @@ public function provideValidFieldSettings(): iterable ]; } - public function provideInValidFieldSettings(): array + public static function provideInValidFieldSettings(): array { return [ [ @@ -545,7 +544,7 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_media'; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ [ @@ -563,7 +562,7 @@ public function provideDataForGetName(): array ]; } - public function provideValidDataForValidate(): iterable + public static function provideValidDataForValidate(): iterable { yield 'valid media file within size limit' => [ [ @@ -585,7 +584,7 @@ public function provideValidDataForValidate(): iterable ]; } - public function provideInvalidDataForValidate(): iterable + public static function provideInvalidDataForValidate(): iterable { yield 'file too large' => [ [ @@ -635,7 +634,7 @@ public function provideInvalidDataForValidate(): iterable new ValidationError( 'A valid file is required. The following file extensions are not allowed: %extensionsBlackList%', null, - ['%extensionsBlackList%' => implode(', ', $this->blackListedExtensions)], + ['%extensionsBlackList%' => implode(', ', self::BLACK_LISTED_EXTENSIONS)], 'fileExtensionBlackList' ), ], diff --git a/tests/lib/FieldType/RelationListTest.php b/tests/lib/FieldType/RelationListTest.php index c4d6ee6158..aaf682d1ce 100644 --- a/tests/lib/FieldType/RelationListTest.php +++ b/tests/lib/FieldType/RelationListTest.php @@ -17,6 +17,7 @@ use Ibexa\Core\FieldType\RelationList\Value; use Ibexa\Core\FieldType\ValidationError; use Ibexa\Core\Repository\Validator\TargetContentValidatorInterface; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\MockObject\MockObject; class RelationListTest extends FieldTypeTestCase @@ -131,7 +132,7 @@ protected function getEmptyValueExpectation(): Value return new Value(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { return [ [ @@ -141,7 +142,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'empty value object' => [ new Value(), @@ -164,7 +165,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { return [ [ @@ -178,7 +179,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { return [ [ @@ -192,7 +193,7 @@ public function provideInputForFromHash(): iterable ]; } - public function provideValidFieldSettings(): iterable + public static function provideValidFieldSettings(): iterable { return [ [ @@ -252,7 +253,7 @@ public function provideValidFieldSettings(): iterable ]; } - public function provideInValidFieldSettings(): array + public static function provideInValidFieldSettings(): array { return [ [ @@ -288,7 +289,7 @@ public function provideInValidFieldSettings(): array ]; } - public function provideValidValidatorConfiguration(): array + public static function provideValidValidatorConfiguration(): array { return [ [ @@ -311,7 +312,7 @@ public function provideValidValidatorConfiguration(): array ]; } - public function provideInvalidValidatorConfiguration(): array + public static function provideInvalidValidatorConfiguration(): array { return [ [ @@ -343,7 +344,7 @@ public function provideInvalidValidatorConfiguration(): array ]; } - public function provideValidDataForValidate(): iterable + public static function provideValidDataForValidate(): iterable { yield 'unlimited selection limit' => [ [ @@ -390,7 +391,7 @@ public function provideValidDataForValidate(): iterable ]; } - public function provideInvalidDataForValidate(): iterable + public static function provideInvalidDataForValidate(): iterable { yield 'selection exceeds limit' => [ [ @@ -418,15 +419,22 @@ public function testValidateNotExistingContentRelations(): void { $invalidDestinationContentId = (int) 'invalid'; $invalidDestinationContentId2 = (int) 'invalid-second'; + $matcher = self::exactly(2); $this->targetContentValidator - ->expects(self::exactly(2)) - ->method('validate') - ->withConsecutive([$invalidDestinationContentId], [$invalidDestinationContentId2]) - ->willReturnOnConsecutiveCalls( - $this->generateValidationError($invalidDestinationContentId), - $this->generateValidationError($invalidDestinationContentId2) - ); + ->expects($matcher) + ->method('validate')->willReturnCallback(function (...$parameters) use ($matcher, $invalidDestinationContentId, $invalidDestinationContentId2) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame($invalidDestinationContentId, $parameters[0]); + + return $this->generateValidationError($invalidDestinationContentId); + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame($invalidDestinationContentId2, $parameters[0]); + + return $this->generateValidationError($invalidDestinationContentId2); + } + }); $validationErrors = $this->doValidate([], new Value([$invalidDestinationContentId, $invalidDestinationContentId2])); @@ -439,17 +447,23 @@ public function testValidateInvalidContentType(): void $destinationContentId = 12; $destinationContentId2 = 13; $allowedContentTypes = ['article', 'folder']; + $matcher = $this->exactly(2); - $this->targetContentValidator - ->method('validate') - ->withConsecutive( - [$destinationContentId, $allowedContentTypes], - [$destinationContentId2, $allowedContentTypes] - ) - ->willReturnOnConsecutiveCalls( - $this->generateContentTypeValidationError('test'), - $this->generateContentTypeValidationError('test') - ); + $this->targetContentValidator->expects($matcher) + ->method('validate')->willReturnCallback(function (...$parameters) use ($matcher, $destinationContentId, $allowedContentTypes, $destinationContentId2) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame($destinationContentId, $parameters[0]); + $this->assertSame($allowedContentTypes, $parameters[1]); + + return $this->generateContentTypeValidationError('test'); + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame($destinationContentId2, $parameters[0]); + $this->assertSame($allowedContentTypes, $parameters[1]); + + return $this->generateContentTypeValidationError('test'); + } + }); $validationErrors = $this->doValidate( ['fieldSettings' => ['selectionContentTypes' => $allowedContentTypes]], @@ -500,9 +514,7 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_object_relation_list'; } - /** - * @dataProvider provideDataForGetName - */ + #[DataProvider('provideDataForGetName')] public function testGetName( SPIValue $value, string $expected, @@ -516,10 +528,10 @@ public function testGetName( self::assertSame($expected, $name); } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ - [$this->getEmptyValueExpectation(), '', [], 'en_GB'], + [new Value(), '', [], 'en_GB'], [new Value([self::DESTINATION_CONTENT_ID_14, self::DESTINATION_CONTENT_ID_22]), 'name_14_en_GB name_22_en_GB', [], 'en_GB'], [new Value([self::DESTINATION_CONTENT_ID_14, self::DESTINATION_CONTENT_ID_22]), 'Name_14_de_DE Name_22_de_DE', [], 'de_DE'], ]; diff --git a/tests/lib/FieldType/RelationTest.php b/tests/lib/FieldType/RelationTest.php index 275742017c..6f6012b731 100644 --- a/tests/lib/FieldType/RelationTest.php +++ b/tests/lib/FieldType/RelationTest.php @@ -18,6 +18,7 @@ use Ibexa\Core\FieldType\Relation\Value; use Ibexa\Core\FieldType\ValidationError; use Ibexa\Core\Repository\Validator\TargetContentValidatorInterface; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\MockObject\MockObject; class RelationTest extends FieldTypeTestCase @@ -105,7 +106,7 @@ protected function getEmptyValueExpectation(): Value return new Value(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { return [ [ @@ -115,7 +116,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'empty Value object' => [ new Value(), @@ -133,7 +134,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { return [ [ @@ -147,7 +148,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { return [ [ @@ -161,7 +162,7 @@ public function provideInputForFromHash(): iterable ]; } - public function provideValidFieldSettings(): iterable + public static function provideValidFieldSettings(): iterable { yield 'browse selection' => [ [ @@ -178,7 +179,7 @@ public function provideValidFieldSettings(): iterable ]; } - public function provideInValidFieldSettings(): array + public static function provideInValidFieldSettings(): array { return [ [ @@ -282,9 +283,7 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_object_relation'; } - /** - * @dataProvider provideDataForGetName - */ + #[DataProvider('provideDataForGetName')] public function testGetName( SPIValue $value, string $expected, @@ -300,11 +299,11 @@ public function testGetName( self::assertSame($expected, $name); } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ 'empty_destination_content_id' => [ - $this->getEmptyValueExpectation(), '', [], 'en_GB', + new Value(), '', [], 'en_GB', ], 'destination_content_id' => [ new Value(self::DESTINATION_CONTENT_ID), 'name_en_GB', [], 'en_GB', @@ -315,7 +314,7 @@ public function provideDataForGetName(): array ]; } - public function provideValidDataForValidate(): iterable + public static function provideValidDataForValidate(): iterable { yield 'valid relation' => [ [], @@ -323,7 +322,7 @@ public function provideValidDataForValidate(): iterable ]; } - public function provideInvalidDataForValidate(): iterable + public static function provideInvalidDataForValidate(): iterable { yield 'invalid relation' => [ [], diff --git a/tests/lib/FieldType/SelectionTest.php b/tests/lib/FieldType/SelectionTest.php index 88e2dac570..f938d1bc38 100644 --- a/tests/lib/FieldType/SelectionTest.php +++ b/tests/lib/FieldType/SelectionTest.php @@ -12,11 +12,11 @@ use Ibexa\Core\FieldType\Selection\Type as Selection; use Ibexa\Core\FieldType\Selection\Value as SelectionValue; use Ibexa\Core\FieldType\ValidationError; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; -/** - * @group fieldType - * @group ibexa_selection - */ +#[Group('fieldType')] +#[Group('ibexa_selection')] class SelectionTest extends FieldTypeTestCase { protected function createFieldTypeUnderTest(): Selection @@ -55,7 +55,7 @@ protected function getEmptyValueExpectation(): SelectionValue return new SelectionValue(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { return [ [ @@ -69,7 +69,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'empty array' => [ [], @@ -92,7 +92,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { return [ [ @@ -106,7 +106,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { return [ [ @@ -120,7 +120,7 @@ public function provideInputForFromHash(): iterable ]; } - public function provideValidFieldSettings(): iterable + public static function provideValidFieldSettings(): iterable { return [ [ @@ -141,7 +141,7 @@ public function provideValidFieldSettings(): iterable ]; } - public function provideInValidFieldSettings(): array + public static function provideInValidFieldSettings(): array { return [ [ @@ -164,9 +164,7 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_selection'; } - /** - * @dataProvider provideDataForGetName - */ + #[DataProvider('provideDataForGetName')] public function testGetName( SPIValue $value, string $expected, @@ -184,10 +182,10 @@ public function testGetName( self::assertSame($expected, $name); } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ - 'empty_value_and_field_settings' => [$this->getEmptyValueExpectation(), '', [], 'en_GB'], + 'empty_value_and_field_settings' => [new SelectionValue(), '', [], 'en_GB'], 'one_option' => [ new SelectionValue(['optionIndex1']), 'option_1', @@ -218,7 +216,7 @@ public function provideDataForGetName(): array ]; } - public function provideValidDataForValidate(): iterable + public static function provideValidDataForValidate(): iterable { yield 'multiple selection allowed' => [ [ @@ -279,7 +277,7 @@ public function provideValidDataForValidate(): iterable ]; } - public function provideInvalidDataForValidate(): iterable + public static function provideInvalidDataForValidate(): iterable { yield 'multiple selections when not allowed' => [ [ diff --git a/tests/lib/FieldType/TextBlockTest.php b/tests/lib/FieldType/TextBlockTest.php index b5ba551db4..f8070c9501 100644 --- a/tests/lib/FieldType/TextBlockTest.php +++ b/tests/lib/FieldType/TextBlockTest.php @@ -10,11 +10,10 @@ use Ibexa\Core\Base\Exceptions\InvalidArgumentException; use Ibexa\Core\FieldType\TextBlock\Type as TextBlockType; use Ibexa\Core\FieldType\TextBlock\Value as TextBlockValue; +use PHPUnit\Framework\Attributes\Group; -/** - * @group fieldType - * @group ibexa_text - */ +#[Group('fieldType')] +#[Group('ibexa_text')] final class TextBlockTest extends FieldTypeTestCase { private const string SAMPLE_TEXT_LINE_VALUE = ' sindelfingen '; @@ -47,7 +46,7 @@ protected function getEmptyValueExpectation(): TextBlockValue return new TextBlockValue(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { yield [ 23, @@ -55,7 +54,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'null input' => [ null, @@ -88,7 +87,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { yield 'empty value' => [ new TextBlockValue(), @@ -101,7 +100,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { yield 'empty string' => [ '', @@ -114,7 +113,7 @@ public function provideInputForFromHash(): iterable ]; } - public function provideValidFieldSettings(): iterable + public static function provideValidFieldSettings(): iterable { yield 'empty settings' => [ [], @@ -127,7 +126,7 @@ public function provideValidFieldSettings(): iterable ]; } - public function provideInValidFieldSettings(): array + public static function provideInValidFieldSettings(): array { return [ [ @@ -149,10 +148,10 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_text'; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ - [$this->getEmptyValueExpectation(), '', [], 'en_GB'], + [new TextBlockValue(), '', [], 'en_GB'], [new TextBlockValue('This is a piece of text'), 'This is a piece of text', [], 'en_GB'], ]; } diff --git a/tests/lib/FieldType/TextLineTest.php b/tests/lib/FieldType/TextLineTest.php index 586161cfb3..93631ac5c9 100644 --- a/tests/lib/FieldType/TextLineTest.php +++ b/tests/lib/FieldType/TextLineTest.php @@ -11,11 +11,10 @@ use Ibexa\Core\FieldType\TextLine\Type as TextLineType; use Ibexa\Core\FieldType\TextLine\Value as TextLineValue; use Ibexa\Core\FieldType\ValidationError; +use PHPUnit\Framework\Attributes\Group; -/** - * @group fieldType - * @group ibexa_string - */ +#[Group('fieldType')] +#[Group('ibexa_string')] final class TextLineTest extends FieldTypeTestCase { private const string STRING_TOO_SHORT_EXPECTED_SINGULAR_MESSAGE = 'The string cannot be shorter than %size% character.'; @@ -57,7 +56,7 @@ protected function getEmptyValueExpectation(): TextLineValue return new TextLineValue(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { return [ [ @@ -67,7 +66,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'null input' => [ null, @@ -115,7 +114,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { return [ [ @@ -133,7 +132,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { return [ [ @@ -151,7 +150,7 @@ public function provideInputForFromHash(): iterable ]; } - public function provideValidValidatorConfiguration(): array + public static function provideValidValidatorConfiguration(): array { return [ [ @@ -196,7 +195,7 @@ public function provideValidValidatorConfiguration(): array ]; } - public function provideInvalidValidatorConfiguration(): array + public static function provideInvalidValidatorConfiguration(): array { return [ [ @@ -255,15 +254,15 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_string'; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ - [$this->getEmptyValueExpectation(), '', [], 'en_GB'], + [new TextLineValue(), '', [], 'en_GB'], [new TextLineValue('This is a line of text'), 'This is a line of text', [], 'en_GB'], ]; } - public function provideValidDataForValidate(): iterable + public static function provideValidDataForValidate(): iterable { yield 'string within length limits' => [ [ @@ -300,7 +299,7 @@ public function provideValidDataForValidate(): iterable ]; } - public function provideInvalidDataForValidate(): iterable + public static function provideInvalidDataForValidate(): iterable { yield 'string too short' => [ [ diff --git a/tests/lib/FieldType/TimeTest.php b/tests/lib/FieldType/TimeTest.php index 6703cbd6ac..c13ac8736f 100644 --- a/tests/lib/FieldType/TimeTest.php +++ b/tests/lib/FieldType/TimeTest.php @@ -11,11 +11,10 @@ use Ibexa\Core\Base\Exceptions\InvalidArgumentException; use Ibexa\Core\FieldType\Time\Type as Time; use Ibexa\Core\FieldType\Time\Value as TimeValue; +use PHPUnit\Framework\Attributes\Group; -/** - * @group fieldType - * @group ibexa_time - */ +#[Group('fieldType')] +#[Group('ibexa_time')] class TimeTest extends FieldTypeTestCase { protected function createFieldTypeUnderTest(): Time @@ -50,7 +49,7 @@ protected function getEmptyValueExpectation(): TimeValue return new TimeValue(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { return [ [ @@ -60,7 +59,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { $dateTime = new DateTime(); // change timezone to UTC (+00:00) to be able to calculate proper TimeValue @@ -106,7 +105,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { return [ [ @@ -124,7 +123,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { return [ [ @@ -142,7 +141,7 @@ public function provideInputForFromHash(): iterable ]; } - public function provideValidFieldSettings(): iterable + public static function provideValidFieldSettings(): iterable { return [ [ @@ -163,7 +162,7 @@ public function provideValidFieldSettings(): iterable ]; } - public function provideInValidFieldSettings(): array + public static function provideInValidFieldSettings(): array { return [ [ @@ -186,10 +185,10 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_time'; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ - [$this->getEmptyValueExpectation(), '', [], 'en_GB'], + [new TimeValue(), '', [], 'en_GB'], [new TimeValue(200), '12:03:20 am', [], 'en_GB'], ]; } diff --git a/tests/lib/FieldType/Url/Gateway/DoctrineStorageTest.php b/tests/lib/FieldType/Url/Gateway/DoctrineStorageTest.php index f6848c42b6..cd16e6037e 100644 --- a/tests/lib/FieldType/Url/Gateway/DoctrineStorageTest.php +++ b/tests/lib/FieldType/Url/Gateway/DoctrineStorageTest.php @@ -12,18 +12,14 @@ use Ibexa\Core\FieldType\Url\UrlStorage\Gateway\DoctrineStorage; use Ibexa\Core\Persistence\Legacy\URL\Gateway\DoctrineDatabase; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\FieldType\Url\UrlStorage\Gateway\DoctrineStorage - */ +#[CoversClass(DoctrineStorage::class)] class DoctrineStorageTest extends TestCase { private DoctrineStorage $storageGateway; - /** - * @covers \Ibexa\Core\FieldType\Url\UrlStorage\Gateway\DoctrineStorage::getIdUrlMap - */ - public function testGetIdUrlMap() + public function testGetIdUrlMap(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urls.php'); @@ -40,10 +36,7 @@ public function testGetIdUrlMap() ); } - /** - * @covers \Ibexa\Core\FieldType\Url\UrlStorage\Gateway\DoctrineStorage::getUrlIdMap - */ - public function testGetUrlIdMap() + public function testGetUrlIdMap(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urls.php'); @@ -64,10 +57,7 @@ public function testGetUrlIdMap() ); } - /** - * @covers \Ibexa\Core\FieldType\Url\UrlStorage\Gateway\DoctrineStorage::insertUrl - */ - public function testInsertUrl() + public function testInsertUrl(): void { $gateway = $this->getStorageGateway(); @@ -110,10 +100,7 @@ public function testInsertUrl() self::assertEquals($expected, $result); } - /** - * @covers \Ibexa\Core\FieldType\Url\UrlStorage\Gateway\DoctrineStorage::linkUrl - */ - public function testLinkUrl() + public function testLinkUrl(): void { $gateway = $this->getStorageGateway(); @@ -147,10 +134,7 @@ public function testLinkUrl() self::assertEquals($expected, $result); } - /** - * @covers \Ibexa\Core\FieldType\Url\UrlStorage\Gateway\DoctrineStorage::unlinkUrl - */ - public function testUnlinkUrl() + public function testUnlinkUrl(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urls.php'); diff --git a/tests/lib/FieldType/Url/UrlStorageTest.php b/tests/lib/FieldType/Url/UrlStorageTest.php index 9d8c0c9857..5e3a930190 100644 --- a/tests/lib/FieldType/Url/UrlStorageTest.php +++ b/tests/lib/FieldType/Url/UrlStorageTest.php @@ -17,7 +17,7 @@ class UrlStorageTest extends TestCase { - public function testStoreFieldDataWithExistingUrl() + public function testStoreFieldDataWithExistingUrl(): void { $versionInfo = new VersionInfo(['versionNo' => 24]); $fieldValue = new FieldValue(['externalData' => 'http://ibexa.co']); @@ -51,7 +51,7 @@ public function testStoreFieldDataWithExistingUrl() self::assertEquals(12, $field->value->data['urlId']); } - public function testStoreFieldDataWithNewUrl() + public function testStoreFieldDataWithNewUrl(): void { $versionInfo = new VersionInfo(['versionNo' => 24]); $fieldValue = new FieldValue(['externalData' => 'http://ibexa.co']); @@ -91,7 +91,7 @@ public function testStoreFieldDataWithNewUrl() self::assertEquals(12, $field->value->data['urlId']); } - public function testStoreFieldDataWithEmptyUrl() + public function testStoreFieldDataWithEmptyUrl(): void { $versionInfo = new VersionInfo(['versionNo' => 24]); $fieldValue = new FieldValue(['externalData' => '']); @@ -121,7 +121,7 @@ public function testStoreFieldDataWithEmptyUrl() self::assertNull($field->value->data); } - public function testGetFieldData() + public function testGetFieldData(): void { $versionInfo = new VersionInfo(); $fieldValue = new FieldValue(['data' => ['urlId' => 12]]); @@ -140,7 +140,7 @@ public function testGetFieldData() self::assertEquals('http://ibexa.co', $field->value->externalData); } - public function testGetFieldDataNotFound() + public function testGetFieldDataNotFound(): void { $versionInfo = new VersionInfo(); $fieldValue = new FieldValue(['data' => ['urlId' => 12]]); @@ -165,7 +165,7 @@ public function testGetFieldDataNotFound() self::assertEquals('', $field->value->externalData); } - public function testGetFieldDataWithEmptyUrlId() + public function testGetFieldDataWithEmptyUrlId(): void { $versionInfo = new VersionInfo(); $fieldValue = new FieldValue(['data' => ['urlId' => null]]); @@ -187,24 +187,27 @@ public function testGetFieldDataWithEmptyUrlId() self::assertNull($field->value->externalData); } - public function testDeleteFieldData() + public function testDeleteFieldData(): void { $versionInfo = new VersionInfo(['versionNo' => 24]); $fieldIds = [12, 23, 34]; $gateway = $this->getGatewayMock(); - foreach ($fieldIds as $index => $id) { - $gateway - ->expects(self::at($index)) - ->method('unlinkUrl') - ->with($id, 24); - } + $matcher = self::exactly(count($fieldIds)); + $gateway + ->expects($matcher) + ->method('unlinkUrl') + ->willReturnCallback(static function ($actualId, $actualVersionNo, array $excludeUrlIds = []) use ($matcher, $fieldIds): void { + $index = $matcher->numberOfInvocations() - 1; + self::assertSame($fieldIds[$index], $actualId); + self::assertSame(24, $actualVersionNo); + }); $storage = $this->getPartlyMockedStorage($gateway); $storage->deleteFieldData($versionInfo, $fieldIds); } - public function testHasFieldData() + public function testHasFieldData(): void { $storage = $this->getPartlyMockedStorage($this->getGatewayMock()); @@ -219,13 +222,13 @@ public function testHasFieldData() protected function getPartlyMockedStorage(StorageGatewayInterface $gateway) { return $this->getMockBuilder(UrlStorage::class) - ->setMethods(null) ->setConstructorArgs( [ $gateway, $this->getLoggerMock(), ] ) + ->onlyMethods([]) ->getMock(); } diff --git a/tests/lib/FieldType/UrlTest.php b/tests/lib/FieldType/UrlTest.php index 03163e1da9..061b0d16e4 100644 --- a/tests/lib/FieldType/UrlTest.php +++ b/tests/lib/FieldType/UrlTest.php @@ -10,11 +10,10 @@ use Ibexa\Core\Base\Exceptions\InvalidArgumentException; use Ibexa\Core\FieldType\Url\Type as UrlType; use Ibexa\Core\FieldType\Url\Value as UrlValue; +use PHPUnit\Framework\Attributes\Group; -/** - * @group fieldType - * @group ibexa_url - */ +#[Group('fieldType')] +#[Group('ibexa_url')] class UrlTest extends FieldTypeTestCase { protected function createFieldTypeUnderTest(): UrlType @@ -40,7 +39,7 @@ protected function getEmptyValueExpectation(): UrlValue return new UrlValue(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { return [ [ @@ -54,7 +53,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'null input' => [ null, @@ -72,7 +71,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { return [ [ @@ -96,7 +95,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { return [ [ @@ -125,10 +124,10 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_url'; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ - [$this->getEmptyValueExpectation(), '', [], 'en_GB'], + [new UrlValue(), '', [], 'en_GB'], [new UrlValue('', 'Url text'), 'Url text', [], 'en_GB'], ]; } diff --git a/tests/lib/FieldType/UserTest.php b/tests/lib/FieldType/UserTest.php index 14936f42ac..9d490ddcb0 100644 --- a/tests/lib/FieldType/UserTest.php +++ b/tests/lib/FieldType/UserTest.php @@ -24,12 +24,14 @@ use Ibexa\Core\Repository\Values\ContentType\FieldDefinition as CoreFieldDefinition; use Ibexa\Core\Repository\Values\User\User as RepositoryUser; use Ibexa\Tests\Core\FieldType\DataProvider\UserValidatorConfigurationSchemaProvider; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\MockObject\Builder\InvocationMocker; -/** - * @group fieldType - * @group ibexa_url - */ +#[CoversClass(Type::class)] +#[Group('fieldType')] +#[Group('ibexa_url')] class UserTest extends FieldTypeTestCase { private const int UNSUPPORTED_HASH_TYPE = 0xDEADBEEF; @@ -37,9 +39,9 @@ class UserTest extends FieldTypeTestCase protected function createFieldTypeUnderTest(): UserType { $fieldType = new UserType( - $this->createMock(UserHandler::class), - $this->createMock(PasswordHashService::class), - $this->createMock(PasswordValidatorInterface::class) + self::createStub(UserHandler::class), + self::createStub(PasswordHashService::class), + self::createStub(PasswordValidatorInterface::class) ); $fieldType->setTransformationProcessor($this->getTransformationProcessorMock()); @@ -79,7 +81,7 @@ protected function getEmptyValueExpectation(): UserValue return new UserValue(); } - public function provideInvalidInputForAcceptValue(): iterable + public static function provideInvalidInputForAcceptValue(): iterable { yield [ 23, @@ -87,7 +89,7 @@ public function provideInvalidInputForAcceptValue(): iterable ]; } - public function provideValidInputForAcceptValue(): iterable + public static function provideValidInputForAcceptValue(): iterable { yield 'null input' => [ null, @@ -135,7 +137,7 @@ public function provideValidInputForAcceptValue(): iterable ]; } - public function provideInputForToHash(): iterable + public static function provideInputForToHash(): iterable { $passwordUpdatedAt = new DateTimeImmutable(); @@ -166,7 +168,7 @@ public function provideInputForToHash(): iterable ]; } - public function provideInputForFromHash(): iterable + public static function provideInputForFromHash(): iterable { yield [ null, @@ -191,27 +193,31 @@ public function provideInputForFromHash(): iterable ]; } - public function provideValidDataForValidate(): iterable + public static function provideValidDataForValidate(): iterable { - yield from []; + yield 'no valid data sets defined' => [ + ['__no_data__' => 'No valid data sets for validate() defined for this FieldType.'], + new UserValue(), + ]; } - public function provideInvalidDataForValidate(): iterable + public static function provideInvalidDataForValidate(): iterable { - yield from []; + yield 'no invalid data sets defined' => [ + ['__no_data__' => 'No invalid data sets for validate() defined for this FieldType.'], + new UserValue(), + [], + ]; } /** - * @covers \Ibexa\Core\FieldType\User\Type::validate - * - * @dataProvider providerForTestValidate - * * @param \Ibexa\Core\FieldType\User\Value $userValue * @param array $expectedValidationErrors * @param callable|null $loadByLoginBehaviorCallback * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ + #[DataProvider('providerForTestValidate')] public function testValidate( UserValue $userValue, array $expectedValidationErrors, @@ -230,8 +236,8 @@ public function testValidate( $userType = new UserType( $userHandlerMock, - $this->createMock(PasswordHashService::class), - $this->createMock(PasswordValidatorInterface::class) + self::createStub(PasswordHashService::class), + self::createStub(PasswordValidatorInterface::class) ); $fieldSettings = [ @@ -329,8 +335,8 @@ public function testEmailAlreadyTaken(): void $userType = new UserType( $userHandlerMock, - $this->createMock(PasswordHashService::class), - $this->createMock(PasswordValidatorInterface::class) + self::createStub(PasswordHashService::class), + self::createStub(PasswordValidatorInterface::class) ); $fieldSettings = [ @@ -354,19 +360,15 @@ public function testEmailAlreadyTaken(): void ], $validationErrors); } - /** - * @covers \Ibexa\Core\FieldType\User\Type::toPersistenceValue - * - * @dataProvider providerForTestCreatePersistenceValue - */ + #[DataProvider('providerForTestCreatePersistenceValue')] public function testCreatePersistenceValue(array $userValueDate, array $expectedFieldValueExternalData): void { $passwordHashServiceMock = $this->createMock(PasswordHashService::class); $passwordHashServiceMock->method('getDefaultHashType')->willReturn(RepositoryUser::DEFAULT_PASSWORD_HASH); $userType = new UserType( - $this->createMock(UserHandler::class), + self::createStub(UserHandler::class), $passwordHashServiceMock, - $this->createMock(PasswordValidatorInterface::class) + self::createStub(PasswordValidatorInterface::class) ); $value = new UserValue($userValueDate); @@ -382,7 +384,7 @@ public function testCreatePersistenceValue(array $userValueDate, array $expected self::assertEquals($expected, $fieldValue); } - public function providerForTestCreatePersistenceValue(): iterable + public static function providerForTestCreatePersistenceValue(): iterable { $passwordUpdatedAt = new DateTimeImmutable(); $userData = [ @@ -456,8 +458,8 @@ public function testEmailFreeToUse(): void $userType = new UserType( $userHandlerMock, - $this->createMock(PasswordHashService::class), - $this->createMock(PasswordValidatorInterface::class) + self::createStub(PasswordHashService::class), + self::createStub(PasswordValidatorInterface::class) ); $fieldSettings = [ @@ -479,7 +481,7 @@ public function testEmailFreeToUse(): void * * @return array data sets for testValidate method ($userValue, $expectedValidationErrors, $loadByLoginBehaviorCallback) */ - public function providerForTestValidate(): array + public static function providerForTestValidate(): array { return [ [ @@ -534,9 +536,9 @@ static function (InvocationMocker $loadByLoginInvocationMocker) { 'username' ), ], - function (InvocationMocker $loadByLoginInvocationMocker) { + static function (InvocationMocker $loadByLoginInvocationMocker) { $loadByLoginInvocationMocker->willReturn( - $this->createMock(UserValue::class) + self::createStub(UserValue::class) ); }, ], @@ -557,7 +559,7 @@ function (InvocationMocker $loadByLoginInvocationMocker) { ]; } - public function provideValidFieldSettings(): iterable + public static function provideValidFieldSettings(): iterable { return [ [ @@ -585,7 +587,7 @@ public function provideValidFieldSettings(): iterable ]; } - public function provideInValidFieldSettings(): array + public static function provideInValidFieldSettings(): array { return [ [ @@ -613,10 +615,10 @@ protected function provideFieldTypeIdentifier(): string return 'ibexa_user'; } - public function provideDataForGetName(): array + public static function provideDataForGetName(): array { return [ - [$this->getEmptyValueExpectation(), '', [], 'en_GB'], + [new UserValue(), '', [], 'en_GB'], [new UserValue(['login' => 'johndoe']), 'johndoe', [], 'en_GB'], ]; } @@ -638,8 +640,8 @@ private function mockValidationErrors(UserValue $validateUserValue): array $userType = new UserType( $userHandlerMock, - $this->createMock(PasswordHashService::class), - $this->createMock(PasswordValidatorInterface::class) + self::createStub(PasswordHashService::class), + self::createStub(PasswordValidatorInterface::class) ); $fieldSettings = [ diff --git a/tests/lib/FieldType/ValidationErrorTest.php b/tests/lib/FieldType/ValidationErrorTest.php index fe2367e549..5188d36e02 100644 --- a/tests/lib/FieldType/ValidationErrorTest.php +++ b/tests/lib/FieldType/ValidationErrorTest.php @@ -9,16 +9,14 @@ namespace Ibexa\Tests\Core\FieldType; use Ibexa\Core\FieldType\ValidationError; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\FieldType\ValidationError - */ +#[CoversClass(ValidationError::class)] final class ValidationErrorTest extends TestCase { - /** - * @dataProvider getDataForTestGetTranslatableMessage - */ + #[DataProvider('getDataForTestGetTranslatableMessage')] public function testGetTranslatableMessage(ValidationError $validationError, string $expectedMessage): void { self::assertSame($expectedMessage, (string)$validationError->getTranslatableMessage()); diff --git a/tests/lib/FieldType/Validator/BaseNumericValidatorTestCase.php b/tests/lib/FieldType/Validator/BaseNumericValidatorTestCase.php index a664bfc87c..c90d506c05 100644 --- a/tests/lib/FieldType/Validator/BaseNumericValidatorTestCase.php +++ b/tests/lib/FieldType/Validator/BaseNumericValidatorTestCase.php @@ -12,6 +12,7 @@ use Ibexa\Contracts\Core\Repository\Exceptions\PropertyNotFoundException; use Ibexa\Contracts\Core\Repository\Values\Translation\Message; use Ibexa\Core\FieldType\Validator; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; /** @@ -35,33 +36,33 @@ abstract class BaseNumericValidatorTestCase extends TestCase */ abstract protected function getValidatorInstance(): Validator; - abstract protected function getMinNumericValueName(): string; + abstract protected static function getMinNumericValueName(): string; - abstract protected function getMaxNumericValueName(): string; + abstract protected static function getMaxNumericValueName(): string; /** * @return iterable */ - abstract public function providerForValidateConstraintsOK(): iterable; + abstract public static function providerForValidateConstraintsOK(): iterable; /** * @return iterable>> */ abstract public static function providerForConstraintsInitializeSetGet(): iterable; - abstract protected function getIncorrectNumericTypeValidationMessage(string $parameterName): string; + abstract protected static function getIncorrectNumericTypeValidationMessage(string $parameterName): string; /** * @return iterable, array}> */ - final public function providerForValidateConstraintsKO(): iterable + final public static function providerForValidateConstraintsKO(): iterable { - $minNumericValueName = $this->getMinNumericValueName(); - $minValueNumericTypeValidationMessage = $this->getIncorrectNumericTypeValidationMessage( + $minNumericValueName = static::getMinNumericValueName(); + $minValueNumericTypeValidationMessage = static::getIncorrectNumericTypeValidationMessage( $minNumericValueName ); - $maxNumericValueName = $this->getMaxNumericValueName(); - $maxValueNumericTypeValidationMessage = $this->getIncorrectNumericTypeValidationMessage( + $maxNumericValueName = static::getMaxNumericValueName(); + $maxValueNumericTypeValidationMessage = static::getIncorrectNumericTypeValidationMessage( $maxNumericValueName ); @@ -136,9 +137,8 @@ final public function providerForValidateConstraintsKO(): iterable /** * @param array $constraints * @param array $expectedMessages - * - * @dataProvider providerForValidateConstraintsKO */ + #[DataProvider('providerForValidateConstraintsKO')] final public function testValidateConstraintsWrongValues(array $constraints, array $expectedMessages): void { $validator = $this->getValidatorInstance(); @@ -175,10 +175,9 @@ final public function testGetBadConstraint(): void } /** - * @dataProvider providerForValidateConstraintsOK - * * @param array{min?: ?scalar, max?: ?scalar} $data */ + #[DataProvider('providerForValidateConstraintsOK')] public function testValidateConstraintsCorrectValues(array $data): void { $validator = $this->getValidatorInstance(); @@ -197,12 +196,11 @@ public function testValidateConstraintsCorrectValues(array $data): void } /** - * @dataProvider providerForConstraintsInitializeSetGet - * * @param array $constraints * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\PropertyNotFoundException */ + #[DataProvider('providerForConstraintsInitializeSetGet')] final public function testConstraintsInitializeGet(array $constraints): void { $minNumericValueName = $this->getMinNumericValueName(); @@ -216,10 +214,9 @@ final public function testConstraintsInitializeGet(array $constraints): void } /** - * @dataProvider providerForConstraintsInitializeSetGet - * * @param array $constraints */ + #[DataProvider('providerForConstraintsInitializeSetGet')] final public function testConstraintsSetGet(array $constraints): void { $minNumericValueName = $this->getMinNumericValueName(); diff --git a/tests/lib/FieldType/Validator/FloatValueValidatorTest.php b/tests/lib/FieldType/Validator/FloatValueValidatorTest.php index 92b8db737c..b63f0822ea 100644 --- a/tests/lib/FieldType/Validator/FloatValueValidatorTest.php +++ b/tests/lib/FieldType/Validator/FloatValueValidatorTest.php @@ -12,15 +12,16 @@ use Ibexa\Core\FieldType\Float\Value as FloatValue; use Ibexa\Core\FieldType\Validator; use Ibexa\Core\FieldType\Validator\FloatValueValidator; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; /** - * @covers \Ibexa\Core\FieldType\Validator\FloatValueValidator - * * @extends BaseNumericValidatorTestCase - * - * @group fieldType - * @group validator */ +#[CoversClass(FloatValueValidator::class)] +#[Group('fieldType')] +#[Group('validator')] final class FloatValueValidatorTest extends BaseNumericValidatorTestCase { private const float MIN_FLOAT_VALUE = 1.4285714285714; @@ -31,22 +32,22 @@ protected function getValidatorInstance(): Validator return new FloatValueValidator(); } - protected function getMinNumericValueName(): string + protected static function getMinNumericValueName(): string { return 'minFloatValue'; } - protected function getMaxNumericValueName(): string + protected static function getMaxNumericValueName(): string { return 'maxFloatValue'; } - protected function getMinFloatValue(): float + protected static function getMinFloatValue(): float { return self::MIN_FLOAT_VALUE; } - protected function getMaxFloatValue(): float + protected static function getMaxFloatValue(): float { return self::MAX_FLOAT_VALUE; } @@ -93,9 +94,7 @@ public function testInitializeBadConstraint(): void ); } - /** - * @dataProvider providerForValidateOK - */ + #[DataProvider('providerForValidateOK')] public function testValidateCorrectValues(float $value): void { $validator = $this->getValidatorInstance(); @@ -108,7 +107,7 @@ public function testValidateCorrectValues(float $value): void /** * @return list */ - public function providerForValidateOK(): array + public static function providerForValidateOK(): array { return [ [ @@ -129,9 +128,7 @@ public function providerForValidateOK(): array ]; } - /** - * @dataProvider providerForValidateKO - */ + #[DataProvider('providerForValidateKO')] public function testValidateWrongValues(float $value, string $message): void { $validator = $this->getValidatorInstance(); @@ -144,20 +141,20 @@ public function testValidateWrongValues(float $value, string $message): void /** * @return list */ - public function providerForValidateKO(): array + public static function providerForValidateKO(): array { return [ [-self::MIN_FLOAT_VALUE, strtr( self::VALUE_TOO_LOW_VALIDATION_MESSAGE, - [self::SIZE_PARAM => $this->getMinFloatValue()] + [self::SIZE_PARAM => self::getMinFloatValue()] )], - [0, strtr(self::VALUE_TOO_LOW_VALIDATION_MESSAGE, [self::SIZE_PARAM => $this->getMinFloatValue()])], - [1.4142857142857, strtr(self::VALUE_TOO_LOW_VALIDATION_MESSAGE, [self::SIZE_PARAM => $this->getMinFloatValue()])], - [1.5857142857143, strtr(self::VALUE_TOO_HIGH_VALIDATION_MESSAGE, [self::SIZE_PARAM => $this->getMaxFloatValue()])], + [0, strtr(self::VALUE_TOO_LOW_VALIDATION_MESSAGE, [self::SIZE_PARAM => self::getMinFloatValue()])], + [1.4142857142857, strtr(self::VALUE_TOO_LOW_VALIDATION_MESSAGE, [self::SIZE_PARAM => self::getMinFloatValue()])], + [1.5857142857143, strtr(self::VALUE_TOO_HIGH_VALIDATION_MESSAGE, [self::SIZE_PARAM => self::getMaxFloatValue()])], ]; } - public function providerForValidateConstraintsOK(): iterable + public static function providerForValidateConstraintsOK(): iterable { yield [[]]; yield [[self::MAX => 3.2]]; @@ -168,7 +165,7 @@ public function providerForValidateConstraintsOK(): iterable yield [[self::MIN => null, self::MAX => null]]; } - protected function getIncorrectNumericTypeValidationMessage(string $parameterName): string + protected static function getIncorrectNumericTypeValidationMessage(string $parameterName): string { return sprintf( "Validator parameter '%s' value must be of numeric type", diff --git a/tests/lib/FieldType/Validator/IntegerValueValidatorTest.php b/tests/lib/FieldType/Validator/IntegerValueValidatorTest.php index 0caa83823b..a0db706ca8 100644 --- a/tests/lib/FieldType/Validator/IntegerValueValidatorTest.php +++ b/tests/lib/FieldType/Validator/IntegerValueValidatorTest.php @@ -12,15 +12,16 @@ use Ibexa\Core\FieldType\Integer\Value as IntegerValue; use Ibexa\Core\FieldType\Validator; use Ibexa\Core\FieldType\Validator\IntegerValueValidator; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; /** - * @covers \Ibexa\Core\FieldType\Validator\IntegerValueValidator - * * @extends BaseNumericValidatorTestCase - * - * @group fieldType - * @group validator */ +#[CoversClass(IntegerValueValidator::class)] +#[Group('fieldType')] +#[Group('validator')] final class IntegerValueValidatorTest extends BaseNumericValidatorTestCase { protected function getValidatorInstance(): Validator @@ -28,22 +29,22 @@ protected function getValidatorInstance(): Validator return new IntegerValueValidator(); } - protected function getMinNumericValueName(): string + protected static function getMinNumericValueName(): string { return 'minIntegerValue'; } - protected function getMaxNumericValueName(): string + protected static function getMaxNumericValueName(): string { return 'maxIntegerValue'; } - protected function getMinIntegerValue(): int + protected static function getMinIntegerValue(): int { return 10; } - protected function getMaxIntegerValue(): int + protected static function getMaxIntegerValue(): int { return 15; } @@ -87,9 +88,7 @@ public function testInitializeBadConstraint(): void ); } - /** - * @dataProvider providerForValidateOK - */ + #[DataProvider('providerForValidateOK')] public function testValidateCorrectValues(int $value): void { $validator = $this->getValidatorInstance(); @@ -102,7 +101,7 @@ public function testValidateCorrectValues(int $value): void /** * @return list */ - public function providerForValidateOK(): array + public static function providerForValidateOK(): array { return [ [10], @@ -116,9 +115,8 @@ public function providerForValidateOK(): array /** * Tests validating a wrong value. - * - * @dataProvider providerForValidateKO */ + #[DataProvider('providerForValidateKO')] public function testValidateWrongValues(int $value, string $message): void { $validator = $this->getValidatorInstance(); @@ -131,17 +129,17 @@ public function testValidateWrongValues(int $value, string $message): void /** * @return list */ - public function providerForValidateKO(): array + public static function providerForValidateKO(): array { return [ - [-12, strtr(self::VALUE_TOO_LOW_VALIDATION_MESSAGE, [self::SIZE_PARAM => $this->getMinIntegerValue()])], - [0, strtr(self::VALUE_TOO_LOW_VALIDATION_MESSAGE, [self::SIZE_PARAM => $this->getMinIntegerValue()])], - [9, strtr(self::VALUE_TOO_LOW_VALIDATION_MESSAGE, [self::SIZE_PARAM => $this->getMinIntegerValue()])], - [16, strtr(self::VALUE_TOO_HIGH_VALIDATION_MESSAGE, [self::SIZE_PARAM => $this->getMaxIntegerValue()])], + [-12, strtr(self::VALUE_TOO_LOW_VALIDATION_MESSAGE, [self::SIZE_PARAM => self::getMinIntegerValue()])], + [0, strtr(self::VALUE_TOO_LOW_VALIDATION_MESSAGE, [self::SIZE_PARAM => self::getMinIntegerValue()])], + [9, strtr(self::VALUE_TOO_LOW_VALIDATION_MESSAGE, [self::SIZE_PARAM => self::getMinIntegerValue()])], + [16, strtr(self::VALUE_TOO_HIGH_VALIDATION_MESSAGE, [self::SIZE_PARAM => self::getMaxIntegerValue()])], ]; } - public function providerForValidateConstraintsOK(): iterable + public static function providerForValidateConstraintsOK(): iterable { yield [[]]; yield [[self::MIN => 5]]; @@ -152,7 +150,7 @@ public function providerForValidateConstraintsOK(): iterable yield [[self::MIN => 6, self::MAX => 8]]; } - protected function getIncorrectNumericTypeValidationMessage(string $parameterName): string + protected static function getIncorrectNumericTypeValidationMessage(string $parameterName): string { return sprintf( "Validator parameter '%s' value must be of integer type", diff --git a/tests/lib/FieldType/Validator/StringLengthValidatorTest.php b/tests/lib/FieldType/Validator/StringLengthValidatorTest.php index e34506e7ef..6741ca1e0d 100644 --- a/tests/lib/FieldType/Validator/StringLengthValidatorTest.php +++ b/tests/lib/FieldType/Validator/StringLengthValidatorTest.php @@ -15,14 +15,14 @@ use Ibexa\Core\FieldType\TextLine\Value as TextLineValue; use Ibexa\Core\FieldType\Validator; use Ibexa\Core\FieldType\Validator\StringLengthValidator; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\FieldType\Validator\StringLengthValidator - * - * @group fieldType - * @group validator - */ +#[CoversClass(StringLengthValidator::class)] +#[Group('fieldType')] +#[Group('validator')] final class StringLengthValidatorTest extends TestCase { private const string STRING_TOO_SHORT_VALIDATION_MESSAGE = 'The string cannot be shorter than 5 characters.'; @@ -32,12 +32,12 @@ final class StringLengthValidatorTest extends TestCase private const string MAX_STR_LEN_INT_TYPE_VALIDATION_MESSAGE = "Validator parameter 'maxStringLength' value must be of integer type"; private const string WRONG_MAX_STR_LEN_VALUE = 'ten billion characters'; - protected function getMinStringLength(): int + protected static function getMinStringLength(): int { return 5; } - protected function getMaxStringLength(): int + protected static function getMaxStringLength(): int { return 10; } @@ -127,9 +127,7 @@ public function testGetBadConstraint(): void $validator->unexisting; } - /** - * @dataProvider providerForValidateOK - */ + #[DataProvider('providerForValidateOK')] public function testValidateCorrectValues(string $value): void { $validator = new StringLengthValidator(); @@ -142,7 +140,7 @@ public function testValidateCorrectValues(string $value): void /** * @return list */ - public function providerForValidateOK(): array + public static function providerForValidateOK(): array { return [ ['hello'], @@ -152,9 +150,7 @@ public function providerForValidateOK(): array ]; } - /** - * @dataProvider providerForValidateKO - */ + #[DataProvider('providerForValidateKO')] public function testValidateWrongValues( string $value, string $expectedMessage, @@ -184,41 +180,41 @@ public function testValidateWrongValues( /** * @return iterable */ - public function providerForValidateKO(): iterable + public static function providerForValidateKO(): iterable { yield 'empty string' => [ '', self::STRING_TOO_SHORT_VALIDATION_MESSAGE, - $this->getMinStringLength(), - $this->getMaxStringLength(), + self::getMinStringLength(), + self::getMaxStringLength(), ]; yield 'too short string' => [ 'Hi!', self::STRING_TOO_SHORT_VALIDATION_MESSAGE, - $this->getMinStringLength(), - $this->getMaxStringLength(), + self::getMinStringLength(), + self::getMaxStringLength(), ]; yield 'too long string' => [ '0123456789!', self::STRING_TOO_LONG_VALIDATION_MESSAGE, - $this->getMinStringLength(), - $this->getMaxStringLength(), + self::getMinStringLength(), + self::getMaxStringLength(), ]; yield 'too short string with special characters' => [ 'ABC♔', self::STRING_TOO_SHORT_VALIDATION_MESSAGE, - $this->getMinStringLength(), - $this->getMaxStringLength(), + self::getMinStringLength(), + self::getMaxStringLength(), ]; yield 'too short string, singular form validation message' => [ '', 'The string cannot be shorter than 1 character.', 1, - $this->getMaxStringLength(), + self::getMaxStringLength(), ]; yield 'too long string, singular form validation message' => [ @@ -231,9 +227,8 @@ public function providerForValidateKO(): iterable /** * @param array $constraints - * - * @dataProvider providerForValidateConstraintsOK */ + #[DataProvider('providerForValidateConstraintsOK')] public function testValidateConstraintsCorrectValues(array $constraints): void { $validator = new StringLengthValidator(); @@ -246,7 +241,7 @@ public function testValidateConstraintsCorrectValues(array $constraints): void /** * @return list>> */ - public function providerForValidateConstraintsOK(): array + public static function providerForValidateConstraintsOK(): array { return [ [ @@ -278,11 +273,10 @@ public function providerForValidateConstraintsOK(): array } /** - * @dataProvider providerForValidateConstraintsKO - * * @param array $constraints * @param string[] $expectedMessages */ + #[DataProvider('providerForValidateConstraintsKO')] public function testValidateConstraintsWrongValues(array $constraints, array $expectedMessages): void { $validator = new StringLengthValidator(); @@ -303,7 +297,7 @@ public function testValidateConstraintsWrongValues(array $constraints, array $ex /** * @return list, string[]}> */ - public function providerForValidateConstraintsKO(): array + public static function providerForValidateConstraintsKO(): array { return [ [ diff --git a/tests/lib/Helper/ContentInfoLocationLoader/SudoMainLocationLoaderTest.php b/tests/lib/Helper/ContentInfoLocationLoader/SudoMainLocationLoaderTest.php index 7f7fd31990..2298dcf869 100644 --- a/tests/lib/Helper/ContentInfoLocationLoader/SudoMainLocationLoaderTest.php +++ b/tests/lib/Helper/ContentInfoLocationLoader/SudoMainLocationLoaderTest.php @@ -30,7 +30,7 @@ protected function setUp(): void $this->loader = new SudoMainLocationLoader($this->getRepositoryMock()); } - public function testLoadLocationNoMainLocation() + public function testLoadLocationNoMainLocation(): void { $this->expectException(NotFoundException::class); @@ -43,7 +43,7 @@ public function testLoadLocationNoMainLocation() $this->loader->loadLocation($contentInfo); } - public function testLoadLocation() + public function testLoadLocation(): void { $contentInfo = new ContentInfo([ 'id' => 123, @@ -70,7 +70,7 @@ public function testLoadLocation() self::assertSame($location, $this->loader->loadLocation($contentInfo)); } - public function testLoadLocationError() + public function testLoadLocationError(): void { $this->expectException(NotFoundException::class); @@ -111,11 +111,11 @@ private function getRepositoryMock() $repositoryMock = $this ->getMockBuilder($repositoryClass) ->disableOriginalConstructor() - ->setMethods( - array_diff( + ->onlyMethods( + array_values(array_diff( get_class_methods($repositoryClass), ['sudo'] - ) + )) ) ->getMock(); } @@ -152,7 +152,7 @@ private function getPermissionResolverMock() return $this ->getMockBuilder(PermissionResolver::class) - ->setMethods(null) + ->onlyMethods([]) ->setConstructorArgs( [ $this diff --git a/tests/lib/Helper/ContentPreviewHelperTest.php b/tests/lib/Helper/ContentPreviewHelperTest.php index 59afe15726..fd6940ab60 100644 --- a/tests/lib/Helper/ContentPreviewHelperTest.php +++ b/tests/lib/Helper/ContentPreviewHelperTest.php @@ -36,7 +36,7 @@ protected function setUp(): void $this->previewHelper = new ContentPreviewHelper($this->eventDispatcher, $this->siteAccessRouter); } - public function testChangeConfigScope() + public function testChangeConfigScope(): void { $newSiteAccessName = 'test'; $newSiteAccess = new SiteAccess($newSiteAccessName); @@ -61,7 +61,7 @@ public function testChangeConfigScope() ); } - public function testRestoreConfigScope() + public function testRestoreConfigScope(): void { $originalSiteAccess = new SiteAccess('foo', 'bar'); $event = new ScopeChangeEvent($originalSiteAccess); @@ -77,7 +77,7 @@ public function testRestoreConfigScope() ); } - public function testPreviewActive() + public function testPreviewActive(): void { $originalSiteAccess = new SiteAccess('foo', 'bar'); $this->previewHelper->setSiteAccess($originalSiteAccess); @@ -91,18 +91,18 @@ public function testPreviewActive() self::assertNotSame($originalSiteAccess, $this->previewHelper->getOriginalSiteAccess()); } - public function testPreviewedContent() + public function testPreviewedContent(): void { self::assertNull($this->previewHelper->getPreviewedContent()); - $content = $this->createMock(APIContent::class); + $content = self::createStub(APIContent::class); $this->previewHelper->setPreviewedContent($content); self::assertSame($content, $this->previewHelper->getPreviewedContent()); } - public function testPreviewedLocation() + public function testPreviewedLocation(): void { self::assertNull($this->previewHelper->getPreviewedLocation()); - $location = $this->createMock(APILocation::class); + $location = self::createStub(APILocation::class); $this->previewHelper->setPreviewedLocation($location); self::assertSame($location, $this->previewHelper->getPreviewedLocation()); } diff --git a/tests/lib/Helper/FieldHelperTest.php b/tests/lib/Helper/FieldHelperTest.php index 175f0f099d..b418b3af7e 100644 --- a/tests/lib/Helper/FieldHelperTest.php +++ b/tests/lib/Helper/FieldHelperTest.php @@ -39,7 +39,7 @@ protected function setUp(): void $this->fieldHelper = new FieldHelper($this->translationHelper, $this->fieldTypeServiceMock); } - public function testIsFieldEmpty() + public function testIsFieldEmpty(): void { $contentTypeId = 123; $contentInfo = new ContentInfo(['contentTypeId' => $contentTypeId]); @@ -85,7 +85,7 @@ public function testIsFieldEmpty() self::assertTrue($this->fieldHelper->isFieldEmpty($content, $fieldDefIdentifier)); } - public function testIsFieldNotEmpty() + public function testIsFieldNotEmpty(): void { $contentTypeId = 123; $contentInfo = new ContentInfo(['contentTypeId' => $contentTypeId]); diff --git a/tests/lib/Helper/FieldsGroups/ArrayTranslatorFieldsGroupsListTest.php b/tests/lib/Helper/FieldsGroups/ArrayTranslatorFieldsGroupsListTest.php index be0bb404ba..c7a3ce933a 100644 --- a/tests/lib/Helper/FieldsGroups/ArrayTranslatorFieldsGroupsListTest.php +++ b/tests/lib/Helper/FieldsGroups/ArrayTranslatorFieldsGroupsListTest.php @@ -9,13 +9,12 @@ use Ibexa\Contracts\Core\Repository\Values\ContentType\FieldDefinition; use Ibexa\Core\Helper\FieldsGroups\ArrayTranslatorFieldsGroupsList; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; use Symfony\Contracts\Translation\TranslatorInterface; -/** - * @covers \Ibexa\Core\Helper\FieldsGroups\ArrayTranslatorFieldsGroupsList - */ +#[CoversClass(ArrayTranslatorFieldsGroupsList::class)] class ArrayTranslatorFieldsGroupsListTest extends TestCase { private const FIRST_GROUP_ID = 'slayer'; diff --git a/tests/lib/Helper/PreviewLocationProviderTest.php b/tests/lib/Helper/PreviewLocationProviderTest.php index c6735e3e09..0215d10520 100644 --- a/tests/lib/Helper/PreviewLocationProviderTest.php +++ b/tests/lib/Helper/PreviewLocationProviderTest.php @@ -37,7 +37,7 @@ protected function setUp(): void $this->provider = new PreviewLocationProvider($this->locationService, $this->locationHandler); } - public function testGetPreviewLocationDraft() + public function testGetPreviewLocationDraft(): void { $contentId = 123; $parentLocationId = 456; @@ -65,7 +65,7 @@ public function testGetPreviewLocationDraft() self::assertTrue($location->isDraft()); } - public function testGetPreviewLocation() + public function testGetPreviewLocation(): void { $contentId = 123; $locationId = 456; @@ -89,7 +89,7 @@ public function testGetPreviewLocation() self::assertSame($content, $location->getContent()); } - public function testGetPreviewLocationNoLocation() + public function testGetPreviewLocationNoLocation(): void { $contentId = 123; $content = $this->getContentMock($contentId); diff --git a/tests/lib/Helper/TranslationHelperTest.php b/tests/lib/Helper/TranslationHelperTest.php index a5aea4f013..3c6468de7b 100644 --- a/tests/lib/Helper/TranslationHelperTest.php +++ b/tests/lib/Helper/TranslationHelperTest.php @@ -14,6 +14,7 @@ use Ibexa\Core\Helper\TranslationHelper; use Ibexa\Core\Repository\Values\Content\Content; use Ibexa\Core\Repository\Values\Content\VersionInfo; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Psr\Log\LoggerInterface; @@ -101,12 +102,11 @@ private function generateVersionInfo() } /** - * @dataProvider getTranslatedNameProvider - * * @param array $prioritizedLanguages * @param string $expectedLocale */ - public function testGetTranslatedName(array $prioritizedLanguages, $expectedLocale) + #[DataProvider('getTranslatedNameProvider')] + public function testGetTranslatedName(array $prioritizedLanguages, $expectedLocale): void { $content = $this->generateContent(); $this->configResolver @@ -119,12 +119,11 @@ public function testGetTranslatedName(array $prioritizedLanguages, $expectedLoca } /** - * @dataProvider getTranslatedNameProvider - * * @param array $prioritizedLanguages * @param string $expectedLocale */ - public function testGetTranslatedNameByContentInfo(array $prioritizedLanguages, $expectedLocale) + #[DataProvider('getTranslatedNameProvider')] + public function testGetTranslatedNameByContentInfo(array $prioritizedLanguages, $expectedLocale): void { $versionInfo = $this->generateVersionInfo(); $contentInfo = new ContentInfo([ @@ -146,7 +145,10 @@ public function testGetTranslatedNameByContentInfo(array $prioritizedLanguages, self::assertSame($this->translatedNames[$expectedLocale], $this->translationHelper->getTranslatedContentNameByContentInfo($contentInfo)); } - public function getTranslatedNameProvider() + /** + * @return array + */ + public static function getTranslatedNameProvider(): array { return [ [['fre-FR', 'eng-GB'], 'fre-FR'], @@ -157,7 +159,7 @@ public function getTranslatedNameProvider() ]; } - public function testGetTranslatedNameByContentInfoForcedLanguage() + public function testGetTranslatedNameByContentInfoForcedLanguage(): void { $versionInfo = $this->generateVersionInfo(); $contentInfo = new ContentInfo([ @@ -179,7 +181,7 @@ public function testGetTranslatedNameByContentInfoForcedLanguage() self::assertSame('Mon nom en français', $this->translationHelper->getTranslatedContentNameByContentInfo($contentInfo, 'eng-US')); } - public function testGetTranslatedNameByContentInfoForcedLanguageMainLanguage() + public function testGetTranslatedNameByContentInfoForcedLanguageMainLanguage(): void { $name = 'Name in main language'; $mainLanguage = 'eng-GB'; @@ -205,7 +207,7 @@ public function testGetTranslatedNameByContentInfoForcedLanguageMainLanguage() ); } - public function testGetTranslatedNameForcedLanguage() + public function testGetTranslatedNameForcedLanguage(): void { $content = $this->generateContent(); $this->configResolver @@ -217,11 +219,10 @@ public function testGetTranslatedNameForcedLanguage() } /** - * @dataProvider getTranslatedFieldProvider - * * @param array $prioritizedLanguages * @param string $expectedLocale */ + #[DataProvider('getTranslatedFieldProvider')] public function getTranslatedField(array $prioritizedLanguages, $expectedLocale) { $content = $this->generateContent(); @@ -234,7 +235,10 @@ public function getTranslatedField(array $prioritizedLanguages, $expectedLocale) self::assertSame($this->translatedFields[$expectedLocale], $this->translationHelper->getTranslatedField($content, 'test')); } - public function getTranslatedFieldProvider() + /** + * @return array + */ + public static function getTranslatedFieldProvider(): array { return [ [['fre-FR', 'eng-GB'], 'fre-FR'], @@ -245,7 +249,7 @@ public function getTranslatedFieldProvider() ]; } - public function testGetTranslationSiteAccessUnkownLanguage() + public function testGetTranslationSiteAccessUnkownLanguage(): void { $this->configResolver ->expects(self::exactly(2)) @@ -266,10 +270,8 @@ public function testGetTranslationSiteAccessUnkownLanguage() self::assertNull($this->translationHelper->getTranslationSiteAccess('eng-DE')); } - /** - * @dataProvider getTranslationSiteAccessProvider - */ - public function testGetTranslationSiteAccess($language, array $translationSiteAccesses, array $relatedSiteAccesses, $expectedResult) + #[DataProvider('getTranslationSiteAccessProvider')] + public function testGetTranslationSiteAccess($language, array $translationSiteAccesses, array $relatedSiteAccesses, $expectedResult): void { $this->configResolver ->expects(self::exactly(2)) @@ -286,7 +288,10 @@ public function testGetTranslationSiteAccess($language, array $translationSiteAc self::assertSame($expectedResult, $this->translationHelper->getTranslationSiteAccess($language)); } - public function getTranslationSiteAccessProvider() + /** + * @return array + */ + public static function getTranslationSiteAccessProvider(): array { return [ ['eng-GB', ['fre', 'eng', 'heb'], ['esl', 'fre', 'eng', 'heb'], 'eng'], @@ -304,7 +309,7 @@ public function getTranslationSiteAccessProvider() ]; } - public function testGetAvailableLanguagesWithTranslationSiteAccesses() + public function testGetAvailableLanguagesWithTranslationSiteAccesses(): void { $this->configResolver ->expects(self::any()) @@ -325,7 +330,7 @@ public function testGetAvailableLanguagesWithTranslationSiteAccesses() self::assertSame($expectedLanguages, $this->translationHelper->getAvailableLanguages()); } - public function testGetAvailableLanguagesWithoutTranslationSiteAccesses() + public function testGetAvailableLanguagesWithoutTranslationSiteAccesses(): void { $this->configResolver ->expects(self::any()) diff --git a/tests/lib/IO/ConfigScopeChangeAwareIOServiceTest.php b/tests/lib/IO/ConfigScopeChangeAwareIOServiceTest.php index 8b3e0b1fb6..6b83486844 100644 --- a/tests/lib/IO/ConfigScopeChangeAwareIOServiceTest.php +++ b/tests/lib/IO/ConfigScopeChangeAwareIOServiceTest.php @@ -275,7 +275,7 @@ public function testDeleteDirectory(): void public function testOnConfigScopeChange(): void { - $event = $this->createMock(ScopeChangeEvent::class); + $event = self::createStub(ScopeChangeEvent::class); $this->innerIOService ->expects(self::once()) ->method('setPrefix') diff --git a/tests/lib/IO/FilePathNormalizer/FlysystemTest.php b/tests/lib/IO/FilePathNormalizer/FlysystemTest.php index 1a54adc199..5f589b6b3e 100644 --- a/tests/lib/IO/FilePathNormalizer/FlysystemTest.php +++ b/tests/lib/IO/FilePathNormalizer/FlysystemTest.php @@ -11,6 +11,7 @@ use Ibexa\Core\IO\FilePathNormalizer\Flysystem; use Ibexa\Core\Persistence\Legacy\Content\UrlAlias\SlugConverter; use League\Flysystem\WhitespacePathNormalizer; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; final class FlysystemTest extends TestCase @@ -27,9 +28,7 @@ public function setUp(): void $this->filePathNormalizer = new Flysystem($this->slugConverter, new WhitespacePathNormalizer()); } - /** - * @dataProvider providerForTestNormalizePath - */ + #[DataProvider('providerForTestNormalizePath')] public function testNormalizePath( string $originalPath, string $fileName, @@ -46,10 +45,10 @@ public function testNormalizePath( $normalizedPath = $this->filePathNormalizer->normalizePath($originalPath, $doHash); self::assertStringEndsWith($sluggedFileName, $normalizedPath); - self::assertRegExp($regex, $normalizedPath); + self::assertMatchesRegularExpression($regex, $normalizedPath); } - public function providerForTestNormalizePath(): array + public static function providerForTestNormalizePath(): array { $defaultPattern = '/\/[0-9a-f]{12}-'; diff --git a/tests/lib/IO/Flysystem/Adapter/DynamicPathFilesystemAdapterDecoratorTest.php b/tests/lib/IO/Flysystem/Adapter/DynamicPathFilesystemAdapterDecoratorTest.php index 3c962914c6..7b918a6d5b 100644 --- a/tests/lib/IO/Flysystem/Adapter/DynamicPathFilesystemAdapterDecoratorTest.php +++ b/tests/lib/IO/Flysystem/Adapter/DynamicPathFilesystemAdapterDecoratorTest.php @@ -14,17 +14,18 @@ use League\Flysystem\FileAttributes; use League\Flysystem\FilesystemAdapter; use League\Flysystem\Visibility; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Depends; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; /** - * @covers \Ibexa\Core\IO\Flysystem\Adapter\DynamicPathFilesystemAdapterDecorator - * * Note: SiteAccess-aware dynamic settings resolving aspect has been tested via PathPrefixer * and Visibility converter test cases: * {@see \Ibexa\Tests\Core\IO\Flysystem\VisibilityConverter\BaseVisibilityConverterTestCase} - * {@see \Ibexa\Tests\Core\IO\Flysystem\PathPrefixer\DFSSiteAccessAwarePathPrefixerTest} + * {@see \Ibexa\Tests\Core\IO\Flysystem\PathPrefixer\DFSSiteAccessAwarePathPrefixerTest}. */ +#[CoversClass(DynamicPathFilesystemAdapterDecorator::class)] final class DynamicPathFilesystemAdapterDecoratorTest extends TestCase { private const FLYSYSTEM_TEST_DIR = __DIR__; @@ -257,10 +258,9 @@ public function testRead(): void } /** - * @depends testWrite - * * @throws \League\Flysystem\FilesystemException */ + #[Depends('testWrite')] public function testReadStream(): void { $fileHandle = tmpfile(); diff --git a/tests/lib/IO/Flysystem/PathPrefixer/BaseSiteAccessAwarePathPrefixerTestCase.php b/tests/lib/IO/Flysystem/PathPrefixer/BaseSiteAccessAwarePathPrefixerTestCase.php index 01b2e3b10c..bb58204151 100644 --- a/tests/lib/IO/Flysystem/PathPrefixer/BaseSiteAccessAwarePathPrefixerTestCase.php +++ b/tests/lib/IO/Flysystem/PathPrefixer/BaseSiteAccessAwarePathPrefixerTestCase.php @@ -8,12 +8,13 @@ namespace Ibexa\Tests\Core\IO\Flysystem\PathPrefixer; +use Ibexa\Core\IO\Flysystem\PathPrefixer\BaseSiteAccessAwarePathPrefixer; use Ibexa\Core\IO\Flysystem\PathPrefixer\PathPrefixerInterface; use Ibexa\Tests\Core\Search\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; -/** - * @covers \Ibexa\Core\IO\Flysystem\PathPrefixer\PathPrefixerInterface - */ +#[CoversClass(BaseSiteAccessAwarePathPrefixer::class)] abstract class BaseSiteAccessAwarePathPrefixerTestCase extends TestCase { abstract protected function getPrefixer(): PathPrefixerInterface; @@ -21,30 +22,28 @@ abstract protected function getPrefixer(): PathPrefixerInterface; /** * @return iterable */ - abstract public function getDataForTestPrefixPath(): iterable; + abstract public static function getDataForTestPrefixPath(): iterable; /** * @return iterable */ - abstract public function getDataForTestPrefixDirectoryPath(): iterable; + abstract public static function getDataForTestPrefixDirectoryPath(): iterable; /** * @return iterable */ - abstract public function getDataForTestStripPrefixPath(): iterable; + abstract public static function getDataForTestStripPrefixPath(): iterable; /** * @return iterable */ - public function getDataForTestStripDirectoryPrefix(): iterable + public static function getDataForTestStripDirectoryPrefix(): iterable { // treat file names as directories - yield from $this->getDataForTestStripPrefixPath(); + yield from static::getDataForTestStripPrefixPath(); } - /** - * @dataProvider getDataForTestPrefixPath - */ + #[DataProvider('getDataForTestPrefixPath')] final public function testPrefixPath(string $expectedPrefixedPath, string $path): void { self::assertSame( @@ -53,9 +52,7 @@ final public function testPrefixPath(string $expectedPrefixedPath, string $path) ); } - /** - * @dataProvider getDataForTestPrefixDirectoryPath - */ + #[DataProvider('getDataForTestPrefixDirectoryPath')] final public function testPrefixDirectoryPath(string $expectedPrefixedPath, string $path): void { self::assertSame( @@ -64,9 +61,7 @@ final public function testPrefixDirectoryPath(string $expectedPrefixedPath, stri ); } - /** - * @dataProvider getDataForTestStripPrefixPath - */ + #[DataProvider('getDataForTestStripPrefixPath')] final public function testStripPrefix(string $expectedStrippedPath, string $path): void { self::assertSame( @@ -75,9 +70,7 @@ final public function testStripPrefix(string $expectedStrippedPath, string $path ); } - /** - * @dataProvider getDataForTestStripDirectoryPrefix - */ + #[DataProvider('getDataForTestStripDirectoryPrefix')] final public function testStripDirectoryPrefix(string $expectedStrippedPath, string $path): void { self::assertSame( diff --git a/tests/lib/IO/Flysystem/PathPrefixer/DFSSiteAccessAwarePathPrefixerTest.php b/tests/lib/IO/Flysystem/PathPrefixer/DFSSiteAccessAwarePathPrefixerTest.php index c9ee5eb847..874ecb0736 100644 --- a/tests/lib/IO/Flysystem/PathPrefixer/DFSSiteAccessAwarePathPrefixerTest.php +++ b/tests/lib/IO/Flysystem/PathPrefixer/DFSSiteAccessAwarePathPrefixerTest.php @@ -11,15 +11,14 @@ use Ibexa\Contracts\Core\SiteAccess\ConfigProcessor; use Ibexa\Core\IO\Flysystem\PathPrefixer\DFSSiteAccessAwarePathPrefixer; use Ibexa\Core\IO\Flysystem\PathPrefixer\PathPrefixerInterface; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\IO\Flysystem\PathPrefixer\DFSSiteAccessAwarePathPrefixer - */ +#[CoversClass(DFSSiteAccessAwarePathPrefixer::class)] final class DFSSiteAccessAwarePathPrefixerTest extends BaseSiteAccessAwarePathPrefixerTestCase { - public function getDataForTestPrefixPath(): iterable + public static function getDataForTestPrefixPath(): iterable { - $dfsRootDir = $this->getDFSRootDir(); + $dfsRootDir = self::getDFSRootDir(); yield 'dynamic path to relative file name' => [$dfsRootDir . '/var/storage/foo', 'foo']; yield 'dynamic path to relative file path name' => [ @@ -29,9 +28,9 @@ public function getDataForTestPrefixPath(): iterable yield 'dynamic path to absolute file name' => [$dfsRootDir . '/var/storage/foo', '/foo']; } - public function getDataForTestPrefixDirectoryPath(): iterable + public static function getDataForTestPrefixDirectoryPath(): iterable { - $dfsRootDir = $this->getDFSRootDir(); + $dfsRootDir = self::getDFSRootDir(); yield 'dynamic path to relative directory' => [ $dfsRootDir . '/var/storage/foo/', @@ -51,9 +50,9 @@ public function getDataForTestPrefixDirectoryPath(): iterable ]; } - public function getDataForTestStripPrefixPath(): iterable + public static function getDataForTestStripPrefixPath(): iterable { - $dfsRootDir = $this->getDFSRootDir(); + $dfsRootDir = self::getDFSRootDir(); yield 'relative single file name' => ['/foo', $dfsRootDir . '/var/storage/foo']; yield 'relative file path' => ['/foo/bar', $dfsRootDir . '/var/storage/foo/bar']; @@ -75,7 +74,7 @@ protected function getPrefixer(): PathPrefixerInterface ); } - private function getDFSRootDir(): string + private static function getDFSRootDir(): string { return sys_get_temp_dir() . '/dfs'; } diff --git a/tests/lib/IO/Flysystem/PathPrefixer/LocalSiteAccessAwarePathPrefixerTest.php b/tests/lib/IO/Flysystem/PathPrefixer/LocalSiteAccessAwarePathPrefixerTest.php index 938d7de010..2d76039c87 100644 --- a/tests/lib/IO/Flysystem/PathPrefixer/LocalSiteAccessAwarePathPrefixerTest.php +++ b/tests/lib/IO/Flysystem/PathPrefixer/LocalSiteAccessAwarePathPrefixerTest.php @@ -11,13 +11,12 @@ use Ibexa\Core\IO\Flysystem\PathPrefixer\LocalSiteAccessAwarePathPrefixer; use Ibexa\Core\IO\Flysystem\PathPrefixer\PathPrefixerInterface; use Ibexa\Core\IO\IOConfigProvider; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\IO\Flysystem\PathPrefixer\LocalSiteAccessAwarePathPrefixer - */ +#[CoversClass(LocalSiteAccessAwarePathPrefixer::class)] final class LocalSiteAccessAwarePathPrefixerTest extends BaseSiteAccessAwarePathPrefixerTestCase { - public function getDataForTestPrefixPath(): iterable + public static function getDataForTestPrefixPath(): iterable { yield 'dynamic path to relative file name' => [__DIR__ . '/var/storage/foo', 'foo']; yield 'dynamic path to relative file path name' => [ @@ -27,7 +26,7 @@ public function getDataForTestPrefixPath(): iterable yield 'dynamic path to absolute file name' => [__DIR__ . '/var/storage/foo', '/foo']; } - public function getDataForTestPrefixDirectoryPath(): iterable + public static function getDataForTestPrefixDirectoryPath(): iterable { yield 'dynamic path to relative directory' => [__DIR__ . '/var/storage/foo/', 'foo/']; yield 'dynamic path to absolute directory' => [__DIR__ . '/var/storage/foo/', '/foo/']; @@ -41,7 +40,7 @@ public function getDataForTestPrefixDirectoryPath(): iterable ]; } - public function getDataForTestStripPrefixPath(): iterable + public static function getDataForTestStripPrefixPath(): iterable { yield 'relative single file name' => ['/foo', __DIR__ . '/var/storage/foo']; yield 'relative file path' => ['/foo/bar', __DIR__ . '/var/storage/foo/bar']; diff --git a/tests/lib/IO/Flysystem/VisibilityConverter/BaseVisibilityConverterTestCase.php b/tests/lib/IO/Flysystem/VisibilityConverter/BaseVisibilityConverterTestCase.php index 56b35885f3..262cb223da 100644 --- a/tests/lib/IO/Flysystem/VisibilityConverter/BaseVisibilityConverterTestCase.php +++ b/tests/lib/IO/Flysystem/VisibilityConverter/BaseVisibilityConverterTestCase.php @@ -11,11 +11,11 @@ use Ibexa\Core\IO\Flysystem\VisibilityConverter\BaseVisibilityConverter; use League\Flysystem\UnixVisibility\VisibilityConverter as FlysystemVisibilityConverter; use League\Flysystem\Visibility; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\IO\Flysystem\VisibilityConverter\BaseVisibilityConverter - */ +#[CoversClass(BaseVisibilityConverter::class)] abstract class BaseVisibilityConverterTestCase extends TestCase { protected const FLYSYSTEM_FILE_FLAGS = 0600; @@ -30,13 +30,13 @@ abstract class BaseVisibilityConverterTestCase extends TestCase abstract protected function buildVisibilityConverter(): BaseVisibilityConverter; - abstract public function getDataForTestForFile(): iterable; + abstract public static function getDataForTestForFile(): iterable; - abstract public function getDataForTestForDirectory(): iterable; + abstract public static function getDataForTestForDirectory(): iterable; - abstract public function getDataForTestInverseForFile(): iterable; + abstract public static function getDataForTestInverseForFile(): iterable; - abstract public function getDataForTestInverseForDirectory(): iterable; + abstract public static function getDataForTestInverseForDirectory(): iterable; final protected function setUp(): void { @@ -53,9 +53,7 @@ final protected function setUp(): void $this->visibilityConverter = $this->buildVisibilityConverter(); } - /** - * @dataProvider getDataForTestForFile - */ + #[DataProvider('getDataForTestForFile')] final public function testForFile(string $visibility, int $expectedVisibilityFlags): void { self::assertSame( @@ -64,9 +62,7 @@ final public function testForFile(string $visibility, int $expectedVisibilityFla ); } - /** - * @dataProvider getDataForTestForDirectory - */ + #[DataProvider('getDataForTestForDirectory')] final public function testForDirectory(string $visibility, int $expectedVisibilityFlags): void { self::assertSame( @@ -75,9 +71,7 @@ final public function testForDirectory(string $visibility, int $expectedVisibili ); } - /** - * @dataProvider getDataForTestInverseForFile - */ + #[DataProvider('getDataForTestInverseForFile')] final public function testInverseForFile(int $fileVisibilityFlags, string $expectedVisibility): void { self::assertSame( @@ -86,9 +80,7 @@ final public function testInverseForFile(int $fileVisibilityFlags, string $expec ); } - /** - * @dataProvider getDataForTestInverseForDirectory - */ + #[DataProvider('getDataForTestInverseForDirectory')] final public function testInverseForDirectory( int $directoryVisibilityFlags, string $expectedVisibility diff --git a/tests/lib/IO/Flysystem/VisibilityConverter/DFSVisibilityConverterTest.php b/tests/lib/IO/Flysystem/VisibilityConverter/DFSVisibilityConverterTest.php index 65fae8d3f1..01a8149089 100644 --- a/tests/lib/IO/Flysystem/VisibilityConverter/DFSVisibilityConverterTest.php +++ b/tests/lib/IO/Flysystem/VisibilityConverter/DFSVisibilityConverterTest.php @@ -11,10 +11,9 @@ use Ibexa\Core\IO\Flysystem\VisibilityConverter\BaseVisibilityConverter; use Ibexa\Core\IO\Flysystem\VisibilityConverter\DFSVisibilityConverter; use League\Flysystem\Visibility; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\IO\Flysystem\VisibilityConverter\DFSVisibilityConverter - */ +#[CoversClass(DFSVisibilityConverter::class)] final class DFSVisibilityConverterTest extends BaseVisibilityConverterTestCase { private const DFS_FILE_FLAGS = 0640; @@ -31,7 +30,7 @@ protected function buildVisibilityConverter(): BaseVisibilityConverter ); } - public function getDataForTestForFile(): iterable + public static function getDataForTestForFile(): iterable { yield 'public visibility (from DFS config)' => [ Visibility::PUBLIC, @@ -43,7 +42,7 @@ public function getDataForTestForFile(): iterable ]; } - public function getDataForTestForDirectory(): iterable + public static function getDataForTestForDirectory(): iterable { yield 'public visibility (from DFS config)' => [ Visibility::PUBLIC, @@ -55,7 +54,7 @@ public function getDataForTestForDirectory(): iterable ]; } - public function getDataForTestInverseForFile(): iterable + public static function getDataForTestInverseForFile(): iterable { yield self::DFS_FILE_FLAGS . ' (DFS config) is public' => [ self::DFS_FILE_FLAGS, @@ -71,7 +70,7 @@ public function getDataForTestInverseForFile(): iterable ]; } - public function getDataForTestInverseForDirectory(): iterable + public static function getDataForTestInverseForDirectory(): iterable { yield self::DFS_DIRECTORY_FLAGS . ' (DFS config) is public' => [ self::DFS_DIRECTORY_FLAGS, diff --git a/tests/lib/IO/Flysystem/VisibilityConverter/SiteAccessAwareVisibilityConverterTest.php b/tests/lib/IO/Flysystem/VisibilityConverter/SiteAccessAwareVisibilityConverterTest.php index 41c897c627..4c8b1ee06f 100644 --- a/tests/lib/IO/Flysystem/VisibilityConverter/SiteAccessAwareVisibilityConverterTest.php +++ b/tests/lib/IO/Flysystem/VisibilityConverter/SiteAccessAwareVisibilityConverterTest.php @@ -12,10 +12,9 @@ use Ibexa\Core\IO\Flysystem\VisibilityConverter\BaseVisibilityConverter; use Ibexa\Core\IO\Flysystem\VisibilityConverter\SiteAccessAwareVisibilityConverter; use League\Flysystem\Visibility; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\IO\Flysystem\VisibilityConverter\SiteAccessAwareVisibilityConverter - */ +#[CoversClass(SiteAccessAwareVisibilityConverter::class)] final class SiteAccessAwareVisibilityConverterTest extends BaseVisibilityConverterTestCase { private const int SITE_FILE_FLAGS = 0644; @@ -39,7 +38,7 @@ protected function buildVisibilityConverter(): BaseVisibilityConverter ); } - public function getDataForTestForFile(): iterable + public static function getDataForTestForFile(): iterable { yield 'public visibility (from SiteAccess config)' => [ Visibility::PUBLIC, @@ -51,7 +50,7 @@ public function getDataForTestForFile(): iterable ]; } - public function getDataForTestForDirectory(): iterable + public static function getDataForTestForDirectory(): iterable { yield 'public visibility (from SiteAccess config)' => [ Visibility::PUBLIC, @@ -63,7 +62,7 @@ public function getDataForTestForDirectory(): iterable ]; } - public function getDataForTestInverseForFile(): iterable + public static function getDataForTestInverseForFile(): iterable { yield self::SITE_FILE_FLAGS . ' (SiteAccess config) is public' => [ self::SITE_FILE_FLAGS, @@ -79,7 +78,7 @@ public function getDataForTestInverseForFile(): iterable ]; } - public function getDataForTestInverseForDirectory(): iterable + public static function getDataForTestInverseForDirectory(): iterable { yield self::SITE_DIRECTORY_FLAGS . ' (SiteAccess config) is public' => [ self::SITE_DIRECTORY_FLAGS, diff --git a/tests/lib/IO/IOBinarydataHandler/FlysystemTest.php b/tests/lib/IO/IOBinarydataHandler/FlysystemTest.php index f0bd268204..3b20fd8d1b 100644 --- a/tests/lib/IO/IOBinarydataHandler/FlysystemTest.php +++ b/tests/lib/IO/IOBinarydataHandler/FlysystemTest.php @@ -59,7 +59,7 @@ public function testCreate(): void $this->handler->create($spiBinaryFileCreateStruct); } - public function testDelete() + public function testDelete(): void { $this->filesystem ->expects(self::once()) diff --git a/tests/lib/IO/IOMetadataHandler/FlysystemTest.php b/tests/lib/IO/IOMetadataHandler/FlysystemTest.php index 88ae2c8324..1dc16675ad 100644 --- a/tests/lib/IO/IOMetadataHandler/FlysystemTest.php +++ b/tests/lib/IO/IOMetadataHandler/FlysystemTest.php @@ -13,6 +13,7 @@ use Ibexa\Core\IO\Exception\BinaryFileNotFoundException; use Ibexa\Core\IO\IOMetadataHandler\Flysystem; use League\Flysystem\UnableToRetrieveMetadata; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; class FlysystemTest extends TestCase @@ -63,7 +64,7 @@ public function testCreate(): void self::assertEquals($expectedSpiBinaryFile, $spiBinaryFile); } - public function testDelete() + public function testDelete(): void { $this->filesystem->expects(self::never())->method('delete'); $this->handler->delete('prefix/my/file.png'); @@ -109,9 +110,7 @@ public function testLoadNotFound(): void $this->handler->load($notExistentPath); } - /** - * @dataProvider getDataForFileExists - */ + #[DataProvider('getDataForFileExists')] public function testExists(string $filePath, bool $exists): void { $this->filesystem @@ -124,7 +123,7 @@ public function testExists(string $filePath, bool $exists): void self::assertSame($exists, $this->handler->exists($filePath)); } - public function getDataForFileExists(): iterable + public static function getDataForFileExists(): iterable { $filePath = 'prefix/my/file.png'; diff --git a/tests/lib/IO/IOMetadataHandler/LegacyDFSClusterTest.php b/tests/lib/IO/IOMetadataHandler/LegacyDFSClusterTest.php index beef55336e..ff378df8fb 100644 --- a/tests/lib/IO/IOMetadataHandler/LegacyDFSClusterTest.php +++ b/tests/lib/IO/IOMetadataHandler/LegacyDFSClusterTest.php @@ -18,6 +18,7 @@ use Ibexa\Core\IO\Exception\BinaryFileNotFoundException; use Ibexa\Core\IO\IOMetadataHandler\LegacyDFSCluster; use Ibexa\Core\IO\UrlDecorator; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; @@ -52,7 +53,7 @@ protected function setUp(): void /** * @return iterable */ - public function providerCreate(): iterable + public static function providerCreate(): iterable { return [ ['prefix/my/file.png', 'image/png', 123, new DateTime('@1307155200'), new DateTime('@1307155200')], @@ -61,9 +62,7 @@ public function providerCreate(): iterable ]; } - /** - * @dataProvider providerCreate - */ + #[DataProvider('providerCreate')] public function testCreate(string $id, string $mimeType, int $size, \DateTime $mtime, \DateTime $mtimeExpected): void { $this->dbalMock @@ -160,15 +159,22 @@ public function testDeletedirectory(): void ->method('where') ->with('name LIKE :spiPath ESCAPE :esc') ->willReturnSelf(); + $matcher = self::exactly(2); $this->qbMock - ->expects(self::exactly(2)) - ->method('setParameter') - ->withConsecutive( - ['esc', '\\'], - ['spiPath', 'prefix/images/\_alias/subfolder/%'], - ) - ->willReturnSelf(); + ->expects($matcher) + ->method('setParameter')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame('esc', $parameters[0]); + $this->assertSame('\\', $parameters[1]); + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame('spiPath', $parameters[0]); + $this->assertSame('prefix/images/\_alias/subfolder/%', $parameters[1]); + } + + return $this->qbMock; + }); $this->qbMock ->expects(self::once()) diff --git a/tests/lib/IO/IOServiceTest.php b/tests/lib/IO/IOServiceTest.php index f77125690f..1febd280ea 100644 --- a/tests/lib/IO/IOServiceTest.php +++ b/tests/lib/IO/IOServiceTest.php @@ -18,12 +18,12 @@ use Ibexa\Core\IO\IOService; use Ibexa\Core\IO\Values\BinaryFile; use Ibexa\Core\IO\Values\BinaryFileCreateStruct; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Depends; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\IO\IOService - */ +#[CoversClass(IOService::class)] class IOServiceTest extends TestCase { public const string PREFIX = 'test-prefix'; @@ -76,9 +76,7 @@ public function testNewBinaryCreateStructFromLocalFile(): BinaryFileCreateStruct return $binaryCreateStruct; } - /** - * @depends testNewBinaryCreateStructFromLocalFile - */ + #[Depends('testNewBinaryCreateStructFromLocalFile')] public function testCreateBinaryFile(BinaryFileCreateStruct $createStruct): BinaryFile { $createStruct->id = 'my/path.php'; @@ -227,9 +225,7 @@ public function testLoadBinaryFileByUriNotFound(): BinaryFile return $this->loadBinaryFileByUriNotFound(); } - /** - * @depends testLoadBinaryFile - */ + #[Depends('testLoadBinaryFile')] public function testGetFileContents(BinaryFile $binaryFile): void { $expectedContents = file_get_contents(__FILE__); @@ -246,9 +242,7 @@ public function testGetFileContents(BinaryFile $binaryFile): void ); } - /** - * @depends testCreateBinaryFile - */ + #[Depends('testCreateBinaryFile')] public function testExists(BinaryFile $binaryFile): void { $this->metadataHandlerMock @@ -279,9 +273,7 @@ public function testExistsNot(): void ); } - /** - * @depends testCreateBinaryFile - */ + #[Depends('testCreateBinaryFile')] public function testGetMimeType(BinaryFile $binaryFile): void { $this->metadataHandlerMock @@ -298,9 +290,7 @@ public function testGetMimeType(BinaryFile $binaryFile): void ); } - /** - * @depends testCreateBinaryFile - */ + #[Depends('testCreateBinaryFile')] public function testDeleteBinaryFile(BinaryFile $binaryFile): void { $this->metadataHandlerMock diff --git a/tests/lib/IO/TolerantIOServiceTest.php b/tests/lib/IO/TolerantIOServiceTest.php index 5c0098f232..d4fca5ef11 100644 --- a/tests/lib/IO/TolerantIOServiceTest.php +++ b/tests/lib/IO/TolerantIOServiceTest.php @@ -7,14 +7,14 @@ namespace Ibexa\Tests\Core\IO; +use Ibexa\Core\IO\IOService; use Ibexa\Core\IO\TolerantIOService; use Ibexa\Core\IO\Values\BinaryFile; use Ibexa\Core\IO\Values\MissingBinaryFile; use Override; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\IO\IOService - */ +#[CoversClass(IOService::class)] class TolerantIOServiceTest extends IOServiceTest { protected function setUp(): void @@ -65,7 +65,6 @@ public function testCreateMissingBinaryFile(): void #[Override] public function testDeleteBinaryFileNotFound(): void { - $this->expectNotToPerformAssertions(); $this->deleteBinaryFileNotFound(); } diff --git a/tests/lib/IO/UrlDecorator/AbsolutePrefixTest.php b/tests/lib/IO/UrlDecorator/AbsolutePrefixTest.php index 0372d84f82..60424ec6b9 100644 --- a/tests/lib/IO/UrlDecorator/AbsolutePrefixTest.php +++ b/tests/lib/IO/UrlDecorator/AbsolutePrefixTest.php @@ -27,7 +27,7 @@ protected function buildDecorator(string $prefix): UrlDecorator return new AbsolutePrefix($ioConfigResolverMock); } - public function provideData(): array + public static function provideData(): array { return [ [ diff --git a/tests/lib/IO/UrlDecorator/PrefixTest.php b/tests/lib/IO/UrlDecorator/PrefixTest.php index 90b32f4561..5c6af49384 100644 --- a/tests/lib/IO/UrlDecorator/PrefixTest.php +++ b/tests/lib/IO/UrlDecorator/PrefixTest.php @@ -11,14 +11,13 @@ use Ibexa\Core\IO\IOConfigProvider; use Ibexa\Core\IO\UrlDecorator; use Ibexa\Core\IO\UrlDecorator\Prefix; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; class PrefixTest extends TestCase { - /** - * @dataProvider provideData - */ - public function testDecorate($url, $prefix, $decoratedUrl) + #[DataProvider('provideData')] + public function testDecorate($url, $prefix, $decoratedUrl): void { $decorator = $this->buildDecorator($prefix); @@ -28,10 +27,8 @@ public function testDecorate($url, $prefix, $decoratedUrl) ); } - /** - * @dataProvider provideData - */ - public function testUndecorate($url, $prefix, $decoratedUrl) + #[DataProvider('provideData')] + public function testUndecorate($url, $prefix, $decoratedUrl): void { $decorator = $this->buildDecorator($prefix); @@ -51,7 +48,10 @@ protected function buildDecorator(string $prefix): UrlDecorator return new Prefix($ioConfigResolverMock); } - public function provideData() + /** + * @return array + */ + public static function provideData(): array { return [ [ diff --git a/tests/lib/IO/UrlRedecoratorTest.php b/tests/lib/IO/UrlRedecoratorTest.php index 45ede2b84b..574ba672b0 100644 --- a/tests/lib/IO/UrlRedecoratorTest.php +++ b/tests/lib/IO/UrlRedecoratorTest.php @@ -30,7 +30,7 @@ protected function setUp(): void ); } - public function testRedecorateFromSource() + public function testRedecorateFromSource(): void { $this->sourceDecoratorMock ->expects(self::once()) @@ -50,7 +50,7 @@ public function testRedecorateFromSource() ); } - public function testRedecorateFromTarget() + public function testRedecorateFromTarget(): void { $this->targetDecoratorMock ->expects(self::once()) diff --git a/tests/lib/Limitation/Base.php b/tests/lib/Limitation/Base.php index be8b5d3153..57cea28871 100644 --- a/tests/lib/Limitation/Base.php +++ b/tests/lib/Limitation/Base.php @@ -44,10 +44,13 @@ public function getUserMock(array $mockMethods = []) return $this->userMock; } - return $this->userMock = $this->getMockBuilder(APIUser::class) - ->setConstructorArgs([]) - ->setMethods($mockMethods) - ->getMock(); + $builder = $this->getMockBuilder(APIUser::class) + ->setConstructorArgs([]); + if ($mockMethods !== []) { + $builder->onlyMethods(array_values($mockMethods)); + } + + return $this->userMock = $builder->getMock(); } /** diff --git a/tests/lib/Limitation/BlockingLimitationTypeTest.php b/tests/lib/Limitation/BlockingLimitationTypeTest.php index 6153a042ad..0f2da47c1a 100644 --- a/tests/lib/Limitation/BlockingLimitationTypeTest.php +++ b/tests/lib/Limitation/BlockingLimitationTypeTest.php @@ -11,7 +11,6 @@ use Ibexa\Contracts\Core\Repository\Exceptions\NotImplementedException; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\MatchNone; -use Ibexa\Contracts\Core\Repository\Values\ContentType\ContentType; use Ibexa\Contracts\Core\Repository\Values\User\Limitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\BlockingLimitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\ObjectStateLimitation; @@ -19,6 +18,9 @@ use Ibexa\Core\Limitation\BlockingLimitationType; use Ibexa\Core\Repository\Values\Content\ContentCreateStruct; use Ibexa\Core\Repository\Values\Content\Location; +use Ibexa\Core\Repository\Values\ContentType\ContentType; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; /** * Test Case for LimitationType. @@ -28,7 +30,7 @@ class BlockingLimitationTypeTest extends Base /** * @return \Ibexa\Core\Limitation\BlockingLimitationType */ - public function testConstruct() + public function testConstruct(): BlockingLimitationType { return new BlockingLimitationType('Test'); } @@ -36,7 +38,7 @@ public function testConstruct() /** * @return array */ - public function providerForTestAcceptValue() + public static function providerForTestAcceptValue(): array { return [ [new BlockingLimitation('Test', [])], @@ -45,14 +47,12 @@ public function providerForTestAcceptValue() } /** - * @dataProvider providerForTestAcceptValue - * - * @depends testConstruct - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\BlockingLimitation $limitation * @param \Ibexa\Core\Limitation\BlockingLimitationType $limitationType */ - public function testAcceptValue(BlockingLimitation $limitation, BlockingLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestAcceptValue')] + public function testAcceptValue(BlockingLimitation $limitation, BlockingLimitationType $limitationType): void { $limitationType->acceptValue($limitation); } @@ -60,7 +60,7 @@ public function testAcceptValue(BlockingLimitation $limitation, BlockingLimitati /** * @return array */ - public function providerForTestAcceptValueException() + public static function providerForTestAcceptValueException(): array { return [ [new ObjectStateLimitation()], @@ -68,14 +68,12 @@ public function providerForTestAcceptValueException() } /** - * @dataProvider providerForTestAcceptValueException - * - * @depends testConstruct - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation $limitation * @param \Ibexa\Core\Limitation\BlockingLimitationType $limitationType */ - public function testAcceptValueException(Limitation $limitation, BlockingLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestAcceptValueException')] + public function testAcceptValueException(Limitation $limitation, BlockingLimitationType $limitationType): void { $this->expectException(InvalidArgumentException::class); @@ -85,7 +83,7 @@ public function testAcceptValueException(Limitation $limitation, BlockingLimitat /** * @return array */ - public function providerForTestValidatePass() + public static function providerForTestValidatePass(): array { return [ [new BlockingLimitation('Test', ['limitationValues' => ['ezjscore::call']])], @@ -94,11 +92,10 @@ public function providerForTestValidatePass() } /** - * @dataProvider providerForTestValidatePass - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\BlockingLimitation $limitation */ - public function testValidatePass(BlockingLimitation $limitation) + #[DataProvider('providerForTestValidatePass')] + public function testValidatePass(BlockingLimitation $limitation): void { // Need to create inline instead of depending on testConstruct() to get correct mock instance $limitationType = $this->testConstruct(); @@ -110,7 +107,7 @@ public function testValidatePass(BlockingLimitation $limitation) /** * @return array */ - public function providerForTestValidateError() + public static function providerForTestValidateError(): array { return [ [new BlockingLimitation('Test', []), 1], @@ -120,12 +117,11 @@ public function providerForTestValidateError() } /** - * @dataProvider providerForTestValidateError - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\BlockingLimitation $limitation * @param int $errorCount */ - public function testValidateError(BlockingLimitation $limitation, $errorCount) + #[DataProvider('providerForTestValidateError')] + public function testValidateError(BlockingLimitation $limitation, $errorCount): void { $this->getPersistenceMock() ->expects(self::never()) @@ -139,11 +135,10 @@ public function testValidateError(BlockingLimitation $limitation, $errorCount) } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\BlockingLimitationType $limitationType */ - public function testBuildValue(BlockingLimitationType $limitationType) + #[Depends('testConstruct')] + public function testBuildValue(BlockingLimitationType $limitationType): void { $expected = ['test', 'test' => 9]; $value = $limitationType->buildValue($expected); @@ -156,7 +151,7 @@ public function testBuildValue(BlockingLimitationType $limitationType) /** * @return array */ - public function providerForTestEvaluate() + public static function providerForTestEvaluate(): array { return [ // ContentInfo, no access @@ -180,34 +175,29 @@ public function providerForTestEvaluate() // ContentCreateStruct, no access [ 'limitation' => new BlockingLimitation('Test', ['limitationValues' => [2]]), - 'object' => new ContentCreateStruct(['contentType' => $this->createContentTypeWithId(22)]), + 'object' => new ContentCreateStruct(['contentType' => self::createContentTypeWithId(22)]), 'targets' => [], ], // ContentCreateStruct, with access [ 'limitation' => new BlockingLimitation('Test', ['limitationValues' => [2, 43]]), - 'object' => new ContentCreateStruct(['contentType' => $this->createContentTypeWithId(43)]), + 'object' => new ContentCreateStruct(['contentType' => self::createContentTypeWithId(43)]), 'targets' => [], ], ]; } - private function createContentTypeWithId(int $id): ContentType + private static function createContentTypeWithId(int $id): ContentType { - $contentType = $this->createMock(ContentType::class); - $contentType->method('__get')->with('id')->willReturn($id); - - return $contentType; + return new ContentType(['id' => $id]); } - /** - * @dataProvider providerForTestEvaluate - */ + #[DataProvider('providerForTestEvaluate')] public function testEvaluate( BlockingLimitation $limitation, ValueObject $object, array $targets - ) { + ): void { // Need to create inline instead of depending on testConstruct() to get correct mock instance $limitationType = $this->testConstruct(); @@ -234,7 +224,7 @@ public function testEvaluate( /** * @return array */ - public function providerForTestEvaluateInvalidArgument() + public static function providerForTestEvaluateInvalidArgument(): array { return [ // invalid limitation @@ -246,14 +236,12 @@ public function providerForTestEvaluateInvalidArgument() ]; } - /** - * @dataProvider providerForTestEvaluateInvalidArgument - */ + #[DataProvider('providerForTestEvaluateInvalidArgument')] public function testEvaluateInvalidArgument( Limitation $limitation, ValueObject $object, array $targets - ) { + ): void { $this->expectException(InvalidArgumentException::class); // Need to create inline instead of depending on testConstruct() to get correct mock instance @@ -279,11 +267,10 @@ public function testEvaluateInvalidArgument( } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\BlockingLimitationType $limitationType */ - public function testGetCriterion(BlockingLimitationType $limitationType) + #[Depends('testConstruct')] + public function testGetCriterion(BlockingLimitationType $limitationType): void { $criterion = $limitationType->getCriterion( new BlockingLimitation('Test', []), @@ -294,11 +281,10 @@ public function testGetCriterion(BlockingLimitationType $limitationType) } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\BlockingLimitationType $limitationType */ - public function testValueSchema(BlockingLimitationType $limitationType) + #[Depends('testConstruct')] + public function testValueSchema(BlockingLimitationType $limitationType): void { $this->expectException(NotImplementedException::class); diff --git a/tests/lib/Limitation/ContentTypeLimitationTypeTest.php b/tests/lib/Limitation/ContentTypeLimitationTypeTest.php index 3e76499da0..e1b48158d4 100644 --- a/tests/lib/Limitation/ContentTypeLimitationTypeTest.php +++ b/tests/lib/Limitation/ContentTypeLimitationTypeTest.php @@ -11,20 +11,22 @@ use Ibexa\Contracts\Core\Persistence\Content\Type\Handler as SPIHandler; use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException; use Ibexa\Contracts\Core\Repository\Exceptions\NotImplementedException; -use Ibexa\Contracts\Core\Repository\Values\Content\Content as APIContent; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\ContentTypeId; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\Operator; -use Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo as APIVersionInfo; use Ibexa\Contracts\Core\Repository\Values\User\Limitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\ContentTypeLimitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\ObjectStateLimitation; use Ibexa\Contracts\Core\Repository\Values\ValueObject; use Ibexa\Core\Base\Exceptions\NotFoundException; use Ibexa\Core\Limitation\ContentTypeLimitationType; +use Ibexa\Core\Repository\Values\Content\Content as CoreContent; use Ibexa\Core\Repository\Values\Content\ContentCreateStruct; use Ibexa\Core\Repository\Values\Content\Location; +use Ibexa\Core\Repository\Values\Content\VersionInfo as CoreVersionInfo; use Ibexa\Core\Repository\Values\ContentType\ContentType; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; /** * Test Case for LimitationType. @@ -55,7 +57,7 @@ protected function tearDown(): void /** * @return \Ibexa\Core\Limitation\ContentTypeLimitationType */ - public function testConstruct() + public function testConstruct(): ContentTypeLimitationType { return new ContentTypeLimitationType($this->getPersistenceMock()); } @@ -63,7 +65,7 @@ public function testConstruct() /** * @return array */ - public function providerForTestAcceptValue() + public static function providerForTestAcceptValue(): array { return [ [new ContentTypeLimitation()], @@ -73,14 +75,12 @@ public function providerForTestAcceptValue() } /** - * @dataProvider providerForTestAcceptValue - * - * @depends testConstruct - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\ContentTypeLimitation $limitation * @param \Ibexa\Core\Limitation\ContentTypeLimitationType $limitationType */ - public function testAcceptValue(ContentTypeLimitation $limitation, ContentTypeLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestAcceptValue')] + public function testAcceptValue(ContentTypeLimitation $limitation, ContentTypeLimitationType $limitationType): void { $limitationType->acceptValue($limitation); } @@ -88,7 +88,7 @@ public function testAcceptValue(ContentTypeLimitation $limitation, ContentTypeLi /** * @return array */ - public function providerForTestAcceptValueException() + public static function providerForTestAcceptValueException(): array { return [ [new ObjectStateLimitation()], @@ -97,14 +97,12 @@ public function providerForTestAcceptValueException() } /** - * @dataProvider providerForTestAcceptValueException - * - * @depends testConstruct - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation $limitation * @param \Ibexa\Core\Limitation\ContentTypeLimitationType $limitationType */ - public function testAcceptValueException(Limitation $limitation, ContentTypeLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestAcceptValueException')] + public function testAcceptValueException(Limitation $limitation, ContentTypeLimitationType $limitationType): void { $this->expectException(InvalidArgumentException::class); @@ -114,7 +112,7 @@ public function testAcceptValueException(Limitation $limitation, ContentTypeLimi /** * @return array */ - public function providerForTestValidatePass() + public static function providerForTestValidatePass(): array { return [ [new ContentTypeLimitation()], @@ -124,11 +122,10 @@ public function providerForTestValidatePass() } /** - * @dataProvider providerForTestValidatePass - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\ContentTypeLimitation $limitation */ - public function testValidatePass(ContentTypeLimitation $limitation) + #[DataProvider('providerForTestValidatePass')] + public function testValidatePass(ContentTypeLimitation $limitation): void { if (!empty($limitation->limitationValues)) { $this->getPersistenceMock() @@ -136,12 +133,14 @@ public function testValidatePass(ContentTypeLimitation $limitation) ->method('contentTypeHandler') ->will(self::returnValue($this->contentTypeHandlerMock)); - foreach ($limitation->limitationValues as $key => $value) { - $this->contentTypeHandlerMock - ->expects(self::at($key)) - ->method('load') - ->with($value); - } + $limitationValues = $limitation->limitationValues; + $matcher = self::exactly(count($limitationValues)); + $this->contentTypeHandlerMock + ->expects($matcher) + ->method('load') + ->willReturnCallback(static function ($actualValue) use ($matcher, $limitationValues): void { + self::assertSame($limitationValues[$matcher->numberOfInvocations() - 1], $actualValue); + }); } // Need to create inline instead of depending on testConstruct() to get correct mock instance @@ -154,7 +153,7 @@ public function testValidatePass(ContentTypeLimitation $limitation) /** * @return array */ - public function providerForTestValidateError() + public static function providerForTestValidateError(): array { return [ [new ContentTypeLimitation(), 0], @@ -164,12 +163,11 @@ public function providerForTestValidateError() } /** - * @dataProvider providerForTestValidateError - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\ContentTypeLimitation $limitation * @param int $errorCount */ - public function testValidateError(ContentTypeLimitation $limitation, $errorCount) + #[DataProvider('providerForTestValidateError')] + public function testValidateError(ContentTypeLimitation $limitation, $errorCount): void { if (!empty($limitation->limitationValues)) { $this->getPersistenceMock() @@ -177,13 +175,17 @@ public function testValidateError(ContentTypeLimitation $limitation, $errorCount ->method('contentTypeHandler') ->will(self::returnValue($this->contentTypeHandlerMock)); - foreach ($limitation->limitationValues as $key => $value) { - $this->contentTypeHandlerMock - ->expects(self::at($key)) - ->method('load') - ->with($value) - ->will(self::throwException(new NotFoundException('contentType', $value))); - } + $limitationValues = $limitation->limitationValues; + $matcher = self::exactly(count($limitationValues)); + $this->contentTypeHandlerMock + ->expects($matcher) + ->method('load') + ->willReturnCallback(static function ($actualValue) use ($matcher, $limitationValues): void { + $value = $limitationValues[$matcher->numberOfInvocations() - 1]; + self::assertSame($value, $actualValue); + + throw new NotFoundException('contentType', $value); + }); } else { $this->getPersistenceMock() ->expects(self::never()) @@ -198,11 +200,10 @@ public function testValidateError(ContentTypeLimitation $limitation, $errorCount } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\ContentTypeLimitationType $limitationType */ - public function testBuildValue(ContentTypeLimitationType $limitationType) + #[Depends('testConstruct')] + public function testBuildValue(ContentTypeLimitationType $limitationType): void { $expected = ['test', 'test' => 9]; $value = $limitationType->buildValue($expected); @@ -215,28 +216,17 @@ public function testBuildValue(ContentTypeLimitationType $limitationType) /** * @return array */ - public function providerForTestEvaluate() + public static function providerForTestEvaluate(): array { - // Mocks for testing Content & VersionInfo objects, should only be used once because of expect rules. - $contentMock = $this->createMock(APIContent::class); - $versionInfoMock = $this->createMock(APIVersionInfo::class); + $contentMock = new CoreContent([ + 'versionInfo' => new CoreVersionInfo([ + 'contentInfo' => new ContentInfo(['contentTypeId' => 66]), + ]), + ]); - $contentMock - ->expects(self::once()) - ->method('getVersionInfo') - ->will(self::returnValue($versionInfoMock)); - - $versionInfoMock - ->expects(self::once()) - ->method('getContentInfo') - ->will(self::returnValue(new ContentInfo(['contentTypeId' => 66]))); - - $versionInfoMock2 = $this->createMock(APIVersionInfo::class); - - $versionInfoMock2 - ->expects(self::once()) - ->method('getContentInfo') - ->will(self::returnValue(new ContentInfo(['contentTypeId' => 66]))); + $versionInfoMock2 = new CoreVersionInfo([ + 'contentInfo' => new ContentInfo(['contentTypeId' => 66]), + ]); return [ // ContentInfo, no access @@ -305,15 +295,13 @@ public function providerForTestEvaluate() ]; } - /** - * @dataProvider providerForTestEvaluate - */ + #[DataProvider('providerForTestEvaluate')] public function testEvaluate( ContentTypeLimitation $limitation, ValueObject $object, array $targets, $expected - ) { + ): void { // Need to create inline instead of depending on testConstruct() to get correct mock instance $limitationType = $this->testConstruct(); @@ -341,7 +329,7 @@ public function testEvaluate( /** * @return array */ - public function providerForTestEvaluateInvalidArgument() + public static function providerForTestEvaluateInvalidArgument(): array { return [ // invalid limitation @@ -359,14 +347,12 @@ public function providerForTestEvaluateInvalidArgument() ]; } - /** - * @dataProvider providerForTestEvaluateInvalidArgument - */ + #[DataProvider('providerForTestEvaluateInvalidArgument')] public function testEvaluateInvalidArgument( Limitation $limitation, ValueObject $object, array $targets - ) { + ): void { $this->expectException(InvalidArgumentException::class); // Need to create inline instead of depending on testConstruct() to get correct mock instance @@ -392,11 +378,10 @@ public function testEvaluateInvalidArgument( } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\ContentTypeLimitationType $limitationType */ - public function testGetCriterionInvalidValue(ContentTypeLimitationType $limitationType) + #[Depends('testConstruct')] + public function testGetCriterionInvalidValue(ContentTypeLimitationType $limitationType): void { $this->expectException(\RuntimeException::class); @@ -407,11 +392,10 @@ public function testGetCriterionInvalidValue(ContentTypeLimitationType $limitati } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\ContentTypeLimitationType $limitationType */ - public function testGetCriterionSingleValue(ContentTypeLimitationType $limitationType) + #[Depends('testConstruct')] + public function testGetCriterionSingleValue(ContentTypeLimitationType $limitationType): void { $criterion = $limitationType->getCriterion( new ContentTypeLimitation(['limitationValues' => [9]]), @@ -426,11 +410,10 @@ public function testGetCriterionSingleValue(ContentTypeLimitationType $limitatio } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\ContentTypeLimitationType $limitationType */ - public function testGetCriterionMultipleValues(ContentTypeLimitationType $limitationType) + #[Depends('testConstruct')] + public function testGetCriterionMultipleValues(ContentTypeLimitationType $limitationType): void { $criterion = $limitationType->getCriterion( new ContentTypeLimitation(['limitationValues' => [9, 55]]), @@ -445,11 +428,10 @@ public function testGetCriterionMultipleValues(ContentTypeLimitationType $limita } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\ContentTypeLimitationType $limitationType */ - public function testValueSchema(ContentTypeLimitationType $limitationType) + #[Depends('testConstruct')] + public function testValueSchema(ContentTypeLimitationType $limitationType): void { $this->expectException(NotImplementedException::class); diff --git a/tests/lib/Limitation/LanguageLimitation/ContentDeleteEvaluatorTest.php b/tests/lib/Limitation/LanguageLimitation/ContentDeleteEvaluatorTest.php index 9722535f8c..67827189db 100644 --- a/tests/lib/Limitation/LanguageLimitation/ContentDeleteEvaluatorTest.php +++ b/tests/lib/Limitation/LanguageLimitation/ContentDeleteEvaluatorTest.php @@ -11,13 +11,12 @@ use Ibexa\Contracts\Core\Limitation\Target; use Ibexa\Contracts\Core\Repository\Values\User\Limitation; use Ibexa\Core\Limitation\LanguageLimitation\ContentDeleteEvaluator; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; final class ContentDeleteEvaluatorTest extends TestCase { - /** - * @dataProvider dataProviderForAccept - */ + #[DataProvider('dataProviderForAccept')] public function testAccept(Target\Version $targetVersion, bool $expected): void { self::assertSame( @@ -26,15 +25,15 @@ public function testAccept(Target\Version $targetVersion, bool $expected): void ); } - public function dataProviderForAccept(): iterable + public static function dataProviderForAccept(): iterable { yield [ - $this->getTergetVersion(['eng-GB', 'ger-DE']), + self::getTergetVersion(['eng-GB', 'ger-DE']), true, ]; yield [ - $this->getTergetVersion([]), + self::getTergetVersion([]), false, ]; @@ -44,9 +43,7 @@ public function dataProviderForAccept(): iterable ]; } - /** - * @dataProvider dataProviderForEvaluate - */ + #[DataProvider('dataProviderForEvaluate')] public function testEvaluate(Target\Version $targetVersion, Limitation $limitationValue, bool $expected): void { self::assertSame( @@ -55,39 +52,39 @@ public function testEvaluate(Target\Version $targetVersion, Limitation $limitati ); } - public function dataProviderForEvaluate(): iterable + public static function dataProviderForEvaluate(): iterable { yield 'same_values' => [ - $this->getTergetVersion(['eng-GB', 'ger-DE']), - $this->getLanguageLimitation(['eng-GB', 'ger-DE']), + self::getTergetVersion(['eng-GB', 'ger-DE']), + self::getLanguageLimitation(['eng-GB', 'ger-DE']), true, ]; yield 'missing_fr_limitation' => [ - $this->getTergetVersion(['eng-GB', 'ger-DE', 'fre-FR']), - $this->getLanguageLimitation(['eng-GB', 'ger-DE']), + self::getTergetVersion(['eng-GB', 'ger-DE', 'fre-FR']), + self::getLanguageLimitation(['eng-GB', 'ger-DE']), false, ]; yield 'extra_fr_limitation' => [ - $this->getTergetVersion(['eng-GB', 'ger-DE']), - $this->getLanguageLimitation(['eng-GB', 'ger-DE', 'fre-FR']), + self::getTergetVersion(['eng-GB', 'ger-DE']), + self::getLanguageLimitation(['eng-GB', 'ger-DE', 'fre-FR']), true, ]; yield 'separable_values' => [ - $this->getTergetVersion(['eng-GB']), - $this->getLanguageLimitation(['fre-FR']), + self::getTergetVersion(['eng-GB']), + self::getLanguageLimitation(['fre-FR']), false, ]; } - private function getTergetVersion(array $languageCodes): Target\Version + private static function getTergetVersion(array $languageCodes): Target\Version { return (new Target\Version())->deleteTranslations($languageCodes); } - private function getLanguageLimitation(array $languageCodes): Limitation\LanguageLimitation + private static function getLanguageLimitation(array $languageCodes): Limitation\LanguageLimitation { return new Limitation\LanguageLimitation(['limitationValues' => $languageCodes]); } diff --git a/tests/lib/Limitation/LocationLimitationTypeTest.php b/tests/lib/Limitation/LocationLimitationTypeTest.php index da4900c708..8ad043a4ce 100644 --- a/tests/lib/Limitation/LocationLimitationTypeTest.php +++ b/tests/lib/Limitation/LocationLimitationTypeTest.php @@ -9,20 +9,22 @@ use Ibexa\Contracts\Core\Persistence\Content\Location\Handler as SPIHandler; use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException; -use Ibexa\Contracts\Core\Repository\Values\Content\Content as APIContent; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; use Ibexa\Contracts\Core\Repository\Values\Content\LocationCreateStruct; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\LocationId; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\Operator; -use Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo as APIVersionInfo; use Ibexa\Contracts\Core\Repository\Values\User\Limitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\LocationLimitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\ObjectStateLimitation; use Ibexa\Contracts\Core\Repository\Values\ValueObject; use Ibexa\Core\Base\Exceptions\NotFoundException; use Ibexa\Core\Limitation\LocationLimitationType; +use Ibexa\Core\Repository\Values\Content\Content as CoreContent; use Ibexa\Core\Repository\Values\Content\ContentCreateStruct; use Ibexa\Core\Repository\Values\Content\Location; +use Ibexa\Core\Repository\Values\Content\VersionInfo as CoreVersionInfo; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; /** * Test Case for LimitationType. @@ -53,7 +55,7 @@ protected function tearDown(): void /** * @return \Ibexa\Core\Limitation\LocationLimitationType */ - public function testConstruct() + public function testConstruct(): LocationLimitationType { return new LocationLimitationType($this->getPersistenceMock()); } @@ -61,7 +63,7 @@ public function testConstruct() /** * @return array */ - public function providerForTestAcceptValue() + public static function providerForTestAcceptValue(): array { return [ [new LocationLimitation()], @@ -71,14 +73,12 @@ public function providerForTestAcceptValue() } /** - * @dataProvider providerForTestAcceptValue - * - * @depends testConstruct - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\LocationLimitation $limitation * @param \Ibexa\Core\Limitation\LocationLimitationType $limitationType */ - public function testAcceptValue(LocationLimitation $limitation, LocationLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestAcceptValue')] + public function testAcceptValue(LocationLimitation $limitation, LocationLimitationType $limitationType): void { $limitationType->acceptValue($limitation); } @@ -86,7 +86,7 @@ public function testAcceptValue(LocationLimitation $limitation, LocationLimitati /** * @return array */ - public function providerForTestAcceptValueException() + public static function providerForTestAcceptValueException(): array { return [ [new ObjectStateLimitation()], @@ -95,14 +95,12 @@ public function providerForTestAcceptValueException() } /** - * @dataProvider providerForTestAcceptValueException - * - * @depends testConstruct - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation $limitation * @param \Ibexa\Core\Limitation\LocationLimitationType $limitationType */ - public function testAcceptValueException(Limitation $limitation, LocationLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestAcceptValueException')] + public function testAcceptValueException(Limitation $limitation, LocationLimitationType $limitationType): void { $this->expectException(InvalidArgumentException::class); @@ -112,7 +110,7 @@ public function testAcceptValueException(Limitation $limitation, LocationLimitat /** * @return array */ - public function providerForTestValidatePass() + public static function providerForTestValidatePass(): array { return [ [new LocationLimitation()], @@ -122,11 +120,10 @@ public function providerForTestValidatePass() } /** - * @dataProvider providerForTestValidatePass - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\LocationLimitation $limitation */ - public function testValidatePass(LocationLimitation $limitation) + #[DataProvider('providerForTestValidatePass')] + public function testValidatePass(LocationLimitation $limitation): void { if (!empty($limitation->limitationValues)) { $this->getPersistenceMock() @@ -134,12 +131,14 @@ public function testValidatePass(LocationLimitation $limitation) ->method('locationHandler') ->will(self::returnValue($this->locationHandlerMock)); - foreach ($limitation->limitationValues as $key => $value) { - $this->locationHandlerMock - ->expects(self::at($key)) - ->method('load') - ->with($value); - } + $limitationValues = $limitation->limitationValues; + $matcher = self::exactly(count($limitationValues)); + $this->locationHandlerMock + ->expects($matcher) + ->method('load') + ->willReturnCallback(static function ($actualValue, ?array $translations = null, bool $useAlwaysAvailable = true) use ($matcher, $limitationValues): void { + self::assertSame($limitationValues[$matcher->numberOfInvocations() - 1], $actualValue); + }); } // Need to create inline instead of depending on testConstruct() to get correct mock instance @@ -152,7 +151,7 @@ public function testValidatePass(LocationLimitation $limitation) /** * @return array */ - public function providerForTestValidateError() + public static function providerForTestValidateError(): array { return [ [new LocationLimitation(), 0], @@ -162,12 +161,11 @@ public function providerForTestValidateError() } /** - * @dataProvider providerForTestValidateError - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\LocationLimitation $limitation * @param int $errorCount */ - public function testValidateError(LocationLimitation $limitation, $errorCount) + #[DataProvider('providerForTestValidateError')] + public function testValidateError(LocationLimitation $limitation, $errorCount): void { if (!empty($limitation->limitationValues)) { $this->getPersistenceMock() @@ -175,13 +173,17 @@ public function testValidateError(LocationLimitation $limitation, $errorCount) ->method('locationHandler') ->will(self::returnValue($this->locationHandlerMock)); - foreach ($limitation->limitationValues as $key => $value) { - $this->locationHandlerMock - ->expects(self::at($key)) - ->method('load') - ->with($value) - ->will(self::throwException(new NotFoundException('location', $value))); - } + $limitationValues = $limitation->limitationValues; + $matcher = self::exactly(count($limitationValues)); + $this->locationHandlerMock + ->expects($matcher) + ->method('load') + ->willReturnCallback(static function ($actualValue, ?array $translations = null, bool $useAlwaysAvailable = true) use ($matcher, $limitationValues): void { + $value = $limitationValues[$matcher->numberOfInvocations() - 1]; + self::assertSame($value, $actualValue); + + throw new NotFoundException('location', $value); + }); } else { $this->getPersistenceMock() ->expects(self::never()) @@ -196,11 +198,10 @@ public function testValidateError(LocationLimitation $limitation, $errorCount) } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\LocationLimitationType $limitationType */ - public function testBuildValue(LocationLimitationType $limitationType) + #[Depends('testConstruct')] + public function testBuildValue(LocationLimitationType $limitationType): void { $expected = ['test', 'test' => 9]; $value = $limitationType->buildValue($expected); @@ -213,28 +214,17 @@ public function testBuildValue(LocationLimitationType $limitationType) /** * @return array */ - public function providerForTestEvaluate() + public static function providerForTestEvaluate(): array { - // Mocks for testing Content & VersionInfo objects, should only be used once because of expect rules. - $contentMock = $this->createMock(APIContent::class); - $versionInfoMock = $this->createMock(APIVersionInfo::class); - - $contentMock - ->expects(self::once()) - ->method('getVersionInfo') - ->will(self::returnValue($versionInfoMock)); - - $versionInfoMock - ->expects(self::once()) - ->method('getContentInfo') - ->will(self::returnValue(new ContentInfo(['published' => true]))); - - $versionInfoMock2 = $this->createMock(APIVersionInfo::class); + $contentMock = new CoreContent([ + 'versionInfo' => new CoreVersionInfo([ + 'contentInfo' => new ContentInfo(['published' => true]), + ]), + ]); - $versionInfoMock2 - ->expects(self::once()) - ->method('getContentInfo') - ->will(self::returnValue(new ContentInfo(['published' => true]))); + $versionInfoMock2 = new CoreVersionInfo([ + 'contentInfo' => new ContentInfo(['published' => true]), + ]); return [ // ContentInfo, with targets, no access @@ -242,7 +232,7 @@ public function providerForTestEvaluate() 'limitation' => new LocationLimitation(), 'object' => new ContentInfo(['published' => true]), 'targets' => [new Location(['id' => 55])], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => false, ], // ContentInfo, with targets, no access @@ -250,7 +240,7 @@ public function providerForTestEvaluate() 'limitation' => new LocationLimitation(['limitationValues' => [2]]), 'object' => new ContentInfo(['published' => true]), 'targets' => [new Location(['id' => 55])], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => false, ], // ContentInfo, with targets, with access @@ -258,7 +248,7 @@ public function providerForTestEvaluate() 'limitation' => new LocationLimitation(['limitationValues' => [2]]), 'object' => new ContentInfo(['id' => 23, 'published' => true]), 'targets' => [new Location(['id' => 2])], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => true, ], // ContentInfo, no targets, with access @@ -266,7 +256,7 @@ public function providerForTestEvaluate() 'limitation' => new LocationLimitation(['limitationValues' => [2]]), 'object' => new ContentInfo(['id' => 23, 'published' => true]), 'targets' => null, - 'persistence' => [new Location(['id' => 2])], + 'persistenceLocations' => [new Location(['id' => 2])], 'expected' => true, ], // ContentInfo, no targets, no access @@ -274,7 +264,7 @@ public function providerForTestEvaluate() 'limitation' => new LocationLimitation(['limitationValues' => [2, 43]]), 'object' => new ContentInfo(['id' => 23, 'published' => true]), 'targets' => null, - 'persistence' => [new Location(['id' => 55])], + 'persistenceLocations' => [new Location(['id' => 55])], 'expected' => false, ], // ContentInfo, no targets, un-published, with access @@ -286,7 +276,7 @@ public function providerForTestEvaluate() 'status' => ContentInfo::STATUS_DRAFT, ]), 'targets' => null, - 'persistence' => [new Location(['id' => 2])], + 'persistenceLocations' => [new Location(['id' => 2])], 'expected' => true, ], // ContentInfo, no targets, un-published, no access @@ -298,7 +288,7 @@ public function providerForTestEvaluate() 'status' => ContentInfo::STATUS_DRAFT, ]), 'targets' => null, - 'persistence' => [new Location(['id' => 55])], + 'persistenceLocations' => [new Location(['id' => 55])], 'expected' => false, ], // Content, with targets, with access @@ -306,7 +296,7 @@ public function providerForTestEvaluate() 'limitation' => new LocationLimitation(['limitationValues' => [2]]), 'object' => $contentMock, 'targets' => [new Location(['id' => 2])], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => true, ], // VersionInfo, with targets, with access @@ -314,7 +304,7 @@ public function providerForTestEvaluate() 'limitation' => new LocationLimitation(['limitationValues' => [2]]), 'object' => $versionInfoMock2, 'targets' => [new Location(['id' => 2])], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => true, ], // ContentCreateStruct, no targets, no access @@ -322,7 +312,7 @@ public function providerForTestEvaluate() 'limitation' => new LocationLimitation(['limitationValues' => [2]]), 'object' => new ContentCreateStruct(), 'targets' => [], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => false, ], // ContentCreateStruct, with targets, no access @@ -330,7 +320,7 @@ public function providerForTestEvaluate() 'limitation' => new LocationLimitation(['limitationValues' => [2, 43]]), 'object' => new ContentCreateStruct(), 'targets' => [new LocationCreateStruct(['parentLocationId' => 55])], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => false, ], // ContentCreateStruct, with targets, with access @@ -338,22 +328,20 @@ public function providerForTestEvaluate() 'limitation' => new LocationLimitation(['limitationValues' => [2, 43]]), 'object' => new ContentCreateStruct(), 'targets' => [new LocationCreateStruct(['parentLocationId' => 43])], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => true, ], ]; } - /** - * @dataProvider providerForTestEvaluate - */ + #[DataProvider('providerForTestEvaluate')] public function testEvaluate( LocationLimitation $limitation, ValueObject $object, $targets, array $persistenceLocations, $expected - ) { + ): void { // Need to create inline instead of depending on testConstruct() to get correct mock instance $limitationType = $this->testConstruct(); @@ -394,7 +382,7 @@ public function testEvaluate( /** * @return array */ - public function providerForTestEvaluateInvalidArgument() + public static function providerForTestEvaluateInvalidArgument(): array { return [ // invalid limitation @@ -402,41 +390,39 @@ public function providerForTestEvaluateInvalidArgument() 'limitation' => new ObjectStateLimitation(), 'object' => new ContentInfo(), 'targets' => [new Location()], - 'persistence' => [], + 'persistenceLocations' => [], ], // invalid object [ 'limitation' => new LocationLimitation(), 'object' => new ObjectStateLimitation(), 'targets' => [new Location()], - 'persistence' => [], + 'persistenceLocations' => [], ], // invalid target [ 'limitation' => new LocationLimitation(), 'object' => new ContentInfo(), 'targets' => [new ObjectStateLimitation()], - 'persistence' => [], + 'persistenceLocations' => [], ], // invalid target when using ContentCreateStruct [ 'limitation' => new LocationLimitation(), 'object' => new ContentCreateStruct(), 'targets' => [new Location()], - 'persistence' => [], + 'persistenceLocations' => [], ], ]; } - /** - * @dataProvider providerForTestEvaluateInvalidArgument - */ + #[DataProvider('providerForTestEvaluateInvalidArgument')] public function testEvaluateInvalidArgument( Limitation $limitation, ValueObject $object, $targets, array $persistenceLocations - ) { + ): void { $this->expectException(InvalidArgumentException::class); // Need to create inline instead of depending on testConstruct() to get correct mock instance @@ -462,11 +448,10 @@ public function testEvaluateInvalidArgument( } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\LocationLimitationType $limitationType */ - public function testGetCriterionInvalidValue(LocationLimitationType $limitationType) + #[Depends('testConstruct')] + public function testGetCriterionInvalidValue(LocationLimitationType $limitationType): void { $this->expectException(\RuntimeException::class); @@ -477,11 +462,10 @@ public function testGetCriterionInvalidValue(LocationLimitationType $limitationT } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\LocationLimitationType $limitationType */ - public function testGetCriterionSingleValue(LocationLimitationType $limitationType) + #[Depends('testConstruct')] + public function testGetCriterionSingleValue(LocationLimitationType $limitationType): void { $criterion = $limitationType->getCriterion( new LocationLimitation(['limitationValues' => [9]]), @@ -496,11 +480,10 @@ public function testGetCriterionSingleValue(LocationLimitationType $limitationTy } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\LocationLimitationType $limitationType */ - public function testGetCriterionMultipleValues(LocationLimitationType $limitationType) + #[Depends('testConstruct')] + public function testGetCriterionMultipleValues(LocationLimitationType $limitationType): void { $criterion = $limitationType->getCriterion( new LocationLimitation(['limitationValues' => [9, 55]]), @@ -515,11 +498,10 @@ public function testGetCriterionMultipleValues(LocationLimitationType $limitatio } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\LocationLimitationType $limitationType */ - public function testValueSchema(LocationLimitationType $limitationType) + #[Depends('testConstruct')] + public function testValueSchema(LocationLimitationType $limitationType): void { self::assertEquals( LocationLimitationType::VALUE_SCHEMA_LOCATION_ID, diff --git a/tests/lib/Limitation/MemberOfLimitationTypeTest.php b/tests/lib/Limitation/MemberOfLimitationTypeTest.php index 5aaea11cc8..7771ef7a75 100644 --- a/tests/lib/Limitation/MemberOfLimitationTypeTest.php +++ b/tests/lib/Limitation/MemberOfLimitationTypeTest.php @@ -24,6 +24,7 @@ use Ibexa\Core\Repository\Values\User\UserGroup; use Ibexa\Core\Repository\Values\User\UserGroupRoleAssignment; use Ibexa\Core\Repository\Values\User\UserRoleAssignment; +use PHPUnit\Framework\Attributes\DataProvider; final class MemberOfLimitationTypeTest extends Base { @@ -38,16 +39,14 @@ protected function setUp(): void ); } - /** - * @dataProvider providerForTestAcceptValue - */ + #[DataProvider('providerForTestAcceptValue')] public function testAcceptValue(MemberOfLimitation $limitation): void { $this->expectNotToPerformAssertions(); $this->limitationType->acceptValue($limitation); } - public function providerForTestAcceptValue(): array + public static function providerForTestAcceptValue(): array { return [ [ @@ -63,16 +62,14 @@ public function providerForTestAcceptValue(): array ]; } - /** - * @dataProvider providerForTestAcceptValueException - */ + #[DataProvider('providerForTestAcceptValueException')] public function testAcceptValueException(MemberOfLimitation $limitation): void { $this->expectException(InvalidArgumentType::class); $this->limitationType->acceptValue($limitation); } - public function providerForTestAcceptValueException(): array + public static function providerForTestAcceptValueException(): array { return [ [ @@ -98,9 +95,7 @@ public function providerForTestAcceptValueException(): array ]; } - /** - * @dataProvider providerForTestAcceptValue - */ + #[DataProvider('providerForTestAcceptValue')] public function testValidatePass(MemberOfLimitation $limitation): void { $contentHandlerMock = $this->createMock(ContentHandlerInterface::class); @@ -118,21 +113,26 @@ public function testValidatePass(MemberOfLimitation $limitation): void self::assertEmpty($validationErrors); } - /** - * @dataProvider providerForTestValidateError - */ + #[DataProvider('providerForTestValidateError')] public function testValidateError(MemberOfLimitation $limitation, int $errorCount): void { $contentHandlerMock = $this->createMock(ContentHandlerInterface::class); if ($limitation->limitationValues !== null) { - $contentHandlerMock - ->method('loadContentInfo') - ->withConsecutive([14], [18]) - ->willReturnOnConsecutiveCalls( - self::throwException(new NotFoundException('UserGroup', 18)), - new ContentInfo() - ); + $matcher = $this->exactly(2); + $contentHandlerMock->expects($matcher) + ->method('loadContentInfo')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame(14, $parameters[0]); + + throw new NotFoundException('UserGroup', 18); + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame(18, $parameters[0]); + + return new ContentInfo(); + } + }); $this->getPersistenceMock() ->method('contentHandler') @@ -143,7 +143,7 @@ public function testValidateError(MemberOfLimitation $limitation, int $errorCoun self::assertCount($errorCount, $validationErrors); } - public function providerForTestValidateError(): array + public static function providerForTestValidateError(): array { return [ [ @@ -155,9 +155,7 @@ public function providerForTestValidateError(): array ]; } - /** - * @dataProvider providerForTestEvaluate - */ + #[DataProvider('providerForTestEvaluate')] public function testEvaluate( MemberOfLimitation $limitation, ValueObject $object, @@ -173,17 +171,21 @@ public function testEvaluate( new Location(['parentId' => 13]), new Location(['parentId' => 14]), ]); + $matcher = $this->exactly(2); - $locationHandlerMock - ->method('load') - ->withConsecutive( - [13], - [14] - ) - ->willReturnOnConsecutiveCalls( - new Location(['contentId' => 14]), - new Location(['contentId' => 25]) - ); + $locationHandlerMock->expects($matcher) + ->method('load')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame(13, $parameters[0]); + + return new Location(['contentId' => 14]); + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame(14, $parameters[0]); + + return new Location(['contentId' => 25]); + } + }); $this->getPersistenceMock() ->method('locationHandler') @@ -199,7 +201,7 @@ public function testEvaluate( self::assertEquals($expected, $value); } - public function providerForTestEvaluate(): array + public static function providerForTestEvaluate(): array { return [ 'valid_group_limitation' => [ @@ -349,9 +351,8 @@ public function providerForTestEvaluate(): array /** * @param \Ibexa\Core\Repository\Values\User\User|\Ibexa\Core\Repository\Values\User\UserRoleAssignment $object - * - * @dataProvider providerForTestEvaluateSelfGroup */ + #[DataProvider('providerForTestEvaluateSelfGroup')] public function testEvaluateSelfGroup( MemberOfLimitation $limitation, ValueObject $object, @@ -365,31 +366,40 @@ public function testEvaluateSelfGroup( foreach ($currentUserGroupLocations as $groupLocation) { $currentUserLocation[] = new Location(['parentId' => $groupLocation->contentId - 1]); } - $locationHandlerMock - ->method('loadLocationsByContent') - ->withConsecutive( - [$object instanceof User ? $object->getUserId() : $object->getUser()->getUserId()], - [$this->getUserMock()->getUserId()] - ) - ->willReturnOnConsecutiveCalls( - [ - new Location(['parentId' => 13]), - new Location(['parentId' => 43]), - ], - $currentUserLocation - ); - - $locationHandlerMock - ->method('load') - ->withConsecutive( - [13], - [43] - ) - ->willReturnOnConsecutiveCalls( - new Location(['contentId' => 14]), - new Location(['contentId' => 44]), - ...$currentUserGroupLocations - ); + $matcher = $this->exactly(2); + $locationHandlerMock->expects($matcher) + ->method('loadLocationsByContent')->willReturnCallback(function (...$parameters) use ($matcher, $object, $currentUserLocation) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame($object instanceof User ? $object->getUserId() : $object->getUser()->getUserId(), $parameters[0]); + + return [ + new Location(['parentId' => 13]), + new Location(['parentId' => 43]), + ]; + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame($this->getUserMock()->getUserId(), $parameters[0]); + + return $currentUserLocation; + } + }); + $matcher = $this->exactly(2 + count($currentUserGroupLocations)); + + $locationHandlerMock->expects($matcher) + ->method('load')->willReturnCallback(function (...$parameters) use ($matcher, $currentUserGroupLocations) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame(13, $parameters[0]); + + return new Location(['contentId' => 14]); + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame(43, $parameters[0]); + + return new Location(['contentId' => 44]); + } + + return $currentUserGroupLocations[$matcher->numberOfInvocations() - 3]; + }); $this->getPersistenceMock() ->method('locationHandler') @@ -408,7 +418,7 @@ public function testEvaluateSelfGroup( self::assertEquals($expected, $value); } - public function providerForTestEvaluateSelfGroup(): array + public static function providerForTestEvaluateSelfGroup(): array { return [ 'role_assign_to_user_in_same_group' => [ diff --git a/tests/lib/Limitation/NewObjectStateLimitationTypeTest.php b/tests/lib/Limitation/NewObjectStateLimitationTypeTest.php index 73fb5aabf1..6231705f61 100644 --- a/tests/lib/Limitation/NewObjectStateLimitationTypeTest.php +++ b/tests/lib/Limitation/NewObjectStateLimitationTypeTest.php @@ -21,6 +21,8 @@ use Ibexa\Core\Repository\Values\Content\Location; use Ibexa\Core\Repository\Values\Content\VersionInfo; use Ibexa\Core\Repository\Values\ObjectState\ObjectState; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; /** * Test Case for LimitationType. @@ -51,7 +53,7 @@ protected function tearDown(): void /** * @return \Ibexa\Core\Limitation\NewObjectStateLimitationType */ - public function testConstruct() + public function testConstruct(): NewObjectStateLimitationType { return new NewObjectStateLimitationType($this->getPersistenceMock()); } @@ -59,7 +61,7 @@ public function testConstruct() /** * @return array */ - public function providerForTestAcceptValue() + public static function providerForTestAcceptValue(): array { return [ [new NewObjectStateLimitation()], @@ -69,14 +71,12 @@ public function providerForTestAcceptValue() } /** - * @dataProvider providerForTestAcceptValue - * - * @depends testConstruct - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\NewObjectStateLimitation $limitation * @param \Ibexa\Core\Limitation\NewObjectStateLimitationType $limitationType */ - public function testAcceptValue(NewObjectStateLimitation $limitation, NewObjectStateLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestAcceptValue')] + public function testAcceptValue(NewObjectStateLimitation $limitation, NewObjectStateLimitationType $limitationType): void { $limitationType->acceptValue($limitation); } @@ -84,7 +84,7 @@ public function testAcceptValue(NewObjectStateLimitation $limitation, NewObjectS /** * @return array */ - public function providerForTestAcceptValueException() + public static function providerForTestAcceptValueException(): array { return [ [new ObjectStateLimitation()], @@ -93,14 +93,12 @@ public function providerForTestAcceptValueException() } /** - * @dataProvider providerForTestAcceptValueException - * - * @depends testConstruct - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation $limitation * @param \Ibexa\Core\Limitation\NewObjectStateLimitationType $limitationType */ - public function testAcceptValueException(Limitation $limitation, NewObjectStateLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestAcceptValueException')] + public function testAcceptValueException(Limitation $limitation, NewObjectStateLimitationType $limitationType): void { $this->expectException(InvalidArgumentException::class); @@ -110,7 +108,7 @@ public function testAcceptValueException(Limitation $limitation, NewObjectStateL /** * @return array */ - public function providerForTestValidatePass() + public static function providerForTestValidatePass(): array { return [ [new NewObjectStateLimitation()], @@ -120,11 +118,10 @@ public function providerForTestValidatePass() } /** - * @dataProvider providerForTestValidatePass - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\NewObjectStateLimitation $limitation */ - public function testValidatePass(NewObjectStateLimitation $limitation) + #[DataProvider('providerForTestValidatePass')] + public function testValidatePass(NewObjectStateLimitation $limitation): void { if (!empty($limitation->limitationValues)) { $this->getPersistenceMock() @@ -132,12 +129,14 @@ public function testValidatePass(NewObjectStateLimitation $limitation) ->method('objectStateHandler') ->will(self::returnValue($this->objectStateHandlerMock)); - foreach ($limitation->limitationValues as $key => $value) { - $this->objectStateHandlerMock - ->expects(self::at($key)) - ->method('load') - ->with($value); - } + $limitationValues = $limitation->limitationValues; + $matcher = self::exactly(count($limitationValues)); + $this->objectStateHandlerMock + ->expects($matcher) + ->method('load') + ->willReturnCallback(static function ($actualValue) use ($matcher, $limitationValues): void { + self::assertSame($limitationValues[$matcher->numberOfInvocations() - 1], $actualValue); + }); } // Need to create inline instead of depending on testConstruct() to get correct mock instance @@ -150,7 +149,7 @@ public function testValidatePass(NewObjectStateLimitation $limitation) /** * @return array */ - public function providerForTestValidateError() + public static function providerForTestValidateError(): array { return [ [new NewObjectStateLimitation(), 0], @@ -160,12 +159,11 @@ public function providerForTestValidateError() } /** - * @dataProvider providerForTestValidateError - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\NewObjectStateLimitation $limitation * @param int $errorCount */ - public function testValidateError(NewObjectStateLimitation $limitation, $errorCount) + #[DataProvider('providerForTestValidateError')] + public function testValidateError(NewObjectStateLimitation $limitation, $errorCount): void { if (!empty($limitation->limitationValues)) { $this->getPersistenceMock() @@ -173,13 +171,17 @@ public function testValidateError(NewObjectStateLimitation $limitation, $errorCo ->method('objectStateHandler') ->will(self::returnValue($this->objectStateHandlerMock)); - foreach ($limitation->limitationValues as $key => $value) { - $this->objectStateHandlerMock - ->expects(self::at($key)) - ->method('load') - ->with($value) - ->will(self::throwException(new NotFoundException('contentType', $value))); - } + $limitationValues = $limitation->limitationValues; + $matcher = self::exactly(count($limitationValues)); + $this->objectStateHandlerMock + ->expects($matcher) + ->method('load') + ->willReturnCallback(static function ($actualValue) use ($matcher, $limitationValues): void { + $value = $limitationValues[$matcher->numberOfInvocations() - 1]; + self::assertSame($value, $actualValue); + + throw new NotFoundException('contentType', $value); + }); } else { $this->getPersistenceMock() ->expects(self::never()) @@ -194,11 +196,10 @@ public function testValidateError(NewObjectStateLimitation $limitation, $errorCo } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\NewObjectStateLimitationType $limitationType */ - public function testBuildValue(NewObjectStateLimitationType $limitationType) + #[Depends('testConstruct')] + public function testBuildValue(NewObjectStateLimitationType $limitationType): void { $expected = ['test', 'test' => 9]; $value = $limitationType->buildValue($expected); @@ -211,7 +212,7 @@ public function testBuildValue(NewObjectStateLimitationType $limitationType) /** * @return array */ - public function providerForTestEvaluate() + public static function providerForTestEvaluate(): array { return [ // ContentInfo, no access @@ -259,15 +260,13 @@ public function providerForTestEvaluate() ]; } - /** - * @dataProvider providerForTestEvaluate - */ + #[DataProvider('providerForTestEvaluate')] public function testEvaluate( NewObjectStateLimitation $limitation, ValueObject $object, array $targets, $expected - ) { + ): void { // Need to create inline instead of depending on testConstruct() to get correct mock instance $limitationType = $this->testConstruct(); @@ -295,7 +294,7 @@ public function testEvaluate( /** * @return array */ - public function providerForTestEvaluateInvalidArgument() + public static function providerForTestEvaluateInvalidArgument(): array { return [ // invalid limitation @@ -319,14 +318,12 @@ public function providerForTestEvaluateInvalidArgument() ]; } - /** - * @dataProvider providerForTestEvaluateInvalidArgument - */ + #[DataProvider('providerForTestEvaluateInvalidArgument')] public function testEvaluateInvalidArgument( Limitation $limitation, ValueObject $object, array $targets - ) { + ): void { $this->expectException(InvalidArgumentException::class); // Need to create inline instead of depending on testConstruct() to get correct mock instance @@ -352,11 +349,10 @@ public function testEvaluateInvalidArgument( } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\NewObjectStateLimitationType $limitationType */ - public function testGetCriterion(NewObjectStateLimitationType $limitationType) + #[Depends('testConstruct')] + public function testGetCriterion(NewObjectStateLimitationType $limitationType): void { $this->expectException(NotImplementedException::class); @@ -367,11 +363,10 @@ public function testGetCriterion(NewObjectStateLimitationType $limitationType) } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\NewObjectStateLimitationType $limitationType */ - public function testValueSchema(NewObjectStateLimitationType $limitationType) + #[Depends('testConstruct')] + public function testValueSchema(NewObjectStateLimitationType $limitationType): void { $this->expectException(NotImplementedException::class); diff --git a/tests/lib/Limitation/ObjectStateLimitationTypeTest.php b/tests/lib/Limitation/ObjectStateLimitationTypeTest.php index 9f6602e838..c517c263fb 100644 --- a/tests/lib/Limitation/ObjectStateLimitationTypeTest.php +++ b/tests/lib/Limitation/ObjectStateLimitationTypeTest.php @@ -18,6 +18,8 @@ use Ibexa\Contracts\Core\Repository\Values\ValueObject; use Ibexa\Core\Limitation\ObjectStateLimitationType; use Ibexa\Core\Repository\Values\Content\ContentCreateStruct; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; /** * Test Case for LimitationType. @@ -80,7 +82,7 @@ protected function tearDown(): void /** * @return \Ibexa\Core\Limitation\ObjectStateLimitationType */ - public function testConstruct() + public function testConstruct(): ObjectStateLimitationType { return new ObjectStateLimitationType($this->getPersistenceMock()); } @@ -88,7 +90,7 @@ public function testConstruct() /** * @return array */ - public function providerForTestEvaluate(): array + public static function providerForTestEvaluate(): array { return [ 'ContentInfo, published, no Limitations, no access' => [ @@ -177,14 +179,12 @@ public function providerForTestEvaluate(): array ]; } - /** - * @dataProvider providerForTestEvaluate - */ + #[DataProvider('providerForTestEvaluate')] public function testEvaluate( ObjectStateLimitation $limitation, ValueObject $object, $expected - ) { + ): void { $getContentStateMap = [ [ 1, @@ -238,11 +238,10 @@ public function testEvaluate( } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\ObjectStateLimitationType $limitationType */ - public function testGetCriterionInvalidValue(ObjectStateLimitationType $limitationType) + #[Depends('testConstruct')] + public function testGetCriterionInvalidValue(ObjectStateLimitationType $limitationType): void { $this->expectException(\RuntimeException::class); @@ -253,11 +252,10 @@ public function testGetCriterionInvalidValue(ObjectStateLimitationType $limitati } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\ObjectStateLimitationType $limitationType */ - public function testGetCriterionSingleValue(ObjectStateLimitationType $limitationType) + #[Depends('testConstruct')] + public function testGetCriterionSingleValue(ObjectStateLimitationType $limitationType): void { $criterion = $limitationType->getCriterion( new ObjectStateLimitation(['limitationValues' => [2]]), @@ -271,7 +269,7 @@ public function testGetCriterionSingleValue(ObjectStateLimitationType $limitatio self::assertEquals([2], $criterion->value); } - public function testGetCriterionMultipleValuesFromSingleGroup() + public function testGetCriterionMultipleValuesFromSingleGroup(): void { $this->getPersistenceMock() ->method('objectStateHandler') @@ -300,7 +298,7 @@ public function testGetCriterionMultipleValuesFromSingleGroup() self::assertEquals([1, 2], $criterion->value); } - public function testGetCriterionMultipleValuesFromMultipleGroups() + public function testGetCriterionMultipleValuesFromMultipleGroups(): void { $this->getPersistenceMock() ->method('objectStateHandler') diff --git a/tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php b/tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php index 635fe0be9a..ef1df5efe9 100644 --- a/tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php +++ b/tests/lib/Limitation/ParentContentTypeLimitationTypeTest.php @@ -25,6 +25,8 @@ use Ibexa\Core\Limitation\ParentContentTypeLimitationType; use Ibexa\Core\Repository\Values\Content\ContentCreateStruct; use Ibexa\Core\Repository\Values\Content\Location; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; /** * Test Case for LimitationType. @@ -67,7 +69,7 @@ protected function tearDown(): void /** * @return \Ibexa\Core\Limitation\ParentContentTypeLimitationType */ - public function testConstruct() + public function testConstruct(): ParentContentTypeLimitationType { return new ParentContentTypeLimitationType($this->getPersistenceMock()); } @@ -75,7 +77,7 @@ public function testConstruct() /** * @return array */ - public function providerForTestAcceptValue() + public static function providerForTestAcceptValue(): array { return [ [new ParentContentTypeLimitation()], @@ -85,14 +87,12 @@ public function providerForTestAcceptValue() } /** - * @dataProvider providerForTestAcceptValue - * - * @depends testConstruct - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\ParentContentTypeLimitation $limitation * @param \Ibexa\Core\Limitation\ParentContentTypeLimitationType $limitationType */ - public function testAcceptValue(ParentContentTypeLimitation $limitation, ParentContentTypeLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestAcceptValue')] + public function testAcceptValue(ParentContentTypeLimitation $limitation, ParentContentTypeLimitationType $limitationType): void { $limitationType->acceptValue($limitation); } @@ -100,7 +100,7 @@ public function testAcceptValue(ParentContentTypeLimitation $limitation, ParentC /** * @return array */ - public function providerForTestAcceptValueException() + public static function providerForTestAcceptValueException(): array { return [ [new ObjectStateLimitation()], @@ -110,14 +110,12 @@ public function providerForTestAcceptValueException() } /** - * @dataProvider providerForTestAcceptValueException - * - * @depends testConstruct - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation $limitation * @param \Ibexa\Core\Limitation\ParentContentTypeLimitationType $limitationType */ - public function testAcceptValueException(Limitation $limitation, ParentContentTypeLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestAcceptValueException')] + public function testAcceptValueException(Limitation $limitation, ParentContentTypeLimitationType $limitationType): void { $this->expectException(InvalidArgumentException::class); @@ -127,7 +125,7 @@ public function testAcceptValueException(Limitation $limitation, ParentContentTy /** * @return array */ - public function providerForTestValidatePass() + public static function providerForTestValidatePass(): array { return [ [new ParentContentTypeLimitation()], @@ -137,11 +135,10 @@ public function providerForTestValidatePass() } /** - * @dataProvider providerForTestValidatePass - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\ParentContentTypeLimitation $limitation */ - public function testValidatePass(ParentContentTypeLimitation $limitation) + #[DataProvider('providerForTestValidatePass')] + public function testValidatePass(ParentContentTypeLimitation $limitation): void { if (!empty($limitation->limitationValues)) { $this->getPersistenceMock() @@ -149,13 +146,16 @@ public function testValidatePass(ParentContentTypeLimitation $limitation) ->method('contentTypeHandler') ->will(self::returnValue($this->contentTypeHandlerMock)); - foreach ($limitation->limitationValues as $key => $value) { - $this->contentTypeHandlerMock - ->expects(self::at($key)) - ->method('load') - ->with($value) - ->will(self::returnValue(42)); - } + $limitationValues = $limitation->limitationValues; + $matcher = self::exactly(count($limitationValues)); + $this->contentTypeHandlerMock + ->expects($matcher) + ->method('load') + ->willReturnCallback(static function ($actualValue) use ($matcher, $limitationValues) { + self::assertSame($limitationValues[$matcher->numberOfInvocations() - 1], $actualValue); + + return 42; + }); } // Need to create inline instead of depending on testConstruct() to get correct mock instance @@ -168,7 +168,7 @@ public function testValidatePass(ParentContentTypeLimitation $limitation) /** * @return array */ - public function providerForTestValidateError() + public static function providerForTestValidateError(): array { return [ [new ParentContentTypeLimitation(), 0], @@ -178,12 +178,11 @@ public function providerForTestValidateError() } /** - * @dataProvider providerForTestValidateError - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\ParentContentTypeLimitation $limitation * @param int $errorCount */ - public function testValidateError(ParentContentTypeLimitation $limitation, $errorCount) + #[DataProvider('providerForTestValidateError')] + public function testValidateError(ParentContentTypeLimitation $limitation, $errorCount): void { if (!empty($limitation->limitationValues)) { $this->getPersistenceMock() @@ -191,13 +190,17 @@ public function testValidateError(ParentContentTypeLimitation $limitation, $erro ->method('contentTypeHandler') ->will(self::returnValue($this->contentTypeHandlerMock)); - foreach ($limitation->limitationValues as $key => $value) { - $this->contentTypeHandlerMock - ->expects(self::at($key)) - ->method('load') - ->with($value) - ->will(self::throwException(new NotFoundException('location', $value))); - } + $limitationValues = $limitation->limitationValues; + $matcher = self::exactly(count($limitationValues)); + $this->contentTypeHandlerMock + ->expects($matcher) + ->method('load') + ->willReturnCallback(static function ($actualValue) use ($matcher, $limitationValues): void { + $value = $limitationValues[$matcher->numberOfInvocations() - 1]; + self::assertSame($value, $actualValue); + + throw new NotFoundException('location', $value); + }); } else { $this->getPersistenceMock() ->expects(self::never()) @@ -212,11 +215,10 @@ public function testValidateError(ParentContentTypeLimitation $limitation, $erro } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\ParentContentTypeLimitationType $limitationType */ - public function testBuildValue(ParentContentTypeLimitationType $limitationType) + #[Depends('testConstruct')] + public function testBuildValue(ParentContentTypeLimitationType $limitationType): void { $expected = ['test', 'test' => '1']; $value = $limitationType->buildValue($expected); @@ -253,7 +255,7 @@ protected function getTestEvaluateVersionInfoMock() /** * @return array */ - public function providerForTestEvaluate() + public static function providerForTestEvaluate(): array { return [ // ContentInfo, with API targets, no access @@ -367,7 +369,7 @@ public function providerForTestEvaluate() // Content, with API targets, with access [ 'limitation' => new ParentContentTypeLimitation(['limitationValues' => [42]]), - 'object' => $this->getTestEvaluateContentMock(), + 'object' => 'contentMock', 'targets' => [new Location(['contentInfo' => new ContentInfo(['contentTypeId' => 42])])], 'persistence' => [], 'expected' => true, @@ -375,7 +377,7 @@ public function providerForTestEvaluate() // Content, with SPI targets, with access [ 'limitation' => new ParentContentTypeLimitation(['limitationValues' => [42]]), - 'object' => $this->getTestEvaluateContentMock(), + 'object' => 'contentMock', 'targets' => [new SPILocation(['contentId' => '24'])], 'persistence' => [ 'contentInfos' => [new SPIContentInfo(['contentTypeId' => '42'])], @@ -385,7 +387,7 @@ public function providerForTestEvaluate() // VersionInfo, with API targets, with access [ 'limitation' => new ParentContentTypeLimitation(['limitationValues' => [42]]), - 'object' => $this->getTestEvaluateVersionInfoMock(), + 'object' => 'versionInfoMock', 'targets' => [new Location(['contentInfo' => new ContentInfo(['contentTypeId' => 42])])], 'persistence' => [], 'expected' => true, @@ -393,7 +395,7 @@ public function providerForTestEvaluate() // VersionInfo, with SPI targets, with access [ 'limitation' => new ParentContentTypeLimitation(['limitationValues' => [42]]), - 'object' => $this->getTestEvaluateVersionInfoMock(), + 'object' => 'versionInfoMock', 'targets' => [new SPILocation(['contentId' => '24'])], 'persistence' => [ 'contentInfos' => [new SPIContentInfo(['contentTypeId' => '42'])], @@ -403,7 +405,7 @@ public function providerForTestEvaluate() // VersionInfo, with LocationCreateStruct targets, with access [ 'limitation' => new ParentContentTypeLimitation(['limitationValues' => [42]]), - 'object' => $this->getTestEvaluateVersionInfoMock(), + 'object' => 'versionInfoMock', 'targets' => [new LocationCreateStruct(['parentLocationId' => 24])], 'persistence' => [ 'locations' => [new SPILocation(['contentId' => 100])], @@ -414,7 +416,7 @@ public function providerForTestEvaluate() // Content, with LocationCreateStruct targets, no access [ 'limitation' => new ParentContentTypeLimitation(['limitationValues' => [42]]), - 'object' => $this->getTestEvaluateContentMock(), + 'object' => 'contentMock', 'targets' => [new LocationCreateStruct(['parentLocationId' => 24])], 'persistence' => [ 'locations' => [new SPILocation(['contentId' => 100])], @@ -452,33 +454,68 @@ public function providerForTestEvaluate() ], 'expected' => true, ], + // ContentCreateStruct, with multiple LocationCreateStruct targets, with access + [ + 'limitation' => new ParentContentTypeLimitation(['limitationValues' => [12, 34]]), + 'object' => new ContentCreateStruct(), + 'targets' => [ + new LocationCreateStruct(['parentLocationId' => 43]), + new LocationCreateStruct(['parentLocationId' => 55]), + ], + 'persistence' => [ + 'locations' => [ + new SPILocation(['contentId' => 100]), + new SPILocation(['contentId' => 200]), + ], + 'contentInfos' => [ + new SPIContentInfo(['contentTypeId' => 12]), + new SPIContentInfo(['contentTypeId' => 34]), + ], + ], + 'expected' => true, + ], ]; } - protected function assertContentHandlerExpectations($callNo, $persistenceCalled, $contentId, $contentInfo) + /** + * @param int[]|string[] $contentIds + * @param \Ibexa\Contracts\Core\Persistence\Content\ContentInfo[] $contentInfos + */ + private function assertContentHandlerExpectations(array $contentIds, array $contentInfos): void { + $contentIds = array_values($contentIds); + $contentInfos = array_values($contentInfos); + $this->getPersistenceMock() - ->expects(self::at($callNo + ($persistenceCalled ? 1 : 0))) + ->expects(self::exactly(count($contentIds))) ->method('contentHandler') - ->will(self::returnValue($this->contentHandlerMock)); + ->willReturn($this->contentHandlerMock); + $matcher = self::exactly(count($contentIds)); $this->contentHandlerMock - ->expects(self::at($callNo)) + ->expects($matcher) ->method('loadContentInfo') - ->with($contentId) - ->will(self::returnValue($contentInfo)); + ->willReturnCallback(static function ($contentId) use ($matcher, $contentIds, $contentInfos) { + self::assertSame($contentIds[$matcher->numberOfInvocations() - 1], $contentId); + + return $contentInfos[$matcher->numberOfInvocations() - 1]; + }); } - /** - * @dataProvider providerForTestEvaluate - */ + #[DataProvider('providerForTestEvaluate')] public function testEvaluate( ParentContentTypeLimitation $limitation, - ValueObject $object, + $object, $targets, array $persistence, $expected - ) { + ): void { + if ($object === 'contentMock') { + $object = $this->getTestEvaluateContentMock(); + } elseif ($object === 'versionInfoMock') { + $object = $this->getTestEvaluateVersionInfoMock(); + } + // Need to create inline instead of depending on testConstruct() to get correct mock instance $limitationType = $this->testConstruct(); @@ -499,40 +536,47 @@ public function testEvaluate( ->expects(self::never()) ->method(self::anything()); } elseif (!empty($targets)) { + $locationLoadArguments = []; + $locationLoadReturnValues = []; + $contentIds = []; + $contentInfos = []; + foreach ($targets as $index => $target) { if ($target instanceof LocationCreateStruct) { - $this->getPersistenceMock() - ->expects(self::once()) - ->method('locationHandler') - ->will(self::returnValue($this->locationHandlerMock)); - - $this->locationHandlerMock - ->expects(self::at($index)) - ->method('load') - ->with($target->parentLocationId) - ->will(self::returnValue($location = $persistence['locations'][$index])); - - $contentId = $location->contentId; + $locationLoadArguments[] = $target->parentLocationId; + $location = $persistence['locations'][$index]; + $locationLoadReturnValues[] = $location; + $contentIds[] = $location->contentId; } else { - $contentId = $target->contentId; + $contentIds[] = $target->contentId; } - $this->assertContentHandlerExpectations( - $index, - $target instanceof LocationCreateStruct, - $contentId, - $persistence['contentInfos'][$index] - ); + $contentInfos[] = $persistence['contentInfos'][$index]; + } + + if ($locationLoadArguments !== []) { + $this->getPersistenceMock() + ->expects(self::exactly(count($locationLoadArguments))) + ->method('locationHandler') + ->willReturn($this->locationHandlerMock); + + $locationMatcher = self::exactly(count($locationLoadArguments)); + $this->locationHandlerMock + ->expects($locationMatcher) + ->method('load') + ->willReturnCallback(static function ($parentLocationId) use ($locationMatcher, $locationLoadArguments, $locationLoadReturnValues) { + self::assertSame($locationLoadArguments[$locationMatcher->numberOfInvocations() - 1], $parentLocationId); + + return $locationLoadReturnValues[$locationMatcher->numberOfInvocations() - 1]; + }); } + + $this->assertContentHandlerExpectations($contentIds, $contentInfos); } else { $this->getPersistenceMock() ->method('locationHandler') ->will(self::returnValue($this->locationHandlerMock)); - $this->getPersistenceMock() - ->method('contentHandler') - ->will(self::returnValue($this->contentHandlerMock)); - $this->locationHandlerMock ->method( $object instanceof ContentInfo && $object->published ? 'loadLocationsByContent' : 'loadParentLocationsForDraftContent' @@ -556,14 +600,21 @@ public function testEvaluate( } } - foreach ($persistence['locations'] as $index => $location) { - $this->assertContentHandlerExpectations( - $index, - true, - $location->contentId, - $persistence['contentInfos'][$index] - ); + $contentIds = []; + $contentInfos = []; + $contentInfoIndex = 0; + foreach ($persistence['locations'] as $location) { + // Locations with a depth > 0 are resolved to their parent location first (see + // ParentContentTypeLimitationType::loadParentLocations()); the parent's content ID + // is what evaluate() actually passes to contentHandler()->loadContentInfo(). + $target = $persistence['parentLocations'][$location->parentId] ?? $location; + + $contentIds[] = $target->contentId; + $contentInfos[] = $persistence['contentInfos'][$contentInfoIndex]; + ++$contentInfoIndex; } + + $this->assertContentHandlerExpectations($contentIds, $contentInfos); } $value = $limitationType->evaluate( @@ -580,7 +631,7 @@ public function testEvaluate( /** * @return array */ - public function providerForTestEvaluateInvalidArgument() + public static function providerForTestEvaluateInvalidArgument(): array { return [ // invalid limitation @@ -588,36 +639,30 @@ public function providerForTestEvaluateInvalidArgument() 'limitation' => new ObjectStateLimitation(), 'object' => new ContentInfo(), 'targets' => [new Location()], - 'persistence' => [], ], // invalid object [ 'limitation' => new ParentContentTypeLimitation(), 'object' => new ObjectStateLimitation(), 'targets' => [], - 'persistence' => [], ], // invalid target when using ContentCreateStruct [ 'limitation' => new ParentContentTypeLimitation(), 'object' => new ContentCreateStruct(), 'targets' => [new Location()], - 'persistence' => [], ], // invalid target when not using ContentCreateStruct [ 'limitation' => new ParentContentTypeLimitation(), 'object' => new ContentInfo(), 'targets' => [new ObjectStateLimitation()], - 'persistence' => [], ], ]; } - /** - * @dataProvider providerForTestEvaluateInvalidArgument - */ - public function testEvaluateInvalidArgument(Limitation $limitation, ValueObject $object, $targets) + #[DataProvider('providerForTestEvaluateInvalidArgument')] + public function testEvaluateInvalidArgument(Limitation $limitation, ValueObject $object, $targets): void { $this->expectException(InvalidArgumentException::class); @@ -643,11 +688,10 @@ public function testEvaluateInvalidArgument(Limitation $limitation, ValueObject } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\ParentContentTypeLimitationType $limitationType */ - public function testGetCriterionInvalidValue(ParentContentTypeLimitationType $limitationType) + #[Depends('testConstruct')] + public function testGetCriterionInvalidValue(ParentContentTypeLimitationType $limitationType): void { $this->expectException(NotImplementedException::class); @@ -658,11 +702,10 @@ public function testGetCriterionInvalidValue(ParentContentTypeLimitationType $li } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\ParentContentTypeLimitationType $limitationType */ - public function testValueSchema(ParentContentTypeLimitationType $limitationType) + #[Depends('testConstruct')] + public function testValueSchema(ParentContentTypeLimitationType $limitationType): void { self::markTestIncomplete('Method is not implemented yet: ' . __METHOD__); } diff --git a/tests/lib/Limitation/ParentDepthLimitationTypeTest.php b/tests/lib/Limitation/ParentDepthLimitationTypeTest.php index 545c44d161..b35a346d3a 100644 --- a/tests/lib/Limitation/ParentDepthLimitationTypeTest.php +++ b/tests/lib/Limitation/ParentDepthLimitationTypeTest.php @@ -9,17 +9,19 @@ use Ibexa\Contracts\Core\Persistence\Content\Location\Handler as SPILocationHandler; use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException; -use Ibexa\Contracts\Core\Repository\Values\Content\Content as APIContent; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; use Ibexa\Contracts\Core\Repository\Values\Content\LocationCreateStruct; -use Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo as APIVersionInfo; use Ibexa\Contracts\Core\Repository\Values\User\Limitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\ObjectStateLimitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\ParentDepthLimitation; use Ibexa\Contracts\Core\Repository\Values\ValueObject; use Ibexa\Core\Limitation\ParentDepthLimitationType; +use Ibexa\Core\Repository\Values\Content\Content as CoreContent; use Ibexa\Core\Repository\Values\Content\ContentCreateStruct; use Ibexa\Core\Repository\Values\Content\Location; +use Ibexa\Core\Repository\Values\Content\VersionInfo as CoreVersionInfo; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; /** * Test Case for LimitationType. @@ -52,7 +54,7 @@ protected function tearDown(): void /** * @return \Ibexa\Core\Limitation\ParentDepthLimitationType */ - public function testConstruct() + public function testConstruct(): ParentDepthLimitationType { return new ParentDepthLimitationType($this->getPersistenceMock()); } @@ -60,7 +62,7 @@ public function testConstruct() /** * @return array */ - public function providerForTestAcceptValue() + public static function providerForTestAcceptValue(): array { return [ [new ParentDepthLimitation()], @@ -70,14 +72,12 @@ public function providerForTestAcceptValue() } /** - * @dataProvider providerForTestAcceptValue - * - * @depends testConstruct - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\ParentDepthLimitation $limitation * @param \Ibexa\Core\Limitation\ParentDepthLimitationType $limitationType */ - public function testAcceptValue(ParentDepthLimitation $limitation, ParentDepthLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestAcceptValue')] + public function testAcceptValue(ParentDepthLimitation $limitation, ParentDepthLimitationType $limitationType): void { $limitationType->acceptValue($limitation); } @@ -85,7 +85,7 @@ public function testAcceptValue(ParentDepthLimitation $limitation, ParentDepthLi /** * @return array */ - public function providerForTestAcceptValueException() + public static function providerForTestAcceptValueException(): array { return [ [new ObjectStateLimitation()], @@ -94,14 +94,12 @@ public function providerForTestAcceptValueException() } /** - * @dataProvider providerForTestAcceptValueException - * - * @depends testConstruct - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation $limitation * @param \Ibexa\Core\Limitation\ParentDepthLimitationType $limitationType */ - public function testAcceptValueException(Limitation $limitation, ParentDepthLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestAcceptValueException')] + public function testAcceptValueException(Limitation $limitation, ParentDepthLimitationType $limitationType): void { $this->expectException(InvalidArgumentException::class); @@ -111,7 +109,7 @@ public function testAcceptValueException(Limitation $limitation, ParentDepthLimi /** * @return array */ - public function providerForTestValidatePass() + public static function providerForTestValidatePass(): array { return [ [new ParentDepthLimitation()], @@ -121,24 +119,21 @@ public function providerForTestValidatePass() } /** - * @dataProvider providerForTestValidatePass - * - * @depends testConstruct - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\ParentDepthLimitation $limitation */ - public function testValidatePass(ParentDepthLimitation $limitation, ParentDepthLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestValidatePass')] + public function testValidatePass(ParentDepthLimitation $limitation, ParentDepthLimitationType $limitationType): void { $validationErrors = $limitationType->validate($limitation); self::assertEmpty($validationErrors); } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\ParentDepthLimitationType $limitationType */ - public function testBuildValue(ParentDepthLimitationType $limitationType) + #[Depends('testConstruct')] + public function testBuildValue(ParentDepthLimitationType $limitationType): void { $expected = [2, 7]; $value = $limitationType->buildValue($expected); @@ -154,28 +149,18 @@ public function testBuildValue(ParentDepthLimitationType $limitationType) /** * @return array */ - public function providerForTestEvaluate() + public static function providerForTestEvaluate(): array { - // Mocks for testing Content & VersionInfo objects, should only be used once because of expect rules. - $contentMock = $this->createMock(APIContent::class); - $versionInfoMock = $this->createMock(APIVersionInfo::class); + // Real Content & VersionInfo objects, avoiding mocks since providers must be static. + $content = new CoreContent([ + 'versionInfo' => new CoreVersionInfo([ + 'contentInfo' => new ContentInfo(['published' => true]), + ]), + ]); - $contentMock - ->expects(self::once()) - ->method('getVersionInfo') - ->will(self::returnValue($versionInfoMock)); - - $versionInfoMock - ->expects(self::once()) - ->method('getContentInfo') - ->will(self::returnValue(new ContentInfo(['published' => true]))); - - $versionInfoMock2 = $this->createMock(APIVersionInfo::class); - - $versionInfoMock2 - ->expects(self::once()) - ->method('getContentInfo') - ->will(self::returnValue(new ContentInfo(['published' => true]))); + $versionInfo = new CoreVersionInfo([ + 'contentInfo' => new ContentInfo(['published' => true]), + ]); return [ // ContentInfo, with targets, no access @@ -183,7 +168,7 @@ public function providerForTestEvaluate() 'limitation' => new ParentDepthLimitation(), 'object' => new ContentInfo(['published' => true]), 'targets' => [new Location()], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => false, ], // ContentInfo, with targets, no access @@ -191,7 +176,7 @@ public function providerForTestEvaluate() 'limitation' => new ParentDepthLimitation(['limitationValues' => [2]]), 'object' => new ContentInfo(['published' => true]), 'targets' => [new Location(['depth' => 55])], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => false, ], // ContentInfo, with targets, with access @@ -199,7 +184,7 @@ public function providerForTestEvaluate() 'limitation' => new ParentDepthLimitation(['limitationValues' => [2]]), 'object' => new ContentInfo(['published' => true]), 'targets' => [new Location(['depth' => 2])], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => true, ], // ContentInfo, no targets, with access @@ -210,7 +195,7 @@ public function providerForTestEvaluate() 'published' => true, ]), 'targets' => null, - 'persistence' => [new Location(['depth' => 2])], + 'persistenceLocations' => [new Location(['depth' => 2])], 'expected' => true, ], // ContentInfo, no targets, no access @@ -221,7 +206,7 @@ public function providerForTestEvaluate() 'published' => true, ]), 'targets' => null, - 'persistence' => [new Location(['depth' => 55])], + 'persistenceLocations' => [new Location(['depth' => 55])], 'expected' => false, ], // ContentInfo, no targets, un-published, with access @@ -232,7 +217,7 @@ public function providerForTestEvaluate() 'published' => false, ]), 'targets' => null, - 'persistence' => [new Location(['depth' => 2])], + 'persistenceLocations' => [new Location(['depth' => 2])], 'expected' => true, ], // ContentInfo, no targets, un-published, no access @@ -243,23 +228,23 @@ public function providerForTestEvaluate() 'published' => false, ]), 'targets' => null, - 'persistence' => [new Location(['depth' => 55])], + 'persistenceLocations' => [new Location(['depth' => 55])], 'expected' => false, ], // Content, with targets, with access [ 'limitation' => new ParentDepthLimitation(['limitationValues' => [2]]), - 'object' => $contentMock, + 'object' => $content, 'targets' => [new Location(['depth' => 2])], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => true, ], // VersionInfo, with targets, with access [ 'limitation' => new ParentDepthLimitation(['limitationValues' => [2]]), - 'object' => $versionInfoMock2, + 'object' => $versionInfo, 'targets' => [new Location(['depth' => 2])], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => true, ], // ContentCreateStruct, no targets, no access @@ -267,7 +252,7 @@ public function providerForTestEvaluate() 'limitation' => new ParentDepthLimitation(['limitationValues' => [2]]), 'object' => new ContentCreateStruct(), 'targets' => [], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => false, ], // ContentCreateStruct, with targets, no access @@ -275,7 +260,7 @@ public function providerForTestEvaluate() 'limitation' => new ParentDepthLimitation(['limitationValues' => [2, 43]]), 'object' => new ContentCreateStruct(), 'targets' => [new LocationCreateStruct(['parentLocationId' => 55])], - 'persistence' => [ + 'persistenceLocations' => [ 55 => new Location(['depth' => 42]), ], 'expected' => false, @@ -285,24 +270,36 @@ public function providerForTestEvaluate() 'limitation' => new ParentDepthLimitation(['limitationValues' => [2, 42]]), 'object' => new ContentCreateStruct(), 'targets' => [new LocationCreateStruct(['parentLocationId' => 43])], - 'persistence' => [ + 'persistenceLocations' => [ + 43 => new Location(['depth' => 42]), + ], + 'expected' => true, + ], + // ContentCreateStruct, with multiple targets, with access + [ + 'limitation' => new ParentDepthLimitation(['limitationValues' => [2, 42]]), + 'object' => new ContentCreateStruct(), + 'targets' => [ + new LocationCreateStruct(['parentLocationId' => 43]), + new LocationCreateStruct(['parentLocationId' => 55]), + ], + 'persistenceLocations' => [ 43 => new Location(['depth' => 42]), + 55 => new Location(['depth' => 2]), ], 'expected' => true, ], ]; } - /** - * @dataProvider providerForTestEvaluate - */ + #[DataProvider('providerForTestEvaluate')] public function testEvaluate( ParentDepthLimitation $limitation, ValueObject $object, $targets, array $persistenceLocations, $expected - ) { + ): void { // Need to create inline instead of depending on testConstruct() to get correct mock instance $limitationType = $this->testConstruct(); @@ -317,18 +314,25 @@ public function testEvaluate( ->expects(self::never()) ->method(self::anything()); } elseif ($object instanceof ContentCreateStruct) { + $parentLocationIds = array_map( + static fn (LocationCreateStruct $target): int => $target->parentLocationId, + array_values($targets) + ); + $this->getPersistenceMock() - ->expects(self::once()) + ->expects(self::exactly(count($parentLocationIds))) ->method('locationHandler') - ->will(self::returnValue($this->locationHandlerMock)); + ->willReturn($this->locationHandlerMock); + + $matcher = self::exactly(count($parentLocationIds)); + $this->locationHandlerMock + ->expects($matcher) + ->method('load') + ->willReturnCallback(static function ($parentLocationId) use ($matcher, $parentLocationIds, $persistenceLocations) { + self::assertSame($parentLocationIds[$matcher->numberOfInvocations() - 1], $parentLocationId); - foreach ($targets as $target) { - $this->locationHandlerMock - ->expects(self::once()) - ->method('load') - ->with($target->parentLocationId) - ->will(self::returnValue($persistenceLocations[$target->parentLocationId])); - } + return $persistenceLocations[$parentLocationId]; + }); } else { $this->getPersistenceMock() ->expects(self::once()) @@ -360,7 +364,7 @@ public function testEvaluate( /** * @return array */ - public function providerForTestEvaluateInvalidArgument() + public static function providerForTestEvaluateInvalidArgument(): array { return [ // invalid limitation @@ -368,41 +372,39 @@ public function providerForTestEvaluateInvalidArgument() 'limitation' => new ObjectStateLimitation(), 'object' => new ContentInfo(), 'targets' => [new Location()], - 'persistence' => [], + 'persistenceLocations' => [], ], // invalid object [ 'limitation' => new ParentDepthLimitation(), 'object' => new ObjectStateLimitation(), 'targets' => [new Location()], - 'persistence' => [], + 'persistenceLocations' => [], ], // invalid target [ 'limitation' => new ParentDepthLimitation(), 'object' => new ContentInfo(), 'targets' => [new ObjectStateLimitation()], - 'persistence' => [], + 'persistenceLocations' => [], ], // invalid target when using ContentCreateStruct [ 'limitation' => new ParentDepthLimitation(), 'object' => new ContentCreateStruct(), 'targets' => [new Location()], - 'persistence' => [], + 'persistenceLocations' => [], ], ]; } - /** - * @dataProvider providerForTestEvaluateInvalidArgument - */ + #[DataProvider('providerForTestEvaluateInvalidArgument')] public function testEvaluateInvalidArgument( Limitation $limitation, ValueObject $object, $targets, array $persistenceLocations - ) { + ): void { $this->expectException(InvalidArgumentException::class); // Need to create inline instead of depending on testConstruct() to get correct mock instance diff --git a/tests/lib/Limitation/RoleLimitationTypeTest.php b/tests/lib/Limitation/RoleLimitationTypeTest.php index ea6035ea61..9e36564597 100644 --- a/tests/lib/Limitation/RoleLimitationTypeTest.php +++ b/tests/lib/Limitation/RoleLimitationTypeTest.php @@ -25,6 +25,7 @@ use Ibexa\Core\Repository\Values\User\UserGroup; use Ibexa\Core\Repository\Values\User\UserGroupRoleAssignment; use Ibexa\Core\Repository\Values\User\UserRoleAssignment; +use PHPUnit\Framework\Attributes\DataProvider; final class RoleLimitationTypeTest extends Base { @@ -39,16 +40,14 @@ protected function setUp(): void ); } - /** - * @dataProvider providerForTestAcceptValue - */ + #[DataProvider('providerForTestAcceptValue')] public function testAcceptValue(UserRoleLimitation $limitation): void { $this->expectNotToPerformAssertions(); $this->limitationType->acceptValue($limitation); } - public function providerForTestAcceptValue(): array + public static function providerForTestAcceptValue(): array { return [ [ @@ -64,16 +63,14 @@ public function providerForTestAcceptValue(): array ]; } - /** - * @dataProvider providerForTestAcceptValueException - */ + #[DataProvider('providerForTestAcceptValueException')] public function testAcceptValueException(UserRoleLimitation $limitation): void { $this->expectException(InvalidArgumentType::class); $this->limitationType->acceptValue($limitation); } - public function providerForTestAcceptValueException(): array + public static function providerForTestAcceptValueException(): array { return [ [ @@ -99,18 +96,25 @@ public function providerForTestAcceptValueException(): array ]; } - /** - * @dataProvider providerForTestAcceptValue - */ + #[DataProvider('providerForTestAcceptValue')] public function testValidatePass(UserRoleLimitation $limitation): void { $userHandlerMock = $this->createMock(UserHandlerInterface::class); $contentHandlerMock = $this->createMock(ContentHandlerInterface::class); if ($limitation->limitationValues !== null) { - $userHandlerMock - ->method('loadRole') - ->withConsecutive([4, Role::STATUS_DEFINED], [8, Role::STATUS_DEFINED]); + $matcher = $this->any(); + $userHandlerMock->expects($matcher) + ->method('loadRole')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame(4, $parameters[0]); + $this->assertSame(Role::STATUS_DEFINED, $parameters[1]); + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame(8, $parameters[0]); + $this->assertSame(Role::STATUS_DEFINED, $parameters[1]); + } + }); $this->getPersistenceMock() ->method('userHandler') @@ -118,9 +122,16 @@ public function testValidatePass(UserRoleLimitation $limitation): void } if ($limitation->limitationValues !== null) { - $contentHandlerMock - ->method('loadContentInfo') - ->withConsecutive([14], [21]); + $matcher = $this->any(); + $contentHandlerMock->expects($matcher) + ->method('loadContentInfo')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame(14, $parameters[0]); + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame(21, $parameters[0]); + } + }); $this->getPersistenceMock() ->method('contentHandler') @@ -132,21 +143,28 @@ public function testValidatePass(UserRoleLimitation $limitation): void self::assertEmpty($validationErrors); } - /** - * @dataProvider providerForTestValidateError - */ + #[DataProvider('providerForTestValidateError')] public function testValidateError(UserRoleLimitation $limitation, int $errorCount): void { $userHandlerMock = $this->createMock(UserHandlerInterface::class); if ($limitation->limitationValues !== null) { - $userHandlerMock - ->method('loadRole') - ->withConsecutive([4, Role::STATUS_DEFINED], [8, Role::STATUS_DEFINED]) - ->willReturnOnConsecutiveCalls( - self::throwException(new NotFoundException('Role', 4)), - new Role() - ); + $matcher = $this->exactly(2); + $userHandlerMock->expects($matcher) + ->method('loadRole')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame(4, $parameters[0]); + $this->assertSame(Role::STATUS_DEFINED, $parameters[1]); + + throw new NotFoundException('Role', 4); + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame(8, $parameters[0]); + $this->assertSame(Role::STATUS_DEFINED, $parameters[1]); + + return new Role(); + } + }); $this->getPersistenceMock() ->method('userHandler') @@ -157,7 +175,10 @@ public function testValidateError(UserRoleLimitation $limitation, int $errorCoun self::assertCount($errorCount, $validationErrors); } - public function providerForTestValidateError() + /** + * @return array + */ + public static function providerForTestValidateError(): array { return [ [ @@ -169,9 +190,7 @@ public function providerForTestValidateError() ]; } - /** - * @dataProvider providerForTestEvaluate - */ + #[DataProvider('providerForTestEvaluate')] public function testEvaluate( UserRoleLimitation $limitation, ValueObject $object, @@ -204,7 +223,10 @@ public function testEvaluate( self::assertEquals($expected, $value); } - public function providerForTestEvaluate() + /** + * @return array + */ + public static function providerForTestEvaluate(): array { return [ 'valid_role_limitation' => [ diff --git a/tests/lib/Limitation/SectionLimitationTypeTest.php b/tests/lib/Limitation/SectionLimitationTypeTest.php index fdb938866d..54645f877f 100644 --- a/tests/lib/Limitation/SectionLimitationTypeTest.php +++ b/tests/lib/Limitation/SectionLimitationTypeTest.php @@ -12,20 +12,22 @@ use Ibexa\Contracts\Core\Persistence\Content\Section\Handler as SPISectionHandler; use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException; use Ibexa\Contracts\Core\Repository\Exceptions\NotImplementedException; -use Ibexa\Contracts\Core\Repository\Values\Content\Content as APIContent; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; use Ibexa\Contracts\Core\Repository\Values\Content\LocationCreateStruct; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\Operator; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\SectionId; -use Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo as APIVersionInfo; use Ibexa\Contracts\Core\Repository\Values\User\Limitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\ObjectStateLimitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\SectionLimitation; use Ibexa\Contracts\Core\Repository\Values\ValueObject; use Ibexa\Core\Base\Exceptions\NotFoundException; use Ibexa\Core\Limitation\SectionLimitationType; +use Ibexa\Core\Repository\Values\Content\Content as CoreContent; use Ibexa\Core\Repository\Values\Content\ContentCreateStruct; use Ibexa\Core\Repository\Values\Content\Location; +use Ibexa\Core\Repository\Values\Content\VersionInfo as CoreVersionInfo; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; /** * Test Case for LimitationType. @@ -56,7 +58,7 @@ protected function tearDown(): void /** * @return \Ibexa\Core\Limitation\SectionLimitationType */ - public function testConstruct() + public function testConstruct(): SectionLimitationType { return new SectionLimitationType($this->getPersistenceMock()); } @@ -64,7 +66,7 @@ public function testConstruct() /** * @return array */ - public function providerForTestAcceptValue() + public static function providerForTestAcceptValue(): array { return [ [new SectionLimitation()], @@ -74,14 +76,12 @@ public function providerForTestAcceptValue() } /** - * @dataProvider providerForTestAcceptValue - * - * @depends testConstruct - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\SectionLimitation $limitation * @param \Ibexa\Core\Limitation\SectionLimitationType $limitationType */ - public function testAcceptValue(SectionLimitation $limitation, SectionLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestAcceptValue')] + public function testAcceptValue(SectionLimitation $limitation, SectionLimitationType $limitationType): void { $limitationType->acceptValue($limitation); } @@ -89,7 +89,7 @@ public function testAcceptValue(SectionLimitation $limitation, SectionLimitation /** * @return array */ - public function providerForTestAcceptValueException() + public static function providerForTestAcceptValueException(): array { return [ [new ObjectStateLimitation()], @@ -101,14 +101,12 @@ public function providerForTestAcceptValueException() } /** - * @dataProvider providerForTestAcceptValueException - * - * @depends testConstruct - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation $limitation * @param \Ibexa\Core\Limitation\SectionLimitationType $limitationType */ - public function testAcceptValueException(Limitation $limitation, SectionLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestAcceptValueException')] + public function testAcceptValueException(Limitation $limitation, SectionLimitationType $limitationType): void { $this->expectException(InvalidArgumentException::class); @@ -118,7 +116,7 @@ public function testAcceptValueException(Limitation $limitation, SectionLimitati /** * @return array */ - public function providerForTestValidatePass() + public static function providerForTestValidatePass(): array { return [ [new SectionLimitation()], @@ -128,11 +126,10 @@ public function providerForTestValidatePass() } /** - * @dataProvider providerForTestValidatePass - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\SectionLimitation $limitation */ - public function testValidatePass(SectionLimitation $limitation) + #[DataProvider('providerForTestValidatePass')] + public function testValidatePass(SectionLimitation $limitation): void { if (!empty($limitation->limitationValues)) { $this->getPersistenceMock() @@ -140,17 +137,17 @@ public function testValidatePass(SectionLimitation $limitation) ->method('sectionHandler') ->will(self::returnValue($this->sectionHandlerMock)); - foreach ($limitation->limitationValues as $key => $value) { - $this->sectionHandlerMock - ->expects(self::at($key)) - ->method('load') - ->with($value) - ->will( - self::returnValue( - new SPISection(['id' => $value]) - ) - ); - } + $limitationValues = $limitation->limitationValues; + $matcher = self::exactly(count($limitationValues)); + $this->sectionHandlerMock + ->expects($matcher) + ->method('load') + ->willReturnCallback(static function ($actualValue) use ($matcher, $limitationValues): SPISection { + $value = $limitationValues[$matcher->numberOfInvocations() - 1]; + self::assertSame($value, $actualValue); + + return new SPISection(['id' => $value]); + }); } // Need to create inline instead of depending on testConstruct() to get correct mock instance @@ -163,7 +160,7 @@ public function testValidatePass(SectionLimitation $limitation) /** * @return array */ - public function providerForTestValidateError() + public static function providerForTestValidateError(): array { return [ [new SectionLimitation(), 0], @@ -173,12 +170,11 @@ public function providerForTestValidateError() } /** - * @dataProvider providerForTestValidateError - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\SectionLimitation $limitation * @param int $errorCount */ - public function testValidateError(SectionLimitation $limitation, $errorCount) + #[DataProvider('providerForTestValidateError')] + public function testValidateError(SectionLimitation $limitation, $errorCount): void { if (!empty($limitation->limitationValues)) { $this->getPersistenceMock() @@ -186,13 +182,17 @@ public function testValidateError(SectionLimitation $limitation, $errorCount) ->method('sectionHandler') ->will(self::returnValue($this->sectionHandlerMock)); - foreach ($limitation->limitationValues as $key => $value) { - $this->sectionHandlerMock - ->expects(self::at($key)) - ->method('load') - ->with($value) - ->will(self::throwException(new NotFoundException('Section', $value))); - } + $limitationValues = $limitation->limitationValues; + $matcher = self::exactly(count($limitationValues)); + $this->sectionHandlerMock + ->expects($matcher) + ->method('load') + ->willReturnCallback(static function ($actualValue) use ($matcher, $limitationValues): void { + $value = $limitationValues[$matcher->numberOfInvocations() - 1]; + self::assertSame($value, $actualValue); + + throw new NotFoundException('Section', $value); + }); } else { $this->getPersistenceMock() ->expects(self::never()) @@ -207,11 +207,10 @@ public function testValidateError(SectionLimitation $limitation, $errorCount) } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\SectionLimitationType $limitationType */ - public function testBuildValue(SectionLimitationType $limitationType) + #[Depends('testConstruct')] + public function testBuildValue(SectionLimitationType $limitationType): void { $expected = ['test', 'test' => '33']; $value = $limitationType->buildValue($expected); @@ -224,28 +223,17 @@ public function testBuildValue(SectionLimitationType $limitationType) /** * @return array */ - public function providerForTestEvaluate() + public static function providerForTestEvaluate(): array { - // Mocks for testing Content & VersionInfo objects, should only be used once because of expect rules. - $contentMock = $this->createMock(APIContent::class); - $versionInfoMock = $this->createMock(APIVersionInfo::class); + $contentMock = new CoreContent([ + 'versionInfo' => new CoreVersionInfo([ + 'contentInfo' => new ContentInfo(['sectionId' => 2]), + ]), + ]); - $contentMock - ->expects(self::once()) - ->method('getVersionInfo') - ->will(self::returnValue($versionInfoMock)); - - $versionInfoMock - ->expects(self::once()) - ->method('getContentInfo') - ->will(self::returnValue(new ContentInfo(['sectionId' => 2]))); - - $versionInfoMock2 = $this->createMock(APIVersionInfo::class); - - $versionInfoMock2 - ->expects(self::once()) - ->method('getContentInfo') - ->will(self::returnValue(new ContentInfo(['sectionId' => 2]))); + $versionInfoMock2 = new CoreVersionInfo([ + 'contentInfo' => new ContentInfo(['sectionId' => 2]), + ]); return [ // ContentInfo, with targets, no access @@ -349,15 +337,13 @@ public function providerForTestEvaluate() ]; } - /** - * @dataProvider providerForTestEvaluate - */ + #[DataProvider('providerForTestEvaluate')] public function testEvaluate( SectionLimitation $limitation, ValueObject $object, $targets, $expected - ) { + ): void { // Need to create inline instead of depending on testConstruct() to get correct mock instance $limitationType = $this->testConstruct(); @@ -383,7 +369,7 @@ public function testEvaluate( /** * @return array */ - public function providerForTestEvaluateInvalidArgument() + public static function providerForTestEvaluateInvalidArgument(): array { return [ // invalid limitation @@ -395,14 +381,12 @@ public function providerForTestEvaluateInvalidArgument() ]; } - /** - * @dataProvider providerForTestEvaluateInvalidArgument - */ + #[DataProvider('providerForTestEvaluateInvalidArgument')] public function testEvaluateInvalidArgument( Limitation $limitation, ValueObject $object, $targets - ) { + ): void { $this->expectException(InvalidArgumentException::class); // Need to create inline instead of depending on testConstruct() to get correct mock instance @@ -427,11 +411,10 @@ public function testEvaluateInvalidArgument( } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\SectionLimitationType $limitationType */ - public function testGetCriterionInvalidValue(SectionLimitationType $limitationType) + #[Depends('testConstruct')] + public function testGetCriterionInvalidValue(SectionLimitationType $limitationType): void { $this->expectException(\RuntimeException::class); @@ -442,11 +425,10 @@ public function testGetCriterionInvalidValue(SectionLimitationType $limitationTy } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\SectionLimitationType $limitationType */ - public function testGetCriterionSingleValue(SectionLimitationType $limitationType) + #[Depends('testConstruct')] + public function testGetCriterionSingleValue(SectionLimitationType $limitationType): void { $criterion = $limitationType->getCriterion( new SectionLimitation(['limitationValues' => ['9']]), @@ -461,11 +443,10 @@ public function testGetCriterionSingleValue(SectionLimitationType $limitationTyp } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\SectionLimitationType $limitationType */ - public function testGetCriterionMultipleValues(SectionLimitationType $limitationType) + #[Depends('testConstruct')] + public function testGetCriterionMultipleValues(SectionLimitationType $limitationType): void { $criterion = $limitationType->getCriterion( new SectionLimitation(['limitationValues' => ['9', '55']]), @@ -480,11 +461,10 @@ public function testGetCriterionMultipleValues(SectionLimitationType $limitation } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\SectionLimitationType $limitationType */ - public function testValueSchema(SectionLimitationType $limitationType) + #[Depends('testConstruct')] + public function testValueSchema(SectionLimitationType $limitationType): void { $this->expectException(NotImplementedException::class); diff --git a/tests/lib/Limitation/SiteAccessLimitationTypeTest.php b/tests/lib/Limitation/SiteAccessLimitationTypeTest.php index 2996a4f4a5..377ebe97a0 100644 --- a/tests/lib/Limitation/SiteAccessLimitationTypeTest.php +++ b/tests/lib/Limitation/SiteAccessLimitationTypeTest.php @@ -15,6 +15,8 @@ use Ibexa\Contracts\Core\Repository\Values\ValueObject; use Ibexa\Core\Limitation\SiteAccessLimitationType; use Ibexa\Core\MVC\Symfony\SiteAccess; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; /** * Test Case for LimitationType. @@ -40,7 +42,7 @@ protected function setUp(): void /** * @return \Ibexa\Core\Limitation\SiteAccessLimitationType */ - public function testConstruct() + public function testConstruct(): SiteAccessLimitationType { return new SiteAccessLimitationType( $this->siteAccessServiceMock @@ -50,7 +52,7 @@ public function testConstruct() /** * @return array */ - public function providerForTestAcceptValue() + public static function providerForTestAcceptValue(): array { return [ [new SiteAccessLimitation()], @@ -81,14 +83,12 @@ public function providerForTestAcceptValue() } /** - * @depends testConstruct - * - * @dataProvider providerForTestAcceptValue - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\SiteAccessLimitation $limitation * @param \Ibexa\Core\Limitation\SiteAccessLimitationType $limitationType */ - public function testAcceptValue(SiteAccessLimitation $limitation, SiteAccessLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestAcceptValue')] + public function testAcceptValue(SiteAccessLimitation $limitation, SiteAccessLimitationType $limitationType): void { $limitationType->acceptValue($limitation); } @@ -96,7 +96,7 @@ public function testAcceptValue(SiteAccessLimitation $limitation, SiteAccessLimi /** * @return array */ - public function providerForTestAcceptValueException() + public static function providerForTestAcceptValueException(): array { return [ [new ObjectStateLimitation()], @@ -105,14 +105,12 @@ public function providerForTestAcceptValueException() } /** - * @depends testConstruct - * - * @dataProvider providerForTestAcceptValueException - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation $limitation * @param \Ibexa\Core\Limitation\SiteAccessLimitationType $limitationType */ - public function testAcceptValueException(Limitation $limitation, SiteAccessLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestAcceptValueException')] + public function testAcceptValueException(Limitation $limitation, SiteAccessLimitationType $limitationType): void { $this->expectException(InvalidArgumentException::class); @@ -122,7 +120,7 @@ public function testAcceptValueException(Limitation $limitation, SiteAccessLimit /** * @return array */ - public function providerForTestValidateError() + public static function providerForTestValidateError(): array { return [ [new SiteAccessLimitation(), 0], @@ -163,26 +161,23 @@ public function providerForTestValidateError() } /** - * @dataProvider providerForTestValidateError - * - * @depends testConstruct - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\SiteAccessLimitation $limitation * @param int $errorCount * @param \Ibexa\Core\Limitation\SiteAccessLimitationType $limitationType */ - public function testValidateError(SiteAccessLimitation $limitation, $errorCount, SiteAccessLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestValidateError')] + public function testValidateError(SiteAccessLimitation $limitation, $errorCount, SiteAccessLimitationType $limitationType): void { $validationErrors = $limitationType->validate($limitation); self::assertCount($errorCount, $validationErrors); } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\SiteAccessLimitationType $limitationType */ - public function testBuildValue(SiteAccessLimitationType $limitationType) + #[Depends('testConstruct')] + public function testBuildValue(SiteAccessLimitationType $limitationType): void { $expected = ['test', 'test' => 9]; $value = $limitationType->buildValue($expected); @@ -195,41 +190,38 @@ public function testBuildValue(SiteAccessLimitationType $limitationType) /** * @return array */ - public function providerForTestEvaluate() + public static function providerForTestEvaluate(): array { return [ // SiteAccess, no access [ - 'limitation' => new SiteAccessLimitation(), - 'object' => new SiteAccess('behat_site'), - 'expected' => false, + new SiteAccessLimitation(), + new SiteAccess('behat_site'), + false, ], // SiteAccess, no access [ - 'limitation' => new SiteAccessLimitation(['limitationValues' => ['2339567439']]), - 'object' => new SiteAccess('behat_site'), - 'expected' => false, + new SiteAccessLimitation(['limitationValues' => ['2339567439']]), + new SiteAccess('behat_site'), + false, ], // SiteAccess, with access [ - 'limitation' => new SiteAccessLimitation(['limitationValues' => ['1817462202']]), - 'object' => new SiteAccess('behat_site'), - 'expected' => true, + new SiteAccessLimitation(['limitationValues' => ['1817462202']]), + new SiteAccess('behat_site'), + true, ], ]; } - /** - * @depends testConstruct - * - * @dataProvider providerForTestEvaluate - */ + #[Depends('testConstruct')] + #[DataProvider('providerForTestEvaluate')] public function testEvaluate( SiteAccessLimitation $limitation, ValueObject $object, $expected, SiteAccessLimitationType $limitationType - ) { + ): void { $userMock = $this->getUserMock(); $userMock->expects(self::never())->method(self::anything()); @@ -246,32 +238,29 @@ public function testEvaluate( /** * @return array */ - public function providerForTestEvaluateInvalidArgument() + public static function providerForTestEvaluateInvalidArgument(): array { return [ // invalid limitation [ - 'limitation' => new ObjectStateLimitation(), - 'object' => new SiteAccess('test'), + new ObjectStateLimitation(), + new SiteAccess('test'), ], // invalid object [ - 'limitation' => new SiteAccessLimitation(), - 'object' => new ObjectStateLimitation(), + new SiteAccessLimitation(), + new ObjectStateLimitation(), ], ]; } - /** - * @depends testConstruct - * - * @dataProvider providerForTestEvaluateInvalidArgument - */ + #[Depends('testConstruct')] + #[DataProvider('providerForTestEvaluateInvalidArgument')] public function testEvaluateInvalidArgument( Limitation $limitation, ValueObject $object, SiteAccessLimitationType $limitationType - ) { + ): void { $this->expectException(InvalidArgumentException::class); $userMock = $this->getUserMock(); @@ -285,11 +274,10 @@ public function testEvaluateInvalidArgument( } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\SiteAccessLimitationType $limitationType */ - public function testGetCriterion(SiteAccessLimitationType $limitationType) + #[Depends('testConstruct')] + public function testGetCriterion(SiteAccessLimitationType $limitationType): void { $this->expectException(NotImplementedException::class); @@ -297,18 +285,15 @@ public function testGetCriterion(SiteAccessLimitationType $limitationType) } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\SiteAccessLimitationType $limitationType */ - public function testValueSchema(SiteAccessLimitationType $limitationType) + #[Depends('testConstruct')] + public function testValueSchema(SiteAccessLimitationType $limitationType): void { self::markTestSkipped('Method valueSchema() is not implemented'); } - /** - * @depends testConstruct - */ + #[Depends('testConstruct')] public function testGenerateSiteAccessValue(SiteAccessLimitationType $limitationType): void { self::assertSame('341347141', $limitationType->generateSiteAccessValue('ger')); diff --git a/tests/lib/Limitation/StatusLimitationTypeTest.php b/tests/lib/Limitation/StatusLimitationTypeTest.php index 5960d445b3..ac8db09046 100644 --- a/tests/lib/Limitation/StatusLimitationTypeTest.php +++ b/tests/lib/Limitation/StatusLimitationTypeTest.php @@ -19,6 +19,8 @@ use Ibexa\Core\Limitation\StatusLimitationType; use Ibexa\Core\Repository\Values\Content\VersionInfo; use Ibexa\Core\Repository\Values\User\User; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; /** * Test Case for LimitationType. @@ -28,7 +30,7 @@ class StatusLimitationTypeTest extends Base /** * @return \Ibexa\Core\Limitation\StatusLimitationType */ - public function testConstruct() + public function testConstruct(): StatusLimitationType { return new StatusLimitationType(); } @@ -36,7 +38,7 @@ public function testConstruct() /** * @return array */ - public function providerForTestAcceptValue() + public static function providerForTestAcceptValue(): array { return [ [new StatusLimitation()], @@ -56,14 +58,12 @@ public function providerForTestAcceptValue() } /** - * @depends testConstruct - * - * @dataProvider providerForTestAcceptValue - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\StatusLimitation $limitation * @param \Ibexa\Core\Limitation\StatusLimitationType $limitationType */ - public function testAcceptValue(StatusLimitation $limitation, StatusLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestAcceptValue')] + public function testAcceptValue(StatusLimitation $limitation, StatusLimitationType $limitationType): void { $limitationType->acceptValue($limitation); } @@ -71,7 +71,7 @@ public function testAcceptValue(StatusLimitation $limitation, StatusLimitationTy /** * @return array */ - public function providerForTestAcceptValueException() + public static function providerForTestAcceptValueException(): array { return [ [new ObjectStateLimitation()], @@ -80,14 +80,12 @@ public function providerForTestAcceptValueException() } /** - * @depends testConstruct - * - * @dataProvider providerForTestAcceptValueException - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation $limitation * @param \Ibexa\Core\Limitation\StatusLimitationType $limitationType */ - public function testAcceptValueException(Limitation $limitation, StatusLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestAcceptValueException')] + public function testAcceptValueException(Limitation $limitation, StatusLimitationType $limitationType): void { $this->expectException(InvalidArgumentException::class); @@ -97,7 +95,7 @@ public function testAcceptValueException(Limitation $limitation, StatusLimitatio /** * @return array */ - public function providerForTestValidateError() + public static function providerForTestValidateError(): array { return [ [new StatusLimitation(), 0], @@ -149,26 +147,23 @@ public function providerForTestValidateError() } /** - * @dataProvider providerForTestValidateError - * - * @depends testConstruct - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\StatusLimitation $limitation * @param int $errorCount * @param \Ibexa\Core\Limitation\StatusLimitationType $limitationType */ - public function testValidateError(StatusLimitation $limitation, $errorCount, StatusLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestValidateError')] + public function testValidateError(StatusLimitation $limitation, $errorCount, StatusLimitationType $limitationType): void { $validationErrors = $limitationType->validate($limitation); self::assertCount($errorCount, $validationErrors); } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\StatusLimitationType $limitationType */ - public function testBuildValue(StatusLimitationType $limitationType) + #[Depends('testConstruct')] + public function testBuildValue(StatusLimitationType $limitationType): void { $expected = ['test', 'test' => 9]; $value = $limitationType->buildValue($expected); @@ -182,7 +177,7 @@ protected function getVersionInfoMock($shouldBeCalled = true) { $versionInfoMock = $this->getMockBuilder(APIVersionInfo::class) ->disableOriginalConstructor() - ->setMethods(['__get']) + ->onlyMethods(['__get']) ->getMockForAbstractClass(); if ($shouldBeCalled) { @@ -201,17 +196,16 @@ protected function getVersionInfoMock($shouldBeCalled = true) return $versionInfoMock; } - protected function getContentMock() + protected function getContentMock($shouldBeCalled = true) { $contentMock = $this->getMockBuilder(APIContent::class) ->setConstructorArgs([]) - ->setMethods([]) ->getMock(); $contentMock ->expects(self::once()) ->method('getVersionInfo') - ->will(self::returnValue($this->getVersionInfoMock())); + ->will(self::returnValue($this->getVersionInfoMock($shouldBeCalled))); return $contentMock; } @@ -219,59 +213,65 @@ protected function getContentMock() /** * @return array */ - public function providerForTestEvaluate() + public static function providerForTestEvaluate(): array { return [ // VersionInfo, no access [ - 'limitation' => new StatusLimitation(), - 'object' => $this->getVersionInfoMock(false), - 'expected' => false, + new StatusLimitation(), + 'versionInfo', + false, + false, ], // VersionInfo, no access [ - 'limitation' => new StatusLimitation(['limitationValues' => [42]]), - 'object' => $this->getVersionInfoMock(), - 'expected' => false, + new StatusLimitation(['limitationValues' => [42]]), + 'versionInfo', + true, + false, ], // VersionInfo, with access [ - 'limitation' => new StatusLimitation(['limitationValues' => [24]]), - 'object' => $this->getVersionInfoMock(), - 'expected' => true, + new StatusLimitation(['limitationValues' => [24]]), + 'versionInfo', + true, + true, ], // Content, no access [ - 'limitation' => new StatusLimitation(), - 'object' => $this->getContentMock(), - 'expected' => false, + new StatusLimitation(), + 'content', + false, + false, ], // Content, no access [ - 'limitation' => new StatusLimitation(['limitationValues' => [42]]), - 'object' => $this->getContentMock(), - 'expected' => false, + new StatusLimitation(['limitationValues' => [42]]), + 'content', + true, + false, ], // Content, with access [ - 'limitation' => new StatusLimitation(['limitationValues' => [24]]), - 'object' => $this->getContentMock(), - 'expected' => true, + new StatusLimitation(['limitationValues' => [24]]), + 'content', + true, + true, ], ]; } - /** - * @depends testConstruct - * - * @dataProvider providerForTestEvaluate - */ + #[Depends('testConstruct')] + #[DataProvider('providerForTestEvaluate')] public function testEvaluate( StatusLimitation $limitation, - ValueObject $object, + string $objectType, + bool $shouldBeCalled, $expected, StatusLimitationType $limitationType - ) { + ): void { + $object = $objectType === 'versionInfo' ? $this->getVersionInfoMock($shouldBeCalled) : $this->getContentMock($shouldBeCalled); + $userMock = $this->getUserMock(); $userMock->expects(self::never()) ->method(self::anything()); @@ -290,37 +290,61 @@ public function testEvaluate( /** * @return array */ - public function providerForTestEvaluateInvalidArgument() + public static function providerForTestEvaluateInvalidArgument(): array { - $versionInfoMock = $this->getMockBuilder(APIVersionInfo::class) - ->setConstructorArgs([]) - ->setMethods([]) - ->getMock(); + $versionInfoStub = new class() extends APIVersionInfo { + public function getContentInfo(): \Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo + { + return new \Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo(); + } + + public function getCreator(): User + { + return new User(); + } + + public function getInitialLanguage(): \Ibexa\Contracts\Core\Repository\Values\Content\Language + { + return new \Ibexa\Contracts\Core\Repository\Values\Content\Language(); + } + + public function getLanguages(): iterable + { + return []; + } + + public function getNames(): array + { + return []; + } + + public function getName(?string $languageCode = null): ?string + { + return null; + } + }; return [ // invalid limitation [ - 'limitation' => new ObjectStateLimitation(), - 'object' => $versionInfoMock, + new ObjectStateLimitation(), + $versionInfoStub, ], // invalid object [ - 'limitation' => new StatusLimitation(), - 'object' => new ObjectStateLimitation(), + new StatusLimitation(), + new ObjectStateLimitation(), ], ]; } - /** - * @depends testConstruct - * - * @dataProvider providerForTestEvaluateInvalidArgument - */ + #[Depends('testConstruct')] + #[DataProvider('providerForTestEvaluateInvalidArgument')] public function testEvaluateInvalidArgument( Limitation $limitation, ValueObject $object, StatusLimitationType $limitationType - ) { + ): void { $this->expectException(InvalidArgumentException::class); $userMock = $this->getUserMock(); @@ -335,11 +359,10 @@ public function testEvaluateInvalidArgument( } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\StatusLimitationType $limitationType */ - public function testGetCriterion(StatusLimitationType $limitationType) + #[Depends('testConstruct')] + public function testGetCriterion(StatusLimitationType $limitationType): void { $this->expectException(NotImplementedException::class); @@ -347,11 +370,10 @@ public function testGetCriterion(StatusLimitationType $limitationType) } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\StatusLimitationType $limitationType */ - public function testValueSchema(StatusLimitationType $limitationType) + #[Depends('testConstruct')] + public function testValueSchema(StatusLimitationType $limitationType): void { self::markTestSkipped('Method valueSchema() is not implemented'); } diff --git a/tests/lib/Limitation/SubtreeLimitationTypeTest.php b/tests/lib/Limitation/SubtreeLimitationTypeTest.php index 7e6842e2bf..2ceb8585ea 100644 --- a/tests/lib/Limitation/SubtreeLimitationTypeTest.php +++ b/tests/lib/Limitation/SubtreeLimitationTypeTest.php @@ -11,21 +11,23 @@ use Ibexa\Contracts\Core\Persistence\Content\Location as SPILocation; use Ibexa\Contracts\Core\Persistence\Content\Location\Handler as SPILocationHandler; use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException; -use Ibexa\Contracts\Core\Repository\Values\Content\Content as APIContent; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; use Ibexa\Contracts\Core\Repository\Values\Content\LocationCreateStruct; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\Operator; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\Subtree; -use Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo as APIVersionInfo; use Ibexa\Contracts\Core\Repository\Values\User\Limitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\ObjectStateLimitation; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\SubtreeLimitation; use Ibexa\Contracts\Core\Repository\Values\ValueObject; use Ibexa\Core\Base\Exceptions\NotFoundException; use Ibexa\Core\Limitation\SubtreeLimitationType; +use Ibexa\Core\Repository\Values\Content\Content as CoreContent; use Ibexa\Core\Repository\Values\Content\ContentCreateStruct; use Ibexa\Core\Repository\Values\Content\Location; use Ibexa\Core\Repository\Values\Content\Query\Criterion\PermissionSubtree; +use Ibexa\Core\Repository\Values\Content\VersionInfo as CoreVersionInfo; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; /** * Test Case for LimitationType. @@ -58,7 +60,7 @@ protected function tearDown(): void /** * @return \Ibexa\Core\Limitation\SubtreeLimitationType */ - public function testConstruct() + public function testConstruct(): SubtreeLimitationType { return new SubtreeLimitationType($this->getPersistenceMock()); } @@ -66,7 +68,7 @@ public function testConstruct() /** * @return array */ - public function providerForTestAcceptValue() + public static function providerForTestAcceptValue(): array { return [ [new SubtreeLimitation()], @@ -76,14 +78,12 @@ public function providerForTestAcceptValue() } /** - * @dataProvider providerForTestAcceptValue - * - * @depends testConstruct - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\SubtreeLimitation $limitation * @param \Ibexa\Core\Limitation\SubtreeLimitationType $limitationType */ - public function testAcceptValue(SubtreeLimitation $limitation, SubtreeLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestAcceptValue')] + public function testAcceptValue(SubtreeLimitation $limitation, SubtreeLimitationType $limitationType): void { $limitationType->acceptValue($limitation); } @@ -91,7 +91,7 @@ public function testAcceptValue(SubtreeLimitation $limitation, SubtreeLimitation /** * @return array */ - public function providerForTestAcceptValueException() + public static function providerForTestAcceptValueException(): array { return [ [new ObjectStateLimitation()], @@ -103,14 +103,12 @@ public function providerForTestAcceptValueException() } /** - * @dataProvider providerForTestAcceptValueException - * - * @depends testConstruct - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation $limitation * @param \Ibexa\Core\Limitation\SubtreeLimitationType $limitationType */ - public function testAcceptValueException(Limitation $limitation, SubtreeLimitationType $limitationType) + #[Depends('testConstruct')] + #[DataProvider('providerForTestAcceptValueException')] + public function testAcceptValueException(Limitation $limitation, SubtreeLimitationType $limitationType): void { $this->expectException(InvalidArgumentException::class); @@ -120,7 +118,7 @@ public function testAcceptValueException(Limitation $limitation, SubtreeLimitati /** * @return array */ - public function providerForTestValidatePass() + public static function providerForTestValidatePass(): array { return [ [new SubtreeLimitation()], @@ -130,11 +128,10 @@ public function providerForTestValidatePass() } /** - * @dataProvider providerForTestValidatePass - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\SubtreeLimitation $limitation */ - public function testValidatePass(SubtreeLimitation $limitation) + #[DataProvider('providerForTestValidatePass')] + public function testValidatePass(SubtreeLimitation $limitation): void { if (!empty($limitation->limitationValues)) { $this->getPersistenceMock() @@ -142,18 +139,23 @@ public function testValidatePass(SubtreeLimitation $limitation) ->method('locationHandler') ->will(self::returnValue($this->locationHandlerMock)); + $loadArguments = []; + $loadReturnValues = []; foreach ($limitation->limitationValues as $key => $value) { $pathArray = explode('/', trim($value, '/')); - $this->locationHandlerMock - ->expects(self::at($key)) - ->method('load') - ->with(end($pathArray)) - ->will( - self::returnValue( - new SPILocation(['pathString' => $value]) - ) - ); + $loadArguments[$key] = end($pathArray); + $loadReturnValues[$key] = new SPILocation(['pathString' => $value]); } + + $matcher = self::exactly(count($limitation->limitationValues)); + $this->locationHandlerMock + ->expects($matcher) + ->method('load') + ->willReturnCallback(function (...$parameters) use ($matcher, $loadArguments, $loadReturnValues) { + $this->assertSame($loadArguments[$matcher->numberOfInvocations() - 1], $parameters[0]); + + return $loadReturnValues[$matcher->numberOfInvocations() - 1]; + }); } // Need to create inline instead of depending on testConstruct() to get correct mock instance @@ -166,7 +168,7 @@ public function testValidatePass(SubtreeLimitation $limitation) /** * @return array */ - public function providerForTestValidateError() + public static function providerForTestValidateError(): array { return [ [new SubtreeLimitation(), 0], @@ -176,12 +178,11 @@ public function providerForTestValidateError() } /** - * @dataProvider providerForTestValidateError - * * @param \Ibexa\Contracts\Core\Repository\Values\User\Limitation\SubtreeLimitation $limitation * @param int $errorCount */ - public function testValidateError(SubtreeLimitation $limitation, $errorCount) + #[DataProvider('providerForTestValidateError')] + public function testValidateError(SubtreeLimitation $limitation, $errorCount): void { if (!empty($limitation->limitationValues)) { $this->getPersistenceMock() @@ -189,14 +190,23 @@ public function testValidateError(SubtreeLimitation $limitation, $errorCount) ->method('locationHandler') ->will(self::returnValue($this->locationHandlerMock)); + $loadArguments = []; + $loadExceptions = []; foreach ($limitation->limitationValues as $key => $value) { $pathArray = explode('/', trim($value, '/')); - $this->locationHandlerMock - ->expects(self::at($key)) - ->method('load') - ->with(end($pathArray)) - ->will(self::throwException(new NotFoundException('location', $value))); + $loadArguments[$key] = end($pathArray); + $loadExceptions[$key] = new NotFoundException('location', $value); } + + $matcher = self::exactly(count($limitation->limitationValues)); + $this->locationHandlerMock + ->expects($matcher) + ->method('load') + ->willReturnCallback(function (...$parameters) use ($matcher, $loadArguments, $loadExceptions) { + $this->assertSame($loadArguments[$matcher->numberOfInvocations() - 1], $parameters[0]); + + throw $loadExceptions[$matcher->numberOfInvocations() - 1]; + }); } else { $this->getPersistenceMock() ->expects(self::never()) @@ -210,7 +220,7 @@ public function testValidateError(SubtreeLimitation $limitation, $errorCount) self::assertCount($errorCount, $validationErrors); } - public function testValidateErrorWrongPath() + public function testValidateErrorWrongPath(): void { $limitation = new SubtreeLimitation(['limitationValues' => ['/1/2/42/']]); @@ -219,19 +229,24 @@ public function testValidateErrorWrongPath() ->method('locationHandler') ->will(self::returnValue($this->locationHandlerMock)); + $loadArguments = []; + $loadReturnValues = []; foreach ($limitation->limitationValues as $key => $value) { $pathArray = explode('/', trim($value, '/')); - $this->locationHandlerMock - ->expects(self::at($key)) - ->method('load') - ->with(end($pathArray)) - ->will( - self::returnValue( - new SPILocation(['pathString' => '/1/5/42']) - ) - ); + $loadArguments[$key] = end($pathArray); + $loadReturnValues[$key] = new SPILocation(['pathString' => '/1/5/42']); } + $matcher = self::exactly(count($limitation->limitationValues)); + $this->locationHandlerMock + ->expects($matcher) + ->method('load') + ->willReturnCallback(function (...$parameters) use ($matcher, $loadArguments, $loadReturnValues) { + $this->assertSame($loadArguments[$matcher->numberOfInvocations() - 1], $parameters[0]); + + return $loadReturnValues[$matcher->numberOfInvocations() - 1]; + }); + // Need to create inline instead of depending on testConstruct() to get correct mock instance $limitationType = $this->testConstruct(); @@ -240,11 +255,10 @@ public function testValidateErrorWrongPath() } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\SubtreeLimitationType $limitationType */ - public function testBuildValue(SubtreeLimitationType $limitationType) + #[Depends('testConstruct')] + public function testBuildValue(SubtreeLimitationType $limitationType): void { $expected = ['test', 'test' => '/1/999/']; $value = $limitationType->buildValue($expected); @@ -257,28 +271,18 @@ public function testBuildValue(SubtreeLimitationType $limitationType) /** * @return array */ - public function providerForTestEvaluate() + public static function providerForTestEvaluate(): array { - // Mocks for testing Content & VersionInfo objects, should only be used once because of expect rules. - $contentMock = $this->createMock(APIContent::class); - $versionInfoMock = $this->createMock(APIVersionInfo::class); - - $contentMock - ->expects(self::once()) - ->method('getVersionInfo') - ->will(self::returnValue($versionInfoMock)); + // Real Content & VersionInfo objects, avoiding mocks since providers must be static. + $content = new CoreContent([ + 'versionInfo' => new CoreVersionInfo([ + 'contentInfo' => new ContentInfo(['published' => true, 'status' => ContentInfo::STATUS_PUBLISHED]), + ]), + ]); - $versionInfoMock - ->expects(self::once()) - ->method('getContentInfo') - ->willReturn(new ContentInfo(['published' => true, 'status' => ContentInfo::STATUS_PUBLISHED])); - - $versionInfoMock2 = $this->createMock(APIVersionInfo::class); - - $versionInfoMock2 - ->expects(self::once()) - ->method('getContentInfo') - ->willReturn(new ContentInfo(['published' => true, 'status' => ContentInfo::STATUS_PUBLISHED])); + $versionInfo = new CoreVersionInfo([ + 'contentInfo' => new ContentInfo(['published' => true, 'status' => ContentInfo::STATUS_PUBLISHED]), + ]); return [ // ContentInfo, with targets, no access @@ -286,7 +290,7 @@ public function providerForTestEvaluate() 'limitation' => new SubtreeLimitation(), 'object' => new ContentInfo(['published' => true, 'status' => ContentInfo::STATUS_PUBLISHED]), 'targets' => [new Location()], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => LimitationType::ACCESS_DENIED, ], // ContentInfo, with targets, no access @@ -294,7 +298,7 @@ public function providerForTestEvaluate() 'limitation' => new SubtreeLimitation(['limitationValues' => ['/1/2/']]), 'object' => new ContentInfo(['published' => true, 'status' => ContentInfo::STATUS_PUBLISHED]), 'targets' => [new Location(['pathString' => '/1/55/'])], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => LimitationType::ACCESS_DENIED, ], // ContentInfo, with targets, with access @@ -302,7 +306,7 @@ public function providerForTestEvaluate() 'limitation' => new SubtreeLimitation(['limitationValues' => ['/1/2/']]), 'object' => new ContentInfo(['published' => true, 'status' => ContentInfo::STATUS_PUBLISHED]), 'targets' => [new Location(['pathString' => '/1/2/'])], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => LimitationType::ACCESS_GRANTED, ], // ContentInfo, no targets, with access @@ -314,7 +318,7 @@ public function providerForTestEvaluate() 'status' => ContentInfo::STATUS_PUBLISHED, ]), 'targets' => null, - 'persistence' => [new Location(['pathString' => '/1/2/'])], + 'persistenceLocations' => [new Location(['pathString' => '/1/2/'])], 'expected' => LimitationType::ACCESS_GRANTED, ], // ContentInfo, no targets, no access @@ -326,7 +330,7 @@ public function providerForTestEvaluate() 'status' => ContentInfo::STATUS_PUBLISHED, ]), 'targets' => null, - 'persistence' => [new Location(['pathString' => '/1/55/'])], + 'persistenceLocations' => [new Location(['pathString' => '/1/55/'])], 'expected' => LimitationType::ACCESS_DENIED, ], // ContentInfo, no targets, un-published, with access @@ -338,7 +342,7 @@ public function providerForTestEvaluate() 'status' => ContentInfo::STATUS_DRAFT, ]), 'targets' => null, - 'persistence' => [new Location(['pathString' => '/1/2/'])], + 'persistenceLocations' => [new Location(['pathString' => '/1/2/'])], 'expected' => LimitationType::ACCESS_GRANTED, ], // ContentInfo, no targets, un-published, no access @@ -350,23 +354,23 @@ public function providerForTestEvaluate() 'status' => ContentInfo::STATUS_DRAFT, ]), 'targets' => null, - 'persistence' => [new Location(['pathString' => '/1/55/'])], + 'persistenceLocations' => [new Location(['pathString' => '/1/55/'])], 'expected' => LimitationType::ACCESS_DENIED, ], // Content, with targets, with access [ 'limitation' => new SubtreeLimitation(['limitationValues' => ['/1/2/']]), - 'object' => $contentMock, + 'object' => $content, 'targets' => [new Location(['pathString' => '/1/2/'])], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => LimitationType::ACCESS_GRANTED, ], // VersionInfo, with targets, with access [ 'limitation' => new SubtreeLimitation(['limitationValues' => ['/1/2/']]), - 'object' => $versionInfoMock2, + 'object' => $versionInfo, 'targets' => [new Location(['pathString' => '/1/2/'])], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => LimitationType::ACCESS_GRANTED, ], // ContentCreateStruct, no targets, no access @@ -374,7 +378,7 @@ public function providerForTestEvaluate() 'limitation' => new SubtreeLimitation(['limitationValues' => ['/1/2/']]), 'object' => new ContentCreateStruct(), 'targets' => [], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => LimitationType::ACCESS_DENIED, ], // ContentCreateStruct, with targets, no access @@ -382,7 +386,7 @@ public function providerForTestEvaluate() 'limitation' => new SubtreeLimitation(['limitationValues' => ['/1/2/', '/1/43/']]), 'object' => new ContentCreateStruct(), 'targets' => [new LocationCreateStruct(['parentLocationId' => 55])], - 'persistence' => [new Location(['pathString' => '/1/55/'])], + 'persistenceLocations' => [new Location(['pathString' => '/1/55/'])], 'expected' => LimitationType::ACCESS_DENIED, ], // ContentCreateStruct, with targets, with access @@ -390,7 +394,7 @@ public function providerForTestEvaluate() 'limitation' => new SubtreeLimitation(['limitationValues' => ['/1/2/', '/1/43/']]), 'object' => new ContentCreateStruct(), 'targets' => [new LocationCreateStruct(['parentLocationId' => 43])], - 'persistence' => [new Location(['pathString' => '/1/43/'])], + 'persistenceLocations' => [new Location(['pathString' => '/1/43/'])], 'expected' => LimitationType::ACCESS_GRANTED, ], // invalid object @@ -398,7 +402,7 @@ public function providerForTestEvaluate() 'limitation' => new SubtreeLimitation(), 'object' => new ObjectStateLimitation(), 'targets' => [new LocationCreateStruct(['parentLocationId' => 43])], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => LimitationType::ACCESS_ABSTAIN, ], // invalid target @@ -406,22 +410,20 @@ public function providerForTestEvaluate() 'limitation' => new SubtreeLimitation(), 'object' => new ContentInfo(['published' => true, 'status' => ContentInfo::STATUS_PUBLISHED]), 'targets' => [new ObjectStateLimitation()], - 'persistence' => [], + 'persistenceLocations' => [], 'expected' => LimitationType::ACCESS_ABSTAIN, ], ]; } - /** - * @dataProvider providerForTestEvaluate - */ + #[DataProvider('providerForTestEvaluate')] public function testEvaluate( SubtreeLimitation $limitation, ValueObject $object, $targets, array $persistenceLocations, $expected - ) { + ): void { // Need to create inline instead of depending on testConstruct() to get correct mock instance $limitationType = $this->testConstruct(); @@ -436,18 +438,27 @@ public function testEvaluate( ->expects(self::never()) ->method(self::anything()); } elseif ($object instanceof ContentCreateStruct) { + $this->getPersistenceMock() + ->expects(self::exactly(count($targets))) + ->method('locationHandler') + ->willReturn($this->locationHandlerMock); + + $loadArguments = []; + $loadReturnValues = []; foreach ((array)$targets as $key => $target) { - $this->getPersistenceMock() - ->expects(self::at($key)) - ->method('locationHandler') - ->will(self::returnValue($this->locationHandlerMock)); - - $this->locationHandlerMock - ->expects(self::at($key)) - ->method('load') - ->with($target->parentLocationId) - ->will(self::returnValue($persistenceLocations[$key])); + $loadArguments[$key] = $target->parentLocationId; + $loadReturnValues[$key] = $persistenceLocations[$key]; } + + $matcher = self::exactly(count($targets)); + $this->locationHandlerMock + ->expects($matcher) + ->method('load') + ->willReturnCallback(function (...$parameters) use ($matcher, $loadArguments, $loadReturnValues) { + $this->assertSame($loadArguments[$matcher->numberOfInvocations() - 1], $parameters[0]); + + return $loadReturnValues[$matcher->numberOfInvocations() - 1]; + }); } else { $this->getPersistenceMock() ->expects(self::once()) @@ -474,7 +485,7 @@ public function testEvaluate( /** * @return array */ - public function providerForTestEvaluateInvalidArgument() + public static function providerForTestEvaluateInvalidArgument(): array { return [ // invalid limitation @@ -482,27 +493,25 @@ public function providerForTestEvaluateInvalidArgument() 'limitation' => new ObjectStateLimitation(), 'object' => new ContentInfo(), 'targets' => [new Location()], - 'persistence' => [], + 'persistenceLocations' => [], ], // invalid target when using ContentCreateStruct [ 'limitation' => new SubtreeLimitation(), 'object' => new ContentCreateStruct(), 'targets' => [new Location()], - 'persistence' => [], + 'persistenceLocations' => [], ], ]; } - /** - * @dataProvider providerForTestEvaluateInvalidArgument - */ + #[DataProvider('providerForTestEvaluateInvalidArgument')] public function testEvaluateInvalidArgument( Limitation $limitation, ValueObject $object, $targets, array $persistenceLocations - ) { + ): void { $this->expectException(InvalidArgumentException::class); // Need to create inline instead of depending on testConstruct() to get correct mock instance @@ -528,11 +537,10 @@ public function testEvaluateInvalidArgument( } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\SubtreeLimitationType $limitationType */ - public function testGetCriterionInvalidValue(SubtreeLimitationType $limitationType) + #[Depends('testConstruct')] + public function testGetCriterionInvalidValue(SubtreeLimitationType $limitationType): void { $this->expectException(\RuntimeException::class); @@ -543,11 +551,10 @@ public function testGetCriterionInvalidValue(SubtreeLimitationType $limitationTy } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\SubtreeLimitationType $limitationType */ - public function testGetCriterionSingleValue(SubtreeLimitationType $limitationType) + #[Depends('testConstruct')] + public function testGetCriterionSingleValue(SubtreeLimitationType $limitationType): void { $criterion = $limitationType->getCriterion( new SubtreeLimitation(['limitationValues' => ['/1/9/']]), @@ -564,11 +571,10 @@ public function testGetCriterionSingleValue(SubtreeLimitationType $limitationTyp } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\SubtreeLimitationType $limitationType */ - public function testGetCriterionMultipleValues(SubtreeLimitationType $limitationType) + #[Depends('testConstruct')] + public function testGetCriterionMultipleValues(SubtreeLimitationType $limitationType): void { $criterion = $limitationType->getCriterion( new SubtreeLimitation(['limitationValues' => ['/1/9/', '/1/55/']]), @@ -585,11 +591,10 @@ public function testGetCriterionMultipleValues(SubtreeLimitationType $limitation } /** - * @depends testConstruct - * * @param \Ibexa\Core\Limitation\SubtreeLimitationType $limitationType */ - public function testValueSchema(SubtreeLimitationType $limitationType) + #[Depends('testConstruct')] + public function testValueSchema(SubtreeLimitationType $limitationType): void { self::assertEquals( SubtreeLimitationType::VALUE_SCHEMA_LOCATION_PATH, diff --git a/tests/lib/MVC/Symfony/Component/Serializer/CompoundMatcherNormalizerTest.php b/tests/lib/MVC/Symfony/Component/Serializer/CompoundMatcherNormalizerTest.php index c7c67b26f6..f7733bf532 100644 --- a/tests/lib/MVC/Symfony/Component/Serializer/CompoundMatcherNormalizerTest.php +++ b/tests/lib/MVC/Symfony/Component/Serializer/CompoundMatcherNormalizerTest.php @@ -13,15 +13,17 @@ use Ibexa\Core\MVC\Symfony\SiteAccess\Matcher\Compound; use Ibexa\Tests\Core\MVC\Symfony\Component\Serializer\Stubs\CompoundStub; use Ibexa\Tests\Core\MVC\Symfony\Component\Serializer\Stubs\MatcherStub; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; use PHPUnit\Framework\TestCase; use Symfony\Component\Serializer\Normalizer\DenormalizerInterface; use Symfony\Component\Serializer\Normalizer\NormalizerInterface; /** - * @covers \Ibexa\Core\MVC\Symfony\Component\Serializer\CompoundMatcherNormalizer - * * @phpstan-type TNormalizedData array{type?: class-string, subMatchers: array, config: array, matchersMap: array} */ +#[CoversClass(CompoundMatcherNormalizer::class)] final class CompoundMatcherNormalizerTest extends TestCase { /** @phpstan-var TNormalizedData */ @@ -79,8 +81,8 @@ public function testSupportsNormalization(): void { $normalizer = new CompoundMatcherNormalizer(); - self::assertTrue($normalizer->supportsNormalization($this->createMock(Compound::class))); - self::assertFalse($normalizer->supportsNormalization($this->createMock(Matcher::class))); + self::assertTrue($normalizer->supportsNormalization(self::createStub(Compound::class))); + self::assertFalse($normalizer->supportsNormalization(self::createStub(Matcher::class))); } /** @@ -98,11 +100,10 @@ public static function getDataForSupportsNormalization(): iterable } /** - * @dataProvider getDataForSupportsNormalization - * * @phpstan-param TNormalizedData $data * @phpstan-param class-string $type */ + #[DataProvider('getDataForSupportsNormalization')] public function testSupportsDenormalization(array $data, string $type, bool $supports): void { $normalizer = new CompoundMatcherNormalizer(); @@ -111,12 +112,11 @@ public function testSupportsDenormalization(array $data, string $type, bool $sup } /** - * @depends testNormalization - * * @phpstan-param array{type: class-string, subMatchers: array, config: array{}, matchersMap: array{}} $data * * @throws \Symfony\Component\Serializer\Exception\ExceptionInterface */ + #[Depends('testNormalization')] public function testDenormalization(array $data): void { $expectedCompoundMatcher = new CompoundStub($this->getSubMatchers()); diff --git a/tests/lib/MVC/Symfony/Component/Serializer/HostElementNormalizerTest.php b/tests/lib/MVC/Symfony/Component/Serializer/HostElementNormalizerTest.php index b9fb81129b..b3ec89780e 100644 --- a/tests/lib/MVC/Symfony/Component/Serializer/HostElementNormalizerTest.php +++ b/tests/lib/MVC/Symfony/Component/Serializer/HostElementNormalizerTest.php @@ -12,13 +12,12 @@ use Ibexa\Core\MVC\Symfony\Routing\SimplifiedRequest; use Ibexa\Core\MVC\Symfony\SiteAccess\Matcher; use Ibexa\Core\MVC\Symfony\SiteAccess\Matcher\HostElement; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; use Symfony\Component\Serializer\Normalizer\ObjectNormalizer; use Symfony\Component\Serializer\Serializer; -/** - * @covers \Ibexa\Core\MVC\Symfony\Component\Serializer\HostElementNormalizer - */ +#[CoversClass(HostElementNormalizer::class)] final class HostElementNormalizerTest extends TestCase { private const array DATA = [ @@ -58,8 +57,8 @@ public function testSupportsNormalization(): void { $normalizer = new HostElementNormalizer(); - self::assertTrue($normalizer->supportsNormalization($this->createMock(HostElement::class))); - self::assertFalse($normalizer->supportsNormalization($this->createMock(Matcher::class))); + self::assertTrue($normalizer->supportsNormalization(self::createStub(HostElement::class))); + self::assertFalse($normalizer->supportsNormalization(self::createStub(Matcher::class))); } /** diff --git a/tests/lib/MVC/Symfony/Component/Serializer/HostTextNormalizerTest.php b/tests/lib/MVC/Symfony/Component/Serializer/HostTextNormalizerTest.php index 157fd17285..e0c6e8e5b0 100644 --- a/tests/lib/MVC/Symfony/Component/Serializer/HostTextNormalizerTest.php +++ b/tests/lib/MVC/Symfony/Component/Serializer/HostTextNormalizerTest.php @@ -48,7 +48,7 @@ public function testSupportsNormalization(): void { $normalizer = new HostTextNormalizer(); - self::assertTrue($normalizer->supportsNormalization($this->createMock(HostText::class))); - self::assertFalse($normalizer->supportsNormalization($this->createMock(Matcher::class))); + self::assertTrue($normalizer->supportsNormalization(self::createStub(HostText::class))); + self::assertFalse($normalizer->supportsNormalization(self::createStub(Matcher::class))); } } diff --git a/tests/lib/MVC/Symfony/Component/Serializer/MapNormalizerTest.php b/tests/lib/MVC/Symfony/Component/Serializer/MapNormalizerTest.php index e605db860b..4a57c5c55b 100644 --- a/tests/lib/MVC/Symfony/Component/Serializer/MapNormalizerTest.php +++ b/tests/lib/MVC/Symfony/Component/Serializer/MapNormalizerTest.php @@ -37,7 +37,7 @@ public function testSupportsNormalization(): void { $normalizer = new MapNormalizer(); - self::assertTrue($normalizer->supportsNormalization($this->createMock(MapMatcher::class))); - self::assertFalse($normalizer->supportsNormalization($this->createMock(Matcher::class))); + self::assertTrue($normalizer->supportsNormalization(self::createStub(MapMatcher::class))); + self::assertFalse($normalizer->supportsNormalization(self::createStub(Matcher::class))); } } diff --git a/tests/lib/MVC/Symfony/Component/Serializer/RegexNormalizerTest.php b/tests/lib/MVC/Symfony/Component/Serializer/RegexNormalizerTest.php index 30a3ad4259..519ad6312c 100644 --- a/tests/lib/MVC/Symfony/Component/Serializer/RegexNormalizerTest.php +++ b/tests/lib/MVC/Symfony/Component/Serializer/RegexNormalizerTest.php @@ -35,7 +35,7 @@ public function testSupportsNormalization(): void { $normalizer = new RegexNormalizer(); - self::assertTrue($normalizer->supportsNormalization($this->createMock(RegexMatcher::class))); - self::assertFalse($normalizer->supportsNormalization($this->createMock(Matcher::class))); + self::assertTrue($normalizer->supportsNormalization(self::createStub(RegexMatcher::class))); + self::assertFalse($normalizer->supportsNormalization(self::createStub(Matcher::class))); } } diff --git a/tests/lib/MVC/Symfony/Component/Serializer/SimplifiedRequestNormalizerTest.php b/tests/lib/MVC/Symfony/Component/Serializer/SimplifiedRequestNormalizerTest.php index 8c67e1e7f1..0d5eadfb67 100644 --- a/tests/lib/MVC/Symfony/Component/Serializer/SimplifiedRequestNormalizerTest.php +++ b/tests/lib/MVC/Symfony/Component/Serializer/SimplifiedRequestNormalizerTest.php @@ -9,12 +9,11 @@ use Ibexa\Core\MVC\Symfony\Component\Serializer\SimplifiedRequestNormalizer; use Ibexa\Core\MVC\Symfony\Routing\SimplifiedRequest; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; use stdClass; -/** - * @covers \Ibexa\Core\MVC\Symfony\Component\Serializer\SimplifiedRequestNormalizer - */ +#[CoversClass(SimplifiedRequestNormalizer::class)] final class SimplifiedRequestNormalizerTest extends TestCase { /** diff --git a/tests/lib/MVC/Symfony/Component/Serializer/URIElementNormalizerTest.php b/tests/lib/MVC/Symfony/Component/Serializer/URIElementNormalizerTest.php index 32e41163c6..bd3572e038 100644 --- a/tests/lib/MVC/Symfony/Component/Serializer/URIElementNormalizerTest.php +++ b/tests/lib/MVC/Symfony/Component/Serializer/URIElementNormalizerTest.php @@ -12,20 +12,19 @@ use Ibexa\Core\MVC\Symfony\Routing\SimplifiedRequest; use Ibexa\Core\MVC\Symfony\SiteAccess\Matcher; use Ibexa\Core\MVC\Symfony\SiteAccess\Matcher\URIElement; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\Serializer\Normalizer\ObjectNormalizer; use Symfony\Component\Serializer\Serializer; -/** - * @covers \Ibexa\Core\MVC\Symfony\Component\Serializer\URIElementNormalizer - */ +#[CoversClass(URIElementNormalizer::class)] final class URIElementNormalizerTest extends TestCase { /** - * @dataProvider provideForTestNormalization - * * @throws \Symfony\Component\Serializer\Exception\ExceptionInterface */ + #[DataProvider('provideForTestNormalization')] public function testNormalization(bool $initializeUriElements): void { $normalizer = new URIElementNormalizer(); @@ -66,7 +65,7 @@ public function testSupportsNormalization(): void { $normalizer = new URIElementNormalizer(); - self::assertTrue($normalizer->supportsNormalization($this->createMock(URIElement::class))); - self::assertFalse($normalizer->supportsNormalization($this->createMock(Matcher::class))); + self::assertTrue($normalizer->supportsNormalization(self::createStub(URIElement::class))); + self::assertFalse($normalizer->supportsNormalization(self::createStub(Matcher::class))); } } diff --git a/tests/lib/MVC/Symfony/Component/Serializer/URITextNormalizerTest.php b/tests/lib/MVC/Symfony/Component/Serializer/URITextNormalizerTest.php index 2fc6a505b6..931192d3bf 100644 --- a/tests/lib/MVC/Symfony/Component/Serializer/URITextNormalizerTest.php +++ b/tests/lib/MVC/Symfony/Component/Serializer/URITextNormalizerTest.php @@ -12,12 +12,11 @@ use Ibexa\Core\MVC\Symfony\SiteAccess\Matcher; use Ibexa\Core\MVC\Symfony\SiteAccess\Matcher\URIText; use Ibexa\Tests\Core\Search\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; use Symfony\Component\Serializer\Normalizer\ObjectNormalizer; use Symfony\Component\Serializer\Serializer; -/** - * @covers \Ibexa\Core\MVC\Symfony\Component\Serializer\URITextNormalizer - */ +#[CoversClass(URITextNormalizer::class)] final class URITextNormalizerTest extends TestCase { /** @@ -54,7 +53,7 @@ public function testSupportsNormalization(): void { $normalizer = new URITextNormalizer(); - self::assertTrue($normalizer->supportsNormalization($this->createMock(URIText::class))); - self::assertFalse($normalizer->supportsNormalization($this->createMock(Matcher::class))); + self::assertTrue($normalizer->supportsNormalization(self::createStub(URIText::class))); + self::assertFalse($normalizer->supportsNormalization(self::createStub(Matcher::class))); } } diff --git a/tests/lib/MVC/Symfony/Controller/Controller/Content/DownloadControllerTest.php b/tests/lib/MVC/Symfony/Controller/Controller/Content/DownloadControllerTest.php index 40e6bfbae7..db83e56236 100644 --- a/tests/lib/MVC/Symfony/Controller/Controller/Content/DownloadControllerTest.php +++ b/tests/lib/MVC/Symfony/Controller/Controller/Content/DownloadControllerTest.php @@ -10,14 +10,16 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Field; use Ibexa\Core\Base\Exceptions\NotFoundException as BaseNotFoundException; +use Ibexa\Core\MVC\Symfony\Controller\Content\DownloadController; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; use Symfony\Bridge\PhpUnit\ExpectDeprecationTrait; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpKernel\Exception\NotFoundHttpException; -/** - * @covers \Ibexa\Core\MVC\Symfony\Controller\Content\DownloadController - */ +#[CoversClass(DownloadController::class)] final class DownloadControllerTest extends TestCase { use DownloadControllerTestTrait; @@ -123,9 +125,7 @@ public function testDownloadBinaryFileByIdActionReturnsFileWhenFilenameMatches() self::assertStringContainsString(self::FILENAME, (string) $response->headers->get('Content-Disposition')); } - /** - * @dataProvider provideNotFoundCases - */ + #[DataProvider('provideNotFoundCases')] public function testDownloadBinaryFileByIdActionReturnsNotFound(int $fieldId, string $filename): void { $content = $this->createContent(self::FILENAME); @@ -154,9 +154,7 @@ public static function provideNotFoundCases(): iterable yield 'field id does not exist in content' => [123, self::FILENAME]; } - /** - * @group legacy - */ + #[Group('legacy')] public function testDownloadBinaryFileByIdActionTriggersDeprecationWithoutFilename(): void { $content = $this->createContent(self::FILENAME); diff --git a/tests/lib/MVC/Symfony/Controller/Controller/Content/PreviewControllerTest.php b/tests/lib/MVC/Symfony/Controller/Controller/Content/PreviewControllerTest.php index 7040853152..358a260323 100644 --- a/tests/lib/MVC/Symfony/Controller/Controller/Content/PreviewControllerTest.php +++ b/tests/lib/MVC/Symfony/Controller/Controller/Content/PreviewControllerTest.php @@ -19,6 +19,9 @@ use Ibexa\Core\MVC\Symfony\Controller\Content\PreviewController; use Ibexa\Core\MVC\Symfony\SiteAccess; use Ibexa\Core\MVC\Symfony\View\CustomLocationControllerChecker; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\MockObject\Stub; use PHPUnit\Framework\TestCase; use Psr\Log\LoggerInterface; use Symfony\Component\HttpFoundation\Request; @@ -27,9 +30,7 @@ use Symfony\Component\Security\Core\Authorization\AuthorizationCheckerInterface; use Symfony\Component\Security\Core\Exception\AccessDeniedException; -/** - * @covers \Ibexa\Core\MVC\Symfony\Controller\Content\PreviewController - */ +#[CoversClass(PreviewController::class)] final class PreviewControllerTest extends TestCase { /** @var \Ibexa\Contracts\Core\Repository\ContentService&\PHPUnit\Framework\MockObject\MockObject */ @@ -50,8 +51,7 @@ final class PreviewControllerTest extends TestCase /** @var \Ibexa\Core\Helper\PreviewLocationProvider&\PHPUnit\Framework\MockObject\MockObject */ protected PreviewLocationProvider $locationProvider; - /** @var \Ibexa\Core\MVC\Symfony\View\CustomLocationControllerChecker&\PHPUnit\Framework\MockObject\MockObject */ - protected CustomLocationControllerChecker $controllerChecker; + protected CustomLocationControllerChecker&Stub $controllerChecker; /** @var \Psr\Log\LoggerInterface&\PHPUnit\Framework\MockObject\MockObject */ private LoggerInterface $logger; @@ -66,7 +66,7 @@ protected function setUp(): void $this->previewHelper = $this->createMock(ContentPreviewHelper::class); $this->authorizationChecker = $this->createMock(AuthorizationCheckerInterface::class); $this->locationProvider = $this->createMock(PreviewLocationProvider::class); - $this->controllerChecker = $this->createMock(CustomLocationControllerChecker::class); + $this->controllerChecker = self::createStub(CustomLocationControllerChecker::class); $this->logger = $this->createMock(LoggerInterface::class); } @@ -115,9 +115,9 @@ public function testPreviewCanUserFail(): void $contentId = 123; $lang = 'eng-GB'; $versionNo = 3; - $content = $this->createMock(Content::class); + $content = self::createStub(Content::class); - $location = $this->createMock(Location::class); + $location = self::createStub(Location::class); $this->locationProvider ->method('loadMainLocationByContent') ->with($content) @@ -142,12 +142,12 @@ public function testPreviewWithLogMessage(): void $contentId = 123; $lang = 'eng-GB'; $versionNo = 3; - $content = $this->createMock(Content::class); + $content = self::createStub(Content::class); $location = $this->createMock(Location::class); $location->method('__get')->with('id')->willReturn('42'); - $siteAccess = $this->createMock(SiteAccess::class); + $siteAccess = self::createStub(SiteAccess::class); $this->locationProvider ->method('loadMainLocationByContent') ->with($content) @@ -224,10 +224,9 @@ public static function getDataForTestPreview(): iterable } /** - * @dataProvider getDataForTestPreview - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\Exception */ + #[DataProvider('getDataForTestPreview')] public function testPreview( ?SiteAccess $previewSiteAccess, int $contentId, @@ -236,7 +235,7 @@ public function testPreview( ?int $locationId, ?string $viewType = null ): void { - $content = $this->createMock(Content::class); + $content = self::createStub(Content::class); $location = $this->getMockBuilder(Location::class) ->setConstructorArgs([['id' => $locationId ?? 456]]) ->getMockForAbstractClass(); @@ -333,10 +332,17 @@ private function configurePreviewHelper( SiteAccess $originalSiteAccess, ?SiteAccess $previewSiteAccess = null ): void { + $matcher = self::exactly(2); $this->previewHelper - ->expects(self::exactly(2)) - ->method('setPreviewActive') - ->withConsecutive([true], [false]) + ->expects($matcher) + ->method('setPreviewActive')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertTrue($parameters[0]); + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertFalse($parameters[0]); + } + }) ; $this->previewHelper diff --git a/tests/lib/MVC/Symfony/Controller/ControllerTest.php b/tests/lib/MVC/Symfony/Controller/ControllerTest.php index 35b001520c..f135b3640a 100644 --- a/tests/lib/MVC/Symfony/Controller/ControllerTest.php +++ b/tests/lib/MVC/Symfony/Controller/ControllerTest.php @@ -8,16 +8,16 @@ namespace Ibexa\Tests\Core\MVC\Symfony\Controller; use Ibexa\Core\MVC\Symfony\Controller\Controller; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; use Symfony\Component\DependencyInjection\ContainerInterface; use Symfony\Component\HttpFoundation\Response; use Twig\Environment; /** - * @covers \Ibexa\Core\MVC\Symfony\Controller\Controller::render - * * @mvc */ +#[CoversClass(Controller::class)] class ControllerTest extends TestCase { /** @var \Ibexa\Core\MVC\Symfony\Controller\Controller */ @@ -41,7 +41,7 @@ protected function setUp(): void ->will(self::returnValue($this->templateEngineMock)); } - public function testRender() + public function testRender(): void { $view = 'some:valid:view.html.twig'; $params = ['foo' => 'bar', 'truc' => 'muche']; @@ -56,7 +56,7 @@ public function testRender() self::assertSame($tplResult, $response->getContent()); } - public function testRenderWithResponse() + public function testRenderWithResponse(): void { $response = new Response(); $view = 'some:valid:view.html.twig'; diff --git a/tests/lib/MVC/Symfony/Controller/QueryRenderControllerTest.php b/tests/lib/MVC/Symfony/Controller/QueryRenderControllerTest.php index 1343336d1c..2fbabe346c 100644 --- a/tests/lib/MVC/Symfony/Controller/QueryRenderControllerTest.php +++ b/tests/lib/MVC/Symfony/Controller/QueryRenderControllerTest.php @@ -15,17 +15,17 @@ use Ibexa\Core\Pagination\Pagerfanta\Pagerfanta; use Ibexa\Core\Pagination\Pagerfanta\SearchResultAdapter; use Ibexa\Core\Query\QueryFactoryInterface; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; use Symfony\Component\HttpFoundation\Request; /** - * @covers \Ibexa\Core\MVC\Symfony\Controller\QueryRenderController - * * @phpstan-import-type TOptionsArray from \Ibexa\Core\MVC\Symfony\Controller\QueryRenderController * * @template TSearchHitValueObject of \Ibexa\Contracts\Core\Repository\Values\ValueObject */ +#[CoversClass(QueryRenderController::class)] final class QueryRenderControllerTest extends TestCase { private const int EXAMPLE_CURRENT_PAGE = 3; diff --git a/tests/lib/MVC/Symfony/Event/RouteReferenceGenerationEventTest.php b/tests/lib/MVC/Symfony/Event/RouteReferenceGenerationEventTest.php index 09c47f2133..79cb947c98 100644 --- a/tests/lib/MVC/Symfony/Event/RouteReferenceGenerationEventTest.php +++ b/tests/lib/MVC/Symfony/Event/RouteReferenceGenerationEventTest.php @@ -14,7 +14,7 @@ class RouteReferenceGenerationEventTest extends TestCase { - public function testConstruct() + public function testConstruct(): void { $routeReference = new RouteReference('foo'); $request = new Request(); @@ -23,7 +23,7 @@ public function testConstruct() self::assertSame($request, $event->getRequest()); } - public function testGetSet() + public function testGetSet(): void { $routeReference = new RouteReference('foo'); $request = new Request(); diff --git a/tests/lib/MVC/Symfony/Event/ScopeChangeEventTest.php b/tests/lib/MVC/Symfony/Event/ScopeChangeEventTest.php index c44d0c463b..8869d4efb5 100644 --- a/tests/lib/MVC/Symfony/Event/ScopeChangeEventTest.php +++ b/tests/lib/MVC/Symfony/Event/ScopeChangeEventTest.php @@ -13,7 +13,7 @@ class ScopeChangeEventTest extends TestCase { - public function testGetSiteAccess() + public function testGetSiteAccess(): void { $siteAccess = new SiteAccess('foo', 'test'); $event = new ScopeChangeEvent($siteAccess); diff --git a/tests/lib/MVC/Symfony/EventListener/ContentViewTwigVariablesSubscriberTest.php b/tests/lib/MVC/Symfony/EventListener/ContentViewTwigVariablesSubscriberTest.php index 9732352854..b3d23488c5 100644 --- a/tests/lib/MVC/Symfony/EventListener/ContentViewTwigVariablesSubscriberTest.php +++ b/tests/lib/MVC/Symfony/EventListener/ContentViewTwigVariablesSubscriberTest.php @@ -72,7 +72,7 @@ private function getContentViewMockSubscriber(): ContentViewTwigVariablesSubscri $this->getRegistry([ $this->getProvider('test_provider'), ]), - $this->createMock(ConfigResolverInterface::class) + self::createStub(ConfigResolverInterface::class) ); } diff --git a/tests/lib/MVC/Symfony/EventListener/LanguageSwitchListenerTest.php b/tests/lib/MVC/Symfony/EventListener/LanguageSwitchListenerTest.php index ce13fc1191..531ca4d4a2 100644 --- a/tests/lib/MVC/Symfony/EventListener/LanguageSwitchListenerTest.php +++ b/tests/lib/MVC/Symfony/EventListener/LanguageSwitchListenerTest.php @@ -28,7 +28,7 @@ protected function setUp(): void ->getMock(); } - public function testGetSubscribedEvents() + public function testGetSubscribedEvents(): void { self::assertSame( [MVCEvents::ROUTE_REFERENCE_GENERATION => 'onRouteReferenceGeneration'], @@ -36,7 +36,7 @@ public function testGetSubscribedEvents() ); } - public function testOnRouteReferenceGenerationNoLanguage() + public function testOnRouteReferenceGenerationNoLanguage(): void { $this->translationHelper ->expects(self::never()) @@ -47,7 +47,7 @@ public function testOnRouteReferenceGenerationNoLanguage() $listener->onRouteReferenceGeneration($event); } - public function testOnRouteReferenceGeneration() + public function testOnRouteReferenceGeneration(): void { $language = 'fre-FR'; $routeReference = new RouteReference('foo', ['language' => $language]); @@ -66,7 +66,7 @@ public function testOnRouteReferenceGeneration() self::assertSame($expectedSiteAccess, $routeReference->get('siteaccess')); } - public function testOnRouteReferenceGenerationNoTranslationSiteAccess() + public function testOnRouteReferenceGenerationNoTranslationSiteAccess(): void { $language = 'fre-FR'; $routeReference = new RouteReference('foo', ['language' => $language]); diff --git a/tests/lib/MVC/Symfony/EventListener/SiteAccessMatchListenerTest.php b/tests/lib/MVC/Symfony/EventListener/SiteAccessMatchListenerTest.php index 04e776f1cc..8b07fade12 100644 --- a/tests/lib/MVC/Symfony/EventListener/SiteAccessMatchListenerTest.php +++ b/tests/lib/MVC/Symfony/EventListener/SiteAccessMatchListenerTest.php @@ -26,6 +26,8 @@ use Ibexa\Core\MVC\Symfony\SiteAccess\Matcher; use Ibexa\Core\MVC\Symfony\SiteAccess\Router; use Ibexa\Core\MVC\Symfony\SiteAccessGroup; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; use Symfony\Component\EventDispatcher\EventDispatcherInterface; use Symfony\Component\HttpFoundation\Request; @@ -40,19 +42,14 @@ use Symfony\Component\Serializer\Serializer; use Symfony\Component\Serializer\SerializerInterface; -/** - * @covers \Ibexa\Core\MVC\Symfony\EventListener\SiteAccessMatchListener - */ +#[CoversClass(SiteAccessMatchListener::class)] final class SiteAccessMatchListenerTest extends TestCase { - /** @var \PHPUnit\Framework\MockObject\MockObject&\Ibexa\Core\MVC\Symfony\SiteAccess\Router */ - private Router $saRouter; + private Router&MockObject $saRouter; - /** @var \PHPUnit\Framework\MockObject\MockObject&\Symfony\Component\EventDispatcher\EventDispatcherInterface */ - private EventDispatcherInterface $eventDispatcher; + private EventDispatcherInterface&MockObject $eventDispatcher; - /** @var \PHPUnit\Framework\MockObject\MockObject&\Ibexa\Bundle\Core\SiteAccess\SiteAccessMatcherRegistryInterface */ - private SiteAccessMatcherRegistryInterface $registry; + private SiteAccessMatcherRegistryInterface&MockObject $registry; private SiteAccessMatchListener $listener; @@ -248,7 +245,7 @@ private function assertRequestHasSiteAccess( ): void { $originalRequest ??= $request; $event = new RequestEvent( - $this->createMock(HttpKernelInterface::class), + self::createStub(HttpKernelInterface::class), $request, HttpKernelInterface::MAIN_REQUEST ); @@ -288,7 +285,7 @@ private function assertRequestHasSiteAccess( private function dispatchRequestEvent(Request $request, SiteAccess $siteAccess): void { $event = new RequestEvent( - $this->createMock(HttpKernelInterface::class), + self::createStub(HttpKernelInterface::class), $request, HttpKernelInterface::MAIN_REQUEST ); diff --git a/tests/lib/MVC/Symfony/EventListener/SiteAccessRestoreListenerTest.php b/tests/lib/MVC/Symfony/EventListener/SiteAccessRestoreListenerTest.php index fc56def369..cb36739c25 100644 --- a/tests/lib/MVC/Symfony/EventListener/SiteAccessRestoreListenerTest.php +++ b/tests/lib/MVC/Symfony/EventListener/SiteAccessRestoreListenerTest.php @@ -12,6 +12,10 @@ use Ibexa\Core\MVC\Symfony\EventListener\SiteAccessRestoreListener; use Ibexa\Core\MVC\Symfony\MVCEvents; use Ibexa\Core\MVC\Symfony\SiteAccess; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\MockObject\MockObject; +use PHPUnit\Framework\MockObject\Stub; use PHPUnit\Framework\TestCase; use Symfony\Component\EventDispatcher\EventDispatcherInterface; use Symfony\Component\HttpFoundation\Request; @@ -20,16 +24,12 @@ use Symfony\Component\HttpKernel\HttpKernelInterface; use Symfony\Component\HttpKernel\KernelEvents; -/** - * @covers \Ibexa\Core\MVC\Symfony\EventListener\SiteAccessRestoreListener - */ +#[CoversClass(SiteAccessRestoreListener::class)] final class SiteAccessRestoreListenerTest extends TestCase { - /** @var \PHPUnit\Framework\MockObject\MockObject&\Symfony\Component\HttpKernel\HttpKernelInterface */ - private HttpKernelInterface $kernel; + private HttpKernelInterface&Stub $kernel; - /** @var \PHPUnit\Framework\MockObject\MockObject&\Symfony\Component\EventDispatcher\EventDispatcherInterface */ - private EventDispatcherInterface $eventDispatcher; + private EventDispatcherInterface&MockObject $eventDispatcher; private RequestStack $requestStack; @@ -38,7 +38,7 @@ final class SiteAccessRestoreListenerTest extends TestCase protected function setUp(): void { parent::setUp(); - $this->kernel = $this->createMock(HttpKernelInterface::class); + $this->kernel = self::createStub(HttpKernelInterface::class); $this->eventDispatcher = $this->createMock(EventDispatcherInterface::class); $this->requestStack = new RequestStack(); $this->listener = new SiteAccessRestoreListener( @@ -84,10 +84,9 @@ static function (PostSiteAccessMatchEvent $event) use ($parentSiteAccess, $paren } /** - * @dataProvider provideNoDispatchCases - * * @param \Symfony\Component\HttpFoundation\Request[] $requests */ + #[DataProvider('provideNoDispatchCases')] public function testNoDispatch(array $requests, int $requestType): void { $finishingRequest = null; diff --git a/tests/lib/MVC/Symfony/FieldType/BinaryBase/ContentDownloadUrlGeneratorTest.php b/tests/lib/MVC/Symfony/FieldType/BinaryBase/ContentDownloadUrlGeneratorTest.php index 8d1949b3b4..4961e1274b 100644 --- a/tests/lib/MVC/Symfony/FieldType/BinaryBase/ContentDownloadUrlGeneratorTest.php +++ b/tests/lib/MVC/Symfony/FieldType/BinaryBase/ContentDownloadUrlGeneratorTest.php @@ -13,13 +13,12 @@ use Ibexa\Contracts\Core\Persistence\Content\FieldValue; use Ibexa\Contracts\Core\Persistence\Content\VersionInfo; use Ibexa\Core\MVC\Symfony\FieldType\BinaryBase\ContentDownloadUrlGenerator; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; use Symfony\Component\Routing\RouterInterface; -/** - * @covers \Ibexa\Core\MVC\Symfony\FieldType\BinaryBase\ContentDownloadUrlGenerator - */ +#[CoversClass(ContentDownloadUrlGenerator::class)] final class ContentDownloadUrlGeneratorTest extends TestCase { private const string ROUTE = 'ibexa.content.download.field_id.filename'; diff --git a/tests/lib/MVC/Symfony/FieldType/ImageAsset/ParameterProviderTest.php b/tests/lib/MVC/Symfony/FieldType/ImageAsset/ParameterProviderTest.php index 74171e7119..95ab0ba8d7 100644 --- a/tests/lib/MVC/Symfony/FieldType/ImageAsset/ParameterProviderTest.php +++ b/tests/lib/MVC/Symfony/FieldType/ImageAsset/ParameterProviderTest.php @@ -17,6 +17,7 @@ use Ibexa\Core\FieldType\ImageAsset\Value as ImageAssetValue; use Ibexa\Core\MVC\Symfony\FieldType\ImageAsset\ParameterProvider; use Ibexa\Core\Repository\SiteAccessAware\Repository; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; class ParameterProviderTest extends TestCase @@ -57,7 +58,7 @@ protected function setUp(): void $this->parameterProvider = new ParameterProvider($this->repository); } - public function dataProviderForTestGetViewParameters(): array + public static function dataProviderForTestGetViewParameters(): array { return [ [ContentInfo::STATUS_PUBLISHED, ['available' => true]], @@ -65,9 +66,7 @@ public function dataProviderForTestGetViewParameters(): array ]; } - /** - * @dataProvider dataProviderForTestGetViewParameters - */ + #[DataProvider('dataProviderForTestGetViewParameters')] public function testGetViewParameters($status, array $expected): void { $destinationContentId = 1; @@ -112,7 +111,7 @@ public function testGetViewParametersHandleNotFoundException(): void ->expects(self::once()) ->method('sudo') ->with($closure) - ->willThrowException($this->createMock(NotFoundException::class)); + ->willThrowException(self::createStub(NotFoundException::class)); $actual = $this->parameterProvider->getViewParameters( $this->createField($destinationContentId) @@ -131,26 +130,28 @@ public function testGetViewParametersHandleUnauthorizedAccess(): void ->method('isEmptyValue') ->willReturn(false); - $contentInfo = $this->createMock(ContentInfo::class); + $contentInfo = self::createStub(ContentInfo::class); $this->repository ->method('sudo') ->willReturn($contentInfo) ; + $matcher = self::exactly(2); $this->permissionsResolver - ->expects(self::at(0)) + ->expects($matcher) ->method('canUser') - ->with('content', 'read', $contentInfo) - ->willReturn(false) - ; - - $this->permissionsResolver - ->expects(self::at(1)) - ->method('canUser') - ->with('content', 'view_embed', $contentInfo) - ->willReturn(false) - ; + ->willReturnCallback(static function (string $module, string $function, object $object, array $targets = []) use ($matcher, $contentInfo): bool { + self::assertSame('content', $module); + self::assertSame($contentInfo, $object); + if ($matcher->numberOfInvocations() === 1) { + self::assertSame('read', $function); + } else { + self::assertSame('view_embed', $function); + } + + return false; + }); $actual = $this->parameterProvider->getViewParameters( $this->createField($destinationContentId) @@ -169,7 +170,7 @@ public function testGetViewParametersHandleEmptyValue(): void ->method('isEmptyValue') ->willReturn(true); - $contentInfo = $this->createMock(ContentInfo::class); + $contentInfo = self::createStub(ContentInfo::class); $this->repository ->method('sudo') diff --git a/tests/lib/MVC/Symfony/FieldType/Relation/ParameterProviderTest.php b/tests/lib/MVC/Symfony/FieldType/Relation/ParameterProviderTest.php index 5000f84fc3..157ed3c9b1 100644 --- a/tests/lib/MVC/Symfony/FieldType/Relation/ParameterProviderTest.php +++ b/tests/lib/MVC/Symfony/FieldType/Relation/ParameterProviderTest.php @@ -14,11 +14,15 @@ use Ibexa\Core\Base\Exceptions\UnauthorizedException; use Ibexa\Core\FieldType\Relation\Value; use Ibexa\Core\MVC\Symfony\FieldType\Relation\ParameterProvider; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; class ParameterProviderTest extends TestCase { - public function providerForTestGetViewParameters() + /** + * @return array + */ + public static function providerForTestGetViewParameters(): array { return [ [ContentInfo::STATUS_DRAFT, ['available' => true]], @@ -27,10 +31,8 @@ public function providerForTestGetViewParameters() ]; } - /** - * @dataProvider providerForTestGetViewParameters - */ - public function testGetViewParameters($status, array $expected) + #[DataProvider('providerForTestGetViewParameters')] + public function testGetViewParameters($status, array $expected): void { $contentServiceMock = $this->createMock(ContentService::class); $contentServiceMock @@ -47,7 +49,7 @@ public function testGetViewParameters($status, array $expected) TestCase::assertSame($parameters, $expected); } - public function testNotFoundGetViewParameters() + public function testNotFoundGetViewParameters(): void { $contentId = 123; @@ -64,7 +66,7 @@ public function testNotFoundGetViewParameters() TestCase::assertSame($parameters, ['available' => false]); } - public function testUnauthorizedGetViewParameters() + public function testUnauthorizedGetViewParameters(): void { $contentId = 123; diff --git a/tests/lib/MVC/Symfony/FieldType/RelationList/ParameterProviderTest.php b/tests/lib/MVC/Symfony/FieldType/RelationList/ParameterProviderTest.php index 7a5aa2df1b..7828434e39 100644 --- a/tests/lib/MVC/Symfony/FieldType/RelationList/ParameterProviderTest.php +++ b/tests/lib/MVC/Symfony/FieldType/RelationList/ParameterProviderTest.php @@ -12,11 +12,15 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Field; use Ibexa\Core\FieldType\RelationList\Value; use Ibexa\Core\MVC\Symfony\FieldType\RelationList\ParameterProvider; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; class ParameterProviderTest extends TestCase { - public function providerForTestGetViewParameters() + /** + * @return array + */ + public static function providerForTestGetViewParameters(): array { return [ [[123, 456, 789], ['available' => [123 => true, 456 => true, 789 => false]]], @@ -26,10 +30,8 @@ public function providerForTestGetViewParameters() ]; } - /** - * @dataProvider providerForTestGetViewParameters - */ - public function testGetViewParameters(array $desinationContentIds, array $expected) + #[DataProvider('providerForTestGetViewParameters')] + public function testGetViewParameters(array $desinationContentIds, array $expected): void { $contentServiceMock = $this->createMock(ContentService::class); $contentServiceMock @@ -60,7 +62,7 @@ public function testGetViewParameters(array $desinationContentIds, array $expect TestCase::assertSame($parameters, $expected); } - public function testNotFoundGetViewParameters() + public function testNotFoundGetViewParameters(): void { $contentId = 123; @@ -78,7 +80,7 @@ public function testNotFoundGetViewParameters() TestCase::assertSame($parameters, ['available' => [$contentId => false]]); } - public function testUnauthorizedGetViewParameters() + public function testUnauthorizedGetViewParameters(): void { $contentId = 123; diff --git a/tests/lib/MVC/Symfony/FieldType/User/ParameterProviderTest.php b/tests/lib/MVC/Symfony/FieldType/User/ParameterProviderTest.php index 46214e9b71..400e4d6784 100644 --- a/tests/lib/MVC/Symfony/FieldType/User/ParameterProviderTest.php +++ b/tests/lib/MVC/Symfony/FieldType/User/ParameterProviderTest.php @@ -16,6 +16,7 @@ use Ibexa\Contracts\Core\Repository\Values\User\User; use Ibexa\Core\FieldType\User\Value; use Ibexa\Core\MVC\Symfony\FieldType\User\ParameterProvider; +use PHPUnit\Framework\MockObject\Stub; use PHPUnit\Framework\TestCase; class ParameterProviderTest extends TestCase @@ -25,15 +26,14 @@ class ParameterProviderTest extends TestCase /** @var \Ibexa\Contracts\Core\Repository\UserService|\PHPUnit\Framework\MockObject\MockObject */ private $userService; - /** @var \Ibexa\Contracts\Core\Repository\Values\User\User|\PHPUnit\Framework\MockObject\MockObject */ - private $user; + private User&Stub $user; /** @var \Ibexa\Core\MVC\Symfony\FieldType\User\ParameterProvider */ private $parameterProvider; protected function setUp(): void { - $this->user = $this->createMock(User::class); + $this->user = self::createStub(User::class); $this->userService = $this->createMock(UserService::class); $this->userService diff --git a/tests/lib/MVC/Symfony/FieldType/View/ParameterProvider/LocaleParameterProviderTest.php b/tests/lib/MVC/Symfony/FieldType/View/ParameterProvider/LocaleParameterProviderTest.php index b9946d8788..95a02542ee 100644 --- a/tests/lib/MVC/Symfony/FieldType/View/ParameterProvider/LocaleParameterProviderTest.php +++ b/tests/lib/MVC/Symfony/FieldType/View/ParameterProvider/LocaleParameterProviderTest.php @@ -10,6 +10,7 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Field; use Ibexa\Core\MVC\Symfony\FieldType\View\ParameterProvider\LocaleParameterProvider; use Ibexa\Core\MVC\Symfony\Locale\LocaleConverterInterface; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\HttpFoundation\ParameterBag; use Symfony\Component\HttpFoundation\Request; @@ -17,7 +18,10 @@ class LocaleParameterProviderTest extends TestCase { - public function providerForTestGetViewParameters() + /** + * @return array + */ + public static function providerForTestGetViewParameters(): array { return [ [true, 'fr_FR'], @@ -25,10 +29,8 @@ public function providerForTestGetViewParameters() ]; } - /** - * @dataProvider providerForTestGetViewParameters - */ - public function testGetViewParameters($hasRequestLocale, $expectedLocale) + #[DataProvider('providerForTestGetViewParameters')] + public function testGetViewParameters($hasRequestLocale, $expectedLocale): void { $field = new Field(['languageCode' => 'cro-HR']); $parameterProvider = new LocaleParameterProvider($this->getLocaleConverterMock()); diff --git a/tests/lib/MVC/Symfony/FieldType/View/ParameterProviderRegistryTest.php b/tests/lib/MVC/Symfony/FieldType/View/ParameterProviderRegistryTest.php index cfe023e1e9..efe0c8b495 100644 --- a/tests/lib/MVC/Symfony/FieldType/View/ParameterProviderRegistryTest.php +++ b/tests/lib/MVC/Symfony/FieldType/View/ParameterProviderRegistryTest.php @@ -9,25 +9,24 @@ use Ibexa\Core\MVC\Symfony\FieldType\View\ParameterProviderInterface; use Ibexa\Core\MVC\Symfony\FieldType\View\ParameterProviderRegistry; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\MVC\Symfony\FieldType\View\ParameterProviderRegistry::setParameterProvider - */ +#[CoversClass(ParameterProviderRegistry::class)] class ParameterProviderRegistryTest extends TestCase { - public function testSetHasParameterProvider() + public function testSetHasParameterProvider(): void { $registry = new ParameterProviderRegistry(); self::assertFalse($registry->hasParameterProvider('foo')); $registry->setParameterProvider( - $this->createMock(ParameterProviderInterface::class), + self::createStub(ParameterProviderInterface::class), 'foo' ); self::assertTrue($registry->hasParameterProvider('foo')); } - public function testGetParameterProviderFail() + public function testGetParameterProviderFail(): void { $this->expectException(\InvalidArgumentException::class); @@ -35,9 +34,9 @@ public function testGetParameterProviderFail() $registry->getParameterProvider('foo'); } - public function testGetParameterProvider() + public function testGetParameterProvider(): void { - $provider = $this->createMock(ParameterProviderInterface::class); + $provider = self::createStub(ParameterProviderInterface::class); $registry = new ParameterProviderRegistry(); $registry->setParameterProvider($provider, 'foo'); self::assertSame($provider, $registry->getParameterProvider('foo')); diff --git a/tests/lib/MVC/Symfony/Locale/LocaleConverterTest.php b/tests/lib/MVC/Symfony/Locale/LocaleConverterTest.php index cee827aa1b..89dc87d6ba 100644 --- a/tests/lib/MVC/Symfony/Locale/LocaleConverterTest.php +++ b/tests/lib/MVC/Symfony/Locale/LocaleConverterTest.php @@ -8,12 +8,12 @@ namespace Ibexa\Tests\Core\MVC\Symfony\Locale; use Ibexa\Core\MVC\Symfony\Locale\LocaleConverter; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Psr\Log\LoggerInterface; -/** - * @covers \Ibexa\Core\MVC\Symfony\Locale\LocaleConverter - */ +#[CoversClass(LocaleConverter::class)] final class LocaleConverterTest extends TestCase { private LocaleConverter $localeConverter; @@ -48,9 +48,7 @@ protected function setUp(): void $this->localeConverter = new LocaleConverter($this->conversionMap, $this->logger); } - /** - * @dataProvider convertToPOSIXProvider - */ + #[DataProvider('convertToPOSIXProvider')] public function testConvertToPOSIX(string $repositoryLocale, ?string $expected): void { if ($expected === null) { @@ -62,7 +60,7 @@ public function testConvertToPOSIX(string $repositoryLocale, ?string $expected): self::assertSame($expected, $this->localeConverter->convertToPOSIX($repositoryLocale)); } - public function convertToPOSIXProvider(): array + public static function convertToPOSIXProvider(): array { return [ ['eng-GB', 'en_GB'], @@ -74,9 +72,7 @@ public function convertToPOSIXProvider(): array ]; } - /** - * @dataProvider convertToRepositoryProvider - */ + #[DataProvider('convertToRepositoryProvider')] public function testConvertToRepository(string $posixLocale, ?string $expected): void { if ($expected === null) { @@ -96,7 +92,7 @@ public function testConvertToRepository(string $posixLocale, ?string $expected): * } * } */ - public function convertToRepositoryProvider(): array + public static function convertToRepositoryProvider(): array { return [ ['en_GB', 'eng-GB'], diff --git a/tests/lib/MVC/Symfony/Locale/UserLanguagePreferenceProviderTest.php b/tests/lib/MVC/Symfony/Locale/UserLanguagePreferenceProviderTest.php index c3373aea71..59dcdc1769 100644 --- a/tests/lib/MVC/Symfony/Locale/UserLanguagePreferenceProviderTest.php +++ b/tests/lib/MVC/Symfony/Locale/UserLanguagePreferenceProviderTest.php @@ -12,6 +12,7 @@ use Ibexa\Contracts\Core\Repository\Values\UserPreference\UserPreference; use Ibexa\Core\Base\Exceptions\NotFoundException; use Ibexa\Core\MVC\Symfony\Locale\UserLanguagePreferenceProvider; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; use Symfony\Component\HttpFoundation\HeaderBag; @@ -46,11 +47,10 @@ protected function setUp(): void } /** - * @dataProvider providerForTestGetPreferredLanguages - * * @param list $userLanguages * @param list $expectedEzLanguageCodes */ + #[DataProvider('providerForTestGetPreferredLanguages')] public function testGetPreferredLanguagesWithoutUserLanguage(array $userLanguages, array $expectedEzLanguageCodes): void { $request = new Request(); @@ -85,11 +85,10 @@ public function testGetPreferredLanguagesWithoutUserLanguage(array $userLanguage } /** - * @dataProvider providerForTestGetPreferredLanguagesWithUserPreferredLanguage - * * @param list $userLanguages * @param list $expectedEzLanguageCodes */ + #[DataProvider('providerForTestGetPreferredLanguagesWithUserPreferredLanguage')] public function testGetPreferredLanguagesWithUserPreferredLanguage( array $userLanguages, array $expectedEzLanguageCodes @@ -164,7 +163,7 @@ public function testGetPreferredLocalesExcludesAcceptLanguageWildcard(): void * * @return array, list}> */ - public function providerForTestGetPreferredLanguages(): array + public static function providerForTestGetPreferredLanguages(): array { return [ [[], ['eng-GB', 'eng-US']], @@ -180,7 +179,7 @@ public function providerForTestGetPreferredLanguages(): array * * @return array, list}> */ - public function providerForTestGetPreferredLanguagesWithUserPreferredLanguage(): array + public static function providerForTestGetPreferredLanguagesWithUserPreferredLanguage(): array { return [ [[], ['nor-NO', 'eng-GB', 'eng-US']], diff --git a/tests/lib/MVC/Symfony/Matcher/ContentBased/BaseTestCase.php b/tests/lib/MVC/Symfony/Matcher/ContentBased/BaseTestCase.php index 28d47fda8c..127c0c9497 100644 --- a/tests/lib/MVC/Symfony/Matcher/ContentBased/BaseTestCase.php +++ b/tests/lib/MVC/Symfony/Matcher/ContentBased/BaseTestCase.php @@ -44,7 +44,7 @@ protected function getPartiallyMockedViewProvider(array $matchingConfig = []) $matchingConfig, ] ) - ->setMethods(['getMatcher']) + ->onlyMethods(['getMatcher']) ->getMock(); } @@ -58,11 +58,11 @@ protected function getRepositoryMock() return $this ->getMockBuilder($repositoryClass) ->disableOriginalConstructor() - ->setMethods( - array_diff( + ->onlyMethods( + array_values(array_diff( get_class_methods($repositoryClass), ['sudo'] - ) + )) ) ->getMock(); } @@ -103,12 +103,12 @@ protected function getPermissionResolverMock() return $this ->getMockBuilder(PermissionResolver::class) - ->setMethods(null) + ->onlyMethods([]) ->setConstructorArgs( [ - $this->createMock(RoleDomainMapper::class), - $this->createMock(LimitationService::class), - $this->createMock(SPIUserHandler::class), + self::createStub(RoleDomainMapper::class), + self::createStub(LimitationService::class), + self::createStub(SPIUserHandler::class), $configResolverMock, [], ] diff --git a/tests/lib/MVC/Symfony/Matcher/ContentBased/DepthTest.php b/tests/lib/MVC/Symfony/Matcher/ContentBased/DepthTest.php index d44193fe72..b3a00cfe30 100644 --- a/tests/lib/MVC/Symfony/Matcher/ContentBased/DepthTest.php +++ b/tests/lib/MVC/Symfony/Matcher/ContentBased/DepthTest.php @@ -10,8 +10,15 @@ use Ibexa\Contracts\Core\Repository\LocationService; use Ibexa\Contracts\Core\Repository\Repository; use Ibexa\Contracts\Core\Repository\Values\Content\Location; +use Ibexa\Core\MVC\RepositoryAware; use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Depth as DepthMatcher; +use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +#[CoversClass(DepthMatcher::class)] +#[CoversClass(MultipleValued::class)] +#[CoversClass(RepositoryAware::class)] class DepthTest extends BaseTestCase { /** @var \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Depth */ @@ -24,71 +31,63 @@ protected function setUp(): void } /** - * @dataProvider matchLocationProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Depth::matchLocation - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * * @param int|int[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Values\Content\Location $location * @param bool $expectedResult */ - public function testMatchLocation($matchingConfig, Location $location, $expectedResult) + #[DataProvider('matchLocationProvider')] + public function testMatchLocation($matchingConfig, int $depth, $expectedResult): void { $this->matcher->setMatchingConfig($matchingConfig); - self::assertSame($expectedResult, $this->matcher->matchLocation($location)); + self::assertSame($expectedResult, $this->matcher->matchLocation($this->getLocationMock(['depth' => $depth]))); } - public function matchLocationProvider() + /** + * @return array + */ + public static function matchLocationProvider(): array { return [ [ 1, - $this->getLocationMock(['depth' => 1]), + 1, true, ], [ 1, - $this->getLocationMock(['depth' => 2]), + 2, false, ], [ [1, 3], - $this->getLocationMock(['depth' => 2]), + 2, false, ], [ [1, 3], - $this->getLocationMock(['depth' => 3]), + 3, true, ], [ [1, 3], - $this->getLocationMock(['depth' => 0]), + 0, false, ], [ [0, 1], - $this->getLocationMock(['depth' => 0]), + 0, true, ], ]; } /** - * @dataProvider matchContentInfoProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Depth::matchContentInfo - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * @covers \Ibexa\Core\MVC\RepositoryAware::setRepository - * * @param int|int[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Repository $repository * @param bool $expectedResult */ - public function testMatchContentInfo($matchingConfig, Repository $repository, $expectedResult) + #[DataProvider('matchContentInfoProvider')] + public function testMatchContentInfo($matchingConfig, int $depth, $expectedResult): void { - $this->matcher->setRepository($repository); + $this->matcher->setRepository($this->generateRepositoryMockForDepth($depth)); $this->matcher->setMatchingConfig($matchingConfig); self::assertSame( $expectedResult, @@ -96,27 +95,30 @@ public function testMatchContentInfo($matchingConfig, Repository $repository, $e ); } - public function matchContentInfoProvider() + /** + * @return array + */ + public static function matchContentInfoProvider(): array { return [ [ 1, - $this->generateRepositoryMockForDepth(1), + 1, true, ], [ 1, - $this->generateRepositoryMockForDepth(2), + 2, false, ], [ [1, 3], - $this->generateRepositoryMockForDepth(2), + 2, false, ], [ [1, 3], - $this->generateRepositoryMockForDepth(3), + 3, true, ], ]; diff --git a/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTest.php b/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTest.php index 67c66b6a3f..e658674980 100644 --- a/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTest.php +++ b/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTest.php @@ -7,11 +7,15 @@ namespace Ibexa\Tests\Core\MVC\Symfony\Matcher\ContentBased\Id; -use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; use Ibexa\Contracts\Core\Repository\Values\Content\Location; use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\Content as ContentIdMatcher; +use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued; use Ibexa\Tests\Core\MVC\Symfony\Matcher\ContentBased\BaseTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +#[CoversClass(ContentIdMatcher::class)] +#[CoversClass(MultipleValued::class)] class ContentTest extends BaseTestCase { /** @var \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\Content */ @@ -24,42 +28,40 @@ protected function setUp(): void } /** - * @dataProvider matchLocationProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\Content::matchLocation - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * * @param int|int[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Values\Content\Location $location * @param bool $expectedResult */ - public function testMatchLocation($matchingConfig, Location $location, $expectedResult) + #[DataProvider('matchLocationProvider')] + public function testMatchLocation($matchingConfig, int $contentId, $expectedResult): void { $this->matcher->setMatchingConfig($matchingConfig); - self::assertSame($expectedResult, $this->matcher->matchLocation($location)); + self::assertSame($expectedResult, $this->matcher->matchLocation($this->generateLocationForContentId($contentId))); } - public function matchLocationProvider() + /** + * @return array + */ + public static function matchLocationProvider(): array { return [ [ 123, - $this->generateLocationForContentId(123), + 123, true, ], [ 123, - $this->generateLocationForContentId(456), + 456, false, ], [ [123, 789], - $this->generateLocationForContentId(456), + 456, false, ], [ [123, 789], - $this->generateLocationForContentId(789), + 789, true, ], ]; @@ -88,42 +90,40 @@ private function generateLocationForContentId($contentId) } /** - * @dataProvider matchContentInfoProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\Content::matchContentInfo - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * * @param int|int[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo $contentInfo * @param bool $expectedResult */ - public function testMatchContentInfo($matchingConfig, ContentInfo $contentInfo, $expectedResult) + #[DataProvider('matchContentInfoProvider')] + public function testMatchContentInfo($matchingConfig, int $contentId, $expectedResult): void { $this->matcher->setMatchingConfig($matchingConfig); - self::assertSame($expectedResult, $this->matcher->matchContentInfo($contentInfo)); + self::assertSame($expectedResult, $this->matcher->matchContentInfo($this->getContentInfoMock(['id' => $contentId]))); } - public function matchContentInfoProvider() + /** + * @return array + */ + public static function matchContentInfoProvider(): array { return [ [ 123, - $this->getContentInfoMock(['id' => 123]), + 123, true, ], [ 123, - $this->getContentInfoMock(['id' => 456]), + 456, false, ], [ [123, 789], - $this->getContentInfoMock(['id' => 456]), + 456, false, ], [ [123, 789], - $this->getContentInfoMock(['id' => 789]), + 789, true, ], ]; diff --git a/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeGroupTest.php b/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeGroupTest.php index 3633ada542..340f51e0c7 100644 --- a/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeGroupTest.php +++ b/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeGroupTest.php @@ -12,8 +12,13 @@ use Ibexa\Contracts\Core\Repository\Values\ContentType\ContentType; use Ibexa\Contracts\Core\Repository\Values\ContentType\ContentTypeGroup; use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\ContentTypeGroup as ContentTypeGroupIdMatcher; +use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued; use Ibexa\Tests\Core\MVC\Symfony\Matcher\ContentBased\BaseTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +#[CoversClass(ContentTypeGroupIdMatcher::class)] +#[CoversClass(MultipleValued::class)] class ContentTypeGroupTest extends BaseTestCase { /** @var \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\ContentTypeGroup */ @@ -26,18 +31,13 @@ protected function setUp(): void } /** - * @dataProvider matchLocationProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\ContentTypeGroup::matchLocation - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * * @param int|int[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Repository $repository * @param bool $expectedResult */ - public function testMatchLocation($matchingConfig, Repository $repository, $expectedResult) + #[DataProvider('matchLocationProvider')] + public function testMatchLocation($matchingConfig, int $contentTypeGroupId, $expectedResult): void { - $this->matcher->setRepository($repository); + $this->matcher->setRepository($this->generateRepositoryMockForContentTypeGroupId($contentTypeGroupId)); $this->matcher->setMatchingConfig($matchingConfig); $result = $this->matcher->matchLocation($this->generateLocationMock()); @@ -48,31 +48,34 @@ public function testMatchLocation($matchingConfig, Repository $repository, $expe ); } - public function matchLocationProvider() + /** + * @return array + */ + public static function matchLocationProvider(): array { $data = []; $data[] = [ 123, - $this->generateRepositoryMockForContentTypeGroupId(123), + 123, true, ]; $data[] = [ 123, - $this->generateRepositoryMockForContentTypeGroupId(456), + 456, false, ]; $data[] = [ [123, 789], - $this->generateRepositoryMockForContentTypeGroupId(456), + 456, false, ]; $data[] = [ [123, 789], - $this->generateRepositoryMockForContentTypeGroupId(789), + 789, true, ]; @@ -100,18 +103,13 @@ private function generateLocationMock() } /** - * @dataProvider matchContentInfoProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\ContentTypeGroup::matchContentInfo - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * * @param int|int[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Repository $repository * @param bool $expectedResult */ - public function testMatchContentInfo($matchingConfig, Repository $repository, $expectedResult) + #[DataProvider('matchContentInfoProvider')] + public function testMatchContentInfo($matchingConfig, int $contentTypeGroupId, $expectedResult): void { - $this->matcher->setRepository($repository); + $this->matcher->setRepository($this->generateRepositoryMockForContentTypeGroupId($contentTypeGroupId)); $this->matcher->setMatchingConfig($matchingConfig); self::assertSame( @@ -120,31 +118,34 @@ public function testMatchContentInfo($matchingConfig, Repository $repository, $e ); } - public function matchContentInfoProvider() + /** + * @return array + */ + public static function matchContentInfoProvider(): array { $data = []; $data[] = [ 123, - $this->generateRepositoryMockForContentTypeGroupId(123), + 123, true, ]; $data[] = [ 123, - $this->generateRepositoryMockForContentTypeGroupId(456), + 456, false, ]; $data[] = [ [123, 789], - $this->generateRepositoryMockForContentTypeGroupId(456), + 456, false, ]; $data[] = [ [123, 789], - $this->generateRepositoryMockForContentTypeGroupId(789), + 789, true, ]; diff --git a/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeTest.php b/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeTest.php index 26ad0c4e99..f6532415ff 100644 --- a/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeTest.php +++ b/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ContentTypeTest.php @@ -10,8 +10,13 @@ use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; use Ibexa\Contracts\Core\Repository\Values\Content\Location; use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\ContentType as ContentTypeIdMatcher; +use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued; use Ibexa\Tests\Core\MVC\Symfony\Matcher\ContentBased\BaseTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +#[CoversClass(ContentTypeIdMatcher::class)] +#[CoversClass(MultipleValued::class)] class ContentTypeTest extends BaseTestCase { /** @var \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\ContentType */ @@ -24,46 +29,44 @@ protected function setUp(): void } /** - * @dataProvider matchLocationProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\ContentType::matchLocation - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * * @param int|int[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Values\Content\Location $location * @param bool $expectedResult */ - public function testMatchLocation($matchingConfig, Location $location, $expectedResult) + #[DataProvider('matchLocationProvider')] + public function testMatchLocation($matchingConfig, int $contentTypeId, $expectedResult): void { $this->matcher->setMatchingConfig($matchingConfig); - self::assertSame($expectedResult, $this->matcher->matchLocation($location)); + self::assertSame($expectedResult, $this->matcher->matchLocation($this->generateLocationForContentType($contentTypeId))); } - public function matchLocationProvider() + /** + * @return array + */ + public static function matchLocationProvider(): array { $data = []; $data[] = [ 123, - $this->generateLocationForContentType(123), + 123, true, ]; $data[] = [ 123, - $this->generateLocationForContentType(456), + 456, false, ]; $data[] = [ [123, 789], - $this->generateLocationForContentType(456), + 456, false, ]; $data[] = [ [123, 789], - $this->generateLocationForContentType(789), + 789, true, ]; @@ -105,46 +108,44 @@ private function generateContentInfoForContentType($contentTypeId) } /** - * @dataProvider matchContentInfoProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\ContentType::matchContentInfo - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * * @param int|int[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo $contentInfo * @param bool $expectedResult */ - public function testMatchContentInfo($matchingConfig, ContentInfo $contentInfo, $expectedResult) + #[DataProvider('matchContentInfoProvider')] + public function testMatchContentInfo($matchingConfig, int $contentTypeId, $expectedResult): void { $this->matcher->setMatchingConfig($matchingConfig); - self::assertSame($expectedResult, $this->matcher->matchContentInfo($contentInfo)); + self::assertSame($expectedResult, $this->matcher->matchContentInfo($this->generateContentInfoForContentType($contentTypeId))); } - public function matchContentInfoProvider() + /** + * @return array + */ + public static function matchContentInfoProvider(): array { $data = []; $data[] = [ 123, - $this->generateContentInfoForContentType(123), + 123, true, ]; $data[] = [ 123, - $this->generateContentInfoForContentType(456), + 456, false, ]; $data[] = [ [123, 789], - $this->generateContentInfoForContentType(456), + 456, false, ]; $data[] = [ [123, 789], - $this->generateContentInfoForContentType(789), + 789, true, ]; diff --git a/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/LocationTest.php b/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/LocationTest.php index bb3b90778d..999e793eb2 100644 --- a/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/LocationTest.php +++ b/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/LocationTest.php @@ -7,11 +7,14 @@ namespace Ibexa\Tests\Core\MVC\Symfony\Matcher\ContentBased\Id; -use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; -use Ibexa\Contracts\Core\Repository\Values\Content\Location; use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\Location as LocationIdMatcher; +use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued; use Ibexa\Tests\Core\MVC\Symfony\Matcher\ContentBased\BaseTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +#[CoversClass(LocationIdMatcher::class)] +#[CoversClass(MultipleValued::class)] class LocationTest extends BaseTestCase { /** @var \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\Location */ @@ -24,84 +27,80 @@ protected function setUp(): void } /** - * @dataProvider matchLocationProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\Location::matchLocation - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * * @param int|int[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Values\Content\Location $location * @param bool $expectedResult */ - public function testMatchLocation($matchingConfig, Location $location, $expectedResult) + #[DataProvider('matchLocationProvider')] + public function testMatchLocation($matchingConfig, int $id, $expectedResult): void { $this->matcher->setMatchingConfig($matchingConfig); - self::assertSame($expectedResult, $this->matcher->matchLocation($location)); + self::assertSame($expectedResult, $this->matcher->matchLocation($this->getLocationMock(['id' => $id]))); } - public function matchLocationProvider() + /** + * @return array + */ + public static function matchLocationProvider(): array { return [ [ 123, - $this->getLocationMock(['id' => 123]), + 123, true, ], [ 123, - $this->getLocationMock(['id' => 456]), + 456, false, ], [ [123, 789], - $this->getLocationMock(['id' => 456]), + 456, false, ], [ [123, 789], - $this->getLocationMock(['id' => 789]), + 789, true, ], ]; } /** - * @dataProvider matchContentInfoProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\Location::matchContentInfo - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * * @param int|int[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo $contentInfo * @param bool $expectedResult */ - public function testMatchContentInfo($matchingConfig, ContentInfo $contentInfo, $expectedResult) + #[DataProvider('matchContentInfoProvider')] + public function testMatchContentInfo($matchingConfig, int $mainLocationId, $expectedResult): void { $this->matcher->setMatchingConfig($matchingConfig); - self::assertSame($expectedResult, $this->matcher->matchContentInfo($contentInfo)); + self::assertSame($expectedResult, $this->matcher->matchContentInfo($this->getContentInfoMock(['mainLocationId' => $mainLocationId]))); } - public function matchContentInfoProvider() + /** + * @return array + */ + public static function matchContentInfoProvider(): array { return [ [ 123, - $this->getContentInfoMock(['mainLocationId' => 123]), + 123, true, ], [ 123, - $this->getContentInfoMock(['mainLocationId' => 456]), + 456, false, ], [ [123, 789], - $this->getContentInfoMock(['mainLocationId' => 456]), + 456, false, ], [ [123, 789], - $this->getContentInfoMock(['mainLocationId' => 789]), + 789, true, ], ]; diff --git a/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentContentTypeTest.php b/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentContentTypeTest.php index 6371b7a2fe..9cab4dd9db 100644 --- a/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentContentTypeTest.php +++ b/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentContentTypeTest.php @@ -9,9 +9,16 @@ use Ibexa\Contracts\Core\Repository\LocationService; use Ibexa\Contracts\Core\Repository\Repository; +use Ibexa\Core\MVC\RepositoryAware; use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\ParentContentType as ParentContentTypeMatcher; +use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued; use Ibexa\Tests\Core\MVC\Symfony\Matcher\ContentBased\BaseTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +#[CoversClass(ParentContentTypeMatcher::class)] +#[CoversClass(MultipleValued::class)] +#[CoversClass(RepositoryAware::class)] class ParentContentTypeTest extends BaseTestCase { private const EXAMPLE_LOCATION_ID = 54; @@ -77,19 +84,13 @@ private function generateRepositoryMockForContentTypeId($contentTypeId) } /** - * @dataProvider matchLocationProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\ParentContentType::matchLocation - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * @covers \Ibexa\Core\MVC\RepositoryAware::setRepository - * * @param int|int[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Repository $repository * @param bool $expectedResult */ - public function testMatchLocation($matchingConfig, Repository $repository, $expectedResult) + #[DataProvider('matchLocationProvider')] + public function testMatchLocation($matchingConfig, int $contentTypeId, $expectedResult): void { - $this->matcher->setRepository($repository); + $this->matcher->setRepository($this->generateRepositoryMockForContentTypeId($contentTypeId)); $this->matcher->setMatchingConfig($matchingConfig); self::assertSame( $expectedResult, @@ -97,46 +98,43 @@ public function testMatchLocation($matchingConfig, Repository $repository, $expe ); } - public function matchLocationProvider() + /** + * @return array + */ + public static function matchLocationProvider(): array { return [ [ 123, - $this->generateRepositoryMockForContentTypeId(123), + 123, true, ], [ 123, - $this->generateRepositoryMockForContentTypeId(456), + 456, false, ], [ [123, 789], - $this->generateRepositoryMockForContentTypeId(456), + 456, false, ], [ [123, 789], - $this->generateRepositoryMockForContentTypeId(789), + 789, true, ], ]; } /** - * @dataProvider matchLocationProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\ParentContentType::matchContentInfo - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * @covers \Ibexa\Core\MVC\RepositoryAware::setRepository - * * @param int|int[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Repository $repository * @param bool $expectedResult */ - public function testMatchContentInfo($matchingConfig, Repository $repository, $expectedResult) + #[DataProvider('matchLocationProvider')] + public function testMatchContentInfo($matchingConfig, int $contentTypeId, $expectedResult): void { - $this->matcher->setRepository($repository); + $this->matcher->setRepository($this->generateRepositoryMockForContentTypeId($contentTypeId)); $this->matcher->setMatchingConfig($matchingConfig); self::assertSame( diff --git a/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentLocationTest.php b/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentLocationTest.php index 8ec598e0cd..b83c189c8d 100644 --- a/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentLocationTest.php +++ b/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/ParentLocationTest.php @@ -10,9 +10,16 @@ use Ibexa\Contracts\Core\Repository\LocationService; use Ibexa\Contracts\Core\Repository\Repository; use Ibexa\Contracts\Core\Repository\Values\Content\Location; +use Ibexa\Core\MVC\RepositoryAware; use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\ParentLocation as ParentLocationIdMatcher; +use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued; use Ibexa\Tests\Core\MVC\Symfony\Matcher\ContentBased\BaseTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +#[CoversClass(ParentLocationIdMatcher::class)] +#[CoversClass(MultipleValued::class)] +#[CoversClass(RepositoryAware::class)] class ParentLocationTest extends BaseTestCase { /** @var \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\ParentLocation */ @@ -25,61 +32,53 @@ protected function setUp(): void } /** - * @dataProvider matchLocationProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\ParentLocation::matchLocation - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * * @param int|int[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Values\Content\Location $location * @param bool $expectedResult */ - public function testMatchLocation($matchingConfig, Location $location, $expectedResult) + #[DataProvider('matchLocationProvider')] + public function testMatchLocation($matchingConfig, int $parentLocationId, $expectedResult): void { $this->matcher->setMatchingConfig($matchingConfig); - self::assertSame($expectedResult, $this->matcher->matchLocation($location)); + self::assertSame($expectedResult, $this->matcher->matchLocation($this->getLocationMock(['parentLocationId' => $parentLocationId]))); } - public function matchLocationProvider() + /** + * @return array + */ + public static function matchLocationProvider(): array { return [ [ 123, - $this->getLocationMock(['parentLocationId' => 123]), + 123, true, ], [ 123, - $this->getLocationMock(['parentLocationId' => 456]), + 456, false, ], [ [123, 789], - $this->getLocationMock(['parentLocationId' => 456]), + 456, false, ], [ [123, 789], - $this->getLocationMock(['parentLocationId' => 789]), + 789, true, ], ]; } /** - * @dataProvider matchContentInfoProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\ParentLocation::matchContentInfo - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * @covers \Ibexa\Core\MVC\RepositoryAware::setRepository - * * @param int|int[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Repository $repository * @param bool $expectedResult */ - public function testMatchContentInfo($matchingConfig, Repository $repository, $expectedResult) + #[DataProvider('matchContentInfoProvider')] + public function testMatchContentInfo($matchingConfig, int $parentLocationId, $expectedResult): void { - $this->matcher->setRepository($repository); + $this->matcher->setRepository($this->generateRepositoryMockForParentLocationId($parentLocationId)); $this->matcher->setMatchingConfig($matchingConfig); self::assertSame( $expectedResult, @@ -87,27 +86,30 @@ public function testMatchContentInfo($matchingConfig, Repository $repository, $e ); } - public function matchContentInfoProvider() + /** + * @return array + */ + public static function matchContentInfoProvider(): array { return [ [ 123, - $this->generateRepositoryMockForParentLocationId(123), + 123, true, ], [ 123, - $this->generateRepositoryMockForParentLocationId(456), + 456, false, ], [ [123, 789], - $this->generateRepositoryMockForParentLocationId(456), + 456, false, ], [ [123, 789], - $this->generateRepositoryMockForParentLocationId(789), + 789, true, ], ]; diff --git a/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/RemoteTest.php b/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/RemoteTest.php index 213f961dc6..7dfd245bc0 100644 --- a/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/RemoteTest.php +++ b/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/RemoteTest.php @@ -7,11 +7,14 @@ namespace Ibexa\Tests\Core\MVC\Symfony\Matcher\ContentBased\Id; -use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; -use Ibexa\Contracts\Core\Repository\Values\Content\Location; use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\Remote as RemoteIdMatcher; +use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued; use Ibexa\Tests\Core\MVC\Symfony\Matcher\ContentBased\BaseTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +#[CoversClass(RemoteIdMatcher::class)] +#[CoversClass(MultipleValued::class)] class RemoteTest extends BaseTestCase { /** @var \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\Remote */ @@ -24,84 +27,80 @@ protected function setUp(): void } /** - * @dataProvider matchLocationProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\Remote::matchLocation - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * * @param string|string[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Values\Content\Location $location * @param bool $expectedResult */ - public function testMatchLocation($matchingConfig, Location $location, $expectedResult) + #[DataProvider('matchLocationProvider')] + public function testMatchLocation($matchingConfig, string $remoteId, $expectedResult): void { $this->matcher->setMatchingConfig($matchingConfig); - self::assertSame($expectedResult, $this->matcher->matchLocation($location)); + self::assertSame($expectedResult, $this->matcher->matchLocation($this->getLocationMock(['remoteId' => $remoteId]))); } - public function matchLocationProvider() + /** + * @return array + */ + public static function matchLocationProvider(): array { return [ [ 'foo', - $this->getLocationMock(['remoteId' => 'foo']), + 'foo', true, ], [ 'foo', - $this->getLocationMock(['remoteId' => 'bar']), + 'bar', false, ], [ ['foo', 'baz'], - $this->getLocationMock(['remoteId' => 'bar']), + 'bar', false, ], [ ['foo', 'baz'], - $this->getLocationMock(['remoteId' => 'baz']), + 'baz', true, ], ]; } /** - * @dataProvider matchContentInfoProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\Remote::matchContentInfo - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * * @param string|string[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo $contentInfo * @param bool $expectedResult */ - public function testMatchContentInfo($matchingConfig, ContentInfo $contentInfo, $expectedResult) + #[DataProvider('matchContentInfoProvider')] + public function testMatchContentInfo($matchingConfig, string $remoteId, $expectedResult): void { $this->matcher->setMatchingConfig($matchingConfig); - self::assertSame($expectedResult, $this->matcher->matchContentInfo($contentInfo)); + self::assertSame($expectedResult, $this->matcher->matchContentInfo($this->getContentInfoMock(['remoteId' => $remoteId]))); } - public function matchContentInfoProvider() + /** + * @return array + */ + public static function matchContentInfoProvider(): array { return [ [ 'foo', - $this->getContentInfoMock(['remoteId' => 'foo']), + 'foo', true, ], [ 'foo', - $this->getContentInfoMock(['remoteId' => 'bar']), + 'bar', false, ], [ ['foo', 'baz'], - $this->getContentInfoMock(['remoteId' => 'bar']), + 'bar', false, ], [ ['foo', 'baz'], - $this->getContentInfoMock(['remoteId' => 'baz']), + 'baz', true, ], ]; diff --git a/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/SectionTest.php b/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/SectionTest.php index a15821a9d2..535aa275a8 100644 --- a/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/SectionTest.php +++ b/tests/lib/MVC/Symfony/Matcher/ContentBased/Id/SectionTest.php @@ -7,11 +7,15 @@ namespace Ibexa\Tests\Core\MVC\Symfony\Matcher\ContentBased\Id; -use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; use Ibexa\Contracts\Core\Repository\Values\Content\Location; use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\Section as SectionIdMatcher; +use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued; use Ibexa\Tests\Core\MVC\Symfony\Matcher\ContentBased\BaseTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +#[CoversClass(MultipleValued::class)] +#[CoversClass(SectionIdMatcher::class)] class SectionTest extends BaseTestCase { /** @var \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\Section */ @@ -24,42 +28,40 @@ protected function setUp(): void } /** - * @dataProvider matchLocationProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * * @param int|int[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Values\Content\Location $location * @param bool $expectedResult */ - public function testMatchLocation($matchingConfig, Location $location, $expectedResult) + #[DataProvider('matchLocationProvider')] + public function testMatchLocation($matchingConfig, int $sectionId, $expectedResult): void { $this->matcher->setMatchingConfig($matchingConfig); - self::assertSame($expectedResult, $this->matcher->matchLocation($location)); + self::assertSame($expectedResult, $this->matcher->matchLocation($this->generateLocationForSectionId($sectionId))); } - public function matchLocationProvider() + /** + * @return array + */ + public static function matchLocationProvider(): array { return [ [ 123, - $this->generateLocationForSectionId(123), + 123, true, ], [ 123, - $this->generateLocationForSectionId(456), + 456, false, ], [ [123, 789], - $this->generateLocationForSectionId(456), + 456, false, ], [ [123, 789], - $this->generateLocationForSectionId(789), + 789, true, ], ]; @@ -88,42 +90,40 @@ private function generateLocationForSectionId($sectionId) } /** - * @dataProvider matchContentInfoProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Id\Section::matchContentInfo - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * * @param int|int[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo $contentInfo * @param bool $expectedResult */ - public function testMatchContentInfo($matchingConfig, ContentInfo $contentInfo, $expectedResult) + #[DataProvider('matchContentInfoProvider')] + public function testMatchContentInfo($matchingConfig, int $sectionId, $expectedResult): void { $this->matcher->setMatchingConfig($matchingConfig); - self::assertSame($expectedResult, $this->matcher->matchContentInfo($contentInfo)); + self::assertSame($expectedResult, $this->matcher->matchContentInfo($this->getContentInfoMock(['sectionId' => $sectionId]))); } - public function matchContentInfoProvider() + /** + * @return array + */ + public static function matchContentInfoProvider(): array { return [ [ 123, - $this->getContentInfoMock(['sectionId' => 123]), + 123, true, ], [ 123, - $this->getContentInfoMock(['sectionId' => 456]), + 456, false, ], [ [123, 789], - $this->getContentInfoMock(['sectionId' => 456]), + 456, false, ], [ [123, 789], - $this->getContentInfoMock(['sectionId' => 789]), + 789, true, ], ]; diff --git a/tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ContentTypeTest.php b/tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ContentTypeTest.php index fb676f4f1e..2eb8b8f91b 100644 --- a/tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ContentTypeTest.php +++ b/tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ContentTypeTest.php @@ -11,8 +11,13 @@ use Ibexa\Contracts\Core\Repository\Repository; use Ibexa\Contracts\Core\Repository\Values\ContentType\ContentType; use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Identifier\ContentType as ContentTypeIdentifierMatcher; +use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued; use Ibexa\Tests\Core\MVC\Symfony\Matcher\ContentBased\BaseTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +#[CoversClass(ContentTypeIdentifierMatcher::class)] +#[CoversClass(MultipleValued::class)] class ContentTypeTest extends BaseTestCase { /** @var \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Identifier\ContentType */ @@ -25,18 +30,13 @@ protected function setUp(): void } /** - * @dataProvider matchLocationProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Identifier\ContentType::matchLocation - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * * @param string|string[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Repository $repository * @param bool $expectedResult */ - public function testMatchLocation($matchingConfig, Repository $repository, $expectedResult) + #[DataProvider('matchLocationProvider')] + public function testMatchLocation($matchingConfig, string $contentTypeIdentifier, $expectedResult): void { - $this->matcher->setRepository($repository); + $this->matcher->setRepository($this->generateRepositoryMockForContentTypeIdentifier($contentTypeIdentifier)); $this->matcher->setMatchingConfig($matchingConfig); self::assertSame( @@ -45,31 +45,34 @@ public function testMatchLocation($matchingConfig, Repository $repository, $expe ); } - public function matchLocationProvider() + /** + * @return array + */ + public static function matchLocationProvider(): array { $data = []; $data[] = [ 'foo', - $this->generateRepositoryMockForContentTypeIdentifier('foo'), + 'foo', true, ]; $data[] = [ 'foo', - $this->generateRepositoryMockForContentTypeIdentifier('bar'), + 'bar', false, ]; $data[] = [ ['foo', 'baz'], - $this->generateRepositoryMockForContentTypeIdentifier('bar'), + 'bar', false, ]; $data[] = [ ['foo', 'baz'], - $this->generateRepositoryMockForContentTypeIdentifier('baz'), + 'baz', true, ]; @@ -97,18 +100,13 @@ private function generateLocationMock() } /** - * @dataProvider matchContentInfoProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Identifier\ContentType::matchLocation - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * * @param string|string[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Repository $repository * @param bool $expectedResult */ - public function testMatchContentInfo($matchingConfig, Repository $repository, $expectedResult) + #[DataProvider('matchContentInfoProvider')] + public function testMatchContentInfo($matchingConfig, string $contentTypeIdentifier, $expectedResult): void { - $this->matcher->setRepository($repository); + $this->matcher->setRepository($this->generateRepositoryMockForContentTypeIdentifier($contentTypeIdentifier)); $this->matcher->setMatchingConfig($matchingConfig); self::assertSame( @@ -119,31 +117,34 @@ public function testMatchContentInfo($matchingConfig, Repository $repository, $e ); } - public function matchContentInfoProvider() + /** + * @return array + */ + public static function matchContentInfoProvider(): array { $data = []; $data[] = [ 'foo', - $this->generateRepositoryMockForContentTypeIdentifier('foo'), + 'foo', true, ]; $data[] = [ 'foo', - $this->generateRepositoryMockForContentTypeIdentifier('bar'), + 'bar', false, ]; $data[] = [ ['foo', 'baz'], - $this->generateRepositoryMockForContentTypeIdentifier('bar'), + 'bar', false, ]; $data[] = [ ['foo', 'baz'], - $this->generateRepositoryMockForContentTypeIdentifier('baz'), + 'baz', true, ]; diff --git a/tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ParentContentTypeTest.php b/tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ParentContentTypeTest.php index b4f58a6ac1..7a99b5dda6 100644 --- a/tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ParentContentTypeTest.php +++ b/tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/ParentContentTypeTest.php @@ -11,9 +11,16 @@ use Ibexa\Contracts\Core\Repository\LocationService; use Ibexa\Contracts\Core\Repository\Repository; use Ibexa\Contracts\Core\Repository\Values\ContentType\ContentType; +use Ibexa\Core\MVC\RepositoryAware; use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Identifier\ParentContentType as ParentContentTypeMatcher; +use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued; use Ibexa\Tests\Core\MVC\Symfony\Matcher\ContentBased\BaseTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +#[CoversClass(ParentContentTypeMatcher::class)] +#[CoversClass(MultipleValued::class)] +#[CoversClass(RepositoryAware::class)] class ParentContentTypeTest extends BaseTestCase { private const EXAMPLE_LOCATION_ID = 54; @@ -98,19 +105,13 @@ private function generateRepositoryMockForContentTypeIdentifier($contentTypeIden } /** - * @dataProvider matchLocationProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Identifier\ParentContentType::matchLocation - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * @covers \Ibexa\Core\MVC\RepositoryAware::setRepository - * * @param string|string[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Repository $repository * @param bool $expectedResult */ - public function testMatchLocation($matchingConfig, Repository $repository, $expectedResult) + #[DataProvider('matchLocationProvider')] + public function testMatchLocation($matchingConfig, string $contentTypeIdentifier, $expectedResult): void { - $this->matcher->setRepository($repository); + $this->matcher->setRepository($this->generateRepositoryMockForContentTypeIdentifier($contentTypeIdentifier)); $this->matcher->setMatchingConfig($matchingConfig); self::assertSame( $expectedResult, @@ -120,46 +121,43 @@ public function testMatchLocation($matchingConfig, Repository $repository, $expe ); } - public function matchLocationProvider() + /** + * @return array + */ + public static function matchLocationProvider(): array { return [ [ 'foo', - $this->generateRepositoryMockForContentTypeIdentifier('foo'), + 'foo', true, ], [ 'foo', - $this->generateRepositoryMockForContentTypeIdentifier('bar'), + 'bar', false, ], [ ['foo', 'baz'], - $this->generateRepositoryMockForContentTypeIdentifier('bar'), + 'bar', false, ], [ ['foo', 'baz'], - $this->generateRepositoryMockForContentTypeIdentifier('baz'), + 'baz', true, ], ]; } /** - * @dataProvider matchLocationProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Identifier\ParentContentType::matchLocation - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * @covers \Ibexa\Core\MVC\RepositoryAware::setRepository - * * @param string|string[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Repository $repository * @param bool $expectedResult */ - public function testMatchContentInfo($matchingConfig, Repository $repository, $expectedResult) + #[DataProvider('matchLocationProvider')] + public function testMatchContentInfo($matchingConfig, string $contentTypeIdentifier, $expectedResult): void { - $this->matcher->setRepository($repository); + $this->matcher->setRepository($this->generateRepositoryMockForContentTypeIdentifier($contentTypeIdentifier)); $this->matcher->setMatchingConfig($matchingConfig); self::assertSame( $expectedResult, diff --git a/tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/SectionTest.php b/tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/SectionTest.php index 6eb7bc68a7..0e38e3d6db 100644 --- a/tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/SectionTest.php +++ b/tests/lib/MVC/Symfony/Matcher/ContentBased/Identifier/SectionTest.php @@ -11,9 +11,16 @@ use Ibexa\Contracts\Core\Repository\Repository; use Ibexa\Contracts\Core\Repository\SectionService; use Ibexa\Contracts\Core\Repository\Values\Content\Section; +use Ibexa\Core\MVC\RepositoryAware; use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Identifier\Section as SectionIdentifierMatcher; +use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued; use Ibexa\Tests\Core\MVC\Symfony\Matcher\ContentBased\BaseTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +#[CoversClass(SectionIdentifierMatcher::class)] +#[CoversClass(MultipleValued::class)] +#[CoversClass(RepositoryAware::class)] class SectionTest extends BaseTestCase { /** @var \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Identifier\Section */ @@ -64,19 +71,13 @@ private function generateRepositoryMockForSectionIdentifier($sectionIdentifier) } /** - * @dataProvider matchSectionProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Identifier\Section::matchLocation - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * @covers \Ibexa\Core\MVC\RepositoryAware::setRepository - * * @param string|string[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Repository $repository * @param bool $expectedResult */ - public function testMatchLocation($matchingConfig, Repository $repository, $expectedResult) + #[DataProvider('matchSectionProvider')] + public function testMatchLocation($matchingConfig, string $sectionIdentifier, $expectedResult): void { - $this->matcher->setRepository($repository); + $this->matcher->setRepository($this->generateRepositoryMockForSectionIdentifier($sectionIdentifier)); $this->matcher->setMatchingConfig($matchingConfig); $location = $this->getLocationMock(); @@ -95,46 +96,43 @@ public function testMatchLocation($matchingConfig, Repository $repository, $expe ); } - public function matchSectionProvider() + /** + * @return array + */ + public static function matchSectionProvider(): array { return [ [ 'foo', - $this->generateRepositoryMockForSectionIdentifier('foo'), + 'foo', true, ], [ 'foo', - $this->generateRepositoryMockForSectionIdentifier('bar'), + 'bar', false, ], [ ['foo', 'baz'], - $this->generateRepositoryMockForSectionIdentifier('bar'), + 'bar', false, ], [ ['foo', 'baz'], - $this->generateRepositoryMockForSectionIdentifier('baz'), + 'baz', true, ], ]; } /** - * @dataProvider matchSectionProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\Identifier\Section::matchLocation - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * @covers \Ibexa\Core\MVC\RepositoryAware::setRepository - * * @param string|string[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Repository $repository * @param bool $expectedResult */ - public function testMatchContentInfo($matchingConfig, Repository $repository, $expectedResult) + #[DataProvider('matchSectionProvider')] + public function testMatchContentInfo($matchingConfig, string $sectionIdentifier, $expectedResult): void { - $this->matcher->setRepository($repository); + $this->matcher->setRepository($this->generateRepositoryMockForSectionIdentifier($sectionIdentifier)); $this->matcher->setMatchingConfig($matchingConfig); self::assertSame( $expectedResult, diff --git a/tests/lib/MVC/Symfony/Matcher/ContentBased/IsPreviewTest.php b/tests/lib/MVC/Symfony/Matcher/ContentBased/IsPreviewTest.php index f77b0447de..2097cc859b 100644 --- a/tests/lib/MVC/Symfony/Matcher/ContentBased/IsPreviewTest.php +++ b/tests/lib/MVC/Symfony/Matcher/ContentBased/IsPreviewTest.php @@ -12,11 +12,11 @@ use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\IsPreview; use Ibexa\Core\MVC\Symfony\View\ContentView; use Ibexa\Core\MVC\Symfony\View\View; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\IsPreview - */ +#[CoversClass(IsPreview::class)] final class IsPreviewTest extends TestCase { private IsPreview $isPreviewMatcher; @@ -76,10 +76,9 @@ public static function getDataForTestMatch(): iterable } /** - * @dataProvider getDataForTestMatch - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ + #[DataProvider('getDataForTestMatch')] public function testMatch(View $view, bool $matchConfig, bool $expectedIsPreview): void { $this->isPreviewMatcher->setMatchingConfig($matchConfig); diff --git a/tests/lib/MVC/Symfony/Matcher/ContentBased/MultipleValuedTest.php b/tests/lib/MVC/Symfony/Matcher/ContentBased/MultipleValuedTest.php index 5ae31433e3..7ad9a5c82e 100644 --- a/tests/lib/MVC/Symfony/Matcher/ContentBased/MultipleValuedTest.php +++ b/tests/lib/MVC/Symfony/Matcher/ContentBased/MultipleValuedTest.php @@ -7,17 +7,17 @@ namespace Ibexa\Tests\Core\MVC\Symfony\Matcher\ContentBased; +use Ibexa\Core\MVC\RepositoryAware; use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +#[CoversClass(MultipleValued::class)] +#[CoversClass(RepositoryAware::class)] class MultipleValuedTest extends BaseTestCase { - /** - * @dataProvider matchingConfigProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::getValues - */ - public function testSetMatchingConfig($matchingConfig) + #[DataProvider('matchingConfigProvider')] + public function testSetMatchingConfig($matchingConfig): void { $matcher = $this->getMultipleValuedMatcherMock(); $matcher->setMatchingConfig($matchingConfig); @@ -35,7 +35,7 @@ public function testSetMatchingConfig($matchingConfig) * * @return array */ - public function matchingConfigProvider() + public static function matchingConfigProvider(): array { return [ [ @@ -47,11 +47,7 @@ public function matchingConfigProvider() ]; } - /** - * @covers \Ibexa\Core\MVC\RepositoryAware::setRepository - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::getRepository - */ - public function testInjectRepository() + public function testInjectRepository(): void { $matcher = $this->getMultipleValuedMatcherMock(); $matcher->setRepository($this->repositoryMock); diff --git a/tests/lib/MVC/Symfony/Matcher/ContentBased/UrlAliasTest.php b/tests/lib/MVC/Symfony/Matcher/ContentBased/UrlAliasTest.php index 0dbad8ece1..8f1bcc8d24 100644 --- a/tests/lib/MVC/Symfony/Matcher/ContentBased/UrlAliasTest.php +++ b/tests/lib/MVC/Symfony/Matcher/ContentBased/UrlAliasTest.php @@ -11,8 +11,15 @@ use Ibexa\Contracts\Core\Repository\URLAliasService; use Ibexa\Contracts\Core\Repository\Values\Content\Location; use Ibexa\Contracts\Core\Repository\Values\Content\URLAlias; +use Ibexa\Core\MVC\RepositoryAware; +use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued; use Ibexa\Core\MVC\Symfony\Matcher\ContentBased\UrlAlias as UrlAliasMatcher; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +#[CoversClass(UrlAliasMatcher::class)] +#[CoversClass(MultipleValued::class)] +#[CoversClass(RepositoryAware::class)] class UrlAliasTest extends BaseTestCase { /** @var \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\UrlAlias */ @@ -25,15 +32,11 @@ protected function setUp(): void } /** - * @dataProvider setMatchingConfigProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\UrlAlias::setMatchingConfig - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\MultipleValued::setMatchingConfig - * * @param string $matchingConfig * @param string[] $expectedValues */ - public function testSetMatchingConfig($matchingConfig, $expectedValues) + #[DataProvider('setMatchingConfigProvider')] + public function testSetMatchingConfig($matchingConfig, $expectedValues): void { $this->matcher->setMatchingConfig($matchingConfig); self::assertSame( @@ -42,7 +45,10 @@ public function testSetMatchingConfig($matchingConfig, $expectedValues) ); } - public function setMatchingConfigProvider() + /** + * @return array + */ + public static function setMatchingConfigProvider(): array { return [ ['/foo/bar/', ['foo/bar']], @@ -65,7 +71,7 @@ private function generateRepositoryMockForUrlAlias($path) // First an url alias that will never match, then the right url alias. // This ensures to test even if the location has several url aliases. $urlAliasList = [ - $this->createMock(URLAlias::class), + self::createStub(URLAlias::class), $this ->getMockBuilder(URLAlias::class) ->setConstructorArgs([['path' => $path]]) @@ -73,20 +79,20 @@ private function generateRepositoryMockForUrlAlias($path) ]; $urlAliasServiceMock = $this->createMock(URLAliasService::class); - $urlAliasServiceMock->expects(self::at(0)) - ->method('listLocationAliases') - ->with( - self::isInstanceOf(Location::class), - true - ) - ->will(self::returnValue([])); - $urlAliasServiceMock->expects(self::at(1)) + $matcher = self::exactly(2); + $urlAliasServiceMock->expects($matcher) ->method('listLocationAliases') - ->with( - self::isInstanceOf(Location::class), - false - ) - ->will(self::returnValue($urlAliasList)); + ->willReturnCallback(static function (Location $location, bool $custom = true, ?string $languageCode = null, ?bool $showAllTranslations = null, ?array $prioritizedLanguages = null) use ($matcher, $urlAliasList): array { + if ($matcher->numberOfInvocations() === 1) { + self::assertTrue($custom); + + return []; + } + + self::assertFalse($custom); + + return $urlAliasList; + }); $repository = $this->getRepositoryMock(); $repository @@ -98,18 +104,14 @@ private function generateRepositoryMockForUrlAlias($path) } /** - * @dataProvider matchLocationProvider - * - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\UrlAlias::matchLocation - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\UrlAlias::setMatchingConfig - * @covers \Ibexa\Core\MVC\RepositoryAware::setRepository - * * @param string|string[] $matchingConfig - * @param \Ibexa\Contracts\Core\Repository\Repository $repository + * @param string $path * @param bool $expectedResult */ - public function testMatchLocation($matchingConfig, Repository $repository, $expectedResult) + #[DataProvider('matchLocationProvider')] + public function testMatchLocation($matchingConfig, string $path, $expectedResult): void { + $repository = $this->generateRepositoryMockForUrlAlias($path); $this->matcher->setRepository($repository); $this->matcher->setMatchingConfig($matchingConfig); self::assertSame( @@ -118,42 +120,41 @@ public function testMatchLocation($matchingConfig, Repository $repository, $expe ); } - public function matchLocationProvider() + /** + * @return array + */ + public static function matchLocationProvider(): array { return [ [ 'foo/url', - $this->generateRepositoryMockForUrlAlias('/foo/url'), + '/foo/url', true, ], [ '/foo/url', - $this->generateRepositoryMockForUrlAlias('/foo/url'), + '/foo/url', true, ], [ 'foo/url', - $this->generateRepositoryMockForUrlAlias('/bar/url'), + '/bar/url', false, ], [ ['foo/url', 'baz'], - $this->generateRepositoryMockForUrlAlias('/bar/url'), + '/bar/url', false, ], [ ['foo/url ', 'baz '], - $this->generateRepositoryMockForUrlAlias('/baz'), + '/baz', true, ], ]; } - /** - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\UrlAlias::matchContentInfo - * @covers \Ibexa\Core\MVC\Symfony\Matcher\ContentBased\UrlAlias::setMatchingConfig - */ - public function testMatchContentInfo() + public function testMatchContentInfo(): void { $this->expectException(\RuntimeException::class); diff --git a/tests/lib/MVC/Symfony/Matcher/DynamicallyConfiguredMatcherFactoryDecoratorTest.php b/tests/lib/MVC/Symfony/Matcher/DynamicallyConfiguredMatcherFactoryDecoratorTest.php index 7779cfe891..2e26ca17be 100644 --- a/tests/lib/MVC/Symfony/Matcher/DynamicallyConfiguredMatcherFactoryDecoratorTest.php +++ b/tests/lib/MVC/Symfony/Matcher/DynamicallyConfiguredMatcherFactoryDecoratorTest.php @@ -11,6 +11,7 @@ use Ibexa\Core\MVC\Symfony\Matcher\ClassNameMatcherFactory; use Ibexa\Core\MVC\Symfony\Matcher\DynamicallyConfiguredMatcherFactoryDecorator; use Ibexa\Core\MVC\Symfony\View\ContentView; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; @@ -30,12 +31,10 @@ public function setUp(): void $this->configResolver = $configResolver; } - /** - * @dataProvider matchConfigProvider - */ + #[DataProvider('matchConfigProvider')] public function testMatch($parameterName, $namespace, $scope, $viewsConfiguration, $matchedConfig): void { - $view = $this->createMock(ContentView::class); + $view = self::createStub(ContentView::class); $this->configResolver->expects(self::atLeastOnce())->method('getParameter')->with( $parameterName, $namespace, @@ -54,7 +53,7 @@ public function testMatch($parameterName, $namespace, $scope, $viewsConfiguratio self::assertEquals($matchedConfig, $matcherFactory->match($view)); } - public function matchConfigProvider(): array + public static function matchConfigProvider(): array { return [ [ diff --git a/tests/lib/MVC/Symfony/Routing/GeneratorTest.php b/tests/lib/MVC/Symfony/Routing/GeneratorTest.php index 51fc9a6c9e..f2b355648b 100644 --- a/tests/lib/MVC/Symfony/Routing/GeneratorTest.php +++ b/tests/lib/MVC/Symfony/Routing/GeneratorTest.php @@ -12,6 +12,7 @@ use Ibexa\Core\MVC\Symfony\SiteAccess\SiteAccessRouterInterface; use Ibexa\Core\MVC\Symfony\SiteAccess\URILexer; use Ibexa\Core\Repository\Values\Content\Location; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Psr\Log\LoggerInterface; use Symfony\Component\Routing\Generator\UrlGeneratorInterface; @@ -38,7 +39,10 @@ protected function setUp(): void $this->generator->setLogger($this->logger); } - public function generateProvider() + /** + * @return array + */ + public static function generateProvider(): array { return [ ['foo_bar', [], UrlGeneratorInterface::ABSOLUTE_PATH], @@ -53,10 +57,8 @@ public function generateProvider() ]; } - /** - * @dataProvider generateProvider - */ - public function testSimpleGenerate($urlResource, array $parameters, $referenceType) + #[DataProvider('generateProvider')] + public function testSimpleGenerate($urlResource, array $parameters, $referenceType): void { $matcher = $this->createMock(URILexer::class); $this->generator->setSiteAccess(new SiteAccess('test', 'fake', $matcher)); @@ -86,10 +88,8 @@ public function testSimpleGenerate($urlResource, array $parameters, $referenceTy self::assertSame($fullUri, $this->generator->generate($urlResource, $parameters, $referenceType)); } - /** - * @dataProvider generateProvider - */ - public function testGenerateWithSiteAccessNoReverseMatch($urlResource, array $parameters, $referenceType) + #[DataProvider('generateProvider')] + public function testGenerateWithSiteAccessNoReverseMatch($urlResource, array $parameters, $referenceType): void { $matcher = $this->createMock(URILexer::class); $this->generator->setSiteAccess(new SiteAccess('test', 'test', $matcher)); diff --git a/tests/lib/MVC/Symfony/Routing/RequestContextFactoryTest.php b/tests/lib/MVC/Symfony/Routing/RequestContextFactoryTest.php index 85afc6c314..3beae2e976 100644 --- a/tests/lib/MVC/Symfony/Routing/RequestContextFactoryTest.php +++ b/tests/lib/MVC/Symfony/Routing/RequestContextFactoryTest.php @@ -10,17 +10,15 @@ use Ibexa\Core\MVC\Symfony\Routing\RequestContextFactory; use Ibexa\Core\MVC\Symfony\Routing\SimplifiedRequest; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\Routing\RequestContext; -/** - * @covers \Ibexa\Core\MVC\Symfony\Routing\RequestContextFactory - */ +#[CoversClass(RequestContextFactory::class)] final class RequestContextFactoryTest extends TestCase { - /** - * @dataProvider getDataForTestGetContextBySimplifiedRequest - */ + #[DataProvider('getDataForTestGetContextBySimplifiedRequest')] public function testGetContextBySimplifiedRequest( RequestContext $requestContext, SimplifiedRequest $simplifiedRequest, diff --git a/tests/lib/MVC/Symfony/Routing/RouteReferenceGeneratorTest.php b/tests/lib/MVC/Symfony/Routing/RouteReferenceGeneratorTest.php index 318accc75c..ef4527f38b 100644 --- a/tests/lib/MVC/Symfony/Routing/RouteReferenceGeneratorTest.php +++ b/tests/lib/MVC/Symfony/Routing/RouteReferenceGeneratorTest.php @@ -12,6 +12,7 @@ use Ibexa\Core\MVC\Symfony\Routing\Generator\RouteReferenceGenerator; use Ibexa\Core\MVC\Symfony\Routing\RouteReference; use Ibexa\Core\Repository\Values\Content\Location; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\EventDispatcher\EventDispatcherInterface; use Symfony\Component\HttpFoundation\Request; @@ -28,7 +29,7 @@ protected function setUp(): void $this->dispatcher = $this->createMock(EventDispatcherInterface::class); } - public function testGenerateNullResource() + public function testGenerateNullResource(): void { $currentRouteName = 'my_route'; $currentRouteParams = ['foo' => 'bar']; @@ -52,7 +53,7 @@ public function testGenerateNullResource() self::assertSame($currentRouteParams, $reference->getParams()); } - public function testGenerateNullResourceAndPassedParams() + public function testGenerateNullResourceAndPassedParams(): void { $currentRouteName = 'my_route'; $currentRouteParams = ['foo' => 'bar']; @@ -78,10 +79,8 @@ public function testGenerateNullResourceAndPassedParams() self::assertSame($expectedParams, $reference->getParams()); } - /** - * @dataProvider generateGenerator - */ - public function testGenerate($resource, array $params) + #[DataProvider('generateGenerator')] + public function testGenerate($resource, array $params): void { $currentRouteName = 'my_route'; $currentRouteParams = ['foo' => 'bar']; @@ -105,7 +104,7 @@ public function testGenerate($resource, array $params) self::assertSame($params, $reference->getParams()); } - public function testGenerateNullResourceWithoutRoute() + public function testGenerateNullResourceWithoutRoute(): void { $currentRouteName = 'my_route'; $currentRouteParams = ['foo' => 'bar']; @@ -125,7 +124,10 @@ public function testGenerateNullResourceWithoutRoute() self::assertInstanceOf(RouteReference::class, $reference); } - public function generateGenerator() + /** + * @return array + */ + public static function generateGenerator(): array { return [ ['my_route', ['hello' => 'world', 'isIt' => true]], diff --git a/tests/lib/MVC/Symfony/Routing/RouteReferenceTest.php b/tests/lib/MVC/Symfony/Routing/RouteReferenceTest.php index f8d4dc37ed..c4c6ab8c85 100644 --- a/tests/lib/MVC/Symfony/Routing/RouteReferenceTest.php +++ b/tests/lib/MVC/Symfony/Routing/RouteReferenceTest.php @@ -12,7 +12,7 @@ class RouteReferenceTest extends TestCase { - public function testConstruct() + public function testConstruct(): void { $route = 'my_route'; $params = ['foo' => 'bar', 'some' => 'thing']; @@ -21,7 +21,7 @@ public function testConstruct() self::assertSame($params, $reference->getParams()); } - public function testGetSetRoute() + public function testGetSetRoute(): void { $initialRoute = 'foo'; $newRoute = 'bar'; @@ -32,7 +32,7 @@ public function testGetSetRoute() self::assertSame($newRoute, $reference->getRoute()); } - public function testGetSetParams() + public function testGetSetParams(): void { $reference = new RouteReference('foo'); self::assertSame([], $reference->getParams()); @@ -53,7 +53,7 @@ public function testGetSetParams() self::assertSame($defaultValue, $reference->get('url', $defaultValue)); } - public function testRemoveParam() + public function testRemoveParam(): void { $reference = new RouteReference('foo'); $reference->set('foo', 'bar'); diff --git a/tests/lib/MVC/Symfony/Routing/SimplifiedRequestTest.php b/tests/lib/MVC/Symfony/Routing/SimplifiedRequestTest.php index 0222afb723..02b19fd8ac 100644 --- a/tests/lib/MVC/Symfony/Routing/SimplifiedRequestTest.php +++ b/tests/lib/MVC/Symfony/Routing/SimplifiedRequestTest.php @@ -8,20 +8,19 @@ namespace Ibexa\Tests\Core\MVC\Symfony\Routing; use Ibexa\Core\MVC\Symfony\Routing\SimplifiedRequest; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\MVC\Symfony\Routing\SimplifiedRequest - */ +#[CoversClass(SimplifiedRequest::class)] class SimplifiedRequestTest extends TestCase { /** * @param string $url * @param \Ibexa\Core\MVC\Symfony\Routing\SimplifiedRequest $expectedRequest - * - * @dataProvider fromUrlProvider */ - public function testFromUrl($url, $expectedRequest) + #[DataProvider('fromUrlProvider')] + public function testFromUrl($url, $expectedRequest): void { self::assertEquals( $expectedRequest, @@ -49,7 +48,10 @@ public function testStrictGetters(): void self::assertSame(['param' => 'bar', 'param2' => 'bar2'], $request->getQueryParams()); } - public function fromUrlProvider() + /** + * @return array + */ + public static function fromUrlProvider(): array { return [ [ diff --git a/tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php b/tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php index 845f3bdcca..4f453c0a17 100644 --- a/tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php +++ b/tests/lib/MVC/Symfony/Routing/UrlAliasGeneratorTest.php @@ -21,6 +21,8 @@ use Ibexa\Core\Repository\Permission\PermissionResolver; use Ibexa\Core\Repository\Repository; use Ibexa\Core\Repository\Values\Content\Location; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\MockObject\Stub; use PHPUnit\Framework\TestCase; use Psr\Log\LoggerInterface; use Symfony\Component\Routing\RouterInterface; @@ -45,8 +47,7 @@ class UrlAliasGeneratorTest extends TestCase /** @var \Ibexa\Core\MVC\Symfony\Routing\Generator\UrlAliasGenerator */ private $urlAliasGenerator; - /** @var \PHPUnit\Framework\MockObject\MockObject */ - private $siteAccessRouter; + private SiteAccessRouterInterface&Stub $siteAccessRouter; /** @var \PHPUnit\Framework\MockObject\MockObject */ private $configResolver; @@ -56,17 +57,17 @@ protected function setUp(): void parent::setUp(); $this->router = $this->createMock(RouterInterface::class); $this->logger = $this->createMock(LoggerInterface::class); - $this->siteAccessRouter = $this->createMock(SiteAccessRouterInterface::class); + $this->siteAccessRouter = self::createStub(SiteAccessRouterInterface::class); $this->configResolver = $this->createMock(ConfigResolverInterface::class); $repositoryClass = Repository::class; $this->repository = $repository = $this ->getMockBuilder($repositoryClass) ->disableOriginalConstructor() - ->setMethods( - array_diff( + ->onlyMethods( + array_values(array_diff( get_class_methods($repositoryClass), ['sudo'] - ) + )) ) ->getMock(); $this->urlAliasService = $this->createMock(URLAliasService::class); @@ -100,7 +101,7 @@ protected function setUp(): void $this->urlAliasGenerator->setSiteAccessRouter($this->siteAccessRouter); } - public function testGetPathPrefixByRootLocationId() + public function testGetPathPrefixByRootLocationId(): void { $rootLocationId = 123; $rootLocation = new Location(['id' => $rootLocationId]); @@ -120,10 +121,8 @@ public function testGetPathPrefixByRootLocationId() self::assertSame($pathPrefix, $this->urlAliasGenerator->getPathPrefixByRootLocationId($rootLocationId)); } - /** - * @dataProvider providerTestIsPrefixExcluded - */ - public function testIsPrefixExcluded($uri, $expectedIsExcluded) + #[DataProvider('providerTestIsPrefixExcluded')] + public function testIsPrefixExcluded($uri, $expectedIsExcluded): void { $this->urlAliasGenerator->setExcludedUriPrefixes( [ @@ -135,7 +134,10 @@ public function testIsPrefixExcluded($uri, $expectedIsExcluded) self::assertSame($expectedIsExcluded, $this->urlAliasGenerator->isUriPrefixExcluded($uri)); } - public function providerTestIsPrefixExcluded() + /** + * @return array + */ + public static function providerTestIsPrefixExcluded(): array { return [ ['/foo/bar', false], @@ -152,7 +154,7 @@ public function providerTestIsPrefixExcluded() ]; } - public function testLoadLocation() + public function testLoadLocation(): void { $locationId = 123; $location = new Location(['id' => $locationId]); @@ -164,10 +166,8 @@ public function testLoadLocation() $this->urlAliasGenerator->loadLocation($locationId); } - /** - * @dataProvider providerTestDoGenerate - */ - public function testDoGenerate(URLAlias $urlAlias, array $parameters, $expected) + #[DataProvider('providerTestDoGenerate')] + public function testDoGenerate(URLAlias $urlAlias, array $parameters, $expected): void { $location = new Location(['id' => 123]); $this->urlAliasService @@ -176,12 +176,15 @@ public function testDoGenerate(URLAlias $urlAlias, array $parameters, $expected) ->with($location, false) ->will(self::returnValue([$urlAlias])); - $this->urlAliasGenerator->setSiteAccess(new SiteAccess('test', 'fake', $this->createMock(SiteAccess\URILexer::class))); + $this->urlAliasGenerator->setSiteAccess(new SiteAccess('test', 'fake', self::createStub(SiteAccess\URILexer::class))); self::assertSame($expected, $this->urlAliasGenerator->doGenerate($location, $parameters)); } - public function providerTestDoGenerate() + /** + * @return array + */ + public static function providerTestDoGenerate(): array { return [ 'without_parameters' => [ @@ -208,11 +211,10 @@ public function providerTestDoGenerate() } /** - * @dataProvider providerTestDoGenerateWithSiteaccess - * * @param array $parameters */ - public function testDoGenerateWithSiteAccessParam(URLAlias $urlAlias, array $parameters, string $expected) + #[DataProvider('providerTestDoGenerateWithSiteaccess')] + public function testDoGenerateWithSiteAccessParam(URLAlias $urlAlias, array $parameters, string $expected): void { $siteaccessName = 'foo'; $parameters += ['siteaccess' => $siteaccessName]; @@ -274,12 +276,15 @@ static function ($location) use ($treeRootUrlAlias) { ) ); - $this->urlAliasGenerator->setSiteAccess(new SiteAccess('test', 'fake', $this->createMock(SiteAccess\URILexer::class))); + $this->urlAliasGenerator->setSiteAccess(new SiteAccess('test', 'fake', self::createStub(SiteAccess\URILexer::class))); self::assertSame($expected, $this->urlAliasGenerator->doGenerate($location, $parameters)); } - public function providerTestDoGenerateWithSiteaccess() + /** + * @return array + */ + public static function providerTestDoGenerateWithSiteaccess(): array { return [ [ @@ -398,7 +403,7 @@ public function testDoGenerateWithSiteAccessLoadsLocationWithLanguages(): void ); } - public function testDoGenerateNoUrlAlias() + public function testDoGenerateNoUrlAlias(): void { $location = new Location(['id' => 123, 'contentInfo' => new ContentInfo(['id' => 456])]); $uri = "/content/location/$location->id"; @@ -419,10 +424,8 @@ public function testDoGenerateNoUrlAlias() self::assertSame($uri, $this->urlAliasGenerator->doGenerate($location, [])); } - /** - * @dataProvider providerTestDoGenerateRootLocation - */ - public function testDoGenerateRootLocation(URLAlias $urlAlias, $isOutsideAndNotExcluded, $expected, $pathPrefix) + #[DataProvider('providerTestDoGenerateRootLocation')] + public function testDoGenerateRootLocation(URLAlias $urlAlias, $isOutsideAndNotExcluded, $expected, $pathPrefix): void { $excludedPrefixes = ['/products', '/shared']; $rootLocationId = 456; @@ -458,7 +461,10 @@ public function testDoGenerateRootLocation(URLAlias $urlAlias, $isOutsideAndNotE self::assertSame($expected, $this->urlAliasGenerator->doGenerate($location, [])); } - public function providerTestDoGenerateRootLocation() + /** + * @return array + */ + public static function providerTestDoGenerateRootLocation(): array { return [ [ @@ -534,12 +540,12 @@ protected function getPermissionResolverMock() return $this ->getMockBuilder(PermissionResolver::class) - ->setMethods(null) + ->onlyMethods([]) ->setConstructorArgs( [ - $this->createMock(RoleDomainMapper::class), - $this->createMock(LimitationService::class), - $this->createMock(SPIUserHandler::class), + self::createStub(RoleDomainMapper::class), + self::createStub(LimitationService::class), + self::createStub(SPIUserHandler::class), $configResolverMock, [], ] diff --git a/tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php b/tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php index 52ebd9be49..6c48dbf3af 100644 --- a/tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php +++ b/tests/lib/MVC/Symfony/Routing/UrlAliasRouterTest.php @@ -21,6 +21,7 @@ use Ibexa\Core\MVC\Symfony\View\Manager as ViewManager; use Ibexa\Core\Repository\Repository; use Ibexa\Core\Repository\Values\Content\Location; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Cmf\Component\Routing\RouteObjectInterface; use Symfony\Component\HttpFoundation\Request; @@ -60,11 +61,11 @@ protected function setUp(): void $this->repository = $repository = $this ->getMockBuilder($repositoryClass) ->disableOriginalConstructor() - ->setMethods( - array_diff( + ->onlyMethods( + array_values(array_diff( get_class_methods($repositoryClass), ['sudo'] - ) + )) ) ->getMock(); $this->urlAliasService = $this->createMock(URLAliasService::class); @@ -75,8 +76,8 @@ protected function setUp(): void ->setConstructorArgs( [ $repository, - $this->createMock(RouterInterface::class), - $this->createMock(ConfigResolverInterface::class), + self::createStub(RouterInterface::class), + self::createStub(ConfigResolverInterface::class), ] ) ->getMock(); @@ -99,7 +100,7 @@ protected function getRouter(LocationService $locationService, URLAliasService $ return new UrlAliasRouter($locationService, $urlAliasService, $contentService, $urlAliasGenerator, $requestContext); } - public function testRequestContext() + public function testRequestContext(): void { self::assertSame($this->requestContext, $this->router->getContext()); $newContext = new RequestContext(); @@ -111,22 +112,23 @@ public function testRequestContext() self::assertSame($newContext, $this->router->getContext()); } - public function testMatch() + public function testMatch(): void { $this->expectException(\RuntimeException::class); $this->router->match('/foo'); } - /** - * @dataProvider providerTestSupports - */ - public function testSupports($routeReference, $isSupported) + #[DataProvider('providerTestSupports')] + public function testSupports($routeReference, $isSupported): void { self::assertSame($isSupported, $this->router->supports($routeReference)); } - public function providerTestSupports() + /** + * @return array + */ + public static function providerTestSupports(): array { return [ [new Location(), true], @@ -136,7 +138,7 @@ public function providerTestSupports() ]; } - public function testGetRouteCollection() + public function testGetRouteCollection(): void { self::assertInstanceOf(RouteCollection::class, $this->router->getRouteCollection()); } @@ -155,14 +157,14 @@ protected function getRequestByPathInfo($pathInfo) new SiteAccess( 'test', 'fake', - $this->createMock(Matcher::class) + self::createStub(Matcher::class) ) ); return $request; } - public function testMatchRequestLocation() + public function testMatchRequestLocation(): void { $pathInfo = '/foo/bar'; $destinationId = 123; @@ -196,7 +198,7 @@ public function testMatchRequestLocation() self::assertEquals($expected, $this->router->matchRequest($request)); } - public function testMatchRequestLocationWithCaseRedirect() + public function testMatchRequestLocationWithCaseRedirect(): void { $pathInfo = '/Foo/bAR'; $urlAliasPath = '/foo/bar'; @@ -238,7 +240,7 @@ public function testMatchRequestLocationWithCaseRedirect() self::assertEquals($expected, $this->router->matchRequest($request)); } - public function testMatchRequestLocationWrongCaseUriPrefixExcluded() + public function testMatchRequestLocationWrongCaseUriPrefixExcluded(): void { $pathInfo = '/Foo/bAR'; $urlAliasPath = '/foo/bar'; @@ -280,7 +282,7 @@ public function testMatchRequestLocationWrongCaseUriPrefixExcluded() self::assertEquals($expected, $this->router->matchRequest($request)); } - public function testMatchRequestLocationCorrectCaseUriPrefixExcluded() + public function testMatchRequestLocationCorrectCaseUriPrefixExcluded(): void { $pathInfo = $urlAliasPath = '/foo/bar'; $destinationId = 123; @@ -321,7 +323,7 @@ public function testMatchRequestLocationCorrectCaseUriPrefixExcluded() self::assertSame($pathInfo, $request->attributes->get('semanticPathinfo')); } - public function testMatchRequestLocationHistory() + public function testMatchRequestLocationHistory(): void { $pathInfo = '/foo/bar'; $newPathInfo = '/foo/bar-new'; @@ -368,7 +370,7 @@ public function testMatchRequestLocationHistory() self::assertEquals($expected, $this->router->matchRequest($request)); } - public function testMatchRequestLocationCustom() + public function testMatchRequestLocationCustom(): void { $pathInfo = '/foo/bar'; $destinationId = 123; @@ -404,7 +406,7 @@ public function testMatchRequestLocationCustom() self::assertEquals($expected, $this->router->matchRequest($request)); } - public function testMatchRequestLocationCustomForward() + public function testMatchRequestLocationCustomForward(): void { $pathInfo = '/foo/bar'; $newPathInfo = '/foo/bar-new'; @@ -460,7 +462,7 @@ public function testMatchRequestLocationCustomForward() self::assertEquals($expected, $this->router->matchRequest($request)); } - public function testMatchRequestFail() + public function testMatchRequestFail(): void { $this->expectException(ResourceNotFoundException::class); @@ -474,7 +476,7 @@ public function testMatchRequestFail() $this->router->matchRequest($request); } - public function testMatchRequestResource() + public function testMatchRequestResource(): void { $pathInfo = '/hello_content/hello_search'; $destination = '/content/search'; @@ -500,7 +502,7 @@ public function testMatchRequestResource() self::assertEquals($expected, $this->router->matchRequest($request)); } - public function testMatchRequestResourceWithRedirect() + public function testMatchRequestResourceWithRedirect(): void { $pathInfo = '/hello_content/hello_search'; $destination = '/content/search'; @@ -527,7 +529,7 @@ public function testMatchRequestResourceWithRedirect() self::assertEquals($expected, $this->router->matchRequest($request)); } - public function testMatchRequestResourceWithCaseRedirect() + public function testMatchRequestResourceWithCaseRedirect(): void { $pathInfo = '/heLLo_contEnt/hEllo_SEarch'; $urlAliasPath = '/hello_content/hello_search'; @@ -564,7 +566,7 @@ public function testMatchRequestResourceWithCaseRedirect() * Tests that forwarding custom alias will redirect to the resource destination rather than * to the case-corrected alias. */ - public function testMatchRequestResourceCaseIncorrectWithForwardRedirect() + public function testMatchRequestResourceCaseIncorrectWithForwardRedirect(): void { $pathInfo = '/heLLo_contEnt/hEllo_SEarch'; $urlAliasPath = '/hello_content/hello_search'; @@ -592,7 +594,7 @@ public function testMatchRequestResourceCaseIncorrectWithForwardRedirect() self::assertEquals($expected, $this->router->matchRequest($request)); } - public function testMatchRequestVirtual() + public function testMatchRequestVirtual(): void { $pathInfo = '/foo/bar'; $urlAlias = new URLAlias( @@ -616,7 +618,7 @@ public function testMatchRequestVirtual() self::assertEquals($expected, $this->router->matchRequest($request)); } - public function testMatchRequestVirtualWithCaseRedirect() + public function testMatchRequestVirtualWithCaseRedirect(): void { $pathInfo = '/Foo/bAR'; $urlAliasPath = '/foo/bar'; @@ -646,7 +648,7 @@ public function testMatchRequestVirtualWithCaseRedirect() self::assertEquals($expected, $this->router->matchRequest($request)); } - public function testGenerateFail() + public function testGenerateFail(): void { $this->expectException(RouteNotFoundException::class); @@ -681,21 +683,21 @@ public function testGenerateWithRouteObject(): void ); } - public function testGenerateNoLocation() + public function testGenerateNoLocation(): void { $this->expectException(\InvalidArgumentException::class); $this->router->generate(UrlAliasRouter::URL_ALIAS_ROUTE_NAME, ['foo' => 'bar']); } - public function testGenerateInvalidLocation() + public function testGenerateInvalidLocation(): void { $this->expectException(\LogicException::class); $this->router->generate(UrlAliasRouter::URL_ALIAS_ROUTE_NAME, ['location' => new \stdClass()]); } - public function testGenerateWithLocationId() + public function testGenerateWithLocationId(): void { $locationId = 123; $location = new Location(['id' => $locationId]); @@ -722,7 +724,7 @@ public function testGenerateWithLocationId() ); } - public function testGenerateWithLocationAsParameter() + public function testGenerateWithLocationAsParameter(): void { $locationId = 123; $location = new Location(['id' => $locationId]); @@ -744,7 +746,7 @@ public function testGenerateWithLocationAsParameter() ); } - public function testGenerateWithContentId() + public function testGenerateWithContentId(): void { $locationId = 123; $contentId = 456; @@ -778,7 +780,7 @@ public function testGenerateWithContentId() ); } - public function testGenerateWithContentIdWithMissingMainLocation() + public function testGenerateWithContentIdWithMissingMainLocation(): void { $this->expectException(\LogicException::class); diff --git a/tests/lib/MVC/Symfony/Security/Authentication/AnonymousUserAccessListenerTest.php b/tests/lib/MVC/Symfony/Security/Authentication/AnonymousUserAccessListenerTest.php index 983bb2f8da..c09ee2e675 100644 --- a/tests/lib/MVC/Symfony/Security/Authentication/AnonymousUserAccessListenerTest.php +++ b/tests/lib/MVC/Symfony/Security/Authentication/AnonymousUserAccessListenerTest.php @@ -11,6 +11,7 @@ use Ibexa\Contracts\Core\Repository\PermissionResolver; use Ibexa\Core\MVC\Symfony\Security\Authentication\AnonymousUserAccessListener; use Ibexa\Core\MVC\Symfony\SiteAccess; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; use Symfony\Bundle\SecurityBundle\Security; @@ -100,7 +101,7 @@ public function testAuthenticateWhenUserCanLogin(): void $siteAccess = new SiteAccess('admin', 'default'); $request = new Request([], [], ['siteaccess' => $siteAccess]); $event = new RequestEvent( - $this->createMock(HttpKernelInterface::class), + self::createStub(HttpKernelInterface::class), $request, HttpKernelInterface::MAIN_REQUEST ); @@ -119,7 +120,7 @@ public function testAuthenticateWhenUserCannotLogin(): void $siteAccess = new SiteAccess('site', 'default'); $request = new Request([], [], ['siteaccess' => $siteAccess]); $event = new RequestEvent( - $this->createMock(HttpKernelInterface::class), + self::createStub(HttpKernelInterface::class), $request, HttpKernelInterface::MAIN_REQUEST ); @@ -141,7 +142,7 @@ public function testAuthenticateSkipsSubRequest(): void $siteAccess = new SiteAccess('admin', 'default'); $request = new Request([], [], ['siteaccess' => $siteAccess]); $event = new RequestEvent( - $this->createMock(HttpKernelInterface::class), + self::createStub(HttpKernelInterface::class), $request, HttpKernelInterface::SUB_REQUEST ); @@ -168,9 +169,8 @@ public function testSupportsSkipsUserContextHashRequest(): void /** * The login page is no longer hard-skipped; it defers to access_control, which * is a no-op when no rule protects it, so the login page stays reachable. - * - * @dataProvider provideLoginPaths */ + #[DataProvider('provideLoginPaths')] public function testSupportsDefersToAccessControlOnLoginPage(string $path): void { $request = Request::create($path); @@ -190,9 +190,7 @@ public static function provideLoginPaths(): iterable yield 'login with query string' => ['/login?redirect=/content']; } - /** - * @dataProvider providedSupportedPaths - */ + #[DataProvider('providedSupportedPaths')] public function testSupportsReturnsTrueForSupportedPaths(string $path): void { $request = Request::create($path); @@ -270,7 +268,7 @@ public function testAuthenticateEnforcesAccessControlOnFirewallWithoutLoginPath( ->willReturn(false); $event = new RequestEvent( - $this->createMock(HttpKernelInterface::class), + self::createStub(HttpKernelInterface::class), $request, HttpKernelInterface::MAIN_REQUEST ); @@ -326,7 +324,7 @@ private function prepareForAccessListenerTests(): RequestEvent $this->listener->supports($request); return new RequestEvent( - $this->createMock(HttpKernelInterface::class), + self::createStub(HttpKernelInterface::class), $request, HttpKernelInterface::MAIN_REQUEST ); diff --git a/tests/lib/MVC/Symfony/Security/Authentication/EventSubscriber/OnAuthenticationTokenCreatedRepositoryUserSubscriberTest.php b/tests/lib/MVC/Symfony/Security/Authentication/EventSubscriber/OnAuthenticationTokenCreatedRepositoryUserSubscriberTest.php index 29c3d68685..afbb2a6655 100644 --- a/tests/lib/MVC/Symfony/Security/Authentication/EventSubscriber/OnAuthenticationTokenCreatedRepositoryUserSubscriberTest.php +++ b/tests/lib/MVC/Symfony/Security/Authentication/EventSubscriber/OnAuthenticationTokenCreatedRepositoryUserSubscriberTest.php @@ -12,6 +12,7 @@ use Ibexa\Core\MVC\Symfony\Security\Authentication\EventSubscriber\OnAuthenticationTokenCreatedRepositoryUserSubscriber; use Ibexa\Core\MVC\Symfony\Security\User; use Ibexa\Core\Repository\Values\User\User as ApiUser; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\Security\Core\Authentication\Token\UsernamePasswordToken; use Symfony\Component\Security\Core\User\InMemoryUser; @@ -26,7 +27,7 @@ final class OnAuthenticationTokenCreatedRepositoryUserSubscriberTest extends Tes public function testGetSubscribedEvents(): void { $subscriber = new OnAuthenticationTokenCreatedRepositoryUserSubscriber( - $this->createMock(PermissionResolver::class) + self::createStub(PermissionResolver::class) ); self::assertEquals( @@ -37,9 +38,7 @@ public function testGetSubscribedEvents(): void ); } - /** - * @dataProvider dataProviderForTestSettingCurrentUserReference - */ + #[DataProvider('dataProviderForTestSettingCurrentUserReference')] public function testSettingCurrentUserReference( UserInterface $user, bool $isPermissionResolverInvoked @@ -59,10 +58,10 @@ public function testSettingCurrentUserReference( /** * @return iterable */ - public function dataProviderForTestSettingCurrentUserReference(): iterable + public static function dataProviderForTestSettingCurrentUserReference(): iterable { yield 'authorizing Ibexa user' => [ - new User($this->createMock(ApiUser::class)), + new User(self::createStub(ApiUser::class)), true, ]; diff --git a/tests/lib/MVC/Symfony/Security/Authentication/EventSubscriber/RepositoryUserAuthenticationSubscriberTest.php b/tests/lib/MVC/Symfony/Security/Authentication/EventSubscriber/RepositoryUserAuthenticationSubscriberTest.php index 8802033e18..8d7f1570d9 100644 --- a/tests/lib/MVC/Symfony/Security/Authentication/EventSubscriber/RepositoryUserAuthenticationSubscriberTest.php +++ b/tests/lib/MVC/Symfony/Security/Authentication/EventSubscriber/RepositoryUserAuthenticationSubscriberTest.php @@ -134,17 +134,16 @@ private function getSubscriber( float $constantAuthTime = 1.0, ?LoggerInterface $logger = null ): RepositoryUserAuthenticationSubscriber { - $request = $this->createMock(Request::class); $requestStack = $this->createMock(RequestStack::class); $requestStack ->method('getCurrentRequest') - ->willReturn($request); + ->willReturn(self::createStub(Request::class)); return new RepositoryUserAuthenticationSubscriber( $requestStack, - $userService ?? $this->createMock(UserService::class), + $userService ?? self::createStub(UserService::class), $constantAuthTime, - $logger ?? $this->createMock(LoggerInterface::class) + $logger ?? self::createStub(LoggerInterface::class) ); } @@ -152,7 +151,6 @@ private function getCheckPassportEvent( (User & MockObject)|null $user = null, ?Passport $passport = null, ): CheckPassportEvent { - $authenticator = $this->createMock(AuthenticatorInterface::class); $user = $user ?? $this->createMock(User::class); if ($passport === null) { @@ -172,6 +170,6 @@ private function getCheckPassportEvent( ); } - return new CheckPassportEvent($authenticator, $passport); + return new CheckPassportEvent(self::createStub(AuthenticatorInterface::class), $passport); } } diff --git a/tests/lib/MVC/Symfony/Security/HttpUtilsTest.php b/tests/lib/MVC/Symfony/Security/HttpUtilsTest.php index d196b24bd0..6dc92ec9cc 100644 --- a/tests/lib/MVC/Symfony/Security/HttpUtilsTest.php +++ b/tests/lib/MVC/Symfony/Security/HttpUtilsTest.php @@ -9,16 +9,15 @@ use Ibexa\Core\MVC\Symfony\Security\HttpUtils; use Ibexa\Core\MVC\Symfony\SiteAccess; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\Routing\Generator\UrlGeneratorInterface; class HttpUtilsTest extends TestCase { - /** - * @dataProvider generateUriStandardProvider - */ - public function testGenerateUriStandard($uri, $isUriRouteName, $expected) + #[DataProvider('generateUriStandardProvider')] + public function testGenerateUriStandard($uri, $isUriRouteName, $expected): void { $urlGenerator = $this->createMock(UrlGeneratorInterface::class); $httpUtils = new HttpUtils($urlGenerator); @@ -39,7 +38,10 @@ public function testGenerateUriStandard($uri, $isUriRouteName, $expected) self::assertSame($expected, $httpUtils->generateUri($request, $uri)); } - public function generateUriStandardProvider() + /** + * @return array + */ + public static function generateUriStandardProvider(): array { return [ ['http://localhost/foo/bar', false, 'http://localhost/foo/bar'], @@ -50,10 +52,8 @@ public function generateUriStandardProvider() ]; } - /** - * @dataProvider generateUriProvider - */ - public function testGenerateUri($uri, $isUriRouteName, $siteAccessUri, $expected) + #[DataProvider('generateUriProvider')] + public function testGenerateUri($uri, $isUriRouteName, $siteAccessUri, $expected): void { $siteAccess = new SiteAccess('test', 'test'); if ($uri[0] === '/') { @@ -86,7 +86,10 @@ public function testGenerateUri($uri, $isUriRouteName, $siteAccessUri, $expected self::assertSame($expected, $res); } - public function generateUriProvider() + /** + * @return array + */ + public static function generateUriProvider(): array { return [ ['http://localhost/foo/bar', false, null, 'http://localhost/foo/bar'], @@ -97,7 +100,7 @@ public function generateUriProvider() ]; } - public function testCheckRequestPathStandard() + public function testCheckRequestPathStandard(): void { $httpUtils = new HttpUtils(); $httpUtils->setSiteAccess(new SiteAccess('test')); @@ -105,10 +108,8 @@ public function testCheckRequestPathStandard() self::assertTrue($httpUtils->checkRequestPath($request, '/foo/bar')); } - /** - * @dataProvider checkRequestPathProvider - */ - public function testCheckRequestPath($path, $siteAccessUri, $requestUri, $expected) + #[DataProvider('checkRequestPathProvider')] + public function testCheckRequestPath($path, $siteAccessUri, $requestUri, $expected): void { $siteAccess = new SiteAccess('test', 'test'); if ($siteAccessUri !== null) { @@ -127,7 +128,10 @@ public function testCheckRequestPath($path, $siteAccessUri, $requestUri, $expect self::assertSame($expected, $httpUtils->checkRequestPath($request, $path)); } - public function checkRequestPathProvider() + /** + * @return array + */ + public static function checkRequestPathProvider(): array { return [ ['/foo/bar', null, 'http://localhost/foo/bar', true], diff --git a/tests/lib/MVC/Symfony/Security/User/BaseProviderTestCase.php b/tests/lib/MVC/Symfony/Security/User/BaseProviderTestCase.php index 3cada1549e..232caa7d0f 100644 --- a/tests/lib/MVC/Symfony/Security/User/BaseProviderTestCase.php +++ b/tests/lib/MVC/Symfony/Security/User/BaseProviderTestCase.php @@ -20,6 +20,7 @@ use Ibexa\Core\Repository\Values\Content\VersionInfo; use Ibexa\Core\Repository\Values\User\User; use Ibexa\Core\Repository\Values\User\UserReference; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; use Symfony\Component\Security\Core\Exception\UnsupportedUserException; @@ -51,20 +52,19 @@ protected function setUp(): void /** * @phpstan-return list, bool}> */ - public function supportsClassProvider(): array + public static function supportsClassProvider(): array { return [ [SymfonyUserInterface::class, false], [MVCUser::class, true], - [get_class($this->createMock(MVCUser::class)), true], + [get_class(self::createStub(MVCUser::class)), true], ]; } /** - * @dataProvider supportsClassProvider - * * @phpstan-param class-string<\Symfony\Component\Security\Core\User\UserInterface> $class */ + #[DataProvider('supportsClassProvider')] public function testSupportsClass(string $class, bool $supports): void { self::assertSame($supports, $this->userProvider->supportsClass($class)); @@ -72,7 +72,7 @@ public function testSupportsClass(string $class, bool $supports): void public function testLoadUserByAPIUser(): void { - $apiUser = $this->createMock(APIUser::class); + $apiUser = self::createStub(APIUser::class); $user = $this->userProvider->loadUserByAPIUser($apiUser); @@ -103,7 +103,7 @@ public function testRefreshUserNotFound(): void public function testRefreshUserNotSupported(): void { - $user = $this->createMock(SymfonyUserInterface::class); + $user = self::createStub(SymfonyUserInterface::class); $this->expectException(UnsupportedUserException::class); $this->userProvider->refreshUser($user); @@ -151,7 +151,7 @@ public function testRefreshUser(): void public function testLoadUserByUsername(): void { $username = $this->getUserIdentifier(); - $apiUser = $this->createMock(APIUser::class); + $apiUser = self::createStub(APIUser::class); $this->userService ->expects(self::once()) diff --git a/tests/lib/MVC/Symfony/Security/User/EmailProviderTest.php b/tests/lib/MVC/Symfony/Security/User/EmailProviderTest.php index 261609b26e..45a96ceeb2 100644 --- a/tests/lib/MVC/Symfony/Security/User/EmailProviderTest.php +++ b/tests/lib/MVC/Symfony/Security/User/EmailProviderTest.php @@ -10,10 +10,9 @@ use Ibexa\Core\MVC\Symfony\Security\User\BaseProvider; use Ibexa\Core\MVC\Symfony\Security\User\EmailProvider; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\MVC\Symfony\Security\User\EmailProvider - */ +#[CoversClass(EmailProvider::class)] final class EmailProviderTest extends BaseProviderTestCase { protected function buildProvider(): BaseProvider diff --git a/tests/lib/MVC/Symfony/Security/User/UsernameProviderTest.php b/tests/lib/MVC/Symfony/Security/User/UsernameProviderTest.php index 5886976ba4..7d537e246e 100644 --- a/tests/lib/MVC/Symfony/Security/User/UsernameProviderTest.php +++ b/tests/lib/MVC/Symfony/Security/User/UsernameProviderTest.php @@ -10,10 +10,9 @@ use Ibexa\Core\MVC\Symfony\Security\User\BaseProvider; use Ibexa\Core\MVC\Symfony\Security\User\UsernameProvider; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\MVC\Symfony\Security\User\UsernameProvider - */ +#[CoversClass(UsernameProvider::class)] final class UsernameProviderTest extends BaseProviderTestCase { protected function buildProvider(): BaseProvider diff --git a/tests/lib/MVC/Symfony/Security/UserTest.php b/tests/lib/MVC/Symfony/Security/UserTest.php index 94a7efb783..6c20ee0b1c 100644 --- a/tests/lib/MVC/Symfony/Security/UserTest.php +++ b/tests/lib/MVC/Symfony/Security/UserTest.php @@ -16,7 +16,7 @@ class UserTest extends TestCase { - public function testConstruct() + public function testConstruct(): void { $login = 'my_username'; $passwordHash = 'encoded_password'; @@ -31,7 +31,7 @@ public function testConstruct() ], ] ) - ->setMethods(['getUserId']) + ->onlyMethods(['getUserId']) ->getMockForAbstractClass(); $roles = ['ROLE_USER']; @@ -47,7 +47,7 @@ public function testConstruct() self::assertSame($roles, $user->getRoles()); } - public function testIsEqualTo() + public function testIsEqualTo(): void { $userId = 123; $apiUser = $this->createMock(APIUser::class); @@ -69,7 +69,7 @@ public function testIsEqualTo() self::assertTrue($user->isEqualTo($user2)); } - public function testIsNotEqualTo() + public function testIsNotEqualTo(): void { $apiUser = $this->createMock(APIUser::class); $apiUser @@ -90,9 +90,9 @@ public function testIsNotEqualTo() self::assertFalse($user->isEqualTo($user2)); } - public function testIsEqualToNotSameUserType() + public function testIsEqualToNotSameUserType(): void { - $user = new User($this->createMock(APIUser::class)); + $user = new User(self::createStub(APIUser::class)); $user2 = $this->createMock(ReferenceUserInterface::class); $user2 ->expects(self::once()) @@ -101,10 +101,10 @@ public function testIsEqualToNotSameUserType() self::assertFalse($user->isEqualTo($user2)); } - public function testSetAPIUser() + public function testSetAPIUser(): void { - $apiUserA = $this->createMock(APIUser::class); - $apiUserB = $this->createMock(APIUser::class); + $apiUserA = self::createStub(APIUser::class); + $apiUserB = self::createStub(APIUser::class); $user = new User($apiUserA); $user->setAPIUser($apiUserB); diff --git a/tests/lib/MVC/Symfony/Security/UserWrappedTest.php b/tests/lib/MVC/Symfony/Security/UserWrappedTest.php index b4ac50d84b..ef387c6171 100644 --- a/tests/lib/MVC/Symfony/Security/UserWrappedTest.php +++ b/tests/lib/MVC/Symfony/Security/UserWrappedTest.php @@ -11,39 +11,39 @@ use Ibexa\Contracts\Core\Repository\Values\User\User as APIUser; use Ibexa\Core\MVC\Symfony\Security\UserInterface; use Ibexa\Core\MVC\Symfony\Security\UserWrapped; -use PHPUnit\Framework\MockObject\MockObject; +use PHPUnit\Framework\MockObject\Stub; use PHPUnit\Framework\TestCase; use Symfony\Component\Security\Core\User\EquatableInterface; use Symfony\Component\Security\Core\User\UserInterface as SymfonyUserInterface; final class UserWrappedTest extends TestCase { - private APIUser & MockObject $apiUser; + private APIUser&Stub $apiUser; protected function setUp(): void { parent::setUp(); - $this->apiUser = $this->createMock(APIUser::class); + $this->apiUser = self::createStub(APIUser::class); } public function testGetSetAPIUser(): void { - $originalUser = $this->createMock(SymfonyUserInterface::class); + $originalUser = self::createStub(SymfonyUserInterface::class); $userWrapped = new UserWrapped($originalUser, $this->apiUser); self::assertSame($this->apiUser, $userWrapped->getAPIUser()); - $newApiUser = $this->createMock(APIUser::class); + $newApiUser = self::createStub(APIUser::class); $userWrapped->setAPIUser($newApiUser); self::assertSame($newApiUser, $userWrapped->getAPIUser()); } public function testGetSetWrappedUser(): void { - $originalUser = $this->createMock(SymfonyUserInterface::class); + $originalUser = self::createStub(SymfonyUserInterface::class); $userWrapped = new UserWrapped($originalUser, $this->apiUser); self::assertSame($originalUser, $userWrapped->getWrappedUser()); - $newWrappedUser = $this->createMock(UserInterface::class); + $newWrappedUser = self::createStub(UserInterface::class); $userWrapped->setWrappedUser($newWrappedUser); self::assertSame($newWrappedUser, $userWrapped->getWrappedUser()); } @@ -53,7 +53,7 @@ public function testRegularUser(): void $originalUser = $this->createMock(SymfonyUserInterface::class); $user = new UserWrapped($originalUser, $this->apiUser); - self::assertTrue($user->isEqualTo($this->createMock(SymfonyUserInterface::class))); + self::assertTrue($user->isEqualTo(self::createStub(SymfonyUserInterface::class))); $originalUser ->expects(self::once()) @@ -77,11 +77,11 @@ public function testRegularUser(): void self::assertSame($originalUser, $user->getWrappedUser()); } - public function testIsEqualTo() + public function testIsEqualTo(): void { $originalUser = $this->createMock(UserEquatableInterface::class); $user = new UserWrapped($originalUser, $this->apiUser); - $otherUser = $this->createMock(SymfonyUserInterface::class); + $otherUser = self::createStub(SymfonyUserInterface::class); $originalUser ->expects(self::once()) ->method('isEqualTo') @@ -92,7 +92,7 @@ public function testIsEqualTo() public function testNotSerializeApiUser(): void { - $originalUser = $this->createMock(UserInterface::class); + $originalUser = self::createStub(UserInterface::class); $user = new UserWrapped($originalUser, $this->apiUser); $serialized = serialize($user); $unserializedUser = unserialize($serialized); diff --git a/tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php b/tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php index 2d8261b14c..a759f36564 100644 --- a/tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php +++ b/tests/lib/MVC/Symfony/Security/Voter/CoreVoterTest.php @@ -12,6 +12,7 @@ use Ibexa\Core\MVC\Symfony\Controller\Content\ViewController; use Ibexa\Core\MVC\Symfony\Security\Authorization\Attribute; use Ibexa\Core\MVC\Symfony\Security\Authorization\Voter\CoreVoter; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\Security\Core\Authentication\Token\TokenInterface; use Symfony\Component\Security\Core\Authorization\Voter\VoterInterface; @@ -27,16 +28,17 @@ protected function setUp(): void $this->permissionResolver = $this->createMock(PermissionResolver::class); } - /** - * @dataProvider supportsAttributeProvider - */ - public function testSupportsAttribute($attribute, $expectedResult) + #[DataProvider('supportsAttributeProvider')] + public function testSupportsAttribute($attribute, $expectedResult): void { $voter = new CoreVoter($this->permissionResolver); self::assertSame($expectedResult, $voter->supportsAttribute($attribute)); } - public function supportsAttributeProvider() + /** + * @return array + */ + public static function supportsAttributeProvider(): array { return [ ['foo', false], @@ -48,23 +50,24 @@ public function supportsAttributeProvider() new Attribute( 'foo', 'bar', - ['valueObject' => $this->getMockForAbstractClass(ValueObject::class)] + ['valueObject' => self::createStub(ValueObject::class)] ), false, ], ]; } - /** - * @dataProvider supportsClassProvider - */ - public function testSupportsClass($class) + #[DataProvider('supportsClassProvider')] + public function testSupportsClass($class): void { $voter = new CoreVoter($this->permissionResolver); self::assertTrue($voter->supportsClass($class)); } - public function supportsClassProvider() + /** + * @return array + */ + public static function supportsClassProvider(): array { return [ ['foo'], @@ -74,23 +77,24 @@ public function supportsClassProvider() ]; } - /** - * @dataProvider voteInvalidAttributeProvider - */ - public function testVoteInvalidAttribute(array $attributes) + #[DataProvider('voteInvalidAttributeProvider')] + public function testVoteInvalidAttribute(array $attributes): void { $voter = new CoreVoter($this->permissionResolver); self::assertSame( VoterInterface::ACCESS_ABSTAIN, $voter->vote( - $this->createMock(TokenInterface::class), + self::createStub(TokenInterface::class), new \stdClass(), $attributes ) ); } - public function voteInvalidAttributeProvider() + /** + * @return array + */ + public static function voteInvalidAttributeProvider(): array { return [ [[]], @@ -102,7 +106,7 @@ public function voteInvalidAttributeProvider() new Attribute( 'foo', 'bar', - ['valueObject' => $this->getMockForAbstractClass(ValueObject::class)] + ['valueObject' => self::createStub(ValueObject::class)] ), ], false, @@ -110,10 +114,8 @@ public function voteInvalidAttributeProvider() ]; } - /** - * @dataProvider voteProvider - */ - public function testVote(Attribute $attribute, $repositoryCanUser, $expectedResult) + #[DataProvider('voteProvider')] + public function testVote(Attribute $attribute, $repositoryCanUser, $expectedResult): void { $voter = new CoreVoter($this->permissionResolver); if ($repositoryCanUser !== null) { @@ -131,14 +133,17 @@ public function testVote(Attribute $attribute, $repositoryCanUser, $expectedResu self::assertSame( $expectedResult, $voter->vote( - $this->createMock(TokenInterface::class), + self::createStub(TokenInterface::class), new \stdClass(), [$attribute] ) ); } - public function voteProvider() + /** + * @return array + */ + public static function voteProvider(): array { return [ [ @@ -166,8 +171,8 @@ public function voteProvider() 'content', 'read', [ - 'valueObject' => $this->getMockForAbstractClass(ValueObject::class), - 'targets' => $this->getMockForAbstractClass(ValueObject::class), + 'valueObject' => self::createStub(ValueObject::class), + 'targets' => self::createStub(ValueObject::class), ] ), null, @@ -178,8 +183,8 @@ public function voteProvider() 'content', 'read', [ - 'valueObject' => $this->getMockForAbstractClass(ValueObject::class), - 'targets' => [$this->getMockForAbstractClass(ValueObject::class)], + 'valueObject' => self::createStub(ValueObject::class), + 'targets' => [self::createStub(ValueObject::class)], ] ), null, @@ -190,8 +195,8 @@ public function voteProvider() 'content', 'read', [ - 'valueObject' => $this->getMockForAbstractClass(ValueObject::class), - 'targets' => $this->getMockForAbstractClass(ValueObject::class), + 'valueObject' => self::createStub(ValueObject::class), + 'targets' => self::createStub(ValueObject::class), ] ), null, @@ -202,8 +207,8 @@ public function voteProvider() 'content', 'read', [ - 'valueObject' => $this->getMockForAbstractClass(ValueObject::class), - 'targets' => [$this->getMockForAbstractClass(ValueObject::class)], + 'valueObject' => self::createStub(ValueObject::class), + 'targets' => [self::createStub(ValueObject::class)], ] ), null, diff --git a/tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php b/tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php index 971b646df8..465687a78d 100644 --- a/tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php +++ b/tests/lib/MVC/Symfony/Security/Voter/ValueObjectVoterTest.php @@ -12,6 +12,7 @@ use Ibexa\Core\MVC\Symfony\Security\Authorization\Attribute; use Ibexa\Core\MVC\Symfony\Security\Authorization\Voter\ValueObjectVoter; use Ibexa\Core\Repository\Permission\PermissionResolver; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\Security\Core\Authentication\Token\TokenInterface; use Symfony\Component\Security\Core\Authorization\Voter\VoterInterface; @@ -27,16 +28,17 @@ protected function setUp(): void $this->permissionResolver = $this->createMock(PermissionResolver::class); } - /** - * @dataProvider supportsAttributeProvider - */ - public function testSupportsAttribute($attribute, $expectedResult) + #[DataProvider('supportsAttributeProvider')] + public function testSupportsAttribute($attribute, $expectedResult): void { $voter = new ValueObjectVoter($this->permissionResolver); self::assertSame($expectedResult, $voter->supportsAttribute($attribute)); } - public function supportsAttributeProvider() + /** + * @return array + */ + public static function supportsAttributeProvider(): array { return [ ['foo', false], @@ -48,23 +50,24 @@ public function supportsAttributeProvider() new Attribute( 'foo', 'bar', - ['valueObject' => $this->getMockForAbstractClass(ValueObject::class)] + ['valueObject' => self::createStub(ValueObject::class)] ), true, ], ]; } - /** - * @dataProvider supportsClassProvider - */ - public function testSupportsClass($class) + #[DataProvider('supportsClassProvider')] + public function testSupportsClass($class): void { $voter = new ValueObjectVoter($this->permissionResolver); self::assertTrue($voter->supportsClass($class)); } - public function supportsClassProvider() + /** + * @return array + */ + public static function supportsClassProvider(): array { return [ ['foo'], @@ -74,23 +77,24 @@ public function supportsClassProvider() ]; } - /** - * @dataProvider voteInvalidAttributeProvider - */ - public function testVoteInvalidAttribute(array $attributes) + #[DataProvider('voteInvalidAttributeProvider')] + public function testVoteInvalidAttribute(array $attributes): void { $voter = new ValueObjectVoter($this->permissionResolver); self::assertSame( VoterInterface::ACCESS_ABSTAIN, $voter->vote( - $this->createMock(TokenInterface::class), + self::createStub(TokenInterface::class), new \stdClass(), $attributes ) ); } - public function voteInvalidAttributeProvider() + /** + * @return array + */ + public static function voteInvalidAttributeProvider(): array { return [ [[]], @@ -101,10 +105,8 @@ public function voteInvalidAttributeProvider() ]; } - /** - * @dataProvider voteProvider - */ - public function testVote(Attribute $attribute, $repositoryCanUser, $expectedResult) + #[DataProvider('voteProvider')] + public function testVote(Attribute $attribute, $repositoryCanUser, $expectedResult): void { $voter = new ValueObjectVoter($this->permissionResolver); $targets = isset($attribute->limitations['targets']) ? $attribute->limitations['targets'] : []; @@ -117,30 +119,29 @@ public function testVote(Attribute $attribute, $repositoryCanUser, $expectedResu self::assertSame( $expectedResult, $voter->vote( - $this->createMock(TokenInterface::class), + self::createStub(TokenInterface::class), new \stdClass(), [$attribute] ) ); } - public function voteProvider() + /** + * @return array + */ + public static function voteProvider(): array { return [ [ new Attribute('content', 'read', [ - 'valueObject' => $this->getMockForAbstractClass( - ValueObject::class - ), + 'valueObject' => self::createStub(ValueObject::class), ]), true, VoterInterface::ACCESS_GRANTED, ], [ new Attribute('content', 'read', [ - 'valueObject' => $this->getMockForAbstractClass( - ValueObject::class - ), + 'valueObject' => self::createStub(ValueObject::class), ]), false, VoterInterface::ACCESS_DENIED, @@ -150,8 +151,8 @@ public function voteProvider() 'content', 'read', [ - 'valueObject' => $this->getMockForAbstractClass(ValueObject::class), - 'targets' => [$this->getMockForAbstractClass(ValueObject::class)], + 'valueObject' => self::createStub(ValueObject::class), + 'targets' => [self::createStub(ValueObject::class)], ] ), true, @@ -162,8 +163,8 @@ public function voteProvider() 'content', 'read', [ - 'valueObject' => $this->getMockForAbstractClass(ValueObject::class), - 'targets' => [$this->getMockForAbstractClass(ValueObject::class)], + 'valueObject' => self::createStub(ValueObject::class), + 'targets' => [self::createStub(ValueObject::class)], ] ), true, @@ -174,8 +175,8 @@ public function voteProvider() 'content', 'read', [ - 'valueObject' => $this->getMockForAbstractClass(ValueObject::class), - 'targets' => [$this->getMockForAbstractClass(ValueObject::class)], + 'valueObject' => self::createStub(ValueObject::class), + 'targets' => [self::createStub(ValueObject::class)], ] ), false, @@ -186,8 +187,8 @@ public function voteProvider() 'content', 'read', [ - 'valueObject' => $this->getMockForAbstractClass(ValueObject::class), - 'targets' => [$this->getMockForAbstractClass(ValueObject::class)], + 'valueObject' => self::createStub(ValueObject::class), + 'targets' => [self::createStub(ValueObject::class)], ] ), false, diff --git a/tests/lib/MVC/Symfony/SiteAccess/Compound/CompoundAndTest.php b/tests/lib/MVC/Symfony/SiteAccess/Compound/CompoundAndTest.php index 63db1fe238..243076e996 100644 --- a/tests/lib/MVC/Symfony/SiteAccess/Compound/CompoundAndTest.php +++ b/tests/lib/MVC/Symfony/SiteAccess/Compound/CompoundAndTest.php @@ -15,6 +15,8 @@ use Ibexa\Core\MVC\Symfony\SiteAccess\MatcherBuilder; use Ibexa\Core\MVC\Symfony\SiteAccess\MatcherBuilderInterface; use Ibexa\Core\MVC\Symfony\SiteAccess\VersatileMatcher; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; @@ -65,18 +67,16 @@ private function buildMatcher(): LogicalAnd ); } - /** - * @depends testConstruct - */ + #[Depends('testConstruct')] public function testSetMatcherBuilder(Compound $compoundMatcher): void { $this ->matcherBuilder ->expects(self::any()) ->method('buildMatcher') - ->will(self::returnValue($this->createMock(Matcher::class))); + ->will(self::returnValue(self::createStub(Matcher::class))); - $compoundMatcher->setRequest($this->createMock(SimplifiedRequest::class)); + $compoundMatcher->setRequest(self::createStub(SimplifiedRequest::class)); $compoundMatcher->setMatcherBuilder($this->matcherBuilder); $matchers = $compoundMatcher->getSubMatchers(); self::assertIsArray($matchers); @@ -86,11 +86,10 @@ public function testSetMatcherBuilder(Compound $compoundMatcher): void } /** - * @dataProvider matchProvider - * * @param \Ibexa\Core\MVC\Symfony\Routing\SimplifiedRequest $request * @param $expectedMatch */ + #[DataProvider('matchProvider')] public function testMatch(SimplifiedRequest $request, $expectedMatch): void { $compoundMatcher = $this->buildMatcher(); @@ -120,7 +119,7 @@ public function testSetRequest(): void ->method('buildMatcher') ->will(self::onConsecutiveCalls($matcher1, $matcher2)); - $request = $this->createMock(SimplifiedRequest::class); + $request = self::createStub(SimplifiedRequest::class); $matcher1 ->expects(self::once()) ->method('setRequest') @@ -130,12 +129,12 @@ public function testSetRequest(): void ->method('setRequest') ->with($request); - $compoundMatcher->setRequest($this->createMock(SimplifiedRequest::class)); + $compoundMatcher->setRequest(self::createStub(SimplifiedRequest::class)); $compoundMatcher->setMatcherBuilder($this->matcherBuilder); $compoundMatcher->setRequest($request); } - public function matchProvider(): array + public static function matchProvider(): array { return [ [SimplifiedRequest::fromUrl('http://fr.ezpublish.dev/eng'), 'fr_eng'], @@ -155,16 +154,16 @@ public function testReverseMatchSiteAccessNotConfigured(): void $this->matcherBuilder ->expects(self::any()) ->method('buildMatcher') - ->will(self::returnValue($this->createMock(VersatileMatcher::class))); + ->will(self::returnValue(self::createStub(VersatileMatcher::class))); - $compoundMatcher->setRequest($this->createMock(SimplifiedRequest::class)); + $compoundMatcher->setRequest(self::createStub(SimplifiedRequest::class)); $compoundMatcher->setMatcherBuilder($this->matcherBuilder); self::assertNull($compoundMatcher->reverseMatch('not_configured_sa')); } public function testReverseMatchNotVersatile(): void { - $request = $this->createMock(SimplifiedRequest::class); + $request = self::createStub(SimplifiedRequest::class); $siteAccessName = 'fr_eng'; $mapUriConfig = ['eng' => true]; $mapHostConfig = ['fr.ezpublish.dev' => true]; @@ -184,7 +183,7 @@ public function testReverseMatchNotVersatile(): void $matcher1 = $this->createMock(VersatileMatcher::class); $matcher2 = $this->getMockBuilder(Matcher::class) ->disableOriginalConstructor() - ->setMethods(['reverseMatch']) + ->addMethods(['reverseMatch']) ->getMockForAbstractClass(); $this->matcherBuilder @@ -203,7 +202,7 @@ public function testReverseMatchNotVersatile(): void ->expects(self::once()) ->method('reverseMatch') ->with($siteAccessName) - ->will(self::returnValue($this->createMock(VersatileMatcher::class))); + ->will(self::returnValue(self::createStub(VersatileMatcher::class))); $matcher2 ->expects(self::never()) ->method('reverseMatch'); @@ -214,7 +213,7 @@ public function testReverseMatchNotVersatile(): void public function testReverseMatchFail(): void { - $request = $this->createMock(SimplifiedRequest::class); + $request = self::createStub(SimplifiedRequest::class); $siteAccessName = 'fr_eng'; $mapUriConfig = ['eng' => true]; $mapHostConfig = ['fr.ezpublish.dev' => true]; @@ -249,7 +248,7 @@ public function testReverseMatchFail(): void ->expects(self::once()) ->method('reverseMatch') ->with($siteAccessName) - ->will(self::returnValue($this->createMock(VersatileMatcher::class))); + ->will(self::returnValue(self::createStub(VersatileMatcher::class))); $matcher2 ->expects(self::once()) ->method('reverseMatch') @@ -262,7 +261,7 @@ public function testReverseMatchFail(): void public function testReverseMatch(): void { - $request = $this->createMock(SimplifiedRequest::class); + $request = self::createStub(SimplifiedRequest::class); $siteAccessName = 'fr_eng'; $mapUriConfig = ['eng' => true]; $mapHostConfig = ['fr.ezpublish.dev' => true]; @@ -293,13 +292,13 @@ public function testReverseMatch(): void ) ); - $reverseMatchedMatcher1 = $this->createMock(VersatileMatcher::class); + $reverseMatchedMatcher1 = self::createStub(VersatileMatcher::class); $matcher1 ->expects(self::once()) ->method('reverseMatch') ->with($siteAccessName) ->will(self::returnValue($reverseMatchedMatcher1)); - $reverseMatchedMatcher2 = $this->createMock(VersatileMatcher::class); + $reverseMatchedMatcher2 = self::createStub(VersatileMatcher::class); $matcher2 ->expects(self::once()) ->method('reverseMatch') diff --git a/tests/lib/MVC/Symfony/SiteAccess/Compound/CompoundOrTest.php b/tests/lib/MVC/Symfony/SiteAccess/Compound/CompoundOrTest.php index 47d2d38759..191ff40d5d 100644 --- a/tests/lib/MVC/Symfony/SiteAccess/Compound/CompoundOrTest.php +++ b/tests/lib/MVC/Symfony/SiteAccess/Compound/CompoundOrTest.php @@ -15,6 +15,8 @@ use Ibexa\Core\MVC\Symfony\SiteAccess\MatcherBuilder; use Ibexa\Core\MVC\Symfony\SiteAccess\MatcherBuilderInterface; use Ibexa\Core\MVC\Symfony\SiteAccess\VersatileMatcher; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; @@ -55,17 +57,15 @@ private function buildMatcher(): LogicalOr ); } - /** - * @depends testConstruct - */ + #[Depends('testConstruct')] public function testSetMatcherBuilder(Compound $compoundMatcher): void { $this->matcherBuilder ->expects(self::any()) ->method('buildMatcher') - ->will(self::returnValue($this->createMock(Matcher::class))); + ->will(self::returnValue(self::createStub(Matcher::class))); - $compoundMatcher->setRequest($this->createMock(SimplifiedRequest::class)); + $compoundMatcher->setRequest(self::createStub(SimplifiedRequest::class)); $compoundMatcher->setMatcherBuilder($this->matcherBuilder); $matchers = $compoundMatcher->getSubMatchers(); self::assertIsArray($matchers); @@ -75,11 +75,10 @@ public function testSetMatcherBuilder(Compound $compoundMatcher): void } /** - * @dataProvider matchProvider - * * @param \Ibexa\Core\MVC\Symfony\Routing\SimplifiedRequest $request * @param string $expectedMatch */ + #[DataProvider('matchProvider')] public function testMatch(SimplifiedRequest $request, $expectedMatch): void { $compoundMatcher = $this->buildMatcher(); @@ -88,7 +87,7 @@ public function testMatch(SimplifiedRequest $request, $expectedMatch): void self::assertSame($expectedMatch, $compoundMatcher->match()); } - public function matchProvider(): array + public static function matchProvider(): array { return [ [SimplifiedRequest::fromUrl('http://fr.ezpublish.dev/eng'), 'fr_eng'], @@ -109,16 +108,16 @@ public function testReverseMatchSiteAccessNotConfigured(): void $this->matcherBuilder ->expects(self::any()) ->method('buildMatcher') - ->will(self::returnValue($this->createMock(VersatileMatcher::class))); + ->will(self::returnValue(self::createStub(VersatileMatcher::class))); - $compoundMatcher->setRequest($this->createMock(SimplifiedRequest::class)); + $compoundMatcher->setRequest(self::createStub(SimplifiedRequest::class)); $compoundMatcher->setMatcherBuilder($this->matcherBuilder); self::assertNull($compoundMatcher->reverseMatch('not_configured_sa')); } public function testReverseMatchNotVersatile(): void { - $request = $this->createMock(SimplifiedRequest::class); + $request = self::createStub(SimplifiedRequest::class); $siteAccessName = 'fr_eng'; $mapUriConfig = ['eng' => true]; $mapHostConfig = ['fr.ezpublish.dev' => true]; @@ -137,11 +136,11 @@ public function testReverseMatchNotVersatile(): void $matcher1 = $this->getMockBuilder(Matcher::class) ->disableOriginalConstructor() - ->setMethods(['reverseMatch']) + ->addMethods(['reverseMatch']) ->getMockForAbstractClass(); $matcher2 = $this->getMockBuilder(Matcher::class) ->disableOriginalConstructor() - ->setMethods(['reverseMatch']) + ->addMethods(['reverseMatch']) ->getMockForAbstractClass(); $this->matcherBuilder @@ -169,7 +168,7 @@ public function testReverseMatchNotVersatile(): void public function testReverseMatchFail(): void { - $request = $this->createMock(SimplifiedRequest::class); + $request = self::createStub(SimplifiedRequest::class); $siteAccessName = 'fr_eng'; $mapUriConfig = ['eng' => true]; $mapHostConfig = ['fr.ezpublish.dev' => true]; @@ -217,7 +216,7 @@ public function testReverseMatchFail(): void public function testReverseMatch1(): void { - $request = $this->createMock(SimplifiedRequest::class); + $request = self::createStub(SimplifiedRequest::class); $siteAccessName = 'fr_eng'; $mapUriConfig = ['eng' => true]; $mapHostConfig = ['fr.ezpublish.dev' => true]; @@ -248,7 +247,7 @@ public function testReverseMatch1(): void ) ); - $reverseMatchedMatcher1 = $this->createMock(VersatileMatcher::class); + $reverseMatchedMatcher1 = self::createStub(VersatileMatcher::class); $matcher1 ->expects(self::once()) ->method('reverseMatch') @@ -268,7 +267,7 @@ public function testReverseMatch1(): void public function testReverseMatch2(): void { - $request = $this->createMock(SimplifiedRequest::class); + $request = self::createStub(SimplifiedRequest::class); $siteAccessName = 'fr_eng'; $mapUriConfig = ['eng' => true]; $mapHostConfig = ['fr.ezpublish.dev' => true]; @@ -304,7 +303,7 @@ public function testReverseMatch2(): void ->method('reverseMatch') ->with($siteAccessName) ->will(self::returnValue(null)); - $reverseMatchedMatcher2 = $this->createMock(VersatileMatcher::class); + $reverseMatchedMatcher2 = self::createStub(VersatileMatcher::class); $matcher2 ->expects(self::once()) ->method('reverseMatch') diff --git a/tests/lib/MVC/Symfony/SiteAccess/MatcherSerializationTest.php b/tests/lib/MVC/Symfony/SiteAccess/MatcherSerializationTest.php index 597646267f..37553a0d38 100644 --- a/tests/lib/MVC/Symfony/SiteAccess/MatcherSerializationTest.php +++ b/tests/lib/MVC/Symfony/SiteAccess/MatcherSerializationTest.php @@ -11,15 +11,14 @@ use Ibexa\Core\MVC\Symfony\SiteAccess\Matcher; use Ibexa\Core\MVC\Symfony\SiteAccess\Matcher\Compound\LogicalAnd; use Ibexa\Core\MVC\Symfony\SiteAccess\Matcher\Compound\LogicalOr; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; class MatcherSerializationTest extends TestCase { use SerializerTrait; - /** - * @dataProvider matcherProvider - */ + #[DataProvider('matcherProvider')] public function testDeserialize(Matcher $matcher, ?Matcher $expected = null): void { $serializedMatcher = $this->serializeMatcher($matcher); @@ -55,7 +54,7 @@ private function deserializeMatcher(string $serializedMatcher, string $matcherFQ /** * @return iterable */ - public function matcherProvider(): iterable + public static function matcherProvider(): iterable { $subMatchers = [ Matcher\Map\URI::class => new Matcher\Map\URI(['campaign' => 'event']), @@ -121,9 +120,9 @@ public function matcherProvider(): iterable ] ), ]; - yield 'MapURI' => $this->getMapURIMatcherTestCase(); - yield 'MapPort' => $this->getMapPortMatcherTestCase(); - yield 'MapHost' => $this->getMapHostMatcherTestCase(); + yield 'MapURI' => self::getMapURIMatcherTestCase(); + yield 'MapPort' => self::getMapPortMatcherTestCase(); + yield 'MapHost' => self::getMapHostMatcherTestCase(); yield 'CompoundAnd' => [ $logicalAnd, $expectedLogicalAnd, @@ -137,7 +136,7 @@ public function matcherProvider(): iterable /** * @return array{\Ibexa\Core\MVC\Symfony\SiteAccess\Matcher, \Ibexa\Core\MVC\Symfony\SiteAccess\Matcher} */ - private function getMapPortMatcherTestCase(): array + private static function getMapPortMatcherTestCase(): array { $matcherBeforeSerialization = new Matcher\Map\Port(['8080' => 'event']); $matcherBeforeSerialization->setMapKey('8080'); @@ -151,7 +150,7 @@ private function getMapPortMatcherTestCase(): array /** * @return array{\Ibexa\Core\MVC\Symfony\SiteAccess\Matcher, \Ibexa\Core\MVC\Symfony\SiteAccess\Matcher} */ - private function getMapHostMatcherTestCase(): array + private static function getMapHostMatcherTestCase(): array { $matcherBeforeSerialization = new Matcher\Map\Host(['map' => 'site']); $matcherBeforeSerialization->setMapKey('map'); @@ -165,7 +164,7 @@ private function getMapHostMatcherTestCase(): array /** * @return array{\Ibexa\Core\MVC\Symfony\SiteAccess\Matcher, \Ibexa\Core\MVC\Symfony\SiteAccess\Matcher} */ - private function getMapURIMatcherTestCase(): array + private static function getMapURIMatcherTestCase(): array { $matcherBeforeSerialization = new Matcher\Map\URI(['www.example.org' => 'event_site']); $matcherBeforeSerialization->setMapKey('www.example.org'); diff --git a/tests/lib/MVC/Symfony/SiteAccess/Provider/ChainSiteAccessProviderTest.php b/tests/lib/MVC/Symfony/SiteAccess/Provider/ChainSiteAccessProviderTest.php index c774ec8d2b..d5f904516e 100644 --- a/tests/lib/MVC/Symfony/SiteAccess/Provider/ChainSiteAccessProviderTest.php +++ b/tests/lib/MVC/Symfony/SiteAccess/Provider/ChainSiteAccessProviderTest.php @@ -14,6 +14,7 @@ use Ibexa\Core\MVC\Symfony\SiteAccess\Provider\ChainSiteAccessProvider; use Ibexa\Core\MVC\Symfony\SiteAccess\Provider\StaticSiteAccessProvider; use Ibexa\Core\MVC\Symfony\SiteAccessGroup; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; final class ChainSiteAccessProviderTest extends TestCase @@ -45,7 +46,7 @@ protected function setUp(): void ]; } - public function siteAccessNamesProvider(): array + public static function siteAccessNamesProvider(): array { return [ 'existing_sa' => [self::EXISTING_SA_NAME], @@ -53,9 +54,7 @@ public function siteAccessNamesProvider(): array ]; } - /** - * @dataProvider siteAccessNamesProvider - */ + #[DataProvider('siteAccessNamesProvider')] public function testIsDefined(string $siteAccessName): void { $chainSiteAccessProvider = $this->getChainSiteAccessProvider(); @@ -104,7 +103,7 @@ public function testGetSiteAccesses(): void ); } - public function getExistingSiteProvider(): array + public static function getExistingSiteProvider(): array { return [ 'existing_sa' => [self::EXISTING_SA_NAME, [self::SA_GROUP]], @@ -113,12 +112,11 @@ public function getExistingSiteProvider(): array } /** - * @dataProvider getExistingSiteProvider - * * @param string[] $expectedGroups * * @throws \Ibexa\Core\Base\Exceptions\NotFoundException */ + #[DataProvider('getExistingSiteProvider')] public function testGetExistingSiteAccess(string $siteAccessName, array $expectedGroups): void { $chainSiteAccessProvider = $this->getChainSiteAccessProvider(); diff --git a/tests/lib/MVC/Symfony/SiteAccess/RouterBaseTestCase.php b/tests/lib/MVC/Symfony/SiteAccess/RouterBaseTestCase.php index 599c451a24..6e62d437df 100644 --- a/tests/lib/MVC/Symfony/SiteAccess/RouterBaseTestCase.php +++ b/tests/lib/MVC/Symfony/SiteAccess/RouterBaseTestCase.php @@ -12,6 +12,7 @@ use Ibexa\Core\MVC\Symfony\SiteAccess; use Ibexa\Core\MVC\Symfony\SiteAccess\MatcherBuilder; use Ibexa\Core\MVC\Symfony\SiteAccess\Router; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; abstract class RouterBaseTestCase extends TestCase @@ -40,10 +41,8 @@ public function testConstruct(): Router return $this->createRouter(); } - /** - * @dataProvider matchProvider - */ - public function testMatch(SimplifiedRequest $request, string $siteAccess) + #[DataProvider('matchProvider')] + public function testMatch(SimplifiedRequest $request, string $siteAccess): void { $router = $this->createRouter(); $sa = $router->match($request); @@ -54,7 +53,7 @@ public function testMatch(SimplifiedRequest $request, string $siteAccess) $router->setSiteAccess(); } - abstract public function matchProvider(): array; + abstract public static function matchProvider(): array; abstract protected function createRouter(): Router; diff --git a/tests/lib/MVC/Symfony/SiteAccess/RouterHostElementTest.php b/tests/lib/MVC/Symfony/SiteAccess/RouterHostElementTest.php index 8470fbcff6..a563c3b3d5 100644 --- a/tests/lib/MVC/Symfony/SiteAccess/RouterHostElementTest.php +++ b/tests/lib/MVC/Symfony/SiteAccess/RouterHostElementTest.php @@ -12,11 +12,12 @@ use Ibexa\Core\MVC\Symfony\SiteAccess\Matcher\HostElement; use Ibexa\Core\MVC\Symfony\SiteAccess\Matcher\Map\Host as HostMapMatcher; use Ibexa\Core\MVC\Symfony\SiteAccess\Router; +use PHPUnit\Framework\Attributes\DataProvider; use Psr\Log\LoggerInterface; class RouterHostElementTest extends RouterBaseTestCase { - public function matchProvider(): array + public static function matchProvider(): array { return [ [SimplifiedRequest::fromUrl('http://www.example.com'), 'example'], @@ -73,7 +74,7 @@ public function matchProvider(): array ]; } - public function testGetName() + public function testGetName(): void { $matcher = new HostMapMatcher(['host' => 'foo'], []); self::assertSame('host:map', $matcher->getName()); @@ -82,10 +83,8 @@ public function testGetName() self::assertSame('host:element', $matcherHostElement->getName()); } - /** - * @dataProvider reverseMatchProvider - */ - public function testReverseMatch($siteAccessName, $elementNumber, SimplifiedRequest $request, $expectedHost) + #[DataProvider('reverseMatchProvider')] + public function testReverseMatch($siteAccessName, $elementNumber, SimplifiedRequest $request, $expectedHost): void { $matcher = new HostElement([$elementNumber]); $matcher->setRequest($request); @@ -94,7 +93,10 @@ public function testReverseMatch($siteAccessName, $elementNumber, SimplifiedRequ self::assertSame($expectedHost, $result->getRequest()->getHost()); } - public function reverseMatchProvider() + /** + * @return array + */ + public static function reverseMatchProvider(): array { return [ ['foo', 1, SimplifiedRequest::fromUrl('http://bar.example.com/'), 'foo.example.com'], @@ -104,14 +106,14 @@ public function reverseMatchProvider() ]; } - public function testReverseMatchFail() + public function testReverseMatchFail(): void { $matcher = new HostElement([3]); $matcher->setRequest(new SimplifiedRequest('http', 'ibexa.co')); self::assertNull($matcher->reverseMatch('foo')); } - public function testSerialize() + public function testSerialize(): void { $matcher = new HostElement([1]); $matcher->setRequest(new SimplifiedRequest('http', 'ibexa.co', 80, '/foo/bar')); @@ -128,7 +130,7 @@ protected function createRouter(): Router { return new Router( $this->matcherBuilder, - $this->createMock(LoggerInterface::class), + self::createStub(LoggerInterface::class), 'default_sa', [ 'HostElement' => [ diff --git a/tests/lib/MVC/Symfony/SiteAccess/RouterHostPortURITest.php b/tests/lib/MVC/Symfony/SiteAccess/RouterHostPortURITest.php index 1693f769b3..ca0ce705a9 100644 --- a/tests/lib/MVC/Symfony/SiteAccess/RouterHostPortURITest.php +++ b/tests/lib/MVC/Symfony/SiteAccess/RouterHostPortURITest.php @@ -15,7 +15,7 @@ class RouterHostPortURITest extends RouterBaseTestCase { - public function matchProvider(): array + public static function matchProvider(): array { return [ [SimplifiedRequest::fromUrl('http://example.com'), 'fifth_sa'], @@ -83,7 +83,7 @@ public function matchProvider(): array ]; } - public function testSetGetRequestMapHost() + public function testSetGetRequestMapHost(): void { $mapKey = 'phoenix-rises.fm'; $request = new SimplifiedRequest('http', $mapKey); @@ -93,14 +93,14 @@ public function testSetGetRequestMapHost() self::assertSame($mapKey, $matcher->getMapKey()); } - public function testReverseHostMatchFail() + public function testReverseHostMatchFail(): void { $config = ['foo' => 'bar']; $matcher = new Host($config); self::assertNull($matcher->reverseMatch('non_existent')); } - public function testReverseMatchHost() + public function testReverseMatchHost(): void { $config = [ 'ibexa.co' => 'some_siteaccess', @@ -119,7 +119,7 @@ public function testReverseMatchHost() self::assertSame('phoenix-rises.fm', $result->getRequest()->getHost()); } - public function testSetGetRequestMapPort() + public function testSetGetRequestMapPort(): void { $mapKey = 8000; $request = new SimplifiedRequest('http', '', $mapKey); @@ -129,14 +129,14 @@ public function testSetGetRequestMapPort() self::assertSame((string)$mapKey, $matcher->getMapKey()); } - public function testReversePortMatchFail() + public function testReversePortMatchFail(): void { $config = ['foo' => 8080]; $matcher = new Port($config); self::assertNull($matcher->reverseMatch('non_existent')); } - public function testReverseMatchPort() + public function testReverseMatchPort(): void { $config = [ '80' => 'some_siteaccess', @@ -160,7 +160,7 @@ protected function createRouter(): Router { return new Router( $this->matcherBuilder, - $this->createMock(LoggerInterface::class), + self::createStub(LoggerInterface::class), 'default_sa', [ 'Map\\Host' => [ diff --git a/tests/lib/MVC/Symfony/SiteAccess/RouterHostTextTest.php b/tests/lib/MVC/Symfony/SiteAccess/RouterHostTextTest.php index 645b3105ee..79a32f771e 100644 --- a/tests/lib/MVC/Symfony/SiteAccess/RouterHostTextTest.php +++ b/tests/lib/MVC/Symfony/SiteAccess/RouterHostTextTest.php @@ -14,7 +14,7 @@ class RouterHostTextTest extends RouterBaseTestCase { - public function matchProvider(): array + public static function matchProvider(): array { return [ [SimplifiedRequest::fromUrl('http://example.com'), 'default_sa'], @@ -73,13 +73,13 @@ public function matchProvider(): array ]; } - public function testGetName() + public function testGetName(): void { $matcher = new HostTextMatcher(['host' => 'foo'], []); self::assertSame('host:text', $matcher->getName()); } - public function testReverseMatch() + public function testReverseMatch(): void { $matcher = new HostTextMatcher( [ @@ -101,7 +101,7 @@ protected function createRouter(): Router { return new Router( $this->matcherBuilder, - $this->createMock(LoggerInterface::class), + self::createStub(LoggerInterface::class), 'default_sa', [ 'HostText' => [ diff --git a/tests/lib/MVC/Symfony/SiteAccess/RouterMapURITest.php b/tests/lib/MVC/Symfony/SiteAccess/RouterMapURITest.php index a78712c5cc..a5740f6502 100644 --- a/tests/lib/MVC/Symfony/SiteAccess/RouterMapURITest.php +++ b/tests/lib/MVC/Symfony/SiteAccess/RouterMapURITest.php @@ -9,6 +9,7 @@ use Ibexa\Core\MVC\Symfony\Routing\SimplifiedRequest; use Ibexa\Core\MVC\Symfony\SiteAccess\Matcher\Map\URI as URIMapMatcher; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; class RouterMapURITest extends TestCase @@ -17,10 +18,9 @@ class RouterMapURITest extends TestCase * @param array $config * @param string $pathinfo * @param string $expectedMapKey - * - * @dataProvider setRequestProvider */ - public function testSetGetRequest($config, $pathinfo, $expectedMapKey) + #[DataProvider('setRequestProvider')] + public function testSetGetRequest($config, $pathinfo, $expectedMapKey): void { $request = new SimplifiedRequest('http', '', 80, $pathinfo); $matcher = new URIMapMatcher($config); @@ -32,10 +32,9 @@ public function testSetGetRequest($config, $pathinfo, $expectedMapKey) /** * @param string $uri * @param string $expectedFixedUpURI - * - * @dataProvider fixupURIProvider */ - public function testAnalyseURI($uri, $expectedFixedUpURI) + #[DataProvider('fixupURIProvider')] + public function testAnalyseURI($uri, $expectedFixedUpURI): void { $matcher = new URIMapMatcher([]); $matcher->setRequest( @@ -50,10 +49,9 @@ public function testAnalyseURI($uri, $expectedFixedUpURI) /** * @param string $fullUri * @param string $linkUri - * - * @dataProvider fixupURIProvider */ - public function testAnalyseLink($fullUri, $linkUri) + #[DataProvider('fixupURIProvider')] + public function testAnalyseLink($fullUri, $linkUri): void { $matcher = new URIMapMatcher([]); $matcher->setRequest( @@ -65,7 +63,10 @@ public function testAnalyseLink($fullUri, $linkUri) self::assertSame($fullUri, $unserializedMatcher->analyseLink($linkUri)); } - public function setRequestProvider() + /** + * @return array + */ + public static function setRequestProvider(): array { return [ [['foo' => 'bar'], '/bar/baz', 'bar'], @@ -73,7 +74,10 @@ public function setRequestProvider() ]; } - public function fixupURIProvider() + /** + * @return array + */ + public static function fixupURIProvider(): array { return [ ['/foo', '/'], @@ -86,14 +90,14 @@ public function fixupURIProvider() ]; } - public function testReverseMatchFail() + public function testReverseMatchFail(): void { $config = ['foo' => 'bar']; $matcher = new URIMapMatcher($config); self::assertNull($matcher->reverseMatch('non_existent')); } - public function testReverseMatch() + public function testReverseMatch(): void { $config = [ 'some_uri' => 'some_siteaccess', diff --git a/tests/lib/MVC/Symfony/SiteAccess/RouterPortHostURITest.php b/tests/lib/MVC/Symfony/SiteAccess/RouterPortHostURITest.php index 05b8ad065c..b2f737ae97 100644 --- a/tests/lib/MVC/Symfony/SiteAccess/RouterPortHostURITest.php +++ b/tests/lib/MVC/Symfony/SiteAccess/RouterPortHostURITest.php @@ -13,7 +13,7 @@ class RouterPortHostURITest extends RouterBaseTestCase { - public function matchProvider(): array + public static function matchProvider(): array { return [ [SimplifiedRequest::fromUrl('http://example.com'), 'fifth_sa'], @@ -85,7 +85,7 @@ protected function createRouter(): Router { return new Router( $this->matcherBuilder, - $this->createMock(LoggerInterface::class), + self::createStub(LoggerInterface::class), 'default_sa', [ 'Map\\Port' => [ diff --git a/tests/lib/MVC/Symfony/SiteAccess/RouterSpecialPortsTest.php b/tests/lib/MVC/Symfony/SiteAccess/RouterSpecialPortsTest.php index 3855def8f3..1db63dfa15 100644 --- a/tests/lib/MVC/Symfony/SiteAccess/RouterSpecialPortsTest.php +++ b/tests/lib/MVC/Symfony/SiteAccess/RouterSpecialPortsTest.php @@ -14,7 +14,7 @@ class RouterSpecialPortsTest extends RouterBaseTestCase { - public function matchProvider(): array + public static function matchProvider(): array { return [ [SimplifiedRequest::fromUrl('http://example.com'), 'fifth_sa'], @@ -75,7 +75,7 @@ public function matchProvider(): array ]; } - public function testGetName() + public function testGetName(): void { $matcher = new PortMatcher(['port' => '8080', 'scheme' => 'http'], []); self::assertSame('port', $matcher->getName()); @@ -85,7 +85,7 @@ protected function createRouter(): Router { return new Router( $this->matcherBuilder, - $this->createMock(LoggerInterface::class), + self::createStub(LoggerInterface::class), 'default_sa', [ 'Map\\URI' => [ diff --git a/tests/lib/MVC/Symfony/SiteAccess/RouterTest.php b/tests/lib/MVC/Symfony/SiteAccess/RouterTest.php index 2f01b39b2e..239b41c474 100644 --- a/tests/lib/MVC/Symfony/SiteAccess/RouterTest.php +++ b/tests/lib/MVC/Symfony/SiteAccess/RouterTest.php @@ -14,6 +14,7 @@ use Ibexa\Core\MVC\Symfony\SiteAccess\MatcherBuilderInterface; use Ibexa\Core\MVC\Symfony\SiteAccess\Router; use Ibexa\Core\MVC\Symfony\SiteAccess\VersatileMatcher; +use PHPUnit\Framework\Attributes\DataProvider; use Psr\Log\LoggerInterface; use Symfony\Component\HttpFoundation\Request; @@ -30,10 +31,8 @@ public function testConstructDebug() return $this->createRouter(true); } - /** - * @dataProvider matchProvider - */ - public function testMatch(SimplifiedRequest $request, $siteAccess) + #[DataProvider('matchProvider')] + public function testMatch(SimplifiedRequest $request, $siteAccess): void { $router = $this->createRouter(); $sa = $router->match($request); @@ -44,7 +43,7 @@ public function testMatch(SimplifiedRequest $request, $siteAccess) $router->setSiteAccess(); } - public function testMatchWithDevEnvFail() + public function testMatchWithDevEnvFail(): void { $router = $this->createRouter(true); putenv('EZPUBLISH_SITEACCESS=' . self::UNDEFINED_SA_NAME); @@ -57,7 +56,7 @@ public function testMatchWithDevEnvFail() $router->match(new SimplifiedRequest()); } - public function testMatchWithProdEnvFail() + public function testMatchWithProdEnvFail(): void { $router = $this->createRouter(); putenv('EZPUBLISH_SITEACCESS=' . self::UNDEFINED_SA_NAME); @@ -70,7 +69,7 @@ public function testMatchWithProdEnvFail() $router->match(new SimplifiedRequest()); } - public function testMatchWithEnv() + public function testMatchWithEnv(): void { $router = $this->createRouter(); putenv('EZPUBLISH_SITEACCESS=' . self::ENV_SA_NAME); @@ -99,7 +98,7 @@ public function testMatchWithRequestHeader(): void $router->setSiteAccess(); } - public function matchProvider(): array + public static function matchProvider(): array { return [ [SimplifiedRequest::fromUrl('http://example.com'), 'default_sa'], @@ -163,12 +162,12 @@ public function matchProvider(): array ]; } - public function testMatchByNameInvalidSiteAccess() + public function testMatchByNameInvalidSiteAccess(): void { $this->expectException(\InvalidArgumentException::class); - $matcherBuilder = $this->createMock(MatcherBuilderInterface::class); - $logger = $this->createMock(LoggerInterface::class); + $matcherBuilder = self::createStub(MatcherBuilderInterface::class); + $logger = self::createStub(LoggerInterface::class); $siteAccessProvider = $this->createMock(SiteAccess\SiteAccessProviderInterface::class); $siteAccessProvider ->method('isDefined') @@ -178,10 +177,10 @@ public function testMatchByNameInvalidSiteAccess() $router->matchByName('bar'); } - public function testMatchByName() + public function testMatchByName(): void { $matcherBuilder = $this->createMock(MatcherBuilderInterface::class); - $logger = $this->createMock(LoggerInterface::class); + $logger = self::createStub(LoggerInterface::class); $matcherClass = 'Map\Host'; $matchedSiteAccess = 'foo'; $matcherConfig = [ @@ -212,12 +211,12 @@ public function testMatchByName() ->method('buildMatcher') ->will( self::onConsecutiveCalls( - $this->createMock(Matcher::class), + self::createStub(Matcher::class), $matcher ) ); - $reverseMatchedMatcher = $this->createMock(VersatileMatcher::class); + $reverseMatchedMatcher = self::createStub(VersatileMatcher::class); $matcher ->expects(self::once()) ->method('reverseMatch') @@ -230,7 +229,7 @@ public function testMatchByName() self::assertSame($matchedSiteAccess, $siteAccess->name); } - public function testMatchByNameNoVersatileMatcher() + public function testMatchByNameNoVersatileMatcher(): void { $matcherBuilder = $this->createMock(MatcherBuilderInterface::class); $logger = $this->createMock(LoggerInterface::class); @@ -254,7 +253,7 @@ public function testMatchByNameNoVersatileMatcher() ->expects(self::once()) ->method('buildMatcher') ->with($matcherClass, $matcherConfig, $request) - ->will(self::returnValue($this->createMock(Matcher::class))); + ->will(self::returnValue(self::createStub(Matcher::class))); $logger ->expects(self::once()) @@ -266,7 +265,7 @@ protected function createRouter($debug = false): Router { return new Router( $this->matcherBuilder, - $this->createMock(LoggerInterface::class), + self::createStub(LoggerInterface::class), 'default_sa', [ 'Map\\URI' => [ diff --git a/tests/lib/MVC/Symfony/SiteAccess/RouterURIElement2Test.php b/tests/lib/MVC/Symfony/SiteAccess/RouterURIElement2Test.php index 9e31cde1be..f5c6ce4931 100644 --- a/tests/lib/MVC/Symfony/SiteAccess/RouterURIElement2Test.php +++ b/tests/lib/MVC/Symfony/SiteAccess/RouterURIElement2Test.php @@ -12,11 +12,12 @@ use Ibexa\Core\MVC\Symfony\SiteAccess\Matcher\URIElement; use Ibexa\Core\MVC\Symfony\SiteAccess\Matcher\URIElement as URIElementMatcher; use Ibexa\Core\MVC\Symfony\SiteAccess\Router; +use PHPUnit\Framework\Attributes\DataProvider; use Psr\Log\LoggerInterface; class RouterURIElement2Test extends RouterBaseTestCase { - public function matchProvider(): array + public static function matchProvider(): array { return [ [SimplifiedRequest::fromUrl('http://example.com'), 'default_sa'], @@ -71,10 +72,9 @@ public function matchProvider(): array * @param int $level * @param string $uri * @param string $expectedFixedUpURI - * - * @dataProvider analyseProvider */ - public function testAnalyseURI($level, $uri, $expectedFixedUpURI) + #[DataProvider('analyseProvider')] + public function testAnalyseURI($level, $uri, $expectedFixedUpURI): void { $matcher = new URIElementMatcher([$level]); $matcher->setRequest( @@ -87,10 +87,9 @@ public function testAnalyseURI($level, $uri, $expectedFixedUpURI) * @param int $level * @param string $uri * @param string $expectedFixedUpURI - * - * @dataProvider analyseProvider */ - public function testAnalyseURILevelAsInt($level, $uri, $expectedFixedUpURI) + #[DataProvider('analyseProvider')] + public function testAnalyseURILevelAsInt($level, $uri, $expectedFixedUpURI): void { $matcher = new URIElementMatcher($level); $matcher->setRequest( @@ -103,10 +102,9 @@ public function testAnalyseURILevelAsInt($level, $uri, $expectedFixedUpURI) * @param int $level * @param string $fullUri * @param string $linkUri - * - * @dataProvider analyseProvider */ - public function testAnalyseLink($level, $fullUri, $linkUri) + #[DataProvider('analyseProvider')] + public function testAnalyseLink($level, $fullUri, $linkUri): void { $matcher = new URIElementMatcher([$level]); $matcher->setRequest( @@ -115,7 +113,10 @@ public function testAnalyseLink($level, $fullUri, $linkUri) self::assertSame($fullUri, $matcher->analyseLink($linkUri)); } - public function analyseProvider() + /** + * @return array + */ + public static function analyseProvider(): array { return [ [2, '/my/siteaccess/foo/bar', '/foo/bar'], @@ -133,10 +134,8 @@ public function analyseProvider() ]; } - /** - * @dataProvider reverseMatchProvider - */ - public function testReverseMatch($siteAccessName, $originalPathinfo) + #[DataProvider('reverseMatchProvider')] + public function testReverseMatch($siteAccessName, $originalPathinfo): void { $expectedSiteAccessPath = str_replace('_', '/', $siteAccessName); $matcher = new URIElementMatcher([2]); @@ -149,7 +148,10 @@ public function testReverseMatch($siteAccessName, $originalPathinfo) self::assertSame('/foo/bar/baz', $result->analyseURI("/$expectedSiteAccessPath/foo/bar/baz")); } - public function reverseMatchProvider() + /** + * @return array + */ + public static function reverseMatchProvider(): array { return [ ['some_thing', '/foo/bar'], @@ -157,14 +159,14 @@ public function reverseMatchProvider() ]; } - public function testReverseMatchFail() + public function testReverseMatchFail(): void { $matcher = new URIElementMatcher([2]); $matcher->setRequest(new SimplifiedRequest('http', '', 80, '/my/siteaccess/foo/bar')); self::assertNull($matcher->reverseMatch('another_siteaccess_again_dont_tell_me')); } - public function testSerialize() + public function testSerialize(): void { $matcher = new URIElementMatcher([2]); $matcher->setRequest(new SimplifiedRequest('http', '', 80, '/foo/bar')); @@ -181,7 +183,7 @@ protected function createRouter(): Router { return new Router( $this->matcherBuilder, - $this->createMock(LoggerInterface::class), + self::createStub(LoggerInterface::class), 'default_sa', [ 'URIElement' => [ diff --git a/tests/lib/MVC/Symfony/SiteAccess/RouterURIElementTest.php b/tests/lib/MVC/Symfony/SiteAccess/RouterURIElementTest.php index ff935ccf1b..0ffc4dedc6 100644 --- a/tests/lib/MVC/Symfony/SiteAccess/RouterURIElementTest.php +++ b/tests/lib/MVC/Symfony/SiteAccess/RouterURIElementTest.php @@ -12,11 +12,12 @@ use Ibexa\Core\MVC\Symfony\SiteAccess\Matcher\URIElement; use Ibexa\Core\MVC\Symfony\SiteAccess\Matcher\URIElement as URIElementMatcher; use Ibexa\Core\MVC\Symfony\SiteAccess\Router; +use PHPUnit\Framework\Attributes\DataProvider; use Psr\Log\LoggerInterface; class RouterURIElementTest extends RouterBaseTestCase { - public function matchProvider(): array + public static function matchProvider(): array { return [ [SimplifiedRequest::fromUrl('http://example.com'), 'default_sa'], @@ -67,7 +68,7 @@ public function matchProvider(): array ]; } - public function testGetName() + public function testGetName(): void { $matcher = new URIElementMatcher([]); self::assertSame('uri:element', $matcher->getName()); @@ -76,10 +77,9 @@ public function testGetName() /** * @param string $uri * @param string $expectedFixedUpURI - * - * @dataProvider analyseProvider */ - public function testAnalyseURI($uri, $expectedFixedUpURI) + #[DataProvider('analyseProvider')] + public function testAnalyseURI($uri, $expectedFixedUpURI): void { $matcher = new URIElementMatcher([1]); $matcher->setRequest( @@ -91,10 +91,9 @@ public function testAnalyseURI($uri, $expectedFixedUpURI) /** * @param string $fullUri * @param string $linkUri - * - * @dataProvider analyseProvider */ - public function testAnalyseLink($fullUri, $linkUri) + #[DataProvider('analyseProvider')] + public function testAnalyseLink($fullUri, $linkUri): void { $matcher = new URIElementMatcher([1]); $matcher->setRequest( @@ -103,7 +102,10 @@ public function testAnalyseLink($fullUri, $linkUri) self::assertSame($fullUri, $matcher->analyseLink($linkUri)); } - public function analyseProvider() + /** + * @return array + */ + public static function analyseProvider(): array { return [ ['/my_siteaccess/foo/bar', '/foo/bar'], @@ -111,10 +113,8 @@ public function analyseProvider() ]; } - /** - * @dataProvider reverseMatchProvider - */ - public function testReverseMatch($siteAccessName, $originalPathinfo) + #[DataProvider('reverseMatchProvider')] + public function testReverseMatch($siteAccessName, $originalPathinfo): void { $matcher = new URIElementMatcher([1]); $matcher->setRequest(new SimplifiedRequest('http', '', 80, $originalPathinfo)); @@ -125,7 +125,10 @@ public function testReverseMatch($siteAccessName, $originalPathinfo) self::assertSame('/foo/bar/baz', $result->analyseURI("/$siteAccessName/foo/bar/baz")); } - public function reverseMatchProvider() + /** + * @return array + */ + public static function reverseMatchProvider(): array { return [ ['something', '/foo/bar'], @@ -136,7 +139,7 @@ public function reverseMatchProvider() ]; } - public function testSerialize() + public function testSerialize(): void { $matcher = new URIElementMatcher([1]); $matcher->setRequest(new SimplifiedRequest('http', '', 80, '/foo/bar')); @@ -153,7 +156,7 @@ protected function createRouter(): Router { return new Router( $this->matcherBuilder, - $this->createMock(LoggerInterface::class), + self::createStub(LoggerInterface::class), 'default_sa', [ 'URIElement' => [ diff --git a/tests/lib/MVC/Symfony/SiteAccess/RouterURITextTest.php b/tests/lib/MVC/Symfony/SiteAccess/RouterURITextTest.php index b3002df776..d76f782613 100644 --- a/tests/lib/MVC/Symfony/SiteAccess/RouterURITextTest.php +++ b/tests/lib/MVC/Symfony/SiteAccess/RouterURITextTest.php @@ -15,7 +15,7 @@ class RouterURITextTest extends RouterBaseTestCase { - public function matchProvider(): array + public static function matchProvider(): array { return [ [SimplifiedRequest::fromUrl('http://example.com'), 'default_sa'], @@ -73,13 +73,13 @@ public function matchProvider(): array ]; } - public function testGetName() + public function testGetName(): void { $matcher = new URITextMatcher([], []); self::assertSame('uri:text', $matcher->getName()); } - public function testAnalyseURI() + public function testAnalyseURI(): void { $siteAccessURI = '/footestbar'; $semanticURI = '/something/hoho'; @@ -94,7 +94,7 @@ public function testAnalyseURI() self::assertSame($semanticURI, $matcher->analyseURI($siteAccessURI . $semanticURI)); } - public function testAnalyseLink() + public function testAnalyseLink(): void { $siteAccessURI = '/footestbar'; $semanticURI = '/something/hoho'; @@ -109,7 +109,7 @@ public function testAnalyseLink() self::assertSame($siteAccessURI . $semanticURI, $matcher->analyseLink($semanticURI)); } - public function testReverseMatch() + public function testReverseMatch(): void { $semanticURI = '/hihi/hoho'; $matcher = new URITextMatcher( @@ -131,7 +131,7 @@ protected function createRouter(): Router { return new Router( $this->matcherBuilder, - $this->createMock(LoggerInterface::class), + self::createStub(LoggerInterface::class), 'default_sa', [ 'URIText' => [ diff --git a/tests/lib/MVC/Symfony/SiteAccess/SiteAccessServiceTest.php b/tests/lib/MVC/Symfony/SiteAccess/SiteAccessServiceTest.php index 08cf724234..58056d3e4c 100644 --- a/tests/lib/MVC/Symfony/SiteAccess/SiteAccessServiceTest.php +++ b/tests/lib/MVC/Symfony/SiteAccess/SiteAccessServiceTest.php @@ -53,8 +53,8 @@ protected function setUp(): void public function testGetCurrentSiteAccess(): void { $service = new SiteAccessService( - $this->createMock(SiteAccessProviderInterface::class), - $this->createMock(ConfigResolverInterface::class) + self::createStub(SiteAccessProviderInterface::class), + self::createStub(ConfigResolverInterface::class) ); self::assertNull($service->getCurrent()); @@ -81,8 +81,8 @@ public function testGetSubscribedEvents(): void public function testOnConfigScopeChangeMakesGetCurrentReflectTheNewSiteAccess(): void { $service = new SiteAccessService( - $this->createStub(SiteAccessProviderInterface::class), - $this->createStub(ConfigResolverInterface::class) + self::createStub(SiteAccessProviderInterface::class), + self::createStub(ConfigResolverInterface::class) ); $baseSiteAccess = new SiteAccess('base'); @@ -97,8 +97,8 @@ public function testOnConfigScopeChangeMakesGetCurrentReflectTheNewSiteAccess(): public function testOnConfigScopeRestoreBringsBackThePreviousSiteAccess(): void { $service = new SiteAccessService( - $this->createStub(SiteAccessProviderInterface::class), - $this->createStub(ConfigResolverInterface::class) + self::createStub(SiteAccessProviderInterface::class), + self::createStub(ConfigResolverInterface::class) ); $baseSiteAccess = new SiteAccess('base'); @@ -114,8 +114,8 @@ public function testOnConfigScopeRestoreBringsBackThePreviousSiteAccess(): void public function testOnConfigScopeRestoreNeverDropsTheBaseSiteAccess(): void { $service = new SiteAccessService( - $this->createStub(SiteAccessProviderInterface::class), - $this->createStub(ConfigResolverInterface::class) + self::createStub(SiteAccessProviderInterface::class), + self::createStub(ConfigResolverInterface::class) ); $baseSiteAccess = new SiteAccess('base'); @@ -129,8 +129,8 @@ public function testOnConfigScopeRestoreNeverDropsTheBaseSiteAccess(): void public function testNestedConfigScopeChangesAndRestoresRoundTripLikeAStack(): void { $service = new SiteAccessService( - $this->createStub(SiteAccessProviderInterface::class), - $this->createStub(ConfigResolverInterface::class) + self::createStub(SiteAccessProviderInterface::class), + self::createStub(ConfigResolverInterface::class) ); $baseSiteAccess = new SiteAccess('base'); @@ -160,7 +160,7 @@ public function testGetSiteAccess(): void ); $service = new SiteAccessService( $staticSiteAccessProvider, - $this->createMock(ConfigResolverInterface::class) + self::createStub(ConfigResolverInterface::class) ); self::assertEquals( @@ -177,7 +177,7 @@ public function testGetSiteAccessThrowsNotFoundException(): void ); $service = new SiteAccessService( $staticSiteAccessProvider, - $this->createMock(ConfigResolverInterface::class) + self::createStub(ConfigResolverInterface::class) ); $this->expectException(NotFoundException::class); diff --git a/tests/lib/MVC/Symfony/Templating/GlobalHelperTest.php b/tests/lib/MVC/Symfony/Templating/GlobalHelperTest.php index 5fbbe15c7f..b8fbb2d90b 100644 --- a/tests/lib/MVC/Symfony/Templating/GlobalHelperTest.php +++ b/tests/lib/MVC/Symfony/Templating/GlobalHelperTest.php @@ -14,6 +14,7 @@ use Ibexa\Core\MVC\Symfony\Routing\UrlAliasRouter; use Ibexa\Core\MVC\Symfony\SiteAccess; use Ibexa\Core\MVC\Symfony\Templating\GlobalHelper; +use PHPUnit\Framework\MockObject\Stub; use PHPUnit\Framework\TestCase; use Symfony\Component\DependencyInjection\ContainerInterface; use Symfony\Component\HttpFoundation\Request; @@ -25,8 +26,7 @@ class GlobalHelperTest extends TestCase /** @var \Ibexa\Core\MVC\Symfony\Templating\GlobalHelper */ protected $helper; - /** @var \PHPUnit\Framework\MockObject\MockObject */ - protected $container; + protected ContainerInterface&Stub $container; /** @var \PHPUnit\Framework\MockObject\MockObject */ protected $locationService; @@ -44,7 +44,7 @@ protected function setUp(): void { parent::setUp(); - $this->container = $this->createMock(ContainerInterface::class); + $this->container = self::createStub(ContainerInterface::class); $this->locationService = $this->createMock(LocationService::class); $this->configResolver = $this->createMock(ConfigResolverInterface::class); $this->router = $this->createMock(RouterInterface::class); @@ -52,18 +52,18 @@ protected function setUp(): void $this->helper = new GlobalHelper($this->configResolver, $this->locationService, $this->router, $this->translationHelper); } - public function testGetSiteaccess() + public function testGetSiteaccess(): void { $request = new Request(); $requestStack = new RequestStack([$request]); - $siteAccess = $this->createMock(SiteAccess::class); + $siteAccess = self::createStub(SiteAccess::class); $request->attributes->set('siteaccess', $siteAccess); $this->helper->setRequestStack($requestStack); self::assertSame($siteAccess, $this->helper->getSiteaccess()); } - public function testGetViewParameters() + public function testGetViewParameters(): void { $request = Request::create('/foo'); $viewParameters = [ @@ -78,7 +78,7 @@ public function testGetViewParameters() self::assertSame($viewParameters, $this->helper->getViewParameters()); } - public function testGetViewParametersString() + public function testGetViewParametersString(): void { $request = Request::create('/foo'); $viewParametersString = '/(foo)/bar/(toto)/tata/(somethingelse)/héhé-høhø'; @@ -89,7 +89,7 @@ public function testGetViewParametersString() self::assertSame($viewParametersString, $this->helper->getViewParametersString()); } - public function testGetRequestedUriString() + public function testGetRequestedUriString(): void { $request = Request::create('/ibexa_demo_site/foo/bar'); $semanticPathinfo = '/foo/bar'; @@ -100,7 +100,7 @@ public function testGetRequestedUriString() self::assertSame($semanticPathinfo, $this->helper->getRequestedUriString()); } - public function testGetSystemUriStringNoUrlAlias() + public function testGetSystemUriStringNoUrlAlias(): void { $request = Request::create('/ibexa_demo_site/foo/bar'); $semanticPathinfo = '/foo/bar'; @@ -111,7 +111,7 @@ public function testGetSystemUriStringNoUrlAlias() self::assertSame($semanticPathinfo, $this->helper->getSystemUriString()); } - public function testGetSystemUriString() + public function testGetSystemUriString(): void { $locationId = 123; $contentId = 456; @@ -139,12 +139,12 @@ public function testGetSystemUriString() self::assertSame($expectedSystemUriString, $this->helper->getSystemUriString()); } - public function testGetConfigResolver() + public function testGetConfigResolver(): void { self::assertSame($this->configResolver, $this->helper->getConfigResolver()); } - public function testGetRootLocation() + public function testGetRootLocation(): void { $rootLocationId = 2; $this->configResolver @@ -167,7 +167,7 @@ public function testGetRootLocation() self::assertSame($rootLocation, $this->helper->getRootLocation()); } - public function testGetTranslationSiteAccess() + public function testGetTranslationSiteAccess(): void { $language = 'fre-FR'; $siteaccess = 'fre'; @@ -180,7 +180,7 @@ public function testGetTranslationSiteAccess() self::assertSame($siteaccess, $this->helper->getTranslationSiteAccess($language)); } - public function testGetAvailableLanguages() + public function testGetAvailableLanguages(): void { $languages = ['fre-FR', 'eng-GB', 'esl-ES']; $this->translationHelper diff --git a/tests/lib/MVC/Symfony/Templating/RenderContentStrategyTest.php b/tests/lib/MVC/Symfony/Templating/RenderContentStrategyTest.php index 50eb8b22b9..a99c8e85a9 100644 --- a/tests/lib/MVC/Symfony/Templating/RenderContentStrategyTest.php +++ b/tests/lib/MVC/Symfony/Templating/RenderContentStrategyTest.php @@ -48,7 +48,7 @@ public function testDefaultFragmentRenderer(): void 'inline' ); - $contentMock = $this->createMock(Content::class); + $contentMock = self::createStub(Content::class); self::assertTrue($renderContentStrategy->supports($contentMock)); self::assertSame( @@ -64,7 +64,7 @@ public function testUnknownFragmentRenderer(): void [], ); - $contentMock = $this->createMock(Content::class); + $contentMock = self::createStub(Content::class); self::assertTrue($renderContentStrategy->supports($contentMock)); $this->expectException(InvalidArgumentException::class); @@ -82,7 +82,7 @@ public function testMultipleFragmentRenderers(): void ], ); - $contentMock = $this->createMock(Content::class); + $contentMock = self::createStub(Content::class); self::assertTrue($renderContentStrategy->supports($contentMock)); self::assertSame( @@ -112,7 +112,7 @@ public function testDuplicatedFragmentRenderers(): void ], ); - $contentMock = $this->createMock(Content::class); + $contentMock = self::createStub(Content::class); self::assertTrue($renderContentStrategy->supports($contentMock)); self::assertSame( diff --git a/tests/lib/MVC/Symfony/Templating/RenderLocationStrategyTest.php b/tests/lib/MVC/Symfony/Templating/RenderLocationStrategyTest.php index 08bd48ede7..a49135742c 100644 --- a/tests/lib/MVC/Symfony/Templating/RenderLocationStrategyTest.php +++ b/tests/lib/MVC/Symfony/Templating/RenderLocationStrategyTest.php @@ -48,7 +48,7 @@ public function testDefaultFragmentRenderer(): void 'inline' ); - $locationMock = $this->createMock(Location::class); + $locationMock = self::createStub(Location::class); self::assertTrue($renderLocationStrategy->supports($locationMock)); self::assertSame( @@ -64,7 +64,7 @@ public function testUnknownFragmentRenderer(): void [], ); - $locationMock = $this->createMock(Location::class); + $locationMock = self::createStub(Location::class); self::assertTrue($renderLocationStrategy->supports($locationMock)); $this->expectException(InvalidArgumentException::class); @@ -82,7 +82,7 @@ public function testMultipleFragmentRenderers(): void ], ); - $locationMock = $this->createMock(Location::class); + $locationMock = self::createStub(Location::class); self::assertTrue($renderLocationStrategy->supports($locationMock)); self::assertSame( diff --git a/tests/lib/MVC/Symfony/Templating/Twig/Extension/ContentExtensionTest.php b/tests/lib/MVC/Symfony/Templating/Twig/Extension/ContentExtensionTest.php index 34f47505af..bb0c3300e0 100644 --- a/tests/lib/MVC/Symfony/Templating/Twig/Extension/ContentExtensionTest.php +++ b/tests/lib/MVC/Symfony/Templating/Twig/Extension/ContentExtensionTest.php @@ -45,9 +45,9 @@ public function getExtensions(): array $this->getRepositoryMock(), new TranslationHelper( $configResolver, - $this->createMock(ContentService::class), + self::createStub(ContentService::class), [], - $this->createMock(LoggerInterface::class) + self::createStub(LoggerInterface::class) ), $this->fieldHelperMock, $this->getFieldsGroupsListMock() diff --git a/tests/lib/MVC/Symfony/Templating/Twig/Extension/DataAttributesExtensionTest.php b/tests/lib/MVC/Symfony/Templating/Twig/Extension/DataAttributesExtensionTest.php index 7a48b05db1..e64d51445f 100644 --- a/tests/lib/MVC/Symfony/Templating/Twig/Extension/DataAttributesExtensionTest.php +++ b/tests/lib/MVC/Symfony/Templating/Twig/Extension/DataAttributesExtensionTest.php @@ -20,7 +20,7 @@ public function getExtensions(): array ]; } - protected function getFixturesDir(): string + protected static function getFixturesDirectory(): string { return __DIR__ . '/_fixtures/filters'; } diff --git a/tests/lib/MVC/Symfony/Templating/Twig/Extension/FieldRenderingExtensionIntegrationTest.php b/tests/lib/MVC/Symfony/Templating/Twig/Extension/FieldRenderingExtensionIntegrationTest.php index a67f2a1769..29b36ab4b4 100644 --- a/tests/lib/MVC/Symfony/Templating/Twig/Extension/FieldRenderingExtensionIntegrationTest.php +++ b/tests/lib/MVC/Symfony/Templating/Twig/Extension/FieldRenderingExtensionIntegrationTest.php @@ -35,11 +35,10 @@ class FieldRenderingExtensionIntegrationTest extends FileSystemTwigIntegrationTe public function getExtensions(): array { $configResolver = $this->getConfigResolverMock(); - $twig = $this->createMock(Environment::class); $resourceProvider = $this->getResourceProviderMock(); $fieldBlockRenderer = new FieldBlockRenderer( - $twig, + self::createStub(Environment::class), $resourceProvider, $this->getTemplatePath('base.html.twig') ); @@ -47,12 +46,12 @@ public function getExtensions(): array return [ new FieldRenderingExtension( $fieldBlockRenderer, - $this->createMock(ParameterProviderRegistryInterface::class), + self::createStub(ParameterProviderRegistryInterface::class), new TranslationHelper( $configResolver, - $this->createMock(ContentService::class), + self::createStub(ContentService::class), [], - $this->createMock(LoggerInterface::class) + self::createStub(LoggerInterface::class) ) ), ]; diff --git a/tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php b/tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php index da79e8c9ee..9c1f8ea3dc 100644 --- a/tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php +++ b/tests/lib/MVC/Symfony/Templating/Twig/Extension/FileSizeExtensionTest.php @@ -71,7 +71,7 @@ protected function getExtensions() ]; } - protected function getFixturesDir(): string + protected static function getFixturesDirectory(): string { return __DIR__ . '/_fixtures/functions/ibexa_file_size'; } diff --git a/tests/lib/MVC/Symfony/Templating/Twig/Extension/RenderExtensionTest.php b/tests/lib/MVC/Symfony/Templating/Twig/Extension/RenderExtensionTest.php index 1de91a5351..4c22941c5c 100644 --- a/tests/lib/MVC/Symfony/Templating/Twig/Extension/RenderExtensionTest.php +++ b/tests/lib/MVC/Symfony/Templating/Twig/Extension/RenderExtensionTest.php @@ -55,7 +55,7 @@ protected function getExtensions(): array ]; } - protected function getFixturesDir(): string + protected static function getFixturesDirectory(): string { return __DIR__ . '/_fixtures/render'; } diff --git a/tests/lib/MVC/Symfony/Templating/Twig/Extension/RoutingExtensionTest.php b/tests/lib/MVC/Symfony/Templating/Twig/Extension/RoutingExtensionTest.php index 9a5829ba48..3eeda21e2c 100644 --- a/tests/lib/MVC/Symfony/Templating/Twig/Extension/RoutingExtensionTest.php +++ b/tests/lib/MVC/Symfony/Templating/Twig/Extension/RoutingExtensionTest.php @@ -38,7 +38,7 @@ protected function getExtensions(): array ]; } - protected function getFixturesDir(): string + protected static function getFixturesDirectory(): string { return __DIR__ . '/_fixtures/routing_functions'; } @@ -89,7 +89,7 @@ protected function getExampleUnsupportedObject(): object private function getRouteReferenceGenerator(): RouteReferenceGeneratorInterface { $generator = new RouteReferenceGenerator( - $this->createMock(EventDispatcherInterface::class) + self::createStub(EventDispatcherInterface::class) ); $request = new Request(); $requestStack = new RequestStack([$request]); diff --git a/tests/lib/MVC/Symfony/Templating/Twig/Extension/UserExtensionTest.php b/tests/lib/MVC/Symfony/Templating/Twig/Extension/UserExtensionTest.php index 4c7aeef798..19be4dde71 100644 --- a/tests/lib/MVC/Symfony/Templating/Twig/Extension/UserExtensionTest.php +++ b/tests/lib/MVC/Symfony/Templating/Twig/Extension/UserExtensionTest.php @@ -76,7 +76,7 @@ public function getUser(int $id, bool $isCurrent = false): User return $this->users[$id]; } - protected function getFixturesDir(): string + protected static function getFixturesDirectory(): string { return __DIR__ . '/_fixtures/user_functions'; } diff --git a/tests/lib/MVC/Symfony/Templating/Twig/Extension/UserPreferenceExtensionTest.php b/tests/lib/MVC/Symfony/Templating/Twig/Extension/UserPreferenceExtensionTest.php index 4430dd47df..b838ff7b67 100644 --- a/tests/lib/MVC/Symfony/Templating/Twig/Extension/UserPreferenceExtensionTest.php +++ b/tests/lib/MVC/Symfony/Templating/Twig/Extension/UserPreferenceExtensionTest.php @@ -45,7 +45,7 @@ public function load(string $class): ?RuntimeExtensionInterface ]; } - protected function getFixturesDir(): string + protected static function getFixturesDirectory(): string { return __DIR__ . '/_fixtures/user_preference_functions'; } diff --git a/tests/lib/MVC/Symfony/Translation/BaseMessageExtractorPhpFileVisitorTestCase.php b/tests/lib/MVC/Symfony/Translation/BaseMessageExtractorPhpFileVisitorTestCase.php index f2543a0fc0..de1df8c975 100644 --- a/tests/lib/MVC/Symfony/Translation/BaseMessageExtractorPhpFileVisitorTestCase.php +++ b/tests/lib/MVC/Symfony/Translation/BaseMessageExtractorPhpFileVisitorTestCase.php @@ -14,6 +14,7 @@ use JMS\TranslationBundle\Translation\FileSourceFactory; use PhpParser\Parser; use PhpParser\ParserFactory; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use SplFileInfo; @@ -45,10 +46,9 @@ protected function setUp(): void } /** - * @dataProvider getDataForTestExtractTranslation - * * @param array<\JMS\TranslationBundle\Model\Message> $expectedMessages */ + #[DataProvider('getDataForTestExtractTranslation')] public function testExtractTranslation(string $phpFileName, array $expectedMessages): void { $messageCatalogue = new MessageCatalogue(); diff --git a/tests/lib/MVC/Symfony/Translation/ExceptionMessageTemplateFileVisitorTest.php b/tests/lib/MVC/Symfony/Translation/ExceptionMessageTemplateFileVisitorTest.php index d09c4b643c..85f735750e 100644 --- a/tests/lib/MVC/Symfony/Translation/ExceptionMessageTemplateFileVisitorTest.php +++ b/tests/lib/MVC/Symfony/Translation/ExceptionMessageTemplateFileVisitorTest.php @@ -15,12 +15,11 @@ use JMS\TranslationBundle\Model\MessageCatalogue; use JMS\TranslationBundle\Translation\Extractor\FileVisitorInterface; use JMS\TranslationBundle\Translation\FileSourceFactory; +use PHPUnit\Framework\Attributes\CoversClass; use Psr\Log\LoggerInterface; use SplFileInfo; -/** - * @covers \Ibexa\Core\MVC\Symfony\Translation\ExceptionMessageTemplateFileVisitor - */ +#[CoversClass(ExceptionMessageTemplateFileVisitor::class)] final class ExceptionMessageTemplateFileVisitorTest extends BaseMessageExtractorPhpFileVisitorTestCase { public static function getDataForTestExtractTranslation(): iterable diff --git a/tests/lib/MVC/Symfony/Translation/TranslatableExceptionsFileVisitorTest.php b/tests/lib/MVC/Symfony/Translation/TranslatableExceptionsFileVisitorTest.php index 88fa94ac16..49c5735f04 100644 --- a/tests/lib/MVC/Symfony/Translation/TranslatableExceptionsFileVisitorTest.php +++ b/tests/lib/MVC/Symfony/Translation/TranslatableExceptionsFileVisitorTest.php @@ -13,10 +13,9 @@ use JMS\TranslationBundle\Model\Message; use JMS\TranslationBundle\Translation\Extractor\FileVisitorInterface; use JMS\TranslationBundle\Translation\FileSourceFactory; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\MVC\Symfony\Translation\TranslatableExceptionsFileVisitor - */ +#[CoversClass(TranslatableExceptionsFileVisitor::class)] final class TranslatableExceptionsFileVisitorTest extends BaseMessageExtractorPhpFileVisitorTestCase { public static function getDataForTestExtractTranslation(): iterable diff --git a/tests/lib/MVC/Symfony/Translation/ValidationErrorFileVisitorTest.php b/tests/lib/MVC/Symfony/Translation/ValidationErrorFileVisitorTest.php index 9dbc44e9a3..59e261df3f 100644 --- a/tests/lib/MVC/Symfony/Translation/ValidationErrorFileVisitorTest.php +++ b/tests/lib/MVC/Symfony/Translation/ValidationErrorFileVisitorTest.php @@ -13,10 +13,9 @@ use JMS\TranslationBundle\Model\Message; use JMS\TranslationBundle\Translation\Extractor\FileVisitorInterface; use JMS\TranslationBundle\Translation\FileSourceFactory; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\MVC\Symfony\Translation\ValidationErrorFileVisitor - */ +#[CoversClass(ValidationErrorFileVisitor::class)] final class ValidationErrorFileVisitorTest extends BaseMessageExtractorPhpFileVisitorTestCase { /** diff --git a/tests/lib/MVC/Symfony/View/AbstractViewTestCase.php b/tests/lib/MVC/Symfony/View/AbstractViewTestCase.php index f76a3fceb9..9f744eaa0f 100644 --- a/tests/lib/MVC/Symfony/View/AbstractViewTestCase.php +++ b/tests/lib/MVC/Symfony/View/AbstractViewTestCase.php @@ -9,13 +9,15 @@ namespace Ibexa\Tests\Core\MVC\Symfony\View; use Ibexa\Core\Base\Exceptions\InvalidArgumentType; +use Ibexa\Core\MVC\Symfony\View\BaseView; use Ibexa\Core\MVC\Symfony\View\View; use InvalidArgumentException; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\MVC\Symfony\View\View - */ +#[CoversClass(BaseView::class)] abstract class AbstractViewTestCase extends TestCase { abstract protected function createViewUnderTest($template = null, array $parameters = [], $viewType = 'full'): View; @@ -64,9 +66,7 @@ public function testHasParameter(): View return $view; } - /** - * @depends testHasParameter - */ + #[Depends('testHasParameter')] public function testGetParameter(View $view): View { self::assertSame('bar', $view->getParameter('foo')); @@ -74,9 +74,7 @@ public function testGetParameter(View $view): View return $view; } - /** - * @depends testGetParameter - */ + #[Depends('testGetParameter')] public function testGetParameterFail(View $view): void { $this->expectException(InvalidArgumentException::class); @@ -85,10 +83,9 @@ public function testGetParameterFail(View $view): void } /** - * @dataProvider goodTemplateIdentifierProvider - * * @param string|callable $templateIdentifier */ + #[DataProvider('goodTemplateIdentifierProvider')] public function testSetTemplateIdentifier($templateIdentifier): void { $contentView = $this->createViewUnderTest(); @@ -97,7 +94,7 @@ public function testSetTemplateIdentifier($templateIdentifier): void self::assertSame($templateIdentifier, $contentView->getTemplateIdentifier()); } - public function goodTemplateIdentifierProvider(): array + public static function goodTemplateIdentifierProvider(): array { return [ ['foo:bar:baz.html.twig'], @@ -110,10 +107,9 @@ static function (): string { } /** - * @dataProvider badTemplateIdentifierProvider - * * @param mixed $badTemplateIdentifier */ + #[DataProvider('badTemplateIdentifierProvider')] public function testSetTemplateIdentifierWrongType($badTemplateIdentifier): void { $this->expectException(InvalidArgumentType::class); @@ -122,7 +118,7 @@ public function testSetTemplateIdentifierWrongType($badTemplateIdentifier): void $contentView->setTemplateIdentifier($badTemplateIdentifier); } - public function badTemplateIdentifierProvider(): array + public static function badTemplateIdentifierProvider(): array { return [ [123], diff --git a/tests/lib/MVC/Symfony/View/Builder/ContentViewBuilderTest.php b/tests/lib/MVC/Symfony/View/Builder/ContentViewBuilderTest.php index 3087f377a2..7085d1070b 100644 --- a/tests/lib/MVC/Symfony/View/Builder/ContentViewBuilderTest.php +++ b/tests/lib/MVC/Symfony/View/Builder/ContentViewBuilderTest.php @@ -25,15 +25,14 @@ use Ibexa\Core\Repository\Values\Content\Content; use Ibexa\Core\Repository\Values\Content\Location; use Ibexa\Core\Repository\Values\Content\VersionInfo; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; use ReflectionClass; use Symfony\Component\HttpFoundation\ParameterBag; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\RequestStack; -/** - * @group mvc - */ +#[Group('mvc')] class ContentViewBuilderTest extends TestCase { private const int EXAMPLE_LOCATION_ID = 743; @@ -64,7 +63,7 @@ protected function setUp(): void $this->repository = $this ->getMockBuilder(Repository::class) ->disableOriginalConstructor() - ->setMethods([ + ->onlyMethods([ 'sudo', 'getPermissionResolver', 'getLocationService', @@ -215,12 +214,7 @@ public function testBuildEmbedViewWithoutContentViewEmbedPermission(): void ->willReturn($location); $this->permissionResolver - ->expects(self::at(0)) - ->method('canUser') - ->willReturn(false); - - $this->permissionResolver - ->expects(self::at(1)) + ->expects(self::exactly(2)) ->method('canUser') ->willReturn(false); @@ -342,7 +336,7 @@ public function testBuildViewWithContentWhichDoesNotBelongToLocation(): void ->willReturn($location); $this->permissionResolver - ->expects(self::at(0)) + ->expects(self::once()) ->method('canUser') ->willReturn(true); @@ -424,7 +418,7 @@ public function testBuildView(): void ->willReturn($location); $this->permissionResolver - ->expects(self::at(0)) + ->expects(self::once()) ->method('canUser') ->willReturn(true); diff --git a/tests/lib/MVC/Symfony/View/ContentViewTest.php b/tests/lib/MVC/Symfony/View/ContentViewTest.php index 3e353ef587..6d733f1307 100644 --- a/tests/lib/MVC/Symfony/View/ContentViewTest.php +++ b/tests/lib/MVC/Symfony/View/ContentViewTest.php @@ -11,12 +11,12 @@ use Ibexa\Core\Base\Exceptions\InvalidArgumentType; use Ibexa\Core\MVC\Symfony\View\ContentView; use Ibexa\Core\MVC\Symfony\View\View; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; -/** - * @group mvc - * - * @covers \Ibexa\Core\MVC\Symfony\View\ContentView - */ +#[CoversClass(ContentView::class)] +#[Group('mvc')] class ContentViewTest extends AbstractViewTestCase { /** @@ -26,17 +26,18 @@ class ContentViewTest extends AbstractViewTestCase */ private $valueParams = ['content' => null]; - /** - * @dataProvider constructProvider - */ - public function testConstruct($templateIdentifier, array $params) + #[DataProvider('constructProvider')] + public function testConstruct($templateIdentifier, array $params): void { $contentView = new ContentView($templateIdentifier, $params); self::assertSame($templateIdentifier, $contentView->getTemplateIdentifier()); self::assertSame($this->valueParams + $params, $contentView->getParameters()); } - public function constructProvider() + /** + * @return array + */ + public static function constructProvider(): array { return [ ['some:valid:identifier', ['foo' => 'bar']], @@ -57,17 +58,18 @@ static function (): bool { ]; } - /** - * @dataProvider constructFailProvider - */ - public function testConstructFail($templateIdentifier) + #[DataProvider('constructFailProvider')] + public function testConstructFail($templateIdentifier): void { $this->expectException(InvalidArgumentType::class); new ContentView($templateIdentifier); } - public function constructFailProvider() + /** + * @return array + */ + public static function constructFailProvider(): array { return [ [123], diff --git a/tests/lib/MVC/Symfony/View/LoginFormViewTest.php b/tests/lib/MVC/Symfony/View/LoginFormViewTest.php index 6dbebcaf38..a2f21931ad 100644 --- a/tests/lib/MVC/Symfony/View/LoginFormViewTest.php +++ b/tests/lib/MVC/Symfony/View/LoginFormViewTest.php @@ -10,11 +10,10 @@ use Ibexa\Core\MVC\Symfony\View\LoginFormView; use Ibexa\Core\MVC\Symfony\View\View; +use PHPUnit\Framework\Attributes\Group; use Symfony\Component\Security\Core\Exception\AuthenticationException; -/** - * @group mvc - */ +#[Group('mvc')] final class LoginFormViewTest extends AbstractViewTestCase { public function testSetLastUsername(): void @@ -28,7 +27,7 @@ public function testSetLastUsername(): void public function testSetLastAuthenticationError(): void { - $exception = $this->createMock(AuthenticationException::class); + $exception = self::createStub(AuthenticationException::class); /** @var \Ibexa\Core\MVC\Symfony\View\LoginFormView $view */ $view = $this->createViewUnderTest(); diff --git a/tests/lib/MVC/Symfony/View/Renderer/TemplateRendererTest.php b/tests/lib/MVC/Symfony/View/Renderer/TemplateRendererTest.php index fec5439591..fcfbe41d2e 100644 --- a/tests/lib/MVC/Symfony/View/Renderer/TemplateRendererTest.php +++ b/tests/lib/MVC/Symfony/View/Renderer/TemplateRendererTest.php @@ -37,7 +37,7 @@ protected function setUp(): void ); } - public function testRender() + public function testRender(): void { $view = $this->createView(); $view->setTemplateIdentifier('path/to/template.html.twig'); @@ -61,7 +61,7 @@ public function testRender() $this->renderer->render($view); } - public function testRenderNoViewTemplate() + public function testRenderNoViewTemplate(): void { $this->expectException(NoViewTemplateException::class); diff --git a/tests/lib/MVC/Symfony/View/ViewManagerTest.php b/tests/lib/MVC/Symfony/View/ViewManagerTest.php index 0d5935bb4a..d2cbcb5ddf 100644 --- a/tests/lib/MVC/Symfony/View/ViewManagerTest.php +++ b/tests/lib/MVC/Symfony/View/ViewManagerTest.php @@ -18,13 +18,13 @@ use Ibexa\Core\Repository\Values\Content\Content; use Ibexa\Core\Repository\Values\Content\Location; use Ibexa\Core\Repository\Values\Content\VersionInfo; +use PHPUnit\Framework\Attributes\Group; +use PHPUnit\Framework\MockObject\Stub; use PHPUnit\Framework\TestCase; use Symfony\Component\EventDispatcher\EventDispatcherInterface; use Twig\Environment; -/** - * @group mvc - */ +#[Group('mvc')] class ViewManagerTest extends TestCase { /** @var \Ibexa\Core\MVC\Symfony\View\Manager */ @@ -33,8 +33,7 @@ class ViewManagerTest extends TestCase /** @var \PHPUnit\Framework\MockObject\MockObject|\Twig\Environment */ private $templateEngineMock; - /** @var \PHPUnit\Framework\MockObject\MockObject|\Symfony\Component\EventDispatcher\EventDispatcherInterface */ - private $eventDispatcherMock; + private EventDispatcherInterface&Stub $eventDispatcherMock; /** @var \PHPUnit\Framework\MockObject\MockObject|\Ibexa\Contracts\Core\Repository\Repository */ private $repositoryMock; @@ -51,7 +50,7 @@ protected function setUp(): void { parent::setUp(); $this->templateEngineMock = $this->createMock(Environment::class); - $this->eventDispatcherMock = $this->createMock(EventDispatcherInterface::class); + $this->eventDispatcherMock = self::createStub(EventDispatcherInterface::class); $this->repositoryMock = $this->createMock(Repository::class); $this->configResolverMock = $this->createMock(ConfigResolverInterface::class); $this->viewConfigurator = $this->createMock(Configurator::class); @@ -65,7 +64,7 @@ protected function setUp(): void ); } - public function testRenderContent() + public function testRenderContent(): void { $content = new Content( ['versionInfo' => new VersionInfo(['contentInfo' => new ContentInfo()])] @@ -98,7 +97,7 @@ static function (View $view) use ($templateIdentifier) { self::assertSame($expectedTemplateResult, $this->viewManager->renderContent($content, 'customViewType', $params)); } - public function testRenderContentWithClosure() + public function testRenderContentWithClosure(): void { $content = new Content( ['versionInfo' => new VersionInfo(['contentInfo' => new ContentInfo()])] @@ -132,7 +131,7 @@ static function (View $view) use ($closure) { self::assertEqualsCanonicalizing($expectedTemplateResult, $templateResult); } - public function testRenderLocation() + public function testRenderLocation(): void { $content = new Content(['versionInfo' => new VersionInfo(['contentInfo' => new ContentInfo()])]); $location = new Location(['contentInfo' => new ContentInfo()]); @@ -181,7 +180,7 @@ static function (View $view) use ($templateIdentifier) { self::assertSame($expectedTemplateResult, $this->viewManager->renderLocation($location, 'customViewType', $params)); } - public function testRenderLocationWithContentPassed() + public function testRenderLocationWithContentPassed(): void { $content = new Content(['versionInfo' => new VersionInfo(['contentInfo' => new ContentInfo()])]); $location = new Location(['contentInfo' => new ContentInfo()]); @@ -232,7 +231,7 @@ static function (View $view) use ($templateIdentifier) { self::assertSame($expectedTemplateResult, $this->viewManager->renderLocation($location, 'customViewType', $params)); } - public function testRenderLocationWithClosure() + public function testRenderLocationWithClosure(): void { $content = new Content(['versionInfo' => new VersionInfo(['contentInfo' => new ContentInfo()])]); $location = new Location(['contentInfo' => new ContentInfo()]); diff --git a/tests/lib/Notification/Renderer/RegistryTest.php b/tests/lib/Notification/Renderer/RegistryTest.php index 8e26bf154d..178c58423b 100644 --- a/tests/lib/Notification/Renderer/RegistryTest.php +++ b/tests/lib/Notification/Renderer/RegistryTest.php @@ -52,7 +52,7 @@ public function getTypeLabel(): string } }; - $nonTypedRenderer = $this->createMock(NotificationRenderer::class); + $nonTypedRenderer = self::createStub(NotificationRenderer::class); $registry = new Registry(); $registry->addRenderer('z_type', $typedRendererB); diff --git a/tests/lib/Pagination/AdapterFactory/SearchHitAdapterFactoryTest.php b/tests/lib/Pagination/AdapterFactory/SearchHitAdapterFactoryTest.php index a0e2be28d9..06caec719e 100644 --- a/tests/lib/Pagination/AdapterFactory/SearchHitAdapterFactoryTest.php +++ b/tests/lib/Pagination/AdapterFactory/SearchHitAdapterFactoryTest.php @@ -17,6 +17,7 @@ use Ibexa\Core\Pagination\Pagerfanta\ContentSearchHitAdapter; use Ibexa\Core\Pagination\Pagerfanta\FixedSearchResultHitAdapter; use Ibexa\Core\Pagination\Pagerfanta\LocationSearchHitAdapter; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; final class SearchHitAdapterFactoryTest extends TestCase @@ -65,9 +66,7 @@ public function testCreateAdapterForLocationQuery(): void ); } - /** - * @dataProvider dataProviderForCreateFixedAdapter - */ + #[DataProvider('dataProviderForCreateFixedAdapter')] public function testCreateFixedAdapter(Query $query, string $expectedSearchMethod): void { $hits = [ @@ -93,7 +92,7 @@ public function testCreateFixedAdapter(Query $query, string $expectedSearchMetho ); } - public function dataProviderForCreateFixedAdapter(): iterable + public static function dataProviderForCreateFixedAdapter(): iterable { yield 'content query' => [ new Query(), diff --git a/tests/lib/Pagination/BaseContentSearchResultAdapterTestCase.php b/tests/lib/Pagination/BaseContentSearchResultAdapterTestCase.php index 60be3dbbb2..9355ebd537 100644 --- a/tests/lib/Pagination/BaseContentSearchResultAdapterTestCase.php +++ b/tests/lib/Pagination/BaseContentSearchResultAdapterTestCase.php @@ -63,7 +63,7 @@ protected function mockSearchHitsForGetSlice( for ($i = 0; $i < self::EXAMPLE_LIMIT; ++$i) { $hits[] = new SearchHit( [ - 'valueObject' => $this->createMock(APIContent::class), + 'valueObject' => self::createStub(APIContent::class), ] ); } diff --git a/tests/lib/Pagination/BaseLocationSearchResultAdapterTestCase.php b/tests/lib/Pagination/BaseLocationSearchResultAdapterTestCase.php index 3453dc8791..d13e5c67c5 100644 --- a/tests/lib/Pagination/BaseLocationSearchResultAdapterTestCase.php +++ b/tests/lib/Pagination/BaseLocationSearchResultAdapterTestCase.php @@ -68,7 +68,7 @@ protected function mockSearchHitsForGetSlice( for ($i = 0; $i < self::EXAMPLE_LIMIT; ++$i) { $hits[] = new SearchHit( [ - 'valueObject' => $this->createMock(APILocation::class), + 'valueObject' => self::createStub(APILocation::class), ] ); } diff --git a/tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php b/tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php index 92e1935347..b06a0e2a93 100644 --- a/tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php +++ b/tests/lib/Persistence/Cache/AbstractCacheHandlerTestCase.php @@ -8,20 +8,29 @@ namespace Ibexa\Tests\Core\Persistence\Cache; +use PHPUnit\Framework\Attributes\DataProvider; + /** * Abstract test case for spi cache impl. */ abstract class AbstractCacheHandlerTestCase extends AbstractBaseHandlerTestCase { + /** + * Sentinel method name yielded by {@see providerForCachedLoadMethodsHit()}/ + * {@see providerForCachedLoadMethodsMiss()} implementations that legitimately have no cached + * load methods to test; PHPUnit 11 treats an empty data provider as a hard error, so a single + * sentinel row is yielded instead and the two consuming test methods skip immediately when + * they see it. + */ + protected const NO_DATA_METHOD = '__no_data__'; + abstract public function getHandlerMethodName(): string; abstract public function getHandlerClassName(): string; - abstract public function providerForUnCachedMethods(): array; + abstract public static function providerForUnCachedMethods(): array; /** - * @dataProvider providerForUnCachedMethods - * * @param string $method * @param array $arguments * @param array|null $tagGeneratingArguments @@ -30,6 +39,7 @@ abstract public function providerForUnCachedMethods(): array; * @param string|array|null $key * @param mixed $returnValue */ + #[DataProvider('providerForUnCachedMethods')] final public function testUnCachedMethods( string $method, array $arguments, @@ -38,7 +48,7 @@ final public function testUnCachedMethods( ?array $tags = null, $key = null, $returnValue = null - ) { + ): void { $handlerMethodName = $this->getHandlerMethodName(); $this->loggerMock->expects(self::once())->method('logCall'); @@ -62,22 +72,30 @@ final public function testUnCachedMethods( if ($tags || $key) { if ($tagGeneratingArguments) { + $matcher = self::exactly(count($tagGeneratingArguments)); $this->cacheIdentifierGeneratorMock - ->expects(self::exactly(count($tagGeneratingArguments))) + ->expects($matcher) ->method('generateTag') - ->withConsecutive(...$tagGeneratingArguments) - ->willReturnOnConsecutiveCalls(...$tags); + ->willReturnCallback(function (...$parameters) use ($matcher, $tagGeneratingArguments, $tags) { + $this->assertEquals($tagGeneratingArguments[$matcher->numberOfInvocations() - 1], $parameters); + + return $tags[$matcher->numberOfInvocations() - 1]; + }); } if ($keyGeneratingArguments) { $callsCount = count($keyGeneratingArguments); if (is_array($key)) { + $matcher = self::exactly($callsCount); $this->cacheIdentifierGeneratorMock - ->expects(self::exactly($callsCount)) + ->expects($matcher) ->method('generateKey') - ->withConsecutive(...$keyGeneratingArguments) - ->willReturnOnConsecutiveCalls(...$key); + ->willReturnCallback(function (...$parameters) use ($matcher, $keyGeneratingArguments, $key) { + $this->assertEquals($keyGeneratingArguments[$matcher->numberOfInvocations() - 1], $parameters); + + return $key[$matcher->numberOfInvocations() - 1]; + }); } else { $this->cacheIdentifierGeneratorMock ->expects(self::exactly($callsCount)) @@ -109,11 +127,9 @@ final public function testUnCachedMethods( self::assertEquals($returnValue, $actualReturnValue); } - abstract public function providerForCachedLoadMethodsHit(): array; + abstract public static function providerForCachedLoadMethodsHit(): array; /** - * @dataProvider providerForCachedLoadMethodsHit - * * @param string $method * @param array $arguments * @param string $key @@ -125,6 +141,7 @@ abstract public function providerForCachedLoadMethodsHit(): array; * @param bool $multi Default false, set to true if method will lookup several cache items. * @param array $additionalCalls Sets of additional calls being made to handlers, with 4 values (0: handler name, 1: handler class, 2: method, 3: return data) */ + #[DataProvider('providerForCachedLoadMethodsHit')] final public function testLoadMethodsCacheHit( string $method, array $arguments, @@ -136,26 +153,38 @@ final public function testLoadMethodsCacheHit( $data = null, bool $multi = false, array $additionalCalls = [] - ) { + ): void { + if ($method === self::NO_DATA_METHOD) { + self::markTestSkipped('No cached load methods for this handler.'); + } + $cacheItem = $this->getCacheItem($key, $multi ? reset($data) : $data); $handlerMethodName = $this->getHandlerMethodName(); $this->loggerMock->expects(self::never())->method('logCall'); if ($tagGeneratingArguments) { + $matcher = self::exactly(count($tagGeneratingArguments)); $this->cacheIdentifierGeneratorMock - ->expects(self::exactly(count($tagGeneratingArguments))) + ->expects($matcher) ->method('generateTag') - ->withConsecutive(...$tagGeneratingArguments) - ->willReturnOnConsecutiveCalls(...$tagGeneratingResults); + ->willReturnCallback(function (...$parameters) use ($matcher, $tagGeneratingArguments, $tagGeneratingResults) { + $this->assertEquals($tagGeneratingArguments[$matcher->numberOfInvocations() - 1], $parameters); + + return $tagGeneratingResults[$matcher->numberOfInvocations() - 1]; + }); } if ($keyGeneratingArguments) { + $matcher = self::exactly(count($keyGeneratingArguments)); $this->cacheIdentifierGeneratorMock - ->expects(self::exactly(count($keyGeneratingArguments))) + ->expects($matcher) ->method('generateKey') - ->withConsecutive(...$keyGeneratingArguments) - ->willReturnOnConsecutiveCalls(...$keyGeneratingResults); + ->willReturnCallback(function (...$parameters) use ($matcher, $keyGeneratingArguments, $keyGeneratingResults) { + $this->assertEquals($keyGeneratingArguments[$matcher->numberOfInvocations() - 1], $parameters); + + return $keyGeneratingResults[$matcher->numberOfInvocations() - 1]; + }); } if ($multi) { @@ -188,11 +217,9 @@ final public function testLoadMethodsCacheHit( self::assertEquals($data, $return); } - abstract public function providerForCachedLoadMethodsMiss(): array; + abstract public static function providerForCachedLoadMethodsMiss(): array; /** - * @dataProvider providerForCachedLoadMethodsMiss - * * @param string $method * @param array $arguments * @param string $key @@ -204,6 +231,7 @@ abstract public function providerForCachedLoadMethodsMiss(): array; * @param bool $multi Default false, set to true if method will lookup several cache items. * @param array $additionalCalls Sets of additional calls being made to handlers, with 4 values (0: handler name, 1: handler class, 2: method, 3: return data) */ + #[DataProvider('providerForCachedLoadMethodsMiss')] final public function testLoadMethodsCacheMiss( string $method, array $arguments, @@ -215,7 +243,11 @@ final public function testLoadMethodsCacheMiss( $data = null, bool $multi = false, array $additionalCalls = [] - ) { + ): void { + if ($method === self::NO_DATA_METHOD) { + self::markTestSkipped('No cached load methods for this handler.'); + } + $cacheItem = $this->getCacheItem($key, null); $handlerMethodName = $this->getHandlerMethodName(); @@ -223,22 +255,30 @@ final public function testLoadMethodsCacheMiss( $this->loggerMock ->expects(self::once()) ->method('logCall') - ->with(get_class($handler) . '::' . $method, self::isType('array')); + ->with(get_class($handler) . '::' . $method, self::isArray()); if ($tagGeneratingArguments) { + $matcher = self::exactly(count($tagGeneratingArguments)); $this->cacheIdentifierGeneratorMock - ->expects(self::exactly(count($tagGeneratingArguments))) + ->expects($matcher) ->method('generateTag') - ->withConsecutive(...$tagGeneratingArguments) - ->willReturnOnConsecutiveCalls(...$tagGeneratingResults); + ->willReturnCallback(function (...$parameters) use ($matcher, $tagGeneratingArguments, $tagGeneratingResults) { + $this->assertEquals($tagGeneratingArguments[$matcher->numberOfInvocations() - 1], $parameters); + + return $tagGeneratingResults[$matcher->numberOfInvocations() - 1]; + }); } if ($keyGeneratingArguments) { + $matcher = self::exactly(count($keyGeneratingArguments)); $this->cacheIdentifierGeneratorMock - ->expects(self::exactly(count($keyGeneratingArguments))) + ->expects($matcher) ->method('generateKey') - ->withConsecutive(...$keyGeneratingArguments) - ->willReturnOnConsecutiveCalls(...$keyGeneratingResults); + ->willReturnCallback(function (...$parameters) use ($matcher, $keyGeneratingArguments, $keyGeneratingResults) { + $this->assertEquals($keyGeneratingArguments[$matcher->numberOfInvocations() - 1], $parameters); + + return $keyGeneratingResults[$matcher->numberOfInvocations() - 1]; + }); } if ($multi) { diff --git a/tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php b/tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php index 8d9e394b2b..8f457d1f6c 100644 --- a/tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php +++ b/tests/lib/Persistence/Cache/AbstractInMemoryCacheHandlerTestCase.php @@ -8,6 +8,8 @@ namespace Ibexa\Tests\Core\Persistence\Cache; +use PHPUnit\Framework\Attributes\DataProvider; + /** * Abstract test case for spi cache impl, with in-memory handling. */ @@ -17,11 +19,9 @@ abstract public function getHandlerMethodName(): string; abstract public function getHandlerClassName(): string; - abstract public function providerForUnCachedMethods(): array; + abstract public static function providerForUnCachedMethods(): array; /** - * @dataProvider providerForUnCachedMethods - * * @param string $method * @param array $arguments * @param array|null $tagGeneratingArguments @@ -30,6 +30,7 @@ abstract public function providerForUnCachedMethods(): array; * @param array|null $key * @param mixed $returnValue */ + #[DataProvider('providerForUnCachedMethods')] final public function testUnCachedMethods( string $method, array $arguments, @@ -39,7 +40,7 @@ final public function testUnCachedMethods( ?array $key = null, $returnValue = null, bool $callInnerHandler = true - ) { + ): void { $handlerMethodName = $this->getHandlerMethodName(); $this->loggerMock->expects(self::once())->method('logCall'); @@ -63,22 +64,30 @@ final public function testUnCachedMethods( if ($tags || $key) { if ($tagGeneratingArguments) { + $matcher = self::exactly(count($tagGeneratingArguments)); $this->cacheIdentifierGeneratorMock - ->expects(self::exactly(count($tagGeneratingArguments))) + ->expects($matcher) ->method('generateTag') - ->withConsecutive(...$tagGeneratingArguments) - ->willReturnOnConsecutiveCalls(...$tags); + ->willReturnCallback(function (...$parameters) use ($matcher, $tagGeneratingArguments, $tags) { + $this->assertEquals($tagGeneratingArguments[$matcher->numberOfInvocations() - 1], $parameters); + + return $tags[$matcher->numberOfInvocations() - 1]; + }); } if ($keyGeneratingArguments) { $callsCount = count($keyGeneratingArguments); if (is_array($key)) { + $matcher = self::exactly($callsCount); $this->cacheIdentifierGeneratorMock - ->expects(self::exactly($callsCount)) + ->expects($matcher) ->method('generateKey') - ->withConsecutive(...$keyGeneratingArguments) - ->willReturnOnConsecutiveCalls(...$key); + ->willReturnCallback(function (...$parameters) use ($matcher, $keyGeneratingArguments, $key) { + $this->assertEquals($keyGeneratingArguments[$matcher->numberOfInvocations() - 1], $parameters); + + return $key[$matcher->numberOfInvocations() - 1]; + }); } else { $this->cacheIdentifierGeneratorMock ->expects(self::exactly($callsCount)) @@ -109,11 +118,9 @@ final public function testUnCachedMethods( self::assertEquals($returnValue, $actualReturnValue); } - abstract public function providerForCachedLoadMethodsHit(): array; + abstract public static function providerForCachedLoadMethodsHit(): array; /** - * @dataProvider providerForCachedLoadMethodsHit - * * @param string $method * @param array $arguments * @param string $key @@ -125,6 +132,7 @@ abstract public function providerForCachedLoadMethodsHit(): array; * @param bool $multi Default false, set to true if method will lookup several cache items. * @param array $additionalCalls Sets of additional calls being made to handlers, with 4 values (0: handler name, 1: handler class, 2: method, 3: return data) */ + #[DataProvider('providerForCachedLoadMethodsHit')] final public function testLoadMethodsCacheHit( string $method, array $arguments, @@ -136,7 +144,7 @@ final public function testLoadMethodsCacheHit( $data = null, bool $multi = false, array $additionalCalls = [] - ) { + ): void { $cacheItem = $this->getCacheItem($key, $multi ? reset($data) : $data); $handlerMethodName = $this->getHandlerMethodName(); @@ -145,19 +153,27 @@ final public function testLoadMethodsCacheHit( $this->loggerMock->expects(self::never())->method('logCacheMiss'); if ($tagGeneratingArguments) { + $matcher = self::exactly(count($tagGeneratingArguments)); $this->cacheIdentifierGeneratorMock - ->expects(self::exactly(count($tagGeneratingArguments))) + ->expects($matcher) ->method('generateTag') - ->withConsecutive(...$tagGeneratingArguments) - ->willReturnOnConsecutiveCalls(...$tagGeneratingResults); + ->willReturnCallback(function (...$parameters) use ($matcher, $tagGeneratingArguments, $tagGeneratingResults) { + $this->assertEquals($tagGeneratingArguments[$matcher->numberOfInvocations() - 1], $parameters); + + return $tagGeneratingResults[$matcher->numberOfInvocations() - 1]; + }); } if ($keyGeneratingArguments) { + $matcher = self::exactly(count($keyGeneratingArguments)); $this->cacheIdentifierGeneratorMock - ->expects(self::exactly(count($keyGeneratingArguments))) + ->expects($matcher) ->method('generateKey') - ->withConsecutive(...$keyGeneratingArguments) - ->willReturnOnConsecutiveCalls(...$keyGeneratingResults); + ->willReturnCallback(function (...$parameters) use ($matcher, $keyGeneratingArguments, $keyGeneratingResults) { + $this->assertEquals($keyGeneratingArguments[$matcher->numberOfInvocations() - 1], $parameters); + + return $keyGeneratingResults[$matcher->numberOfInvocations() - 1]; + }); } if ($multi) { @@ -190,11 +206,9 @@ final public function testLoadMethodsCacheHit( self::assertEquals($data, $return); } - abstract public function providerForCachedLoadMethodsMiss(): array; + abstract public static function providerForCachedLoadMethodsMiss(): array; /** - * @dataProvider providerForCachedLoadMethodsMiss - * * @param string $method * @param array $arguments * @param string $key @@ -206,6 +220,7 @@ abstract public function providerForCachedLoadMethodsMiss(): array; * @param bool $multi Default false, set to true if method will lookup several cache items. * @param array $additionalCalls Sets of additional calls being made to handlers, with 4 values (0: handler name, 1: handler class, 2: method, 3: return data) */ + #[DataProvider('providerForCachedLoadMethodsMiss')] final public function testLoadMethodsCacheMiss( string $method, array $arguments, @@ -217,7 +232,7 @@ final public function testLoadMethodsCacheMiss( $data = null, bool $multi = false, array $additionalCalls = [] - ) { + ): void { $cacheItem = $this->getCacheItem($key, null); $handlerMethodName = $this->getHandlerMethodName(); @@ -226,19 +241,27 @@ final public function testLoadMethodsCacheMiss( $this->loggerMock->expects(self::never())->method('logCacheHit'); if ($tagGeneratingArguments) { + $matcher = self::exactly(count($tagGeneratingArguments)); $this->cacheIdentifierGeneratorMock - ->expects(self::exactly(count($tagGeneratingArguments))) + ->expects($matcher) ->method('generateTag') - ->withConsecutive(...$tagGeneratingArguments) - ->willReturnOnConsecutiveCalls(...$tagGeneratingResults); + ->willReturnCallback(function (...$parameters) use ($matcher, $tagGeneratingArguments, $tagGeneratingResults) { + $this->assertEquals($tagGeneratingArguments[$matcher->numberOfInvocations() - 1], $parameters); + + return $tagGeneratingResults[$matcher->numberOfInvocations() - 1]; + }); } if ($keyGeneratingArguments) { + $matcher = self::exactly(count($keyGeneratingArguments)); $this->cacheIdentifierGeneratorMock - ->expects(self::exactly(count($keyGeneratingArguments))) + ->expects($matcher) ->method('generateKey') - ->withConsecutive(...$keyGeneratingArguments) - ->willReturnOnConsecutiveCalls(...$keyGeneratingResults); + ->willReturnCallback(function (...$parameters) use ($matcher, $keyGeneratingArguments, $keyGeneratingResults) { + $this->assertEquals($keyGeneratingArguments[$matcher->numberOfInvocations() - 1], $parameters); + + return $keyGeneratingResults[$matcher->numberOfInvocations() - 1]; + }); } if ($multi) { diff --git a/tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php b/tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php index a27674cb6d..a33cd7c141 100644 --- a/tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php +++ b/tests/lib/Persistence/Cache/Adapter/InMemoryClearingProxyAdapterTest.php @@ -10,6 +10,7 @@ use Ibexa\Core\Persistence\Cache\Adapter\TransactionalInMemoryCacheAdapter; use Ibexa\Core\Persistence\Cache\InMemory\InMemoryCache; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\Cache\Adapter\TagAwareAdapterInterface; use Symfony\Component\Cache\CacheItem; @@ -75,7 +76,7 @@ protected function tearDown(): void parent::tearDown(); } - public function testGetItem() + public function testGetItem(): void { $item = $this->createCacheItem('first'); @@ -91,7 +92,7 @@ public function testGetItem() self::assertSame($item, $returnedItem); } - public function testGetItems() + public function testGetItems(): void { $items = [ 'first' => $this->createCacheItem('first'), @@ -113,7 +114,7 @@ public function testGetItems() /** * Symfony uses generators with getItems() so we need to make sure we handle that. */ - public function testGetItemsWithGenerator() + public function testGetItemsWithGenerator(): void { $items = [ 'first' => $this->createCacheItem('first'), @@ -132,7 +133,7 @@ public function testGetItemsWithGenerator() self::assertSame($items, $returnedItems); } - public function testHasItem() + public function testHasItem(): void { $this->innerPool ->expects(self::once()) @@ -145,10 +146,8 @@ public function testHasItem() self::assertTrue($this->cache->hasItem('first')); } - /** - * @dataProvider providerForDelete - */ - public function testDelete(string $method, $argument) + #[DataProvider('providerForDelete')] + public function testDelete(string $method, $argument): void { $this->innerPool ->expects(self::once()) @@ -165,7 +164,7 @@ public function testDelete(string $method, $argument) self::assertTrue($this->cache->$method($argument)); } - public function providerForDelete(): array + public static function providerForDelete(): array { return [ ['deleteItem', 'first'], @@ -176,10 +175,9 @@ public function providerForDelete(): array /** * Test for clear and invalidateTags as both expects a clear to in-memory as it on purpose does not track tags. - * - * @dataProvider providerForClearAndInvalidation */ - public function testClearAndInvalidation(string $method, $argument) + #[DataProvider('providerForClearAndInvalidation')] + public function testClearAndInvalidation(string $method, $argument): void { if ($argument) { $this->innerPool @@ -202,7 +200,7 @@ public function testClearAndInvalidation(string $method, $argument) self::assertTrue($this->cache->$method($argument)); } - public function providerForClearAndInvalidation(): array + public static function providerForClearAndInvalidation(): array { return [ ['invalidateTags', ['my_tag']], diff --git a/tests/lib/Persistence/Cache/BookmarkHandlerTest.php b/tests/lib/Persistence/Cache/BookmarkHandlerTest.php index 973ea7d2c2..4b8351b708 100644 --- a/tests/lib/Persistence/Cache/BookmarkHandlerTest.php +++ b/tests/lib/Persistence/Cache/BookmarkHandlerTest.php @@ -29,7 +29,7 @@ public function getHandlerClassName(): string return SPIBookmarkHandler::class; } - public function providerForUnCachedMethods(): array + public static function providerForUnCachedMethods(): array { // string $method, array $arguments, array? $tagGeneratingArguments, array? $keyGeneratingArguments, array? tags, array? $tags, string? $key, mixed? $returnValue return [ @@ -41,7 +41,7 @@ public function providerForUnCachedMethods(): array ]; } - public function providerForCachedLoadMethodsHit(): array + public static function providerForCachedLoadMethodsHit(): array { $bookmark = new Bookmark([ 'id' => 1, @@ -68,7 +68,7 @@ public function providerForCachedLoadMethodsHit(): array ]; } - public function providerForCachedLoadMethodsMiss(): array + public static function providerForCachedLoadMethodsMiss(): array { $bookmark = new Bookmark([ 'id' => 1, diff --git a/tests/lib/Persistence/Cache/ContentHandlerTest.php b/tests/lib/Persistence/Cache/ContentHandlerTest.php index 6c89b8e30c..89d9a469c2 100644 --- a/tests/lib/Persistence/Cache/ContentHandlerTest.php +++ b/tests/lib/Persistence/Cache/ContentHandlerTest.php @@ -19,10 +19,9 @@ use Ibexa\Contracts\Core\Persistence\Content\VersionInfo; use Ibexa\Contracts\Core\Repository\Values\Content\RelationType; use Ibexa\Core\Persistence\Cache\ContentHandler; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Cache\ContentHandler - */ +#[CoversClass(ContentHandler::class)] class ContentHandlerTest extends AbstractInMemoryCacheHandlerTestCase { public function getHandlerMethodName(): string @@ -38,7 +37,7 @@ public function getHandlerClassName(): string /** * @return array */ - public function providerForUnCachedMethods(): array + public static function providerForUnCachedMethods(): array { // string $method, array $arguments, array? $tagGeneratingArguments, array? $keyGeneratingArguments, array? $tags, array? $key, ?mixed $returnValue return [ @@ -78,7 +77,7 @@ public function providerForUnCachedMethods(): array /** * @return array */ - public function providerForCachedLoadMethodsHit(): array + public static function providerForCachedLoadMethodsHit(): array { $info = new ContentInfo(['id' => 2]); $version = new VersionInfo(['versionNo' => 1, 'contentInfo' => $info]); @@ -123,7 +122,7 @@ public function providerForCachedLoadMethodsHit(): array /** * @return array */ - public function providerForCachedLoadMethodsMiss(): array + public static function providerForCachedLoadMethodsMiss(): array { $info = new ContentInfo([ 'id' => 2, @@ -437,7 +436,7 @@ public function providerForCachedLoadMethodsMiss(): array ]; } - public function testDeleteContent() + public function testDeleteContent(): void { $this->loggerMock->expects(self::once())->method('logCall'); @@ -466,15 +465,26 @@ public function testDeleteContent() $this->cacheMock ->expects(self::never()) ->method('deleteItem'); + $matcher = self::exactly(2); $this->cacheIdentifierGeneratorMock - ->expects(self::exactly(2)) - ->method('generateTag') - ->withConsecutive( - ['content', [42], false], - ['content', [2], false] - ) - ->willReturnOnConsecutiveCalls('c-42', 'c-2'); + ->expects($matcher) + ->method('generateTag')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame('content', $parameters[0]); + $this->assertSame([42], $parameters[1]); + $this->assertFalse($parameters[2]); + + return 'c-42'; + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame('content', $parameters[0]); + $this->assertSame([2], $parameters[1]); + $this->assertFalse($parameters[2]); + + return 'c-2'; + } + }); $this->cacheMock ->expects(self::once()) diff --git a/tests/lib/Persistence/Cache/ContentLanguageHandlerTest.php b/tests/lib/Persistence/Cache/ContentLanguageHandlerTest.php index cd931f0693..01e555f108 100644 --- a/tests/lib/Persistence/Cache/ContentLanguageHandlerTest.php +++ b/tests/lib/Persistence/Cache/ContentLanguageHandlerTest.php @@ -26,7 +26,7 @@ public function getHandlerClassName(): string return Handler::class; } - public function providerForUnCachedMethods(): array + public static function providerForUnCachedMethods(): array { $language = new SPILanguage(['id' => 5, 'languageCode' => 'eng-GB']); @@ -66,7 +66,7 @@ public function providerForUnCachedMethods(): array ]; } - public function providerForCachedLoadMethodsHit(): array + public static function providerForCachedLoadMethodsHit(): array { $object = new SPILanguage(['id' => 5, 'languageCode' => 'eng-GB']); @@ -80,7 +80,7 @@ public function providerForCachedLoadMethodsHit(): array ]; } - public function providerForCachedLoadMethodsMiss(): array + public static function providerForCachedLoadMethodsMiss(): array { $object = new SPILanguage(['id' => 5, 'languageCode' => 'eng-GB']); diff --git a/tests/lib/Persistence/Cache/ContentTypeHandlerTest.php b/tests/lib/Persistence/Cache/ContentTypeHandlerTest.php index d6262aefd6..33a398c05d 100644 --- a/tests/lib/Persistence/Cache/ContentTypeHandlerTest.php +++ b/tests/lib/Persistence/Cache/ContentTypeHandlerTest.php @@ -34,7 +34,7 @@ public function getHandlerClassName(): string /** * @return array */ - public function providerForUnCachedMethods(): array + public static function providerForUnCachedMethods(): array { $groupUpdate = new SPITypeGroupUpdateStruct(['id' => 3, 'identifier' => 'media']); $typeUpdate = new SPITypeUpdateStruct(['identifier' => 'article', 'remoteId' => '34o9tj8394t']); @@ -181,7 +181,7 @@ public function providerForUnCachedMethods(): array /** * @return array */ - public function providerForCachedLoadMethodsHit(): array + public static function providerForCachedLoadMethodsHit(): array { $group = new SPITypeGroup(['id' => 3, 'identifier' => 'media']); $type = new SPIType(['id' => 5, 'identifier' => 'article', 'remoteId' => '34o9tj8394t']); @@ -238,7 +238,7 @@ public function providerForCachedLoadMethodsHit(): array ]; } - public function providerForCachedLoadMethodsMiss(): array + public static function providerForCachedLoadMethodsMiss(): array { $group = new SPITypeGroup(['id' => 3, 'identifier' => 'media']); $type = new SPIType(['id' => 5, 'identifier' => 'article', 'remoteId' => '34o9tj8394t']); @@ -402,7 +402,7 @@ public function providerForCachedLoadMethodsMiss(): array /** * Test cache invalidation when publishing Content type. */ - public function testPublish() + public function testPublish(): void { $tags = ['t-5', 'tm', 'cft-5']; $method = 'publish'; @@ -425,34 +425,60 @@ public function testPublish() ->method($method) ->with(...$arguments) ->willReturn(null); + $matcher = self::exactly(3); $this->cacheIdentifierGeneratorMock - ->expects(self::exactly(3)) - ->method('generateTag') - ->withConsecutive( - ['type', [5], false], - ['type_map', [], false], - ['content_fields_type', [5], false] - ) - ->willReturnOnConsecutiveCalls( - 't-5', - 'tm', - 'cft-5' - ); + ->expects($matcher) + ->method('generateTag')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame('type', $parameters[0]); + $this->assertSame([5], $parameters[1]); + $this->assertFalse($parameters[2]); + + return 't-5'; + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame('type_map', $parameters[0]); + $this->assertSame([], $parameters[1]); + $this->assertFalse($parameters[2]); + + return 'tm'; + } + if ($matcher->numberOfInvocations() === 3) { + $this->assertSame('content_fields_type', $parameters[0]); + $this->assertSame([5], $parameters[1]); + $this->assertFalse($parameters[2]); + + return 'cft-5'; + } + }); + $matcher = self::exactly(3); $this->cacheIdentifierGeneratorMock - ->expects(self::exactly(3)) - ->method('generateKey') - ->withConsecutive( - ['content_type', [], true], - ['content_type_list_by_group', [3], true], - ['content_type_list_by_group', [4], true] - ) - ->willReturnOnConsecutiveCalls( - 'ibx-ct', - 'ibx-ctlbg-3', - 'ibx-ctlbg-4' - ); + ->expects($matcher) + ->method('generateKey')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame('content_type', $parameters[0]); + $this->assertSame([], $parameters[1]); + $this->assertTrue($parameters[2]); + + return 'ibx-ct'; + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame('content_type_list_by_group', $parameters[0]); + $this->assertSame([3], $parameters[1]); + $this->assertTrue($parameters[2]); + + return 'ibx-ctlbg-3'; + } + if ($matcher->numberOfInvocations() === 3) { + $this->assertSame('content_type_list_by_group', $parameters[0]); + $this->assertSame([4], $parameters[1]); + $this->assertTrue($parameters[2]); + + return 'ibx-ctlbg-4'; + } + }); $this->cacheMock ->expects(!empty($tags) ? self::once() : self::never()) diff --git a/tests/lib/Persistence/Cache/Identifier/CacheIdentifierGeneratorTest.php b/tests/lib/Persistence/Cache/Identifier/CacheIdentifierGeneratorTest.php index dcc7eb690d..22f6aea252 100644 --- a/tests/lib/Persistence/Cache/Identifier/CacheIdentifierGeneratorTest.php +++ b/tests/lib/Persistence/Cache/Identifier/CacheIdentifierGeneratorTest.php @@ -10,6 +10,7 @@ use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException; use Ibexa\Core\Persistence\Cache\Identifier\CacheIdentifierGenerator; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; /** @@ -37,7 +38,7 @@ public function setUp(): void ); } - public function providerForTestGenerateTag(): array + public static function providerForTestGenerateTag(): array { return [ [['content', [], false], 'c'], @@ -46,7 +47,7 @@ public function providerForTestGenerateTag(): array ]; } - public function providerForTestGenerateTagThrowsInvalidArgumentException(): array + public static function providerForTestGenerateTagThrowsInvalidArgumentException(): array { return [ [['test', [], false], 'c'], @@ -54,7 +55,7 @@ public function providerForTestGenerateTagThrowsInvalidArgumentException(): arra ]; } - public function providerForTestGenerateKey(): array + public static function providerForTestGenerateKey(): array { return [ [['content_type', [], true], 'ibx-ct'], @@ -63,7 +64,7 @@ public function providerForTestGenerateKey(): array ]; } - public function providerForTestGenerateKeyThrowsInvalidArgumentException(): array + public static function providerForTestGenerateKeyThrowsInvalidArgumentException(): array { return [ [['test', [], false], 'c'], @@ -71,9 +72,7 @@ public function providerForTestGenerateKeyThrowsInvalidArgumentException(): arra ]; } - /** - * @dataProvider providerForTestGenerateTag - */ + #[DataProvider('providerForTestGenerateTag')] public function testGenerateTag(array $arguments, string $resultKey): void { self::assertEquals( @@ -82,9 +81,7 @@ public function testGenerateTag(array $arguments, string $resultKey): void ); } - /** - * @dataProvider providerForTestGenerateTagThrowsInvalidArgumentException - */ + #[DataProvider('providerForTestGenerateTagThrowsInvalidArgumentException')] public function testGenerateTagThrowsInvalidArgumentException(array $arguments, string $resultKey): void { $this->expectException(InvalidArgumentException::class); @@ -95,9 +92,7 @@ public function testGenerateTagThrowsInvalidArgumentException(array $arguments, ); } - /** - * @dataProvider providerForTestGenerateKey - */ + #[DataProvider('providerForTestGenerateKey')] public function testGenerateKey(array $arguments, string $resultKey): void { self::assertEquals( @@ -106,9 +101,7 @@ public function testGenerateKey(array $arguments, string $resultKey): void ); } - /** - * @dataProvider providerForTestGenerateKeyThrowsInvalidArgumentException - */ + #[DataProvider('providerForTestGenerateKeyThrowsInvalidArgumentException')] public function testGenerateKeyThrowsInvalidArgumentException(array $arguments, string $resultKey): void { $this->expectException(InvalidArgumentException::class); diff --git a/tests/lib/Persistence/Cache/Identifier/CacheIdentifierSanitizerTest.php b/tests/lib/Persistence/Cache/Identifier/CacheIdentifierSanitizerTest.php index 90f3c80055..78711619fc 100644 --- a/tests/lib/Persistence/Cache/Identifier/CacheIdentifierSanitizerTest.php +++ b/tests/lib/Persistence/Cache/Identifier/CacheIdentifierSanitizerTest.php @@ -9,6 +9,7 @@ namespace Ibexa\Tests\Core\Persistence\Cache\Identifier; use Ibexa\Core\Persistence\Cache\Identifier\CacheIdentifierSanitizer; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; /** @@ -24,7 +25,7 @@ public function setUp(): void $this->cacheIdentifierSanitizer = new CacheIdentifierSanitizer(); } - public function providerForTestEscapeCacheKey(): array + public static function providerForTestEscapeCacheKey(): array { return [ [['key'], 'key'], @@ -33,9 +34,7 @@ public function providerForTestEscapeCacheKey(): array ]; } - /** - * @dataProvider providerForTestEscapeCacheKey - */ + #[DataProvider('providerForTestEscapeCacheKey')] public function testEscapeCacheKey(array $arguments, string $resultKey): void { self::assertEquals( diff --git a/tests/lib/Persistence/Cache/LocationHandlerTest.php b/tests/lib/Persistence/Cache/LocationHandlerTest.php index aada9945ec..708d722aec 100644 --- a/tests/lib/Persistence/Cache/LocationHandlerTest.php +++ b/tests/lib/Persistence/Cache/LocationHandlerTest.php @@ -27,7 +27,7 @@ public function getHandlerClassName(): string return SPILocationHandler::class; } - public function providerForUnCachedMethods(): array + public static function providerForUnCachedMethods(): array { // string $method, array $arguments, array? $tagGeneratingArguments, array? $keyGeneratingArguments, array? $tags, array? $key, ?mixed $returnValue return [ @@ -74,7 +74,7 @@ public function providerForUnCachedMethods(): array ]; } - public function providerForCachedLoadMethodsHit(): array + public static function providerForCachedLoadMethodsHit(): array { $location = new Location(['id' => 12]); @@ -133,7 +133,7 @@ public function providerForCachedLoadMethodsHit(): array ]; } - public function providerForCachedLoadMethodsMiss(): array + public static function providerForCachedLoadMethodsMiss(): array { $location = new Location( [ diff --git a/tests/lib/Persistence/Cache/LocationPathConverterTest.php b/tests/lib/Persistence/Cache/LocationPathConverterTest.php index 49acecf2dc..a62e424409 100644 --- a/tests/lib/Persistence/Cache/LocationPathConverterTest.php +++ b/tests/lib/Persistence/Cache/LocationPathConverterTest.php @@ -9,6 +9,7 @@ namespace Ibexa\Tests\Core\Persistence\Cache; use Ibexa\Core\Persistence\Cache\LocationPathConverter; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; /** @@ -24,7 +25,7 @@ public function setUp(): void $this->locationPathConverter = new LocationPathConverter(); } - public function providerForTestConvertToPathIds(): array + public static function providerForTestConvertToPathIds(): array { return [ [[''], []], @@ -34,9 +35,7 @@ public function providerForTestConvertToPathIds(): array ]; } - /** - * @dataProvider providerForTestConvertToPathIds - */ + #[DataProvider('providerForTestConvertToPathIds')] public function testConvertToPathIds(array $arguments, array $resultArray): void { self::assertEquals( diff --git a/tests/lib/Persistence/Cache/NotificationHandlerTest.php b/tests/lib/Persistence/Cache/NotificationHandlerTest.php index c88509654e..995041d4b6 100644 --- a/tests/lib/Persistence/Cache/NotificationHandlerTest.php +++ b/tests/lib/Persistence/Cache/NotificationHandlerTest.php @@ -30,7 +30,7 @@ public function getHandlerClassName(): string return SPINotificationHandler::class; } - public function providerForUnCachedMethods(): array + public static function providerForUnCachedMethods(): array { $ownerId = 7; $notificationId = 5; @@ -126,7 +126,7 @@ public function providerForUnCachedMethods(): array ]; } - public function providerForCachedLoadMethodsHit(): array + public static function providerForCachedLoadMethodsHit(): array { $notificationId = 5; $ownerId = 7; @@ -174,7 +174,7 @@ public function providerForCachedLoadMethodsHit(): array ]; } - public function providerForCachedLoadMethodsMiss(): array + public static function providerForCachedLoadMethodsMiss(): array { $notificationId = 5; $ownerId = 7; diff --git a/tests/lib/Persistence/Cache/ObjectStateHandlerTest.php b/tests/lib/Persistence/Cache/ObjectStateHandlerTest.php index ea950678aa..09384e1d17 100644 --- a/tests/lib/Persistence/Cache/ObjectStateHandlerTest.php +++ b/tests/lib/Persistence/Cache/ObjectStateHandlerTest.php @@ -27,7 +27,7 @@ public function getHandlerClassName(): string return SPIObjectStateHandler::class; } - public function providerForUnCachedMethods(): array + public static function providerForUnCachedMethods(): array { // string $method, array $arguments, array? $tagGeneratingArguments, array? $keyGeneratingArguments, array? $tags, array? $key, ?mixed $returnValue return [ @@ -42,7 +42,7 @@ public function providerForUnCachedMethods(): array ]; } - public function providerForCachedLoadMethodsHit(): array + public static function providerForCachedLoadMethodsHit(): array { $group = new SPIObjectStateGroup(['id' => 5]); $state = new SPIObjectState(['id' => 7]); @@ -95,7 +95,7 @@ public function providerForCachedLoadMethodsHit(): array ]; } - public function providerForCachedLoadMethodsMiss(): array + public static function providerForCachedLoadMethodsMiss(): array { $group = new SPIObjectStateGroup(['id' => 5]); $state = new SPIObjectState([ diff --git a/tests/lib/Persistence/Cache/PersistenceHandlerTest.php b/tests/lib/Persistence/Cache/PersistenceHandlerTest.php index 27d057361d..7c22889131 100644 --- a/tests/lib/Persistence/Cache/PersistenceHandlerTest.php +++ b/tests/lib/Persistence/Cache/PersistenceHandlerTest.php @@ -9,21 +9,22 @@ use Ibexa\Contracts\Core\Persistence as SPIPersistence; use Ibexa\Core\Persistence\Cache; +use Ibexa\Core\Persistence\Cache\Handler; +use PHPUnit\Framework\Attributes\CoversClass; /** * Test case for Persistence\Cache\Handler. - * - * @covers \Ibexa\Core\Persistence\Cache\Handler */ +#[CoversClass(Handler::class)] class PersistenceHandlerTest extends AbstractBaseHandlerTestCase { - public function testHandler() + public function testHandler(): void { self::assertInstanceOf(SPIPersistence\Handler::class, $this->persistenceCacheHandler); self::assertInstanceOf(Cache\Handler::class, $this->persistenceCacheHandler); } - public function testContentHandler() + public function testContentHandler(): void { $this->loggerMock->expects(self::never())->method(self::anything()); $handler = $this->persistenceCacheHandler->contentHandler(); @@ -31,7 +32,7 @@ public function testContentHandler() self::assertInstanceOf(Cache\ContentHandler::class, $handler); } - public function testLanguageHandler() + public function testLanguageHandler(): void { $this->loggerMock->expects(self::never())->method(self::anything()); $handler = $this->persistenceCacheHandler->contentLanguageHandler(); @@ -39,7 +40,7 @@ public function testLanguageHandler() self::assertInstanceOf(Cache\ContentLanguageHandler::class, $handler); } - public function testContentTypeHandler() + public function testContentTypeHandler(): void { $this->loggerMock->expects(self::never())->method(self::anything()); $handler = $this->persistenceCacheHandler->contentTypeHandler(); @@ -47,7 +48,7 @@ public function testContentTypeHandler() self::assertInstanceOf(Cache\ContentTypeHandler::class, $handler); } - public function testContentLocationHandler() + public function testContentLocationHandler(): void { $this->loggerMock->expects(self::never())->method(self::anything()); $handler = $this->persistenceCacheHandler->locationHandler(); @@ -55,7 +56,7 @@ public function testContentLocationHandler() self::assertInstanceOf(Cache\LocationHandler::class, $handler); } - public function testTrashHandler() + public function testTrashHandler(): void { $this->loggerMock->expects(self::never())->method(self::anything()); $handler = $this->persistenceCacheHandler->trashHandler(); @@ -63,7 +64,7 @@ public function testTrashHandler() self::assertInstanceOf(Cache\TrashHandler::class, $handler); } - public function testObjectStateHandler() + public function testObjectStateHandler(): void { $this->loggerMock->expects(self::never())->method(self::anything()); $handler = $this->persistenceCacheHandler->objectStateHandler(); @@ -71,7 +72,7 @@ public function testObjectStateHandler() self::assertInstanceOf(Cache\ObjectStateHandler::class, $handler); } - public function testSectionHandler() + public function testSectionHandler(): void { $this->loggerMock->expects(self::never())->method(self::anything()); $handler = $this->persistenceCacheHandler->sectionHandler(); @@ -79,7 +80,7 @@ public function testSectionHandler() self::assertInstanceOf(Cache\SectionHandler::class, $handler); } - public function testUserHandler() + public function testUserHandler(): void { $this->loggerMock->expects(self::never())->method(self::anything()); $handler = $this->persistenceCacheHandler->userHandler(); @@ -87,7 +88,7 @@ public function testUserHandler() self::assertInstanceOf(Cache\UserHandler::class, $handler); } - public function testUrlAliasHandler() + public function testUrlAliasHandler(): void { $this->loggerMock->expects(self::never())->method(self::anything()); $handler = $this->persistenceCacheHandler->urlAliasHandler(); @@ -95,7 +96,7 @@ public function testUrlAliasHandler() self::assertInstanceOf(Cache\UrlAliasHandler::class, $handler); } - public function testUrlWildcardHandler() + public function testUrlWildcardHandler(): void { $this->loggerMock->expects(self::never())->method(self::anything()); $handler = $this->persistenceCacheHandler->urlWildcardHandler(); @@ -103,7 +104,7 @@ public function testUrlWildcardHandler() self::assertInstanceOf(Cache\UrlWildcardHandler::class, $handler); } - public function testTransactionHandler() + public function testTransactionHandler(): void { $this->loggerMock->expects(self::never())->method(self::anything()); $handler = $this->persistenceCacheHandler->transactionHandler(); diff --git a/tests/lib/Persistence/Cache/PersistenceLoggerTest.php b/tests/lib/Persistence/Cache/PersistenceLoggerTest.php index d6f928cf64..987f887d8c 100644 --- a/tests/lib/Persistence/Cache/PersistenceLoggerTest.php +++ b/tests/lib/Persistence/Cache/PersistenceLoggerTest.php @@ -9,11 +9,11 @@ namespace Ibexa\Tests\Core\Persistence\Cache; use Ibexa\Core\Persistence\Cache\PersistenceLogger; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Depends; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Cache\PersistenceLogger - */ +#[CoversClass(PersistenceLogger::class)] class PersistenceLoggerTest extends TestCase { protected PersistenceLogger $logger; @@ -50,9 +50,7 @@ public function testLogCall(): PersistenceLogger return $this->logger; } - /** - * @depends testLogCall - */ + #[Depends('testLogCall')] public function testGetCallValues(PersistenceLogger $logger): void { $calls = $logger->getCalls(); diff --git a/tests/lib/Persistence/Cache/SectionHandlerTest.php b/tests/lib/Persistence/Cache/SectionHandlerTest.php index 2d3d1fbfaa..8597e4dfdf 100644 --- a/tests/lib/Persistence/Cache/SectionHandlerTest.php +++ b/tests/lib/Persistence/Cache/SectionHandlerTest.php @@ -25,7 +25,7 @@ public function getHandlerClassName(): string return SPISectionHandler::class; } - public function providerForUnCachedMethods(): array + public static function providerForUnCachedMethods(): array { // string $method, array $arguments, array? $tagGeneratingArguments, array? $keyGeneratingArguments, array? $tags, array? $key, ?mixed $returnValue return [ @@ -40,7 +40,7 @@ public function providerForUnCachedMethods(): array ]; } - public function providerForCachedLoadMethodsHit(): array + public static function providerForCachedLoadMethodsHit(): array { $object = new SPISection(['id' => 5]); @@ -51,7 +51,7 @@ public function providerForCachedLoadMethodsHit(): array ]; } - public function providerForCachedLoadMethodsMiss(): array + public static function providerForCachedLoadMethodsMiss(): array { $object = new SPISection(['id' => 5]); diff --git a/tests/lib/Persistence/Cache/SettingHandlerTest.php b/tests/lib/Persistence/Cache/SettingHandlerTest.php index 3fabf581ef..34010a3070 100644 --- a/tests/lib/Persistence/Cache/SettingHandlerTest.php +++ b/tests/lib/Persistence/Cache/SettingHandlerTest.php @@ -25,7 +25,7 @@ public function getHandlerClassName(): string return SettingHandler::class; } - public function providerForUnCachedMethods(): array + public static function providerForUnCachedMethods(): array { // string $method, array $arguments, array? $tagGeneratingArguments, array? $keyGeneratingArguments, array? $tags, array? $key, ?mixed $returnValue return [ @@ -57,7 +57,7 @@ public function providerForUnCachedMethods(): array ]; } - public function providerForCachedLoadMethodsHit(): array + public static function providerForCachedLoadMethodsHit(): array { $object = new Setting(['group' => 'group_a1', 'identifier' => 'identifier_b2']); @@ -76,7 +76,7 @@ public function providerForCachedLoadMethodsHit(): array ]; } - public function providerForCachedLoadMethodsMiss(): array + public static function providerForCachedLoadMethodsMiss(): array { $object = new Setting(['group' => 'group_a1', 'identifier' => 'identifier_b2']); diff --git a/tests/lib/Persistence/Cache/TransactionHandlerTest.php b/tests/lib/Persistence/Cache/TransactionHandlerTest.php index f4ac46b39e..d0375a0e36 100644 --- a/tests/lib/Persistence/Cache/TransactionHandlerTest.php +++ b/tests/lib/Persistence/Cache/TransactionHandlerTest.php @@ -8,10 +8,10 @@ namespace Ibexa\Tests\Core\Persistence\Cache; use Ibexa\Contracts\Core\Persistence\TransactionHandler; +use Ibexa\Core\Persistence\Cache\TransactionHandler as CoveredTransactionHandler; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Cache\TransactionHandler - */ +#[CoversClass(CoveredTransactionHandler::class)] class TransactionHandlerTest extends AbstractCacheHandlerTestCase { public function getHandlerMethodName(): string @@ -24,7 +24,7 @@ public function getHandlerClassName(): string return TransactionHandler::class; } - public function providerForUnCachedMethods(): array + public static function providerForUnCachedMethods(): array { // string $method, array $arguments, array $arguments, array? $cacheTagGeneratingArguments, array? $cacheKeyGeneratingArguments, array? $tags, string? $key return [ @@ -33,21 +33,23 @@ public function providerForUnCachedMethods(): array ]; } - public function providerForCachedLoadMethodsHit(): array + public static function providerForCachedLoadMethodsHit(): array { // string $method, array $arguments, array? $cacheIdentifierGeneratorArguments, array? $cacheIdentifierGeneratorResults, string $key, mixed? $data return [ + [self::NO_DATA_METHOD, [], ''], ]; } - public function providerForCachedLoadMethodsMiss(): array + public static function providerForCachedLoadMethodsMiss(): array { // string $method, array $arguments, array? $cacheIdentifierGeneratorArguments, array? $cacheIdentifierGeneratorResults, string $key, mixed? $data return [ + [self::NO_DATA_METHOD, [], ''], ]; } - public function testRollback() + public function testRollback(): void { $this->loggerMock ->expects(self::once()) @@ -75,7 +77,7 @@ public function testRollback() $handler->rollback(); } - public function testCommitStopsCacheTransaction() + public function testCommitStopsCacheTransaction(): void { $this->loggerMock ->expects(self::once()) @@ -99,7 +101,7 @@ public function testCommitStopsCacheTransaction() $handler->commit(); } - public function testBeginTransactionStartsCacheTransaction() + public function testBeginTransactionStartsCacheTransaction(): void { $this->loggerMock ->expects(self::once()) diff --git a/tests/lib/Persistence/Cache/TrashHandlerTest.php b/tests/lib/Persistence/Cache/TrashHandlerTest.php index 373446e032..b33718c347 100644 --- a/tests/lib/Persistence/Cache/TrashHandlerTest.php +++ b/tests/lib/Persistence/Cache/TrashHandlerTest.php @@ -32,7 +32,7 @@ public function getHandlerClassName(): string return TrashHandler::class; } - public function providerForUnCachedMethods(): array + public static function providerForUnCachedMethods(): array { // string $method, array $arguments, array? $tagGeneratingArguments, array? $keyGeneratingArguments, array? $tags, array? $key, ?mixed $returnValue return [ @@ -40,21 +40,23 @@ public function providerForUnCachedMethods(): array ]; } - public function providerForCachedLoadMethodsHit(): array + public static function providerForCachedLoadMethodsHit(): array { // string $method, array $arguments, string $key, array? $tagGeneratingArguments, array? $tagGeneratingResults, array? $keyGeneratingArguments, array? $keyGeneratingResults, mixed? $data, bool $multi return [ + [self::NO_DATA_METHOD, [], ''], ]; } - public function providerForCachedLoadMethodsMiss(): array + public static function providerForCachedLoadMethodsMiss(): array { // string $method, array $arguments, string $key, array? $tagGeneratingArguments, array? $tagGeneratingResults, array? $keyGeneratingArguments, array? $keyGeneratingResults, mixed? $data, bool $multi return [ + [self::NO_DATA_METHOD, [], ''], ]; } - public function testRecover() + public function testRecover(): void { $originalLocationId = 6; $targetLocationId = 2; @@ -75,7 +77,7 @@ public function testRecover() $handler->recover($originalLocationId, $targetLocationId); } - public function testTrashSubtree() + public function testTrashSubtree(): void { $locationId = 6; $contentId = 42; @@ -111,7 +113,6 @@ private function setUpRoleAssignmentInvalidation(int $locationId, int $contentId $this->loggerMock->expects(self::once())->method('logCall'); $innerHandler = $this->createMock($this->getHandlerClassName()); - $contentHandlerMock = $this->createMock(ContentHandler::class); $locationHandlerMock = $this->createMock(LocationHandler::class); $userHandlerMock = $this->createMock(PersistenceUserHandler::class); @@ -126,7 +127,7 @@ private function setUpRoleAssignmentInvalidation(int $locationId, int $contentId $this->persistenceHandlerMock ->method('contentHandler') - ->willReturn($contentHandlerMock); + ->willReturn(self::createStub(ContentHandler::class)); $this->persistenceHandlerMock ->method('locationHandler') @@ -140,20 +141,33 @@ private function setUpRoleAssignmentInvalidation(int $locationId, int $contentId ->expects(self::once()) ->method($this->getHandlerMethodName()) ->willReturn($innerHandler); + $matcher = self::exactly(3); $this->cacheIdentifierGeneratorMock - ->expects(self::exactly(3)) - ->method('generateTag') - ->withConsecutive( - ['role_assignment_role_list', [$roleId], false], - ['content', [$contentId], false], - ['location_path', [$locationId], false] - ) - ->willReturnOnConsecutiveCalls( - 'rarl-' . $roleId, - 'c-' . $contentId, - 'lp-' . $locationId - ); + ->expects($matcher) + ->method('generateTag')->willReturnCallback(function (...$parameters) use ($matcher, $roleId, $contentId, $locationId) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame('role_assignment_role_list', $parameters[0]); + $this->assertSame([$roleId], $parameters[1]); + $this->assertFalse($parameters[2]); + + return 'rarl-' . $roleId; + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame('content', $parameters[0]); + $this->assertSame([$contentId], $parameters[1]); + $this->assertFalse($parameters[2]); + + return 'c-' . $contentId; + } + if ($matcher->numberOfInvocations() === 3) { + $this->assertSame('location_path', $parameters[0]); + $this->assertSame([$locationId], $parameters[1]); + $this->assertFalse($parameters[2]); + + return 'lp-' . $locationId; + } + }); $this->cacheMock ->expects(self::once()) @@ -163,7 +177,7 @@ private function setUpRoleAssignmentInvalidation(int $locationId, int $contentId return $innerHandler; } - public function testDeleteTrashItem() + public function testDeleteTrashItem(): void { $trashedId = 6; $contentId = 42; @@ -207,20 +221,33 @@ public function testDeleteTrashItem() 'lp-' . $trashedId, 'c-' . $relationSourceContentId, ]; + $matcher = self::exactly(3); $this->cacheIdentifierGeneratorMock - ->expects(self::exactly(3)) - ->method('generateTag') - ->withConsecutive( - ['content', [$relationSourceContentId], false], - ['content', [$contentId], false], - ['location_path', [$trashedId], false] - ) - ->willReturnOnConsecutiveCalls( - 'c-' . $relationSourceContentId, - 'c-' . $contentId, - 'lp-' . $trashedId - ); + ->expects($matcher) + ->method('generateTag')->willReturnCallback(function (...$parameters) use ($matcher, $relationSourceContentId, $contentId, $trashedId) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame('content', $parameters[0]); + $this->assertSame([$relationSourceContentId], $parameters[1]); + $this->assertFalse($parameters[2]); + + return 'c-' . $relationSourceContentId; + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame('content', $parameters[0]); + $this->assertSame([$contentId], $parameters[1]); + $this->assertFalse($parameters[2]); + + return 'c-' . $contentId; + } + if ($matcher->numberOfInvocations() === 3) { + $this->assertSame('location_path', $parameters[0]); + $this->assertSame([$trashedId], $parameters[1]); + $this->assertFalse($parameters[2]); + + return 'lp-' . $trashedId; + } + }); $this->cacheMock ->expects(self::once()) @@ -232,7 +259,7 @@ public function testDeleteTrashItem() $handler->deleteTrashItem($trashedId); } - public function testEmptyTrash() + public function testEmptyTrash(): void { $trashedId = 6; $contentId = 42; @@ -278,13 +305,17 @@ public function testEmptyTrash() 'c-' . $contentId, 'lp-' . $trashedId, ]; + $matcher = self::exactly(6); //one set of arguments and tags for each relation $this->cacheIdentifierGeneratorMock - ->expects(self::exactly(6)) + ->expects($matcher) ->method('generateTag') - ->withConsecutive(...array_merge($cacheIdentifierGeneratorArguments, $cacheIdentifierGeneratorArguments)) - ->willReturnOnConsecutiveCalls(...array_merge($tags, $tags)); + ->willReturnCallback(function (...$parameters) use ($matcher, $cacheIdentifierGeneratorArguments, $tags) { + $this->assertSame(array_merge($cacheIdentifierGeneratorArguments, $cacheIdentifierGeneratorArguments)[$matcher->numberOfInvocations() - 1], $parameters); + + return array_merge($tags, $tags)[$matcher->numberOfInvocations() - 1]; + }); $this->cacheMock ->expects(self::once()) diff --git a/tests/lib/Persistence/Cache/URLHandlerTest.php b/tests/lib/Persistence/Cache/URLHandlerTest.php index 029e6f1920..585f18ffb0 100644 --- a/tests/lib/Persistence/Cache/URLHandlerTest.php +++ b/tests/lib/Persistence/Cache/URLHandlerTest.php @@ -24,7 +24,7 @@ public function getHandlerClassName(): string return SpiURLHandler::class; } - public function providerForUnCachedMethods(): array + public static function providerForUnCachedMethods(): array { // string $method, array $arguments, array? $tagGeneratingArguments, array? $keyGeneratingArguments, array? $tags, array? $key, ?mixed $returnValue return [ @@ -34,7 +34,7 @@ public function providerForUnCachedMethods(): array ]; } - public function providerForCachedLoadMethodsHit(): array + public static function providerForCachedLoadMethodsHit(): array { $url = new URL(['id' => 1]); @@ -44,7 +44,7 @@ public function providerForCachedLoadMethodsHit(): array ]; } - public function providerForCachedLoadMethodsMiss(): array + public static function providerForCachedLoadMethodsMiss(): array { $url = new URL(['id' => 1]); @@ -91,38 +91,60 @@ public function testUpdateUrlWhenAddressIsUpdated(): void ->method('updateUrl') ->with($urlId, $updateStruct) ->willReturn(true); + $matcher = self::exactly(4); $this->cacheIdentifierGeneratorMock - ->expects(self::exactly(4)) - ->method('generateTag') - ->withConsecutive( - ['url', [1], false], - ['content', [2], false], - ['content', [3], false], - ['content', [5], false] - ) - ->willReturnOnConsecutiveCalls( - 'url-1', - 'c-2', - 'c-3', - 'c-5' - ); - + ->expects($matcher) + ->method('generateTag')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame('url', $parameters[0]); + $this->assertSame([1], $parameters[1]); + $this->assertFalse($parameters[2]); + + return 'url-1'; + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame('content', $parameters[0]); + $this->assertSame([2], $parameters[1]); + $this->assertFalse($parameters[2]); + + return 'c-2'; + } + if ($matcher->numberOfInvocations() === 3) { + $this->assertSame('content', $parameters[0]); + $this->assertSame([3], $parameters[1]); + $this->assertFalse($parameters[2]); + + return 'c-3'; + } + if ($matcher->numberOfInvocations() === 4) { + $this->assertSame('content', $parameters[0]); + $this->assertSame([5], $parameters[1]); + $this->assertFalse($parameters[2]); + + return 'c-5'; + } + }); + + $invalidateTagsMatcher = self::exactly(2); $this->cacheMock - ->expects(self::at(0)) + ->expects($invalidateTagsMatcher) ->method('invalidateTags') - ->with(['url-1']); + ->willReturnCallback(static function (array $tags) use ($invalidateTagsMatcher): bool { + if ($invalidateTagsMatcher->numberOfInvocations() === 1) { + self::assertSame(['url-1'], $tags); + } else { + self::assertSame(['c-2', 'c-3', 'c-5'], $tags); + } - $this->cacheMock - ->expects(self::at(1)) - ->method('invalidateTags') - ->with(['c-2', 'c-3', 'c-5']); + return true; + }); $handler = $this->persistenceCacheHandler->urlHandler(); $handler->updateUrl($urlId, $updateStruct); } - public function testUpdateUrlStatusIsUpdated() + public function testUpdateUrlStatusIsUpdated(): void { $urlId = 1; $updateStruct = new URLUpdateStruct(); @@ -147,7 +169,7 @@ public function testUpdateUrlStatusIsUpdated() ->willReturn('url-1'); $this->cacheMock - ->expects(self::at(0)) + ->expects(self::once()) ->method('invalidateTags') ->with(['url-1']); diff --git a/tests/lib/Persistence/Cache/UrlAliasHandlerTest.php b/tests/lib/Persistence/Cache/UrlAliasHandlerTest.php index df892cd83e..5b6c1747f4 100644 --- a/tests/lib/Persistence/Cache/UrlAliasHandlerTest.php +++ b/tests/lib/Persistence/Cache/UrlAliasHandlerTest.php @@ -25,7 +25,7 @@ public function getHandlerClassName(): string return SPIUrlAliasHandler::class; } - public function providerForUnCachedMethods(): array + public static function providerForUnCachedMethods(): array { // string $method, array $arguments, array? $tagGeneratingArguments, array? $keyGeneratingArguments, array? $tags, array? $key, ?mixed $returnValue return [ @@ -141,7 +141,7 @@ public function providerForUnCachedMethods(): array ]; } - public function providerForCachedLoadMethodsHit(): array + public static function providerForCachedLoadMethodsHit(): array { $object = new UrlAlias(['id' => 5]); @@ -154,7 +154,7 @@ public function providerForCachedLoadMethodsHit(): array ]; } - public function providerForCachedLoadMethodsMiss(): array + public static function providerForCachedLoadMethodsMiss(): array { $object = new UrlAlias(['id' => 5]); diff --git a/tests/lib/Persistence/Cache/UrlWildcardHandlerTest.php b/tests/lib/Persistence/Cache/UrlWildcardHandlerTest.php index 07478e3a96..7b2f600fc8 100644 --- a/tests/lib/Persistence/Cache/UrlWildcardHandlerTest.php +++ b/tests/lib/Persistence/Cache/UrlWildcardHandlerTest.php @@ -22,7 +22,7 @@ public function getHandlerClassName(): string return SpiUrlWildcardHandler::class; } - public function providerForUnCachedMethods(): array + public static function providerForUnCachedMethods(): array { $wildcard = new UrlWildcard(['id' => 1]); @@ -35,7 +35,7 @@ public function providerForUnCachedMethods(): array ]; } - public function providerForCachedLoadMethodsHit(): array + public static function providerForCachedLoadMethodsHit(): array { $wildcard = new UrlWildcard(['id' => 1]); @@ -46,7 +46,7 @@ public function providerForCachedLoadMethodsHit(): array ]; } - public function providerForCachedLoadMethodsMiss(): array + public static function providerForCachedLoadMethodsMiss(): array { $wildcard = new UrlWildcard(['id' => 1]); diff --git a/tests/lib/Persistence/Cache/UserHandlerTest.php b/tests/lib/Persistence/Cache/UserHandlerTest.php index a1248b54c0..62fdb726ae 100644 --- a/tests/lib/Persistence/Cache/UserHandlerTest.php +++ b/tests/lib/Persistence/Cache/UserHandlerTest.php @@ -33,7 +33,7 @@ public function getHandlerClassName(): string return SPIUserHandler::class; } - public function providerForUnCachedMethods(): array + public static function providerForUnCachedMethods(): array { $user = new User(['id' => 14, 'login' => 'otto', 'email' => 'otto@ibexa.co']); $policy = new Policy(['id' => 13, 'roleId' => 9]); @@ -164,7 +164,7 @@ public function providerForUnCachedMethods(): array ]; } - public function providerForCachedLoadMethodsHit(): array + public static function providerForCachedLoadMethodsHit(): array { $user = new User(['id' => 14]); $role = new Role(['id' => 9]); @@ -268,7 +268,7 @@ public function providerForCachedLoadMethodsHit(): array ]; } - public function providerForCachedLoadMethodsMiss(): array + public static function providerForCachedLoadMethodsMiss(): array { $user = new User(['id' => 14]); $role = new Role(['id' => 9]); @@ -467,7 +467,7 @@ public function providerForCachedLoadMethodsMiss(): array ]; } - public function testPublishRoleDraftFromExistingRole() + public function testPublishRoleDraftFromExistingRole(): void { $this->loggerMock->expects(self::once())->method('logCall'); $innerHandlerMock = $this->createMock(SPIUserHandler::class); @@ -512,7 +512,7 @@ public function testPublishRoleDraftFromExistingRole() $handler->publishRoleDraft($roleDraftId); } - public function testPublishNewRoleDraft() + public function testPublishNewRoleDraft(): void { $this->loggerMock->expects(self::once())->method('logCall'); $innerHandlerMock = $this->createMock(SPIUserHandler::class); @@ -522,12 +522,12 @@ public function testPublishNewRoleDraft() ->willReturn($innerHandlerMock); $roleDraftId = 33; $innerHandlerMock - ->expects(self::at(0)) + ->expects(self::once()) ->method('loadRole') ->with($roleDraftId, Role::STATUS_DRAFT) ->willReturn(new Role(['originalId' => -1])); $innerHandlerMock - ->expects(self::at(1)) + ->expects(self::once()) ->method('publishRoleDraft') ->with($roleDraftId); $this->cacheMock @@ -537,7 +537,7 @@ public function testPublishNewRoleDraft() $handler->publishRoleDraft($roleDraftId); } - public function testAssignRole() + public function testAssignRole(): void { $innerUserHandlerMock = $this->createMock(SPIUserHandler::class); $innerLocationHandlerMock = $this->createMock(SPILocationHandler::class); @@ -570,16 +570,31 @@ public function testAssignRole() ->willReturn([new Location(['id' => '43'])]); $tags = ['ragl-14', 'rarl-9', 'lp-43']; + $matcher = self::exactly(3); $this->cacheIdentifierGeneratorMock - ->expects(self::exactly(3)) - ->method('generateTag') - ->withConsecutive( - ['role_assignment_group_list', [14], false], - ['role_assignment_role_list', [9], false], - ['location_path', [43], false] - ) - ->willReturnOnConsecutiveCalls(...$tags); + ->expects($matcher) + ->method('generateTag')->willReturnCallback(function (...$parameters) use ($matcher, $tags) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame('role_assignment_group_list', $parameters[0]); + $this->assertSame([14], $parameters[1]); + $this->assertFalse($parameters[2]); + + return $tags[0]; + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame('role_assignment_role_list', $parameters[0]); + $this->assertSame([9], $parameters[1]); + $this->assertFalse($parameters[2]); + + return $tags[1]; + } + $this->assertSame('location_path', $parameters[0]); + $this->assertEquals([43], $parameters[1]); + $this->assertFalse($parameters[2]); + + return $tags[2]; + }); $this->cacheMock ->expects(self::once()) @@ -625,11 +640,24 @@ public function testRemoveRoleAssignment(): void "ragl-$contentId", "rarl-$roleId", ]; + $matcher = self::exactly(count($tags)); $this->cacheIdentifierGeneratorMock - ->expects(self::exactly(count($tags))) - ->method('generateTag') - ->withConsecutive(['role_assignment'], ['role_assignment_group_list'], ['role_assignment_role_list']) - ->willReturnOnConsecutiveCalls(...$tags); + ->expects($matcher) + ->method('generateTag')->willReturnCallback(function (...$parameters) use ($matcher, $tags) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame('role_assignment', $parameters[0]); + + return $tags[0]; + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame('role_assignment_group_list', $parameters[0]); + + return $tags[1]; + } + $this->assertSame('role_assignment_role_list', $parameters[0]); + + return $tags[2]; + }); $this->cacheMock->method('invalidateTags')->with($tags); diff --git a/tests/lib/Persistence/Cache/UserPreferenceHandlerTest.php b/tests/lib/Persistence/Cache/UserPreferenceHandlerTest.php index f78b167fc3..436d9f1794 100644 --- a/tests/lib/Persistence/Cache/UserPreferenceHandlerTest.php +++ b/tests/lib/Persistence/Cache/UserPreferenceHandlerTest.php @@ -36,7 +36,7 @@ public function getHandlerClassName(): string /** * {@inheritdoc} */ - public function providerForUnCachedMethods(): array + public static function providerForUnCachedMethods(): array { $userId = 7; $name = 'setting'; @@ -82,7 +82,7 @@ public function providerForUnCachedMethods(): array /** * {@inheritdoc} */ - public function providerForCachedLoadMethodsHit(): array + public static function providerForCachedLoadMethodsHit(): array { $userId = 7; $name = 'setting'; @@ -105,7 +105,7 @@ public function providerForCachedLoadMethodsHit(): array ]; } - public function providerForCachedLoadMethodsMiss(): array + public static function providerForCachedLoadMethodsMiss(): array { $userId = 7; $name = 'setting'; diff --git a/tests/lib/Persistence/Doctrine/JoinedTablesTrackerTest.php b/tests/lib/Persistence/Doctrine/JoinedTablesTrackerTest.php index 92e8f32375..97144cdde4 100644 --- a/tests/lib/Persistence/Doctrine/JoinedTablesTrackerTest.php +++ b/tests/lib/Persistence/Doctrine/JoinedTablesTrackerTest.php @@ -67,6 +67,6 @@ public function testDifferentTableIdentifiersOnSameQueryBuilderAreTrackedSeparat private function createQueryBuilder(): QueryBuilder { - return new QueryBuilder($this->createMock(Connection::class)); + return new QueryBuilder(self::createStub(Connection::class)); } } diff --git a/tests/lib/Persistence/Doctrine/Query/JsonTextFunctionTest.php b/tests/lib/Persistence/Doctrine/Query/JsonTextFunctionTest.php index 26588f178c..92526b44df 100644 --- a/tests/lib/Persistence/Doctrine/Query/JsonTextFunctionTest.php +++ b/tests/lib/Persistence/Doctrine/Query/JsonTextFunctionTest.php @@ -18,18 +18,16 @@ use Doctrine\ORM\Query\AST\Node; use Doctrine\ORM\Query\SqlWalker; use Ibexa\Core\Persistence\Doctrine\Query\JsonTextFunction; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use ReflectionProperty; use RuntimeException; -/** - * @covers \Ibexa\Core\Persistence\Doctrine\Query\JsonTextFunction - */ +#[CoversClass(JsonTextFunction::class)] final class JsonTextFunctionTest extends TestCase { - /** - * @dataProvider provideForGetSql - */ + #[DataProvider('provideForGetSql')] public function testItReadsTheKeyAsTextOn( AbstractPlatform $platform, string $expectedSql @@ -78,7 +76,7 @@ private function buildFunction(): JsonTextFunction foreach (['document', 'key'] as $property) { (new ReflectionProperty(JsonTextFunction::class, $property)) - ->setValue($function, $this->createMock(Node::class)); + ->setValue($function, self::createStub(Node::class)); } return $function; diff --git a/tests/lib/Persistence/Doctrine/SiteAccessAwareEntityManagerTest.php b/tests/lib/Persistence/Doctrine/SiteAccessAwareEntityManagerTest.php index 0ecfdb5db2..538c9f933c 100644 --- a/tests/lib/Persistence/Doctrine/SiteAccessAwareEntityManagerTest.php +++ b/tests/lib/Persistence/Doctrine/SiteAccessAwareEntityManagerTest.php @@ -100,7 +100,7 @@ public function testLockDelegatesToWrappedEntityManager(): void public function testGetRepositoryDelegatesToWrappedEntityManager(): void { - $repository = $this->createMock(EntityRepository::class); + $repository = self::createStub(EntityRepository::class); $wrapped = $this->createMock(EntityManagerInterface::class); $wrapped->expects(self::once()) ->method('getRepository') @@ -115,7 +115,7 @@ public function testGetRepositoryDelegatesToWrappedEntityManager(): void public function testGetClassMetadataDelegatesToWrappedEntityManager(): void { - $metadata = $this->createMock(ClassMetadata::class); + $metadata = self::createStub(ClassMetadata::class); $wrapped = $this->createMock(EntityManagerInterface::class); $wrapped->expects(self::once()) ->method('getClassMetadata') @@ -130,7 +130,7 @@ public function testGetClassMetadataDelegatesToWrappedEntityManager(): void public function testGetMetadataFactoryDelegatesToWrappedEntityManager(): void { - $metadataFactory = $this->createMock(ClassMetadataFactory::class); + $metadataFactory = self::createStub(ClassMetadataFactory::class); $wrapped = $this->createMock(EntityManagerInterface::class); $wrapped->expects(self::once()) ->method('getMetadataFactory') @@ -144,7 +144,7 @@ public function testGetMetadataFactoryDelegatesToWrappedEntityManager(): void public function testWrappedEntityManagerIsResolvedOnlyOnce(): void { - $wrapped = $this->createMock(EntityManagerInterface::class); + $wrapped = self::createStub(EntityManagerInterface::class); $this->entityManagerFactory->expects(self::once()) ->method('getEntityManager') ->willReturn($wrapped); @@ -156,8 +156,8 @@ public function testWrappedEntityManagerIsResolvedOnlyOnce(): void public function testResetForcesReResolutionOfWrappedEntityManager(): void { - $first = $this->createMock(EntityManagerInterface::class); - $second = $this->createMock(EntityManagerInterface::class); + $first = self::createStub(EntityManagerInterface::class); + $second = self::createStub(EntityManagerInterface::class); $this->entityManagerFactory->expects(self::exactly(2)) ->method('getEntityManager') ->willReturnOnConsecutiveCalls($first, $second); @@ -169,8 +169,8 @@ public function testResetForcesReResolutionOfWrappedEntityManager(): void public function testConfigScopeChangeForcesReResolutionOfWrappedEntityManager(): void { - $first = $this->createMock(EntityManagerInterface::class); - $second = $this->createMock(EntityManagerInterface::class); + $first = self::createStub(EntityManagerInterface::class); + $second = self::createStub(EntityManagerInterface::class); $this->entityManagerFactory->expects(self::exactly(2)) ->method('getEntityManager') ->willReturnOnConsecutiveCalls($first, $second); diff --git a/tests/lib/Persistence/FieldTypeRegistryTest.php b/tests/lib/Persistence/FieldTypeRegistryTest.php index f8b7aff505..136eb5cca6 100644 --- a/tests/lib/Persistence/FieldTypeRegistryTest.php +++ b/tests/lib/Persistence/FieldTypeRegistryTest.php @@ -12,10 +12,9 @@ use Ibexa\Core\Base\Exceptions\NotFound\FieldTypeNotFoundException; use Ibexa\Core\Persistence\FieldTypeRegistry; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\FieldTypeRegistry - */ +#[CoversClass(FieldTypeRegistry::class)] class FieldTypeRegistryTest extends TestCase { private const FIELD_TYPE_IDENTIFIER = 'some-type'; @@ -31,7 +30,7 @@ public function testConstructor(): void ); } - public function testGetFieldTypeInstance() + public function testGetFieldTypeInstance(): void { $instance = $this->getFieldTypeMock(); $registry = new FieldTypeRegistry([self::FIELD_TYPE_IDENTIFIER => $instance]); @@ -44,7 +43,7 @@ public function testGetFieldTypeInstance() /** * @since 5.3.2 */ - public function testGetNotFound() + public function testGetNotFound(): void { $this->expectException(FieldTypeNotFoundException::class); @@ -55,7 +54,7 @@ public function testGetNotFound() /** * BC with 5.0-5.3.2. */ - public function testGetNotFoundBCException() + public function testGetNotFoundBCException(): void { $this->expectException(\RuntimeException::class); @@ -63,7 +62,7 @@ public function testGetNotFoundBCException() $registry->getFieldType('not-found'); } - public function testGetNotInstance() + public function testGetNotInstance(): void { $this->expectException(\TypeError::class); @@ -71,7 +70,7 @@ public function testGetNotInstance() $registry->getFieldType(self::FIELD_TYPE_IDENTIFIER); } - public function testRegister() + public function testRegister(): void { $fieldType = $this->getFieldTypeMock(); $registry = new FieldTypeRegistry([]); diff --git a/tests/lib/Persistence/FieldValue/Converter/ImageConverterTest.php b/tests/lib/Persistence/FieldValue/Converter/ImageConverterTest.php index c3c70e7678..2a32815f82 100644 --- a/tests/lib/Persistence/FieldValue/Converter/ImageConverterTest.php +++ b/tests/lib/Persistence/FieldValue/Converter/ImageConverterTest.php @@ -14,6 +14,8 @@ use Ibexa\Core\IO\UrlRedecoratorInterface; use Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\ImageConverter; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldDefinition; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\MockObject\Stub; use PHPUnit\Framework\TestCase; final class ImageConverterTest extends TestCase @@ -28,16 +30,14 @@ final class ImageConverterTest extends TestCase /** @var \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\ImageConverter */ private $imageConverter; - /** @var \Ibexa\Core\IO\UrlRedecoratorInterface|\PHPUnit\Framework\MockObject\MockObject */ - private $urlRedecorator; + private UrlRedecoratorInterface&Stub $urlRedecorator; - /** @var \Ibexa\Core\IO\IOServiceInterface|\PHPUnit\Framework\MockObject\MockObject */ - private $ioService; + private IOServiceInterface&Stub $ioService; protected function setUp(): void { - $this->ioService = $this->createMock(IOServiceInterface::class); - $this->urlRedecorator = $this->createMock(UrlRedecoratorInterface::class); + $this->ioService = self::createStub(IOServiceInterface::class); + $this->urlRedecorator = self::createStub(UrlRedecoratorInterface::class); $this->imageConverter = new ImageConverter( $this->ioService, @@ -45,9 +45,7 @@ protected function setUp(): void ); } - /** - * @dataProvider dataProviderForTestToStorageFieldDefinition - */ + #[DataProvider('dataProviderForTestToStorageFieldDefinition')] public function testToStorageFieldDefinition( FieldDefinition $fieldDefinition, StorageFieldDefinition $expectedStorageDef @@ -62,7 +60,7 @@ public function testToStorageFieldDefinition( ); } - public function dataProviderForTestToStorageFieldDefinition(): iterable + public static function dataProviderForTestToStorageFieldDefinition(): iterable { yield 'No validators' => [ new FieldDefinition([ @@ -149,9 +147,7 @@ public function dataProviderForTestToStorageFieldDefinition(): iterable ]; } - /** - * @dataProvider dataProviderForTestToFieldDefinition - */ + #[DataProvider('dataProviderForTestToFieldDefinition')] public function testToFieldDefinition( StorageFieldDefinition $storageDef, FieldDefinition $expectedFieldDefinition @@ -166,7 +162,7 @@ public function testToFieldDefinition( ); } - public function dataProviderForTestToFieldDefinition(): iterable + public static function dataProviderForTestToFieldDefinition(): iterable { yield [ new StorageFieldDefinition([ diff --git a/tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php b/tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php index 933fcd5973..b7fb496b5b 100644 --- a/tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php +++ b/tests/lib/Persistence/Legacy/Bookmark/Gateway/DoctrineDatabaseTest.php @@ -12,10 +12,10 @@ use Ibexa\Core\Persistence\Legacy\Bookmark\Gateway; use Ibexa\Core\Persistence\Legacy\Bookmark\Gateway\DoctrineDatabase; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Bookmark\Gateway - */ +#[CoversClass(Gateway::class)] class DoctrineDatabaseTest extends TestCase { public const EXISTING_BOOKMARK_ID = 1; @@ -33,7 +33,7 @@ protected function setUp(): void $this->insertDatabaseFixture(__DIR__ . '/../_fixtures/bookmarks.php'); } - public function testInsertBookmark() + public function testInsertBookmark(): void { $id = $this->getGateway()->insertBookmark(new Bookmark([ 'userId' => 14, @@ -50,14 +50,14 @@ public function testInsertBookmark() ], $data); } - public function testDeleteBookmark() + public function testDeleteBookmark(): void { $this->getGateway()->deleteBookmark(self::EXISTING_BOOKMARK_ID); self::assertEmpty($this->loadBookmark(self::EXISTING_BOOKMARK_ID)); } - public function testLoadBookmarkDataById() + public function testLoadBookmarkDataById(): void { self::assertEquals( [self::EXISTING_BOOKMARK_DATA], @@ -65,7 +65,7 @@ public function testLoadBookmarkDataById() ); } - public function testLoadBookmarkDataByUserIdAndLocationId() + public function testLoadBookmarkDataByUserIdAndLocationId(): void { $data = $this->getGateway()->loadBookmarkDataByUserIdAndLocationId( (int) self::EXISTING_BOOKMARK_DATA['user_id'], @@ -75,23 +75,19 @@ public function testLoadBookmarkDataByUserIdAndLocationId() self::assertEquals([self::EXISTING_BOOKMARK_DATA], $data); } - /** - * @dataProvider dataProviderForLoadUserBookmarks - */ - public function testLoadUserBookmarks(int $userId, int $offset, int $limit, array $expected) + #[DataProvider('dataProviderForLoadUserBookmarks')] + public function testLoadUserBookmarks(int $userId, int $offset, int $limit, array $expected): void { self::assertEquals($expected, $this->getGateway()->loadUserBookmarks($userId, $offset, $limit)); } - /** - * @dataProvider dataProviderForLoadUserBookmarks - */ - public function testCountUserBookmarks(int $userId, int $offset, int $limit, array $expected) + #[DataProvider('dataProviderForLoadUserBookmarks')] + public function testCountUserBookmarks(int $userId, int $offset, int $limit, array $expected): void { self::assertEquals(count($expected), $this->getGateway()->countUserBookmarks($userId)); } - public function dataProviderForLoadUserBookmarks(): array + public static function dataProviderForLoadUserBookmarks(): array { $fixtures = (require __DIR__ . '/../_fixtures/bookmarks.php')[DoctrineDatabase::TABLE_BOOKMARKS]; @@ -116,7 +112,7 @@ public function dataProviderForLoadUserBookmarks(): array ]; } - public function testLocationSwapped() + public function testLocationSwapped(): void { $bookmark1Id = 3; $bookmark2Id = 4; diff --git a/tests/lib/Persistence/Legacy/Bookmark/HandlerTest.php b/tests/lib/Persistence/Legacy/Bookmark/HandlerTest.php index 1b9e0c99f6..9dd1c7cd69 100644 --- a/tests/lib/Persistence/Legacy/Bookmark/HandlerTest.php +++ b/tests/lib/Persistence/Legacy/Bookmark/HandlerTest.php @@ -35,7 +35,7 @@ protected function setUp(): void $this->handler = new Handler($this->gateway, $this->mapper); } - public function testCreate() + public function testCreate(): void { $createStruct = new CreateStruct([ 'locationId' => 54, @@ -64,7 +64,7 @@ public function testCreate() self::assertEquals($bookmark->id, self::BOOKMARK_ID); } - public function testDelete() + public function testDelete(): void { $this->gateway ->expects(self::once()) @@ -74,7 +74,7 @@ public function testDelete() $this->handler->delete(self::BOOKMARK_ID); } - public function testLoadByUserIdAndLocationIdExistingBookmark() + public function testLoadByUserIdAndLocationIdExistingBookmark(): void { $userId = 87; $locationId = 54; @@ -107,7 +107,7 @@ public function testLoadByUserIdAndLocationIdExistingBookmark() self::assertEquals([$locationId => $object], $this->handler->loadByUserIdAndLocationId($userId, [$locationId])); } - public function testLoadByUserIdAndLocationIdNonExistingBookmark() + public function testLoadByUserIdAndLocationIdNonExistingBookmark(): void { $userId = 87; $locationId = 54; @@ -127,7 +127,7 @@ public function testLoadByUserIdAndLocationIdNonExistingBookmark() self::assertEmpty($this->handler->loadByUserIdAndLocationId($userId, [$locationId])); } - public function testLoadUserBookmarks() + public function testLoadUserBookmarks(): void { $userId = 87; $offset = 50; @@ -176,7 +176,7 @@ public function testLoadUserBookmarks() self::assertEquals($objects, $this->handler->loadUserBookmarks($userId, $offset, $limit)); } - public function testLocationSwapped() + public function testLocationSwapped(): void { $location1Id = 1; $location2Id = 2; diff --git a/tests/lib/Persistence/Legacy/Bookmark/MapperTest.php b/tests/lib/Persistence/Legacy/Bookmark/MapperTest.php index 3e88f1cd1e..0123345df9 100644 --- a/tests/lib/Persistence/Legacy/Bookmark/MapperTest.php +++ b/tests/lib/Persistence/Legacy/Bookmark/MapperTest.php @@ -11,11 +11,10 @@ use Ibexa\Contracts\Core\Persistence\Bookmark\Bookmark; use Ibexa\Contracts\Core\Persistence\Bookmark\CreateStruct; use Ibexa\Core\Persistence\Legacy\Bookmark\Mapper; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Bookmark\Mapper - */ +#[CoversClass(Mapper::class)] class MapperTest extends TestCase { /** @var \Ibexa\Core\Persistence\Legacy\Bookmark\Mapper */ @@ -26,7 +25,7 @@ protected function setUp(): void $this->mapper = new Mapper(); } - public function testCreateBookmarkFromCreateStruct() + public function testCreateBookmarkFromCreateStruct(): void { $createStruct = new CreateStruct([ 'locationId' => 54, @@ -39,7 +38,7 @@ public function testCreateBookmarkFromCreateStruct() ]), $this->mapper->createBookmarkFromCreateStruct($createStruct)); } - public function testExtractBookmarksFromRows() + public function testExtractBookmarksFromRows(): void { $rows = [ [ diff --git a/tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php b/tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php index a3b23139f9..9bc5047b34 100644 --- a/tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php +++ b/tests/lib/Persistence/Legacy/Content/ContentHandlerTest.php @@ -33,11 +33,11 @@ use Ibexa\Core\Persistence\Legacy\Content\UrlAlias\Gateway as UrlAliasGateway; use Ibexa\Core\Persistence\Legacy\Content\UrlAlias\SlugConverter; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\MockObject\MockObject; use ReflectionException; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\Handler - */ +#[CoversClass(Handler::class)] class ContentHandlerTest extends TestCase { private const RELATION_ID = 1; @@ -112,15 +112,12 @@ class ContentHandlerTest extends TestCase */ protected $contentTypeHandlerMock; - /** - * @var \PHPUnit\Framework\MockObject\MockObject&\Ibexa\Core\Persistence\Legacy\Content\Language\Handler - */ - private LanguageHandler $languageHandlerMock; + private LanguageHandler&MockObject $languageHandlerMock; /** * @todo Current method way to complex to test, refactor! */ - public function testCreate() + public function testCreate(): void { $handler = $this->getContentHandler(); @@ -129,7 +126,7 @@ public function testCreate() $fieldHandlerMock = $this->getFieldHandlerMock(); $locationMock = $this->getLocationGatewayMock(); $contentTypeHandlerMock = $this->getContentTypeHandlerMock(); - $contentTypeMock = $this->createMock(Type::class); + $contentTypeMock = self::createStub(Type::class); $createStruct = $this->getCreateStructFixture(); $contentTypeHandlerMock->expects(self::once()) @@ -164,7 +161,7 @@ public function testCreate() ->method('insertVersion') ->with( self::isInstanceOf(VersionInfo::class), - self::isType('array') + self::isArray() )->will(self::returnValue(1)); $fieldHandlerMock->expects(self::once()) @@ -215,7 +212,7 @@ public function testCreate() ); } - public function testPublishFirstVersion() + public function testPublishFirstVersion(): void { $handler = $this->getPartlyMockedHandler(['loadVersionInfo']); @@ -225,7 +222,7 @@ public function testPublishFirstVersion() $fieldHandlerMock = $this->getFieldHandlerMock(); $metadataUpdateStruct = new MetadataUpdateStruct(); - $handler->expects(self::at(0)) + $handler->expects(self::once()) ->method('loadVersionInfo') ->with(23, 1) ->will( @@ -292,7 +289,7 @@ public function testPublishFirstVersion() $handler->publish(23, 1, $metadataUpdateStruct); } - public function testPublish() + public function testPublish(): void { $handler = $this->getPartlyMockedHandler(['loadVersionInfo', 'setStatus']); @@ -302,7 +299,7 @@ public function testPublish() $fieldHandlerMock = $this->getFieldHandlerMock(); $metadataUpdateStruct = new MetadataUpdateStruct(); - $handler->expects(self::at(0)) + $handler->expects(self::once()) ->method('loadVersionInfo') ->with(23, 2) ->will( @@ -320,7 +317,7 @@ public function testPublish() ); $handler - ->expects(self::at(1)) + ->expects(self::once()) ->method('setStatus') ->with(23, VersionInfo::STATUS_ARCHIVED, 1); @@ -375,7 +372,7 @@ public function testPublish() $handler->publish(23, 2, $metadataUpdateStruct); } - public function testCreateDraftFromVersion() + public function testCreateDraftFromVersion(): void { $handler = $this->getPartlyMockedHandler(['load']); @@ -472,7 +469,7 @@ public function testCreateDraftFromVersion() ); } - public function testLoad() + public function testLoad(): void { $handler = $this->getContentHandler(); @@ -517,7 +514,7 @@ public function testLoad() ); } - public function testLoadContentList() + public function testLoadContentList(): void { $handler = $this->getContentHandler(); @@ -547,15 +544,22 @@ public function testLoadContentList() 2 => $this->getContentFixtureForDraft(2, 2), 3 => $this->getContentFixtureForDraft(3, 1), ]; - $mapperMock->expects(self::at(0)) + $extractContentFromRowsMatcher = self::exactly(2); + $mapperMock->expects($extractContentFromRowsMatcher) ->method('extractContentFromRows') - ->with(self::equalTo([$contentRows[0]]), self::equalTo([$nameDataRows[0]])) - ->willReturn([$expected[2]]); + ->willReturnCallback(static function (array $rows, array $nameRows, string $prefix = 'content_', ?array $translations = null) use ($extractContentFromRowsMatcher, $contentRows, $nameDataRows, $expected): array { + if ($extractContentFromRowsMatcher->numberOfInvocations() === 1) { + self::assertSame([$contentRows[0]], $rows); + self::assertSame([$nameDataRows[0]], $nameRows); - $mapperMock->expects(self::at(1)) - ->method('extractContentFromRows') - ->with(self::equalTo([$contentRows[1]]), self::equalTo([$nameDataRows[1]])) - ->willReturn([$expected[3]]); + return [$expected[2]]; + } + + self::assertSame([$contentRows[1]], $rows); + self::assertSame([$nameDataRows[1]], $nameRows); + + return [$expected[3]]; + }); $fieldHandlerMock->expects(self::exactly(2)) ->method('loadExternalFieldData') @@ -569,7 +573,7 @@ public function testLoadContentList() ); } - public function testLoadContentInfoByRemoteId() + public function testLoadContentInfoByRemoteId(): void { $contentInfoData = [new ContentInfo()]; $this->getGatewayMock()->expects(self::once()) @@ -591,7 +595,7 @@ public function testLoadContentInfoByRemoteId() ); } - public function testLoadErrorNotFound() + public function testLoadErrorNotFound(): void { $this->expectException(NotFoundException::class); @@ -632,14 +636,14 @@ protected function getContentFixtureForDraft(int $id = 23, int $versionNo = 2) return $content; } - public function testUpdateContent() + public function testUpdateContent(): void { $handler = $this->getPartlyMockedHandler(['load', 'loadContentInfo']); $gatewayMock = $this->getGatewayMock(); $fieldHandlerMock = $this->getFieldHandlerMock(); $contentTypeHandlerMock = $this->getContentTypeHandlerMock(); - $contentTypeMock = $this->createMock(Type::class); + $contentTypeMock = self::createStub(Type::class); $contentStub = new Content( [ 'versionInfo' => new VersionInfo( @@ -674,16 +678,19 @@ public function testUpdateContent() self::isInstanceOf(Type::class) ); - $handler->expects(self::at(0)) + $loadMatcher = self::exactly(2); + $handler->expects($loadMatcher) ->method('load') ->with(14, 4) - ->will(self::returnValue($contentStub)); + ->willReturnCallback(static function () use ($loadMatcher, $contentStub) { + if ($loadMatcher->numberOfInvocations() === 1) { + return $contentStub; + } - $handler->expects(self::at(1)) - ->method('load') - ->with(14, 4); + return null; + }); - $handler->expects(self::at(2)) + $handler->expects(self::once()) ->method('loadContentInfo') ->with(14); @@ -730,7 +737,7 @@ public function testUpdateContent() ); } - public function testUpdateMetadata() + public function testUpdateMetadata(): void { $handler = $this->getPartlyMockedHandler(['load', 'loadContentInfo']); @@ -754,7 +761,7 @@ public function testUpdateMetadata() ->with(14) ->will( self::returnValue( - $this->createMock(ContentInfo::class) + self::createStub(ContentInfo::class) ) ); @@ -765,7 +772,7 @@ public function testUpdateMetadata() self::assertInstanceOf(ContentInfo::class, $resultContentInfo); } - public function testUpdateMetadataUpdatesPathIdentificationString() + public function testUpdateMetadataUpdatesPathIdentificationString(): void { $handler = $this->getPartlyMockedHandler(['load', 'loadContentInfo']); $locationGatewayMock = $this->getLocationGatewayMock(); @@ -819,7 +826,7 @@ public function testUpdateMetadataUpdatesPathIdentificationString() ->with(14) ->will( self::returnValue( - $this->createMock(ContentInfo::class) + self::createStub(ContentInfo::class) ) ); @@ -888,7 +895,7 @@ public function testLoadRelationList(): void ); } - public function testLoadReverseRelations() + public function testLoadReverseRelations(): void { $handler = $this->getContentHandler(); @@ -917,7 +924,7 @@ public function testLoadReverseRelations() ); } - public function testAddRelation() + public function testAddRelation(): void { // expected relation object after creation $expectedRelationObject = new Relation(); @@ -961,7 +968,7 @@ public function testAddRelation() ); } - public function testRemoveRelation() + public function testRemoveRelation(): void { $gatewayMock = $this->getGatewayMock(); @@ -1020,7 +1027,7 @@ public function getCreateStructFixture() return $struct; } - public function testLoadDraftsForUser() + public function testLoadDraftsForUser(): void { $handler = $this->getContentHandler(); $rows = [['content_version_contentobject_id' => 42, 'content_version_version' => 2]]; @@ -1051,7 +1058,7 @@ public function testLoadDraftsForUser() ); } - public function testListVersions() + public function testListVersions(): void { $handler = $this->getContentHandler(); @@ -1071,7 +1078,7 @@ public function testListVersions() ); } - public function testRemoveRawContent() + public function testRemoveRawContent(): void { $handler = $this->getContentHandler(); $treeHandlerMock = $this->getTreeHandlerMock(); @@ -1087,9 +1094,9 @@ public function testRemoveRawContent() /** * Test for the deleteContent() method. */ - public function testDeleteContentWithLocations() + public function testDeleteContentWithLocations(): void { - $handlerMock = $this->getPartlyMockedHandler(['getAllLocationIds']); + $handlerMock = $this->getPartlyMockedHandler([]); $gatewayMock = $this->getGatewayMock(); $treeHandlerMock = $this->getTreeHandlerMock(); @@ -1112,7 +1119,7 @@ public function testDeleteContentWithLocations() /** * Test for the deleteContent() method. */ - public function testDeleteContentWithoutLocations() + public function testDeleteContentWithoutLocations(): void { $handlerMock = $this->getPartlyMockedHandler(['removeRawContent']); $gatewayMock = $this->getGatewayMock(); @@ -1128,7 +1135,7 @@ public function testDeleteContentWithoutLocations() $handlerMock->deleteContent(23); } - public function testDeleteVersion() + public function testDeleteVersion(): void { $handler = $this->getContentHandler(); @@ -1190,7 +1197,7 @@ public function testDeleteVersion() $handler->deleteVersion(225, 2); } - public function testCopySingleVersion() + public function testCopySingleVersion(): void { $handler = $this->getPartlyMockedHandler(['load', 'internalCreate']); $gatewayMock = $this->getGatewayMock(); @@ -1251,7 +1258,7 @@ public function testCopySingleVersion() ); } - public function testCopyAllVersions() + public function testCopyAllVersions(): void { $handler = $this->getPartlyMockedHandler( [ @@ -1265,7 +1272,7 @@ public function testCopyAllVersions() $mapperMock = $this->getMapperMock(); $fieldHandlerMock = $this->getFieldHandlerMock(); $contentTypeHandlerMock = $this->getContentTypeHandlerMock(); - $contentTypeMock = $this->createMock(Type::class); + $contentTypeMock = self::createStub(Type::class); $time = time(); $createStructStub = new CreateStruct( [ @@ -1284,11 +1291,6 @@ public function testCopyAllVersions() ->with(self::equalTo(23)) ->will(self::returnValue(new ContentInfo(['currentVersionNo' => 2]))); - $handler->expects(self::at(1)) - ->method('load') - ->with(self::equalTo(23), self::equalTo(2)) - ->will(self::returnValue(new Content())); - $mapperMock->expects(self::once()) ->method('createCreateStructFromContent') ->with(self::isInstanceOf(Content::class)) @@ -1338,19 +1340,26 @@ public function testCopyAllVersions() ), ] ); - $handler->expects(self::at(4)) + $copyLoadMatcher = self::exactly(2); + $handler->expects($copyLoadMatcher) ->method('load') - ->with(self::equalTo(23), self::equalTo(1)) - ->will( - self::returnValue( - new Content( - [ - 'versionInfo' => $versionInfo, - 'fields' => [], - ] - ) - ) - ); + ->willReturnCallback(static function ($contentId, $versionNo) use ($copyLoadMatcher, $versionInfo) { + self::assertSame(23, $contentId); + if ($copyLoadMatcher->numberOfInvocations() === 1) { + self::assertSame(2, $versionNo); + + return new Content(); + } + + self::assertSame(1, $versionNo); + + return new Content( + [ + 'versionInfo' => $versionInfo, + 'fields' => [], + ] + ); + }); $versionInfo->creationDate = $time; $versionInfo->modificationDate = $time; @@ -1358,7 +1367,7 @@ public function testCopyAllVersions() ->method('insertVersion') ->with( self::equalTo($versionInfo), - self::isType('array') + self::isArray() )->will(self::returnValue(42)); $versionInfo = clone $versionInfo; @@ -1403,7 +1412,7 @@ public function testCopyAllVersions() ); } - public function testCopyThrowsNotFoundExceptionContentNotFound() + public function testCopyThrowsNotFoundExceptionContentNotFound(): void { $this->expectException(NotFoundException::class); @@ -1421,7 +1430,7 @@ public function testCopyThrowsNotFoundExceptionContentNotFound() $handler->copy(23); } - public function testCopyThrowsNotFoundExceptionVersionNotFound() + public function testCopyThrowsNotFoundExceptionVersionNotFound(): void { $this->expectException(NotFoundException::class); @@ -1439,7 +1448,7 @@ public function testCopyThrowsNotFoundExceptionVersionNotFound() $result = $handler->copy(23, 32); } - public function testSetStatus() + public function testSetStatus(): void { $handler = $this->getContentHandler(); @@ -1457,8 +1466,6 @@ public function testSetStatus() } /** - * @covers \Ibexa\Contracts\Core\Persistence\Legacy\Content\Handler::loadVersionInfoList - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException */ public function testLoadVersionInfoList(): void @@ -1547,7 +1554,6 @@ protected function getContentHandler() protected function getPartlyMockedHandler(array $methods) { return $this->getMockBuilder(Handler::class) - ->setMethods($methods) ->setConstructorArgs( [ $this->getGatewayMock(), @@ -1561,6 +1567,7 @@ protected function getPartlyMockedHandler(array $methods) $this->getLanguageHandlerMock(), ] ) + ->onlyMethods(array_values($methods)) ->getMock(); } @@ -1592,10 +1599,7 @@ protected function getContentTypeHandlerMock() return $this->contentTypeHandlerMock; } - /** - * @return \PHPUnit\Framework\MockObject\MockObject&\Ibexa\Core\Persistence\Legacy\Content\Language\Handler - */ - protected function getLanguageHandlerMock(): LanguageHandler + protected function getLanguageHandlerMock(): LanguageHandler&MockObject { if (!isset($this->languageHandlerMock)) { $this->languageHandlerMock = $this->createMock(LanguageHandler::class); diff --git a/tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php b/tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php index cd65e130c6..6dbc495ef8 100644 --- a/tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php +++ b/tests/lib/Persistence/Legacy/Content/FieldHandlerTest.php @@ -22,10 +22,9 @@ use Ibexa\Core\Persistence\Legacy\Content\Mapper; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldValue; use Ibexa\Core\Persistence\Legacy\Content\StorageHandler; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\FieldHandler - */ +#[CoversClass(FieldHandler::class)] class FieldHandlerTest extends LanguageAwareTestCase { /** @@ -84,7 +83,7 @@ protected function assertCreateNewFields($storageHandlerUpdatesFields = false) self::isInstanceOf(StorageFieldValue::class) )->will(self::returnValue(42)); - $callNo = 0; + $expectedStoreFields = []; $fieldValue = new FieldValue(); foreach ([1, 2, 3] as $fieldDefinitionId) { foreach (['eng-US', 'eng-GB'] as $languageCode) { @@ -105,27 +104,37 @@ protected function assertCreateNewFields($storageHandlerUpdatesFields = false) $originalField->languageCode = 'eng-GB'; continue; } - $storageHandlerMock->expects(self::at($callNo++)) - ->method('storeFieldData') - ->with( - self::isInstanceOf(VersionInfo::class), - self::equalTo($field) - )->will(self::returnValue($storageHandlerUpdatesFields)); + $expectedStoreFields[] = $field; } } + $invocationOrder = 0; + $storageHandlerMock->expects(self::exactly(5)) + ->method('storeFieldData') + ->willReturnCallback(function (...$parameters) use (&$invocationOrder, $expectedStoreFields, $storageHandlerUpdatesFields) { + $this->assertInstanceOf(VersionInfo::class, $parameters[0]); + $this->assertEquals($expectedStoreFields[$invocationOrder], $parameters[1]); + ++$invocationOrder; + + return $storageHandlerUpdatesFields; + }); + /* @var $copyField */ /* @var $originalField */ - $storageHandlerMock->expects(self::at($callNo)) + $storageHandlerMock->expects(self::once()) ->method('copyFieldData') - ->with( - self::isInstanceOf(VersionInfo::class), - self::equalTo($copyField), - self::equalTo($originalField) - )->will(self::returnValue($storageHandlerUpdatesFields)); + ->willReturnCallback(function (...$parameters) use (&$invocationOrder, $copyField, $originalField, $storageHandlerUpdatesFields) { + $this->assertSame(5, $invocationOrder); + $this->assertInstanceOf(VersionInfo::class, $parameters[0]); + $this->assertEquals($copyField, $parameters[1]); + $this->assertEquals($originalField, $parameters[2]); + ++$invocationOrder; + + return $storageHandlerUpdatesFields; + }); } - public function testCreateNewFields() + public function testCreateNewFields(): void { $fieldHandler = $this->getFieldHandler(); $mapperMock = $this->getMapperMock(); @@ -143,7 +152,7 @@ public function testCreateNewFields() ); } - public function testCreateNewFieldsUpdatingStorageHandler() + public function testCreateNewFieldsUpdatingStorageHandler(): void { $fieldHandler = $this->getFieldHandler(); $contentGatewayMock = $this->getContentGatewayMock(); @@ -190,10 +199,10 @@ protected function assertCreateNewFieldsForMainLanguage($storageHandlerUpdatesFi self::isInstanceOf(StorageFieldValue::class) )->will(self::returnValue(42)); - $callNo = 0; + $expectedFields = []; $fieldValue = new FieldValue(); foreach ([1, 2, 3] as $fieldDefinitionId) { - $field = new Field( + $expectedFields[] = new Field( [ 'id' => 42, 'fieldDefinitionId' => $fieldDefinitionId, @@ -203,16 +212,20 @@ protected function assertCreateNewFieldsForMainLanguage($storageHandlerUpdatesFi 'languageCode' => 'eng-GB', ] ); - $storageHandlerMock->expects(self::at($callNo++)) - ->method('storeFieldData') - ->with( - self::isInstanceOf(VersionInfo::class), - self::equalTo($field) - )->will(self::returnValue($storageHandlerUpdatesFields)); } + + $matcher = self::exactly(3); + $storageHandlerMock->expects($matcher) + ->method('storeFieldData') + ->willReturnCallback(function (...$parameters) use ($matcher, $expectedFields, $storageHandlerUpdatesFields) { + $this->assertInstanceOf(VersionInfo::class, $parameters[0]); + $this->assertEquals($expectedFields[$matcher->numberOfInvocations() - 1], $parameters[1]); + + return $storageHandlerUpdatesFields; + }); } - public function testCreateNewFieldsForMainLanguage() + public function testCreateNewFieldsForMainLanguage(): void { $fieldHandler = $this->getFieldHandler(); $mapperMock = $this->getMapperMock(); @@ -230,7 +243,7 @@ public function testCreateNewFieldsForMainLanguage() ); } - public function testCreateNewFieldsForMainLanguageUpdatingStorageHandler() + public function testCreateNewFieldsForMainLanguageUpdatingStorageHandler(): void { $fieldHandler = $this->getFieldHandler(); $contentGatewayMock = $this->getContentGatewayMock(); @@ -272,7 +285,7 @@ protected function assertCreateExistingFieldsInNewVersion($storageHandlerUpdates self::isInstanceOf(StorageFieldValue::class) )->will(self::returnValue(42)); - $callNo = 0; + $expectedCopyCalls = []; $fieldValue = new FieldValue(); foreach ([1, 2, 3] as $fieldDefinitionId) { foreach (['eng-US', 'eng-GB'] as $languageIndex => $languageCode) { @@ -287,18 +300,24 @@ protected function assertCreateExistingFieldsInNewVersion($storageHandlerUpdates ); $originalField = clone $field; $field->versionNo = 1; - $storageHandlerMock->expects(self::at($callNo++)) - ->method('copyFieldData') - ->with( - self::isInstanceOf(VersionInfo::class), - self::equalTo($field), - self::equalTo($originalField) - )->will(self::returnValue($storageHandlerUpdatesFields)); + $expectedCopyCalls[] = ['field' => $field, 'original' => $originalField]; } } + + $matcher = self::exactly(6); + $storageHandlerMock->expects($matcher) + ->method('copyFieldData') + ->willReturnCallback(function (...$parameters) use ($matcher, $expectedCopyCalls, $storageHandlerUpdatesFields) { + $index = $matcher->numberOfInvocations() - 1; + $this->assertInstanceOf(VersionInfo::class, $parameters[0]); + $this->assertEquals($expectedCopyCalls[$index]['field'], $parameters[1]); + $this->assertEquals($expectedCopyCalls[$index]['original'], $parameters[2]); + + return $storageHandlerUpdatesFields; + }); } - public function testCreateExistingFieldsInNewVersion() + public function testCreateExistingFieldsInNewVersion(): void { $fieldHandler = $this->getFieldHandler(); $mapperMock = $this->getMapperMock(); @@ -313,7 +332,7 @@ public function testCreateExistingFieldsInNewVersion() $fieldHandler->createExistingFieldsInNewVersion($this->getContentFixture()); } - public function testCreateExistingFieldsInNewVersionUpdatingStorageHandler() + public function testCreateExistingFieldsInNewVersionUpdatingStorageHandler(): void { $fieldHandler = $this->getFieldHandler(); $contentGatewayMock = $this->getContentGatewayMock(); @@ -434,7 +453,7 @@ public function testCreateExistingFieldsInNewVersionAllFieldsReferencedWhenEdite $fieldHandler->createExistingFieldsInNewVersion($content, 'ger-DE'); } - public function testLoadExternalFieldData() + public function testLoadExternalFieldData(): void { $fieldHandler = $this->getFieldHandler(); @@ -471,7 +490,7 @@ public function assertUpdateFieldsWithNewLanguage($storageHandlerUpdatesFields = self::isInstanceOf(StorageFieldValue::class) ); - $callNo = 0; + $expectedStoreFields = []; $fieldValue = new FieldValue(); foreach ([1, 2, 3] as $fieldDefinitionId) { $field = new Field( @@ -491,26 +510,36 @@ public function assertUpdateFieldsWithNewLanguage($storageHandlerUpdatesFields = $originalField->languageCode = 'eng-GB'; continue; } - $storageHandlerMock->expects(self::at($callNo++)) - ->method('storeFieldData') - ->with( - self::isInstanceOf(VersionInfo::class), - self::equalTo($field) - )->will(self::returnValue($storageHandlerUpdatesFields)); + $expectedStoreFields[] = $field; } + $invocationOrder = 0; + $storageHandlerMock->expects(self::exactly(2)) + ->method('storeFieldData') + ->willReturnCallback(function (...$parameters) use (&$invocationOrder, $expectedStoreFields, $storageHandlerUpdatesFields) { + $this->assertInstanceOf(VersionInfo::class, $parameters[0]); + $this->assertEquals($expectedStoreFields[$invocationOrder], $parameters[1]); + ++$invocationOrder; + + return $storageHandlerUpdatesFields; + }); + /* @var $copyField */ /* @var $originalField */ - $storageHandlerMock->expects(self::at($callNo)) + $storageHandlerMock->expects(self::once()) ->method('copyFieldData') - ->with( - self::isInstanceOf(VersionInfo::class), - self::equalTo($copyField), - self::equalTo($originalField) - )->will(self::returnValue($storageHandlerUpdatesFields)); + ->willReturnCallback(function (...$parameters) use (&$invocationOrder, $copyField, $originalField, $storageHandlerUpdatesFields) { + $this->assertSame(2, $invocationOrder); + $this->assertInstanceOf(VersionInfo::class, $parameters[0]); + $this->assertEquals($copyField, $parameters[1]); + $this->assertEquals($originalField, $parameters[2]); + ++$invocationOrder; + + return $storageHandlerUpdatesFields; + }); } - public function testUpdateFieldsWithNewLanguage() + public function testUpdateFieldsWithNewLanguage(): void { $mapperMock = $this->getMapperMock(); $fieldHandler = $this->getFieldHandler(); @@ -542,7 +571,7 @@ public function testUpdateFieldsWithNewLanguage() ); } - public function testUpdateFieldsWithNewLanguageUpdatingStorageHandler() + public function testUpdateFieldsWithNewLanguageUpdatingStorageHandler(): void { $fieldHandler = $this->getFieldHandler(); $mapperMock = $this->getMapperMock(); @@ -589,7 +618,7 @@ public function assertUpdateFieldsExistingLanguages($storageHandlerUpdatesFields { $storageHandlerMock = $this->getStorageHandlerMock(); - $callNo = 0; + $expectedStoreFields = []; $fieldValue = new FieldValue(); $fieldsToCopy = []; foreach ([1, 2, 3] as $fieldDefinitionId) { @@ -614,28 +643,37 @@ public function assertUpdateFieldsExistingLanguages($storageHandlerUpdatesFields 'original' => $originalField, ]; } else { - $storageHandlerMock->expects(self::at($callNo++)) - ->method('storeFieldData') - ->with( - self::isInstanceOf(VersionInfo::class), - self::equalTo($field) - )->will(self::returnValue($storageHandlerUpdatesFields)); + $expectedStoreFields[] = $field; } } } - foreach ($fieldsToCopy as $fieldToCopy) { - $storageHandlerMock->expects(self::at($callNo++)) - ->method('copyFieldData') - ->with( - self::isInstanceOf(VersionInfo::class), - self::equalTo($fieldToCopy['copy']), - self::equalTo($fieldToCopy['original']) - )->will(self::returnValue($storageHandlerUpdatesFields)); - } + $invocationOrder = 0; + $storeCount = count($expectedStoreFields); + $storageHandlerMock->expects(self::exactly($storeCount)) + ->method('storeFieldData') + ->willReturnCallback(function (...$parameters) use (&$invocationOrder, $expectedStoreFields, $storageHandlerUpdatesFields) { + $this->assertInstanceOf(VersionInfo::class, $parameters[0]); + $this->assertEquals($expectedStoreFields[$invocationOrder], $parameters[1]); + ++$invocationOrder; + + return $storageHandlerUpdatesFields; + }); + + $storageHandlerMock->expects(self::exactly(count($fieldsToCopy))) + ->method('copyFieldData') + ->willReturnCallback(function (...$parameters) use (&$invocationOrder, $fieldsToCopy, $storeCount, $storageHandlerUpdatesFields) { + $index = $invocationOrder - $storeCount; + $this->assertInstanceOf(VersionInfo::class, $parameters[0]); + $this->assertEquals($fieldsToCopy[$index]['copy'], $parameters[1]); + $this->assertEquals($fieldsToCopy[$index]['original'], $parameters[2]); + ++$invocationOrder; + + return $storageHandlerUpdatesFields; + }); } - public function testUpdateFieldsExistingLanguages() + public function testUpdateFieldsExistingLanguages(): void { $fieldHandler = $this->getFieldHandler(); $mapperMock = $this->getMapperMock(); @@ -662,7 +700,7 @@ public function testUpdateFieldsExistingLanguages() ); } - public function testUpdateFieldsExistingLanguagesUpdatingStorageHandler() + public function testUpdateFieldsExistingLanguagesUpdatingStorageHandler(): void { $fieldHandler = $this->getFieldHandler(); $mapperMock = $this->getMapperMock(); @@ -696,7 +734,7 @@ public function assertUpdateFieldsForInitialLanguage($storageHandlerUpdatesField { $storageHandlerMock = $this->getStorageHandlerMock(); - $callNo = 0; + $expectedStoreFields = []; $fieldValue = new FieldValue(); $fieldsToCopy = []; foreach ([1, 2, 3] as $id => $fieldDefinitionId) { @@ -722,26 +760,35 @@ public function assertUpdateFieldsForInitialLanguage($storageHandlerUpdatesField } // This field is inserted as empty $field->value = null; - $storageHandlerMock->expects(self::at($callNo++)) - ->method('storeFieldData') - ->with( - self::isInstanceOf(VersionInfo::class), - self::equalTo($field) - )->will(self::returnValue($storageHandlerUpdatesFields)); + $expectedStoreFields[] = $field; } - foreach ($fieldsToCopy as $fieldToCopy) { - $storageHandlerMock->expects(self::at($callNo++)) - ->method('copyFieldData') - ->with( - self::isInstanceOf(VersionInfo::class), - self::equalTo($fieldToCopy['copy']), - self::equalTo($fieldToCopy['original']) - )->will(self::returnValue($storageHandlerUpdatesFields)); - } + $invocationOrder = 0; + $storeCount = count($expectedStoreFields); + $storageHandlerMock->expects(self::exactly($storeCount)) + ->method('storeFieldData') + ->willReturnCallback(function (...$parameters) use (&$invocationOrder, $expectedStoreFields, $storageHandlerUpdatesFields) { + $this->assertInstanceOf(VersionInfo::class, $parameters[0]); + $this->assertEquals($expectedStoreFields[$invocationOrder], $parameters[1]); + ++$invocationOrder; + + return $storageHandlerUpdatesFields; + }); + + $storageHandlerMock->expects(self::exactly(count($fieldsToCopy))) + ->method('copyFieldData') + ->willReturnCallback(function (...$parameters) use (&$invocationOrder, $fieldsToCopy, $storeCount, $storageHandlerUpdatesFields) { + $index = $invocationOrder - $storeCount; + $this->assertInstanceOf(VersionInfo::class, $parameters[0]); + $this->assertEquals($fieldsToCopy[$index]['copy'], $parameters[1]); + $this->assertEquals($fieldsToCopy[$index]['original'], $parameters[2]); + ++$invocationOrder; + + return $storageHandlerUpdatesFields; + }); } - public function testUpdateFieldsForInitialLanguage() + public function testUpdateFieldsForInitialLanguage(): void { $fieldHandler = $this->getFieldHandler(); $mapperMock = $this->getMapperMock(); @@ -763,7 +810,7 @@ public function testUpdateFieldsForInitialLanguage() ); } - public function testUpdateFieldsForInitialLanguageUpdatingStorageHandler() + public function testUpdateFieldsForInitialLanguageUpdatingStorageHandler(): void { $fieldHandler = $this->getFieldHandler(); $mapperMock = $this->getMapperMock(); @@ -793,7 +840,7 @@ public function testUpdateFieldsForInitialLanguageUpdatingStorageHandler() ); } - public function testDeleteFields() + public function testDeleteFields(): void { $fieldHandler = $this->getFieldHandler(); @@ -1095,7 +1142,7 @@ protected function getFieldTypeRegistryMock() )->method( 'getFieldType' )->with( - self::isType('string') + self::isString() )->will( self::returnValue($this->getFieldTypeMock()) ); diff --git a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/AuthorTest.php b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/AuthorTest.php index 1d2a57364e..3c544dc51d 100644 --- a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/AuthorTest.php +++ b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/AuthorTest.php @@ -16,14 +16,13 @@ use Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\AuthorConverter; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldDefinition; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldValue; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\AuthorConverter - * - * @group fieldType - * @group ibexa_author - */ +#[CoversClass(AuthorConverter::class)] +#[Group('fieldType')] +#[Group('ibexa_author')] class AuthorTest extends TestCase { /** @var \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\AuthorConverter */ @@ -49,7 +48,7 @@ protected function tearDown(): void parent::tearDown(); } - public function testToStorageValue() + public function testToStorageValue(): void { $value = new FieldValue(); $value->data = $this->authors; @@ -79,7 +78,7 @@ public function testToStorageValue() self::assertEmpty($this->authors, 'All authors have not been converted as expected'); } - public function testToFieldValue() + public function testToFieldValue(): void { $storageFieldValue = new StorageFieldValue(); $storageFieldValue->dataText = <<converter = new CheckboxConverter(); } - /** - * @group fieldType - * @group ibexa_boolean - */ - public function testToStorageValue() + #[Group('fieldType')] + #[Group('ibexa_boolean')] + public function testToStorageValue(): void { $value = new FieldValue(); $value->data = true; @@ -45,11 +43,9 @@ public function testToStorageValue() self::assertSame('', $storageFieldValue->sortKeyString); } - /** - * @group fieldType - * @group ibexa_boolean - */ - public function testToFieldValue() + #[Group('fieldType')] + #[Group('ibexa_boolean')] + public function testToFieldValue(): void { $storageFieldValue = new StorageFieldValue(); $storageFieldValue->dataInt = 1; @@ -62,11 +58,9 @@ public function testToFieldValue() self::assertSame($storageFieldValue->sortKeyInt, $fieldValue->sortKey); } - /** - * @group fieldType - * @group ibexa_boolean - */ - public function testToStorageFieldDefinition() + #[Group('fieldType')] + #[Group('ibexa_boolean')] + public function testToStorageFieldDefinition(): void { $defaultBool = false; $storageFieldDef = new StorageFieldDefinition(); @@ -85,11 +79,9 @@ public function testToStorageFieldDefinition() ); } - /** - * @group fieldType - * @group ibexa_boolean - */ - public function testToFieldDefinition() + #[Group('fieldType')] + #[Group('ibexa_boolean')] + public function testToFieldDefinition(): void { $defaultBool = true; $fieldDef = new PersistenceFieldDefinition(); diff --git a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php index 7d2f97f0bc..b406e129f7 100644 --- a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php +++ b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/CountryTest.php @@ -14,11 +14,12 @@ use Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\CountryConverter; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldDefinition; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldValue; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\CountryConverter - */ +#[CoversClass(CountryConverter::class)] class CountryTest extends TestCase { /** @var \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\CountryConverter */ @@ -30,7 +31,10 @@ protected function setUp(): void $this->converter = new CountryConverter(); } - public function providerForTestToStorageValue() + /** + * @return array + */ + public static function providerForTestToStorageValue(): array { return [ [['BE', 'FR'], 'belgium,france', 'BE,FR', 'belgium,france'], @@ -38,13 +42,10 @@ public function providerForTestToStorageValue() ]; } - /** - * @group fieldType - * @group country - * - * @dataProvider providerForTestToStorageValue - */ - public function testToStorageValue($data, $sortKey, $dataText, $sortKeyString) + #[Group('fieldType')] + #[Group('country')] + #[DataProvider('providerForTestToStorageValue')] + public function testToStorageValue($data, $sortKey, $dataText, $sortKeyString): void { $value = new FieldValue(); $value->data = $data; @@ -56,7 +57,10 @@ public function testToStorageValue($data, $sortKey, $dataText, $sortKeyString) self::assertSame($sortKeyString, $storageFieldValue->sortKeyString); } - public function providerForTestToFieldValue() + /** + * @return array + */ + public static function providerForTestToFieldValue(): array { return [ ['BE,FR', 'belgium,france', ['BE', 'FR']], @@ -64,13 +68,10 @@ public function providerForTestToFieldValue() ]; } - /** - * @group fieldType - * @group country - * - * @dataProvider providerForTestToFieldValue - */ - public function testToFieldValue($dataText, $sortKeyString, $data) + #[Group('fieldType')] + #[Group('country')] + #[DataProvider('providerForTestToFieldValue')] + public function testToFieldValue($dataText, $sortKeyString, $data): void { $storageFieldValue = new StorageFieldValue(); $storageFieldValue->dataText = $dataText; @@ -81,11 +82,9 @@ public function testToFieldValue($dataText, $sortKeyString, $data) self::assertSame($data, $fieldValue->data); } - /** - * @group fieldType - * @group country - */ - public function testToStorageFieldDefinitionMultiple() + #[Group('fieldType')] + #[Group('country')] + public function testToStorageFieldDefinitionMultiple(): void { $defaultValue = new FieldValue(); $defaultValue->data = ['BE', 'FR']; @@ -116,11 +115,9 @@ public function testToStorageFieldDefinitionMultiple() ); } - /** - * @group fieldType - * @group country - */ - public function testToStorageFieldDefinitionSingle() + #[Group('fieldType')] + #[Group('country')] + public function testToStorageFieldDefinitionSingle(): void { $fieldTypeConstraints = new FieldTypeConstraints(); $fieldTypeConstraints->fieldSettings = new FieldSettings( @@ -147,11 +144,9 @@ public function testToStorageFieldDefinitionSingle() ); } - /** - * @group fieldType - * @group country - */ - public function testToFieldDefinitionMultiple() + #[Group('fieldType')] + #[Group('country')] + public function testToFieldDefinitionMultiple(): void { $fieldDef = new PersistenceFieldDefinition(); @@ -174,11 +169,9 @@ public function testToFieldDefinitionMultiple() ); } - /** - * @group fieldType - * @group country - */ - public function testToFieldDefinitionSingle() + #[Group('fieldType')] + #[Group('country')] + public function testToFieldDefinitionSingle(): void { $fieldDef = new PersistenceFieldDefinition(); diff --git a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateAndTimeTest.php b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateAndTimeTest.php index 2d24478333..b7bd682cf9 100644 --- a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateAndTimeTest.php +++ b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateAndTimeTest.php @@ -18,13 +18,14 @@ use Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\DateAndTimeConverter; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldDefinition; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldValue; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; use ReflectionObject; use SimpleXMLElement; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\DateAndTimeConverter - */ +#[CoversClass(DateAndTimeConverter::class)] class DateAndTimeTest extends TestCase { /** @var \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\DateAndTimeConverter */ @@ -40,11 +41,9 @@ protected function setUp(): void $this->date = new DateTime('@1048633200'); } - /** - * @group fieldType - * @group dateTime - */ - public function testToStorageValue() + #[Group('fieldType')] + #[Group('dateTime')] + public function testToStorageValue(): void { $value = new FieldValue(); $value->data = [ @@ -60,11 +59,9 @@ public function testToStorageValue() self::assertSame('', $storageFieldValue->sortKeyString); } - /** - * @group fieldType - * @group dateTime - */ - public function testToFieldValue() + #[Group('fieldType')] + #[Group('dateTime')] + public function testToFieldValue(): void { $storageFieldValue = new StorageFieldValue(); $storageFieldValue->dataInt = $this->date->getTimestamp(); @@ -87,7 +84,7 @@ public function testToFieldValue() /** * @return mixed[] */ - public function providerForTestToStorageValueMissingData(): array + public static function providerForTestToStorageValueMissingData(): array { return [ [['current_time' => 1048633200, 'rfc850' => 'Thu, 01 Jan 2003 00:00:00 GMT']], @@ -96,13 +93,11 @@ public function providerForTestToStorageValueMissingData(): array } /** - * @group fieldType - * @group dateTime - * - * @dataProvider providerForTestToStorageValueMissingData - * * @param mixed[]|null $data */ + #[Group('fieldType')] + #[Group('dateTime')] + #[DataProvider('providerForTestToStorageValueMissingData')] public function testToStorageValueNoTimestampKey(?array $data): void { $value = new FieldValue(); @@ -116,11 +111,9 @@ public function testToStorageValueNoTimestampKey(?array $data): void self::assertSame('', $storageFieldValue->sortKeyString); } - /** - * @group fieldType - * @group dateTime - */ - public function testToStorageFieldDefinitionWithAdjustment() + #[Group('fieldType')] + #[Group('dateTime')] + public function testToStorageFieldDefinitionWithAdjustment(): void { $storageFieldDef = new StorageFieldDefinition(); $dateInterval = DateInterval::createFromDateString('+10 years, -1 month, +3 days, -13 hours'); @@ -157,11 +150,9 @@ public function testToStorageFieldDefinitionWithAdjustment() } } - /** - * @group fieldType - * @group dateTime - */ - public function testToStorageFieldDefinitionNoDefault() + #[Group('fieldType')] + #[Group('dateTime')] + public function testToStorageFieldDefinitionNoDefault(): void { $storageFieldDef = new StorageFieldDefinition(); $fieldTypeConstraints = new FieldTypeConstraints(); @@ -190,11 +181,9 @@ public function testToStorageFieldDefinitionNoDefault() self::assertNull($storageFieldDef->dataText5); } - /** - * @group fieldType - * @group dateTime - */ - public function testToStorageFieldDefinitionCurrentDate() + #[Group('fieldType')] + #[Group('dateTime')] + public function testToStorageFieldDefinitionCurrentDate(): void { $storageFieldDef = new StorageFieldDefinition(); $fieldTypeConstraints = new FieldTypeConstraints(); @@ -240,11 +229,9 @@ private function getXMLToDateIntervalMap() ]; } - /** - * @group fieldType - * @group dateTime - */ - public function testToFieldDefinitionNoDefault() + #[Group('fieldType')] + #[Group('dateTime')] + public function testToFieldDefinitionNoDefault(): void { $fieldDef = new PersistenceFieldDefinition(); $storageDef = new StorageFieldDefinition( @@ -258,11 +245,9 @@ public function testToFieldDefinitionNoDefault() self::assertNull($fieldDef->defaultValue->data); } - /** - * @group fieldType - * @group dateTime - */ - public function testToFieldDefinitionCurrentDate() + #[Group('fieldType')] + #[Group('dateTime')] + public function testToFieldDefinitionCurrentDate(): void { $time = time(); $fieldDef = new PersistenceFieldDefinition(); @@ -283,11 +268,9 @@ public function testToFieldDefinitionCurrentDate() self::assertEqualsWithDelta($time + 1, $dateTimeFromString->getTimestamp(), 1, 'Time does not match within 1s delta'); } - /** - * @group fieldType - * @group dateTime - */ - public function testToFieldDefinitionWithAdjustmentAndSeconds() + #[Group('fieldType')] + #[Group('dateTime')] + public function testToFieldDefinitionWithAdjustmentAndSeconds(): void { $fieldDef = new PersistenceFieldDefinition(); $dateInterval = DateInterval::createFromDateString('2 years, 1 month, -4 days, 2 hours, 0 minute, 34 seconds'); @@ -314,11 +297,9 @@ public function testToFieldDefinitionWithAdjustmentAndSeconds() self::assertLessThanOrEqual($timestamp + 1, $dateTimeFromString->getTimestamp()); } - /** - * @group fieldType - * @group dateTime - */ - public function testToFieldDefinitionWithAdjustmentNoSeconds() + #[Group('fieldType')] + #[Group('dateTime')] + public function testToFieldDefinitionWithAdjustmentNoSeconds(): void { $fieldDef = new PersistenceFieldDefinition(); $seconds = 34; @@ -371,11 +352,9 @@ private function getXMLStringFromDateInterval(DateInterval $dateInterval): strin return $xmlString; } - /** - * @group fieldType - * @group dateTime - */ - public function testGetDateIntervalFromXML() + #[Group('fieldType')] + #[Group('dateTime')] + public function testGetDateIntervalFromXML(): void { $dateIntervalReference = DateInterval::createFromDateString('2 years, 1 months, -4 days, 2 hours, 0 minutes, 34 seconds'); @@ -395,11 +374,9 @@ public function testGetDateIntervalFromXML() self::assertSame($dateIntervalReference->invert, $generatedDateInterval->invert); } - /** - * @group fieldType - * @group dateTime - */ - public function testGenerateDateIntervalXML() + #[Group('fieldType')] + #[Group('dateTime')] + public function testGenerateDateIntervalXML(): void { $dateIntervalReference = DateInterval::createFromDateString('2 years, 1 month, -4 days, 2 hours, 0 minute, 34 seconds'); $dom = new DOMDocument(); diff --git a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateTest.php b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateTest.php index 1da59eb651..b2f246f3ca 100644 --- a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateTest.php +++ b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/DateTest.php @@ -16,14 +16,14 @@ use Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\DateConverter; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldDefinition; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldValue; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\DateConverter - * - * @group fieldType - * @group date - */ +#[CoversClass(DateConverter::class)] +#[Group('fieldType')] +#[Group('date')] class DateTest extends TestCase { protected DateConverter $converter; @@ -38,10 +38,9 @@ protected function setUp(): void } /** - * @dataProvider providerForTestToStorageValue - * * @param array|null $data */ + #[DataProvider('providerForTestToStorageValue')] public function testToStorageValue( ?array $data, int $sortKey, @@ -144,9 +143,7 @@ public function testToFieldValue(): void self::assertSame($storageFieldValue->sortKeyInt, $fieldValue->sortKey); } - /** - * @dataProvider providerForTestToStorageFieldDefinition - */ + #[DataProvider('providerForTestToStorageFieldDefinition')] public function testToStorageFieldDefinition(int $defaultType): void { $storageFieldDef = new StorageFieldDefinition(); diff --git a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/ISBNTest.php b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/ISBNTest.php index a526c25ae2..533b62ea18 100644 --- a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/ISBNTest.php +++ b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/ISBNTest.php @@ -10,11 +10,11 @@ use Ibexa\Contracts\Core\Persistence\Content\Type\FieldDefinition as PersistenceFieldDefinition; use Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\ISBNConverter; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldDefinition; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\ISBNConverter - */ +#[CoversClass(ISBNConverter::class)] class ISBNTest extends TestCase { /** @var \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\ISBNConverter */ @@ -25,10 +25,8 @@ protected function setUp(): void $this->converter = new ISBNConverter(); } - /** - * @dataProvider providerForTestToFieldDefinition - */ - public function testToFieldDefinition($dataInt, $excpectedIsbn13Value) + #[DataProvider('providerForTestToFieldDefinition')] + public function testToFieldDefinition($dataInt, $excpectedIsbn13Value): void { $fieldDef = new PersistenceFieldDefinition(); $storageDefinition = new StorageFieldDefinition([ @@ -42,7 +40,10 @@ public function testToFieldDefinition($dataInt, $excpectedIsbn13Value) self::assertSame($excpectedIsbn13Value, $fieldSettings['isISBN13']); } - public function providerForTestToFieldDefinition() + /** + * @return array + */ + public static function providerForTestToFieldDefinition(): array { return [ [1, true], diff --git a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/KeywordTest.php b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/KeywordTest.php index efd77df1df..143a6836f7 100644 --- a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/KeywordTest.php +++ b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/KeywordTest.php @@ -12,11 +12,11 @@ use Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\KeywordConverter; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldDefinition; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldValue; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\KeywordConverter - */ +#[CoversClass(KeywordConverter::class)] class KeywordTest extends TestCase { /** @var \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\KeywordConverter */ @@ -28,11 +28,9 @@ protected function setUp(): void $this->converter = new KeywordConverter(); } - /** - * @group fieldType - * @group keyword - */ - public function testToStorageValue() + #[Group('fieldType')] + #[Group('keyword')] + public function testToStorageValue(): void { $value = new FieldValue(); $value->data = ['key1', 'key2']; @@ -47,11 +45,9 @@ public function testToStorageValue() self::assertEquals('', $storageFieldValue->sortKeyString); } - /** - * @group fieldType - * @group keyword - */ - public function testToFieldValue() + #[Group('fieldType')] + #[Group('keyword')] + public function testToFieldValue(): void { $storageFieldValue = new StorageFieldValue(); $fieldValue = new FieldValue(); @@ -61,20 +57,16 @@ public function testToFieldValue() self::assertEquals('', $fieldValue->sortKey); } - /** - * @group fieldType - * @group keyword - */ - public function testToStorageFieldDefinition() + #[Group('fieldType')] + #[Group('keyword')] + public function testToStorageFieldDefinition(): void { $this->converter->toStorageFieldDefinition(new PersistenceFieldDefinition(), new StorageFieldDefinition()); } - /** - * @group fieldType - * @group keyword - */ - public function testToFieldDefinition() + #[Group('fieldType')] + #[Group('keyword')] + public function testToFieldDefinition(): void { $this->converter->toFieldDefinition(new StorageFieldDefinition(), new PersistenceFieldDefinition()); } diff --git a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/MediaTest.php b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/MediaTest.php index 842fd2ed64..cdeea5cf37 100644 --- a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/MediaTest.php +++ b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/MediaTest.php @@ -13,11 +13,11 @@ use Ibexa\Core\FieldType\Media\Type as MediaType; use Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\MediaConverter; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldDefinition; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\MediaConverter - */ +#[CoversClass(MediaConverter::class)] class MediaTest extends TestCase { protected $converter; @@ -27,11 +27,9 @@ protected function setUp(): void $this->converter = new MediaConverter(); } - /** - * @group fieldType - * @group ibexa_media - */ - public function testToStorageFieldDefinition() + #[Group('fieldType')] + #[Group('ibexa_media')] + public function testToStorageFieldDefinition(): void { $storageFieldDef = new StorageFieldDefinition(); @@ -65,11 +63,9 @@ public function testToStorageFieldDefinition() ); } - /** - * @group fieldType - * @group ibexa_media - */ - public function testToFieldDefinition() + #[Group('fieldType')] + #[Group('ibexa_media')] + public function testToFieldDefinition(): void { $fieldDef = new PersistenceFieldDefinition(); $storageDef = new StorageFieldDefinition( diff --git a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/RelationListTest.php b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/RelationListTest.php index bf3354a294..ab76508e52 100644 --- a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/RelationListTest.php +++ b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/RelationListTest.php @@ -14,11 +14,11 @@ use Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\RelationListConverter; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldDefinition; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldValue; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\RelationListConverter - */ +#[CoversClass(RelationListConverter::class)] class RelationListTest extends TestCase { /** @var \PHPUnit\Framework\MockObject\MockObject|\Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\RelationListConverter */ @@ -30,15 +30,13 @@ protected function setUp(): void $this->converter = $this ->getMockBuilder(RelationListConverter::class) ->disableOriginalConstructor() - ->setMethods(['getRelationXmlHashFromDB']) + ->onlyMethods(['getRelationXmlHashFromDB']) ->getMock(); } - /** - * @group fieldType - * @group relationlist - */ - public function testToStorageValue() + #[Group('fieldType')] + #[Group('relationlist')] + public function testToStorageValue(): void { $destinationContentIds = [3, 2, 1]; $fieldValue = new FieldValue(); @@ -103,11 +101,9 @@ public function testToStorageValue() ); } - /** - * @group fieldType - * @group relationlist - */ - public function testToStorageValueEmpty() + #[Group('fieldType')] + #[Group('relationlist')] + public function testToStorageValueEmpty(): void { $destinationContentIds = []; $fieldValue = new FieldValue(); @@ -137,11 +133,9 @@ public function testToStorageValueEmpty() ); } - /** - * @group fieldType - * @group relationlist - */ - public function testToFieldValue() + #[Group('fieldType')] + #[Group('relationlist')] + public function testToFieldValue(): void { $storageFieldValue = new StorageFieldValue(); $storageFieldValue->sortKeyString = ''; @@ -164,11 +158,9 @@ public function testToFieldValue() ); } - /** - * @group fieldType - * @group relationlist - */ - public function testToFieldValueEmpty() + #[Group('fieldType')] + #[Group('relationlist')] + public function testToFieldValueEmpty(): void { $storageFieldValue = new StorageFieldValue(); $storageFieldValue->sortKeyString = ''; @@ -191,11 +183,9 @@ public function testToFieldValueEmpty() ); } - /** - * @group fieldType - * @group relationlist - */ - public function testToStorageFieldDefinition() + #[Group('fieldType')] + #[Group('relationlist')] + public function testToStorageFieldDefinition(): void { $fieldDefinition = new PersistenceFieldDefinition( [ @@ -234,11 +224,9 @@ public function testToStorageFieldDefinition() ); } - /** - * @group fieldType - * @group relationlist - */ - public function testToFieldDefinitionMultiple() + #[Group('fieldType')] + #[Group('relationlist')] + public function testToFieldDefinitionMultiple(): void { $storageFieldDefinition = new StorageFieldDefinition(); $storageFieldDefinition->dataText5 = <<converter = new RelationConverter(); } - /** - * @group fieldType - * @group relationlist - */ - public function testToStorageFieldDefinition() + #[Group('fieldType')] + #[Group('relationlist')] + public function testToStorageFieldDefinition(): void { $fieldDefinition = new PersistenceFieldDefinition( [ diff --git a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/SelectionTest.php b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/SelectionTest.php index 8ba5a8d52d..d919581c40 100644 --- a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/SelectionTest.php +++ b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/SelectionTest.php @@ -15,11 +15,11 @@ use Ibexa\Core\Persistence\Legacy\Content\MultilingualStorageFieldDefinition; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldDefinition; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldValue; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\SelectionConverter - */ +#[CoversClass(SelectionConverter::class)] class SelectionTest extends TestCase { /** @var \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\SelectionConverter */ @@ -32,11 +32,9 @@ protected function setUp(): void $this->converter = new SelectionConverter(); } - /** - * @group fieldType - * @group selection - */ - public function testToStorageValue() + #[Group('fieldType')] + #[Group('selection')] + public function testToStorageValue(): void { $fieldValue = new FieldValue(); $fieldValue->data = [1, 3]; @@ -56,11 +54,9 @@ public function testToStorageValue() ); } - /** - * @group fieldType - * @group selection - */ - public function testToStorageValueEmpty() + #[Group('fieldType')] + #[Group('selection')] + public function testToStorageValueEmpty(): void { $fieldValue = new FieldValue(); $fieldValue->data = []; @@ -80,11 +76,9 @@ public function testToStorageValueEmpty() ); } - /** - * @group fieldType - * @group selection - */ - public function testToFieldValue() + #[Group('fieldType')] + #[Group('selection')] + public function testToFieldValue(): void { $storageFieldValue = new StorageFieldValue(); $storageFieldValue->dataText = '1-3'; @@ -104,11 +98,9 @@ public function testToFieldValue() ); } - /** - * @group fieldType - * @group selection - */ - public function testToFieldValueEmpty() + #[Group('fieldType')] + #[Group('selection')] + public function testToFieldValueEmpty(): void { $storageFieldValue = new StorageFieldValue(); $storageFieldValue->dataText = ''; @@ -128,11 +120,9 @@ public function testToFieldValueEmpty() ); } - /** - * @group fieldType - * @group selection - */ - public function testToStorageFieldDefinitionMultiple() + #[Group('fieldType')] + #[Group('selection')] + public function testToStorageFieldDefinitionMultiple(): void { $fieldDefinition = new PersistenceFieldDefinition( [ @@ -168,11 +158,9 @@ public function testToStorageFieldDefinitionMultiple() self::assertEquals($expectedStorageFieldDefinition, $actualStorageFieldDefinition); } - /** - * @group fieldType - * @group selection - */ - public function testToStorageFieldDefinitionSingle() + #[Group('fieldType')] + #[Group('selection')] + public function testToStorageFieldDefinitionSingle(): void { $fieldDefinition = new PersistenceFieldDefinition( [ @@ -206,11 +194,9 @@ public function testToStorageFieldDefinitionSingle() self::assertEquals($expectedStorageFieldDefinition, $actualStorageFieldDefinition); } - /** - * @group fieldType - * @group selection - */ - public function testToFieldDefinitionMultiple() + #[Group('fieldType')] + #[Group('selection')] + public function testToFieldDefinitionMultiple(): void { $storageFieldDefinition = new StorageFieldDefinition(); $storageFieldDefinition->dataInt1 = 1; @@ -275,11 +261,9 @@ public function testToFieldDefinitionMultiple() self::assertEquals($expectedFieldDefinition, $actualFieldDefinition); } - /** - * @group fieldType - * @group selection - */ - public function testToFieldDefinitionSingleEmpty() + #[Group('fieldType')] + #[Group('selection')] + public function testToFieldDefinitionSingleEmpty(): void { $storageFieldDefinition = new StorageFieldDefinition(); $storageFieldDefinition->dataInt1 = 0; diff --git a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/SerializableConverterTest.php b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/SerializableConverterTest.php index b05cd2b2ae..1f73e89fe8 100644 --- a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/SerializableConverterTest.php +++ b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/SerializableConverterTest.php @@ -16,11 +16,10 @@ use Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\SerializableConverter; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldDefinition; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldValue; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\SerializableConverter - */ +#[CoversClass(SerializableConverter::class)] class SerializableConverterTest extends TestCase { private const EXAMPLE_DATA = [ diff --git a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TextBlockTest.php b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TextBlockTest.php index 5fab303af7..9ee635dc64 100644 --- a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TextBlockTest.php +++ b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TextBlockTest.php @@ -15,11 +15,11 @@ use Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\TextBlockConverter; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldDefinition; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldValue; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\TextBlockConverter - */ +#[CoversClass(TextBlockConverter::class)] class TextBlockTest extends TestCase { /** @var \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\TextBlockConverter */ @@ -41,11 +41,9 @@ protected function setUp(): void EOT; } - /** - * @group fieldType - * @group textBlock - */ - public function testToStorageValue() + #[Group('fieldType')] + #[Group('textBlock')] + public function testToStorageValue(): void { $value = new FieldValue(); $value->data = $this->longText; @@ -58,11 +56,9 @@ public function testToStorageValue() self::assertSame(0, $storageFieldValue->sortKeyInt); } - /** - * @group fieldType - * @group textBlock - */ - public function testToFieldValue() + #[Group('fieldType')] + #[Group('textBlock')] + public function testToFieldValue(): void { $storageFieldValue = new StorageFieldValue(); $storageFieldValue->dataText = $this->longText; @@ -74,11 +70,9 @@ public function testToFieldValue() self::assertSame($storageFieldValue->sortKeyString, $fieldValue->sortKey); } - /** - * @group fieldType - * @group textBlock - */ - public function testToStorageFieldDefinition() + #[Group('fieldType')] + #[Group('textBlock')] + public function testToStorageFieldDefinition(): void { $storageFieldDef = new StorageFieldDefinition(); $fieldTypeConstraints = new FieldTypeConstraints(); @@ -101,11 +95,9 @@ public function testToStorageFieldDefinition() ); } - /** - * @group fieldType - * @group textBlock - */ - public function testToFieldDefinition() + #[Group('fieldType')] + #[Group('textBlock')] + public function testToFieldDefinition(): void { $fieldDef = new PersistenceFieldDefinition(); $storageDef = new StorageFieldDefinition( diff --git a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TextLineTest.php b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TextLineTest.php index 4c4c0c984c..8ceb20edfa 100644 --- a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TextLineTest.php +++ b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TextLineTest.php @@ -14,11 +14,11 @@ use Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\TextLineConverter; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldDefinition; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldValue; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\TextLineConverter - */ +#[CoversClass(TextLineConverter::class)] class TextLineTest extends TestCase { /** @var \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\TextLineConverter */ @@ -30,11 +30,9 @@ protected function setUp(): void $this->converter = new TextLineConverter(); } - /** - * @group fieldType - * @group textLine - */ - public function testToStorageValue() + #[Group('fieldType')] + #[Group('textLine')] + public function testToStorageValue(): void { $value = new FieldValue(); $value->data = "He's holding a thermal detonator!"; @@ -47,11 +45,9 @@ public function testToStorageValue() self::assertSame(0, $storageFieldValue->sortKeyInt); } - /** - * @group fieldType - * @group textLine - */ - public function testToFieldValue() + #[Group('fieldType')] + #[Group('textLine')] + public function testToFieldValue(): void { $storageFieldValue = new StorageFieldValue(); $storageFieldValue->dataText = 'When 900 years old, you reach... Look as good, you will not.'; @@ -64,11 +60,9 @@ public function testToFieldValue() self::assertSame($storageFieldValue->sortKeyString, $fieldValue->sortKey); } - /** - * @group fieldType - * @group textLine - */ - public function testToStorageFieldDefinitionWithValidator() + #[Group('fieldType')] + #[Group('textLine')] + public function testToStorageFieldDefinitionWithValidator(): void { $defaultText = 'This is a default text'; $storageFieldDef = new StorageFieldDefinition(); @@ -101,11 +95,9 @@ public function testToStorageFieldDefinitionWithValidator() ); } - /** - * @group fieldType - * @group textLine - */ - public function testToStorageFieldDefinitionNoValidator() + #[Group('fieldType')] + #[Group('textLine')] + public function testToStorageFieldDefinitionNoValidator(): void { $defaultText = 'This is a default text'; $storageFieldDef = new StorageFieldDefinition(); @@ -130,11 +122,9 @@ public function testToStorageFieldDefinitionNoValidator() ); } - /** - * @group fieldType - * @group textLine - */ - public function testToFieldDefinition() + #[Group('fieldType')] + #[Group('textLine')] + public function testToFieldDefinition(): void { $defaultText = 'This is a default value'; $fieldDef = new PersistenceFieldDefinition(); diff --git a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TimeTest.php b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TimeTest.php index 17259a0f4d..c7923438df 100644 --- a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TimeTest.php +++ b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/TimeTest.php @@ -13,17 +13,17 @@ use Ibexa\Contracts\Core\Persistence\Content\Type\FieldDefinition as PersistenceFieldDefinition; use Ibexa\Core\FieldType\FieldSettings; use Ibexa\Core\FieldType\Time\Type as TimeType; +use Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\DateAndTimeConverter; use Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\TimeConverter; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldDefinition; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldValue; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\DateAndTimeConverter - * - * @group fieldType - * @group time - */ +#[CoversClass(DateAndTimeConverter::class)] +#[Group('fieldType')] +#[Group('time')] class TimeTest extends TestCase { /** @var \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\TimeConverter */ @@ -39,7 +39,7 @@ protected function setUp(): void $this->time = 3661; } - public function testToStorageValue() + public function testToStorageValue(): void { $value = new FieldValue(); $value->data = $this->time; @@ -52,7 +52,7 @@ public function testToStorageValue() self::assertSame('', $storageFieldValue->sortKeyString); } - public function testToFieldValue() + public function testToFieldValue(): void { $storageFieldValue = new StorageFieldValue(); $storageFieldValue->dataInt = $this->time; @@ -66,7 +66,7 @@ public function testToFieldValue() self::assertSame($storageFieldValue->sortKeyInt, $fieldValue->sortKey); } - public function testToStorageFieldDefinitionDefaultEmpty() + public function testToStorageFieldDefinitionDefaultEmpty(): void { $storageFieldDef = new StorageFieldDefinition(); $fieldTypeConstraints = new FieldTypeConstraints(); @@ -87,7 +87,7 @@ public function testToStorageFieldDefinitionDefaultEmpty() self::assertSame(1, $storageFieldDef->dataInt2); } - public function testToStorageFieldDefinitionDefaultCurrentTime() + public function testToStorageFieldDefinitionDefaultCurrentTime(): void { $storageFieldDef = new StorageFieldDefinition(); $fieldTypeConstraints = new FieldTypeConstraints(); @@ -108,7 +108,7 @@ public function testToStorageFieldDefinitionDefaultCurrentTime() self::assertSame(0, $storageFieldDef->dataInt2); } - public function testToFieldDefinitionDefaultEmpty() + public function testToFieldDefinitionDefaultEmpty(): void { $fieldDef = new PersistenceFieldDefinition(); $storageDef = new StorageFieldDefinition( @@ -131,7 +131,7 @@ public function testToFieldDefinitionDefaultEmpty() ); } - public function testToFieldDefinitionDefaultCurrentTime() + public function testToFieldDefinitionDefaultCurrentTime(): void { $fieldDef = new PersistenceFieldDefinition(); $storageDef = new StorageFieldDefinition( diff --git a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/UrlTest.php b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/UrlTest.php index 0f3a167f4b..8e5e7bdccd 100644 --- a/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/UrlTest.php +++ b/tests/lib/Persistence/Legacy/Content/FieldValue/Converter/UrlTest.php @@ -12,11 +12,11 @@ use Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\UrlConverter; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldDefinition; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldValue; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\UrlConverter - */ +#[CoversClass(UrlConverter::class)] class UrlTest extends TestCase { /** @var \Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\UrlConverter */ @@ -28,11 +28,9 @@ protected function setUp(): void $this->converter = new UrlConverter(); } - /** - * @group fieldType - * @group url - */ - public function testToStorageValue() + #[Group('fieldType')] + #[Group('url')] + public function testToStorageValue(): void { $value = new FieldValue(); $text = 'Ibexa'; @@ -45,11 +43,9 @@ public function testToStorageValue() self::assertSame($text, $storageFieldValue->dataText); } - /** - * @group fieldType - * @group url - */ - public function testToFieldValue() + #[Group('fieldType')] + #[Group('url')] + public function testToFieldValue(): void { $text = "A link's text"; $urlId = 842; @@ -67,20 +63,16 @@ public function testToFieldValue() self::assertEquals($urlId, $fieldValue->data['urlId']); } - /** - * @group fieldType - * @group url - */ - public function testToStorageFieldDefinition() + #[Group('fieldType')] + #[Group('url')] + public function testToStorageFieldDefinition(): void { $this->converter->toStorageFieldDefinition(new PersistenceFieldDefinition(), new StorageFieldDefinition()); } - /** - * @group fieldType - * @group url - */ - public function testToFieldDefinition() + #[Group('fieldType')] + #[Group('url')] + public function testToFieldDefinition(): void { $this->converter->toFieldDefinition(new StorageFieldDefinition(), new PersistenceFieldDefinition()); } diff --git a/tests/lib/Persistence/Legacy/Content/FieldValueConverterRegistryTest.php b/tests/lib/Persistence/Legacy/Content/FieldValueConverterRegistryTest.php index fa711c96a2..8826f99a5b 100644 --- a/tests/lib/Persistence/Legacy/Content/FieldValueConverterRegistryTest.php +++ b/tests/lib/Persistence/Legacy/Content/FieldValueConverterRegistryTest.php @@ -10,15 +10,14 @@ use Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter; use Ibexa\Core\Persistence\Legacy\Content\FieldValue\ConverterRegistry as Registry; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\FieldValue\ConverterRegistry - */ +#[CoversClass(Registry::class)] class FieldValueConverterRegistryTest extends TestCase { private const TYPE_NAME = 'some-type'; - public function testRegister() + public function testRegister(): void { $converter = $this->getFieldValueConverterMock(); $registry = new Registry([self::TYPE_NAME => $converter]); @@ -26,7 +25,7 @@ public function testRegister() self::assertSame($converter, $registry->getConverter(self::TYPE_NAME)); } - public function testGetStorage() + public function testGetStorage(): void { $converter = $this->getFieldValueConverterMock(); $registry = new Registry([self::TYPE_NAME => $converter]); @@ -39,7 +38,7 @@ public function testGetStorage() ); } - public function testGetNotFound() + public function testGetNotFound(): void { $this->expectException(Converter\Exception\NotFound::class); diff --git a/tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php b/tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php index 9b361a053b..f95f16a903 100644 --- a/tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php +++ b/tests/lib/Persistence/Legacy/Content/Gateway/DoctrineDatabaseTest.php @@ -22,10 +22,9 @@ use Ibexa\Core\Persistence\Legacy\Content\Gateway\DoctrineDatabase; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldValue; use Ibexa\Tests\Core\Persistence\Legacy\Content\LanguageAwareTestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\Gateway\DoctrineDatabase - */ +#[CoversClass(DoctrineDatabase::class)] class DoctrineDatabaseTest extends LanguageAwareTestCase { /** @@ -38,7 +37,7 @@ class DoctrineDatabaseTest extends LanguageAwareTestCase /** * @todo Fix not available fields */ - public function testInsertContentObject() + public function testInsertContentObject(): void { $struct = $this->getCreateStructFixture(); @@ -162,7 +161,7 @@ protected function getVersionFixture() return $version; } - public function testInsertVersion() + public function testInsertVersion(): void { $version = $this->getVersionFixture(); @@ -201,7 +200,7 @@ public function testInsertVersion() ); } - public function testSetStatus() + public function testSetStatus(): void { $gateway = $this->getDatabaseGateway(); @@ -236,7 +235,7 @@ public function testSetStatus() ); } - public function testSetStatusPublished() + public function testSetStatusPublished(): void { $gateway = $this->getDatabaseGateway(); @@ -271,7 +270,7 @@ public function testSetStatusPublished() ); } - public function testSetStatusUnknownVersion() + public function testSetStatusUnknownVersion(): void { $gateway = $this->getDatabaseGateway(); @@ -280,7 +279,7 @@ public function testSetStatusUnknownVersion() ); } - public function testUpdateContent() + public function testUpdateContent(): void { $gateway = $this->getDatabaseGateway(); @@ -350,7 +349,7 @@ protected function getMetadataUpdateStructFixture() return $struct; } - public function testUpdateVersion() + public function testUpdateVersion(): void { $gateway = $this->getDatabaseGateway(); @@ -386,7 +385,7 @@ public function testUpdateVersion() ); } - public function testInsertNewField() + public function testInsertNewField(): void { $content = $this->getContentFixture(); $content->versionInfo->contentInfo->id = 2342; @@ -431,7 +430,7 @@ public function testInsertNewField() ); } - public function testInsertNewAlwaysAvailableField() + public function testInsertNewAlwaysAvailableField(): void { $content = $this->getContentFixture(); $content->versionInfo->contentInfo->id = 2342; @@ -478,7 +477,7 @@ public function testInsertNewAlwaysAvailableField() ); } - public function testUpdateField() + public function testUpdateField(): void { $content = $this->getContentFixture(); $content->versionInfo->contentInfo->id = 2342; @@ -523,7 +522,7 @@ public function testUpdateField() ); } - public function testUpdateNonTranslatableField() + public function testUpdateNonTranslatableField(): void { $content = $this->getContentFixture(); $content->versionInfo->contentInfo->id = 2342; @@ -611,7 +610,7 @@ public function testListVersions(): void ); } - public function testListVersionNumbers() + public function testListVersionNumbers(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -623,7 +622,7 @@ public function testListVersionNumbers() self::assertEquals([1, 2], $res); } - public function testListVersionsForUser() + public function testListVersionsForUser(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -662,7 +661,7 @@ public function testListVersionsForUser() ); } - public function testLoadWithAllTranslations() + public function testLoadWithAllTranslations(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -684,7 +683,7 @@ public function testLoadWithAllTranslations() ); } - public function testCreateFixtureForMapperExtractContentFromRowsMultipleVersions() + public function testCreateFixtureForMapperExtractContentFromRowsMultipleVersions(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -707,7 +706,7 @@ public function testCreateFixtureForMapperExtractContentFromRowsMultipleVersions self::assertEquals($orig, $res, 'Fixtures differ between what was previously stored(expected) and what it now generates(actual), this hints either some mistake in impl or that the fixture (../_fixtures/extract_content_from_rows_multiple_versions.php) and tests needs to be adapted.'); } - public function testCreateFixtureForMapperExtractContentFromRows() + public function testCreateFixtureForMapperExtractContentFromRows(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -727,7 +726,7 @@ public function testCreateFixtureForMapperExtractContentFromRows() self::assertEquals($orig, $res, 'Fixtures differ between what was previously stored(expected) and what it now generates(actual), this hints either some mistake in impl or that the fixture (../_fixtures/extract_content_from_rows.php) and tests needs to be adapted.'); } - public function testLoadWithSingleTranslation() + public function testLoadWithSingleTranslation(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -752,7 +751,7 @@ public function testLoadWithSingleTranslation() ); } - public function testLoadNonExistentTranslation() + public function testLoadNonExistentTranslation(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -795,7 +794,7 @@ protected function assertValuesInRows($columnKey, array $expectedValues, array $ ); } - public function testGetAllLocationIds() + public function testGetAllLocationIds(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -809,7 +808,7 @@ public function testGetAllLocationIds() ); } - public function testGetFieldIdsByType() + public function testGetFieldIdsByType(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -827,7 +826,7 @@ public function testGetFieldIdsByType() ); } - public function testGetFieldIdsByTypeWithSecondArgument() + public function testGetFieldIdsByTypeWithSecondArgument(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -843,7 +842,7 @@ public function testGetFieldIdsByTypeWithSecondArgument() ); } - public function testDeleteRelationsTo() + public function testDeleteRelationsTo(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -873,7 +872,7 @@ public function testDeleteRelationsTo() ); } - public function testDeleteRelationsFrom() + public function testDeleteRelationsFrom(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -902,7 +901,7 @@ public function testDeleteRelationsFrom() ); } - public function testDeleteRelationsWithSecondArgument() + public function testDeleteRelationsWithSecondArgument(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -959,7 +958,7 @@ public function testDeleteField(): void ); } - public function testDeleteFields() + public function testDeleteFields(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -985,7 +984,7 @@ public function testDeleteFields() ); } - public function testDeleteFieldsWithSecondArgument() + public function testDeleteFieldsWithSecondArgument(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -1011,7 +1010,7 @@ public function testDeleteFieldsWithSecondArgument() ); } - public function testDeleteVersions() + public function testDeleteVersions(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -1037,7 +1036,7 @@ public function testDeleteVersions() ); } - public function testDeleteVersionsWithSecondArgument() + public function testDeleteVersionsWithSecondArgument(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -1066,7 +1065,7 @@ public function testDeleteVersionsWithSecondArgument() /** * @throws \Exception */ - public function testSetName() + public function testSetName(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -1098,7 +1097,7 @@ public function testSetName() ); } - public function testDeleteNames() + public function testDeleteNames(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -1124,7 +1123,7 @@ public function testDeleteNames() ); } - public function testDeleteNamesWithSecondArgument() + public function testDeleteNamesWithSecondArgument(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -1150,7 +1149,7 @@ public function testDeleteNamesWithSecondArgument() ); } - public function testDeleteContent() + public function testDeleteContent(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -1230,7 +1229,7 @@ public function testLoadRelations(): void ); } - public function testLoadRelationsByType() + public function testLoadRelationsByType(): void { $this->insertRelationFixture(); @@ -1253,7 +1252,7 @@ public function testLoadRelationsByType() ); } - public function testLoadRelationsByVersion() + public function testLoadRelationsByVersion(): void { $this->insertRelationFixture(); @@ -1270,7 +1269,7 @@ public function testLoadRelationsByVersion() ); } - public function testLoadRelationsNoResult() + public function testLoadRelationsNoResult(): void { $this->insertRelationFixture(); @@ -1281,7 +1280,7 @@ public function testLoadRelationsNoResult() self::assertCount(0, $relations, 'Expecting no relation to be loaded'); } - public function testLoadReverseRelations() + public function testLoadReverseRelations(): void { $this->insertRelationFixture(); @@ -1298,7 +1297,7 @@ public function testLoadReverseRelations() ); } - public function testLoadReverseRelationsWithType() + public function testLoadReverseRelationsWithType(): void { $this->insertRelationFixture(); @@ -1331,7 +1330,7 @@ protected function insertRelationFixture() ); } - public function testGetLastVersionNumber() + public function testGetLastVersionNumber(): void { $this->insertDatabaseFixture( __DIR__ . '/../_fixtures/contentobjects.php' @@ -1345,7 +1344,7 @@ public function testGetLastVersionNumber() ); } - public function testInsertRelation() + public function testInsertRelation(): void { $struct = $this->getRelationCreateStructFixture(); $gateway = $this->getDatabaseGateway(); @@ -1377,7 +1376,7 @@ public function testInsertRelation() ); } - public function testDeleteRelation() + public function testDeleteRelation(): void { $this->insertRelationFixture(); diff --git a/tests/lib/Persistence/Legacy/Content/Gateway/RandomSortClauseHandlerFactoryTest.php b/tests/lib/Persistence/Legacy/Content/Gateway/RandomSortClauseHandlerFactoryTest.php index ccc27882d6..c24915e2b9 100644 --- a/tests/lib/Persistence/Legacy/Content/Gateway/RandomSortClauseHandlerFactoryTest.php +++ b/tests/lib/Persistence/Legacy/Content/Gateway/RandomSortClauseHandlerFactoryTest.php @@ -23,7 +23,7 @@ class RandomSortClauseHandlerFactoryTest extends TestCase */ public function testGetGateway(): void { - $platform = $this->createMock(AbstractPlatform::class); + $platform = self::createStub(AbstractPlatform::class); $connection = $this->createMock(Connection::class); $connection ->method('getDatabasePlatform') @@ -52,7 +52,7 @@ public function testGetGateway(): void */ public function testGetGatewayNotImplemented(): void { - $platform = $this->createMock(AbstractPlatform::class); + $platform = self::createStub(AbstractPlatform::class); $connection = $this->createMock(Connection::class); $connection ->method('getDatabasePlatform') diff --git a/tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php b/tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php index 5a743d93b4..b5bed5210d 100644 --- a/tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php +++ b/tests/lib/Persistence/Legacy/Content/Language/CachingLanguageHandlerTest.php @@ -16,10 +16,9 @@ use Ibexa\Core\Persistence\Cache\InMemory\InMemoryCache; use Ibexa\Core\Persistence\Legacy\Content\Language\CachingHandler; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\Language\CachingHandler - */ +#[CoversClass(CachingHandler::class)] class CachingLanguageHandlerTest extends TestCase { /** @@ -46,7 +45,7 @@ class CachingLanguageHandlerTest extends TestCase /** @var \Ibexa\Core\Persistence\Cache\Identifier\CacheIdentifierGeneratorInterface */ protected $cacheIdentifierGeneratorMock; - public function testCreate() + public function testCreate(): void { $handler = $this->getLanguageHandler(); $innerHandlerMock = $this->getInnerLanguageHandlerMock(); @@ -100,7 +99,7 @@ protected function getLanguageFixture() return $language; } - public function testUpdate() + public function testUpdate(): void { $handler = $this->getLanguageHandler(); @@ -119,7 +118,7 @@ public function testUpdate() $handler->update($languageFixture); } - public function testLoad() + public function testLoad(): void { $handler = $this->getLanguageHandler(); $cacheMock = $this->getLanguageCacheMock(); @@ -143,7 +142,7 @@ public function testLoad() ); } - public function testLoadFailure() + public function testLoadFailure(): void { $handler = $this->getLanguageHandler(); $cacheMock = $this->getLanguageCacheMock(); @@ -173,7 +172,7 @@ public function testLoadFailure() $handler->load(2); } - public function testLoadByLanguageCode() + public function testLoadByLanguageCode(): void { $handler = $this->getLanguageHandler(); $cacheMock = $this->getLanguageCacheMock(); @@ -197,7 +196,7 @@ public function testLoadByLanguageCode() ); } - public function testLoadByLanguageCodeFailure() + public function testLoadByLanguageCodeFailure(): void { $handler = $this->getLanguageHandler(); $cacheMock = $this->getLanguageCacheMock(); @@ -227,7 +226,7 @@ public function testLoadByLanguageCodeFailure() $handler->loadByLanguageCode('eng-US'); } - public function testLoadAll() + public function testLoadAll(): void { $handler = $this->getLanguageHandler(); $cacheMock = $this->getLanguageCacheMock(); @@ -248,23 +247,31 @@ public function testLoadAll() self::assertIsArray($result); } - public function testDelete() + public function testDelete(): void { $handler = $this->getLanguageHandler(); $cacheMock = $this->getLanguageCacheMock(); $innerHandlerMock = $this->getInnerLanguageHandlerMock(); $cacheIdentifierGeneratorMock = $this->getCacheIdentifierGeneratorMock(); - - $cacheIdentifierGeneratorMock->expects(self::exactly(2)) - ->method('generateKey') - ->withConsecutive( - ['language', [2], true], - ['language_list', [], true] - ) - ->willReturnOnConsecutiveCalls( - 'ibx-la-2', - 'ibx-lal' - ); + $matcher = self::exactly(2); + + $cacheIdentifierGeneratorMock->expects($matcher) + ->method('generateKey')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame('language', $parameters[0]); + $this->assertSame([2], $parameters[1]); + $this->assertTrue($parameters[2]); + + return 'ibx-la-2'; + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame('language_list', $parameters[0]); + $this->assertSame([], $parameters[1]); + $this->assertTrue($parameters[2]); + + return 'ibx-lal'; + } + }); $innerHandlerMock->expects(self::once()) ->method('delete') diff --git a/tests/lib/Persistence/Legacy/Content/Language/Gateway/DoctrineDatabaseTest.php b/tests/lib/Persistence/Legacy/Content/Language/Gateway/DoctrineDatabaseTest.php index 6e1a1dc9ff..80f7edec92 100644 --- a/tests/lib/Persistence/Legacy/Content/Language/Gateway/DoctrineDatabaseTest.php +++ b/tests/lib/Persistence/Legacy/Content/Language/Gateway/DoctrineDatabaseTest.php @@ -11,10 +11,9 @@ use Ibexa\Core\Persistence\Legacy\Content\Language\Gateway; use Ibexa\Core\Persistence\Legacy\Content\Language\Gateway\DoctrineDatabase; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\Language\Gateway\DoctrineDatabase - */ +#[CoversClass(DoctrineDatabase::class)] class DoctrineDatabaseTest extends TestCase { /** @@ -36,7 +35,7 @@ protected function setUp(): void ); } - public function testInsertLanguage() + public function testInsertLanguage(): void { $gateway = $this->getDatabaseGateway(); @@ -74,7 +73,7 @@ protected function getLanguageFixture() return $language; } - public function testUpdateLanguage() + public function testUpdateLanguage(): void { $gateway = $this->getDatabaseGateway(); @@ -99,7 +98,7 @@ public function testUpdateLanguage() ); } - public function testLoadLanguageListData() + public function testLoadLanguageListData(): void { $gateway = $this->getDatabaseGateway(); @@ -118,7 +117,7 @@ public function testLoadLanguageListData() ); } - public function testLoadAllLanguagesData() + public function testLoadAllLanguagesData(): void { $gateway = $this->getDatabaseGateway(); @@ -143,7 +142,7 @@ public function testLoadAllLanguagesData() ); } - public function testDeleteLanguage() + public function testDeleteLanguage(): void { $gateway = $this->getDatabaseGateway(); diff --git a/tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php b/tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php index 7cbde56b28..d7866b68f2 100644 --- a/tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php +++ b/tests/lib/Persistence/Legacy/Content/Language/LanguageHandlerTest.php @@ -14,10 +14,9 @@ use Ibexa\Core\Persistence\Legacy\Content\Language\Handler; use Ibexa\Core\Persistence\Legacy\Content\Language\Mapper as LanguageMapper; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\Language\Handler - */ +#[CoversClass(Handler::class)] class LanguageHandlerTest extends TestCase { /** @@ -41,7 +40,7 @@ class LanguageHandlerTest extends TestCase */ protected $mapperMock; - public function testCreate() + public function testCreate(): void { $handler = $this->getLanguageHandler(); @@ -87,7 +86,7 @@ protected function getCreateStructFixture() return new Language\CreateStruct(); } - public function testUpdate() + public function testUpdate(): void { $handler = $this->getLanguageHandler(); @@ -109,7 +108,7 @@ protected function getLanguageFixture() return new Language(); } - public function testLoad() + public function testLoad(): void { $handler = $this->getLanguageHandler(); $mapperMock = $this->getMapperMock(); @@ -133,7 +132,7 @@ public function testLoad() ); } - public function testLoadFailure() + public function testLoadFailure(): void { $this->expectException(NotFoundException::class); @@ -155,7 +154,7 @@ public function testLoadFailure() $result = $handler->load(2); } - public function testLoadByLanguageCode() + public function testLoadByLanguageCode(): void { $handler = $this->getLanguageHandler(); $mapperMock = $this->getMapperMock(); @@ -179,7 +178,7 @@ public function testLoadByLanguageCode() ); } - public function testLoadByLanguageCodeFailure() + public function testLoadByLanguageCodeFailure(): void { $this->expectException(NotFoundException::class); @@ -201,7 +200,7 @@ public function testLoadByLanguageCodeFailure() $result = $handler->loadByLanguageCode('eng-US'); } - public function testLoadAll() + public function testLoadAll(): void { $handler = $this->getLanguageHandler(); $mapperMock = $this->getMapperMock(); @@ -223,7 +222,7 @@ public function testLoadAll() ); } - public function testDeleteSuccess() + public function testDeleteSuccess(): void { $handler = $this->getLanguageHandler(); $gatewayMock = $this->getGatewayMock(); @@ -239,7 +238,7 @@ public function testDeleteSuccess() $result = $handler->delete(2); } - public function testDeleteFail() + public function testDeleteFail(): void { $this->expectException(\LogicException::class); diff --git a/tests/lib/Persistence/Legacy/Content/Language/MapperTest.php b/tests/lib/Persistence/Legacy/Content/Language/MapperTest.php index 55e19d5dfe..9960215490 100644 --- a/tests/lib/Persistence/Legacy/Content/Language/MapperTest.php +++ b/tests/lib/Persistence/Legacy/Content/Language/MapperTest.php @@ -11,13 +11,12 @@ use Ibexa\Contracts\Core\Persistence\Content\Language\CreateStruct; use Ibexa\Core\Persistence\Legacy\Content\Language\Mapper; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\Language\Mapper - */ +#[CoversClass(Mapper::class)] class MapperTest extends TestCase { - public function testCreateLanguageFromCreateStruct() + public function testCreateLanguageFromCreateStruct(): void { $mapper = new Mapper(); @@ -32,7 +31,7 @@ public function testCreateLanguageFromCreateStruct() ); } - public function testExtractLanguagesFromRows() + public function testExtractLanguagesFromRows(): void { $mapper = new Mapper(); diff --git a/tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php b/tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php index 14c39c2035..1d103d80a0 100644 --- a/tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php +++ b/tests/lib/Persistence/Legacy/Content/Language/MaskGeneratorTest.php @@ -11,14 +11,14 @@ use Ibexa\Contracts\Core\Persistence\Content\Language\Handler as LanguageHandler; use Ibexa\Core\Persistence\Legacy\Content\Language\MaskGenerator; use Ibexa\Tests\Core\Persistence\Legacy\Content\LanguageAwareTestCase; +use PHPUnit\Framework\Attributes\DataProvider; class MaskGeneratorTest extends LanguageAwareTestCase { /** * @param array $languages - * - * @dataProvider getLanguageMaskData */ + #[DataProvider('getLanguageMaskData')] public function testGenerateLanguageMaskFromLanguagesCodes(array $languages, bool $isAlwaysAvailable, int $expectedMask): void { $generator = $this->getMaskGenerator(); @@ -69,14 +69,13 @@ public static function getLanguageMaskData(): array * @param string $languageCode * @param bool $alwaysAvailable * @param int $expectedIndicator - * - * @dataProvider getLanguageIndicatorData */ + #[DataProvider('getLanguageIndicatorData')] public function testGenerateLanguageIndicator( $languageCode, $alwaysAvailable, $expectedIndicator - ) { + ): void { $generator = $this->getMaskGenerator(); self::assertSame( @@ -90,7 +89,7 @@ public function testGenerateLanguageIndicator( * * @return array */ - public static function getLanguageIndicatorData() + public static function getLanguageIndicatorData(): array { return [ 'not_available' => [ @@ -106,7 +105,7 @@ public static function getLanguageIndicatorData() ]; } - public function testIsLanguageAlwaysAvailable() + public function testIsLanguageAlwaysAvailable(): void { $generator = $this->getMaskGenerator(); @@ -121,7 +120,7 @@ public function testIsLanguageAlwaysAvailable() ); } - public function testIsLanguageAlwaysAvailableOtherLanguage() + public function testIsLanguageAlwaysAvailableOtherLanguage(): void { $generator = $this->getMaskGenerator(); @@ -136,7 +135,7 @@ public function testIsLanguageAlwaysAvailableOtherLanguage() ); } - public function testIsLanguageAlwaysAvailableNoDefault() + public function testIsLanguageAlwaysAvailableNoDefault(): void { $generator = $this->getMaskGenerator(); @@ -153,10 +152,9 @@ public function testIsLanguageAlwaysAvailableNoDefault() /** * @param int $langMask * @param bool $expectedResult - * - * @dataProvider isAlwaysAvailableProvider */ - public function testIsAlwaysAvailable($langMask, $expectedResult) + #[DataProvider('isAlwaysAvailableProvider')] + public function testIsAlwaysAvailable($langMask, $expectedResult): void { $generator = $this->getMaskGenerator(); self::assertSame($expectedResult, $generator->isAlwaysAvailable($langMask)); @@ -167,7 +165,7 @@ public function testIsAlwaysAvailable($langMask, $expectedResult) * * @return array */ - public function isAlwaysAvailableProvider() + public static function isAlwaysAvailableProvider(): array { return [ [2, false], @@ -178,10 +176,8 @@ public function isAlwaysAvailableProvider() ]; } - /** - * @dataProvider removeAlwaysAvailableFlagProvider - */ - public function testRemoveAlwaysAvailableFlag($langMask, $expectedResult) + #[DataProvider('removeAlwaysAvailableFlagProvider')] + public function testRemoveAlwaysAvailableFlag($langMask, $expectedResult): void { $generator = $this->getMaskGenerator(); self::assertSame($expectedResult, $generator->removeAlwaysAvailableFlag($langMask)); @@ -192,7 +188,7 @@ public function testRemoveAlwaysAvailableFlag($langMask, $expectedResult) * * @return array */ - public function removeAlwaysAvailableFlagProvider() + public static function removeAlwaysAvailableFlagProvider(): array { return [ [3, 2], @@ -205,10 +201,9 @@ public function removeAlwaysAvailableFlagProvider() /** * @param int $langMask * @param array $expectedResult - * - * @dataProvider languageIdsFromMaskProvider */ - public function testExtractLanguageIdsFromMask($langMask, array $expectedResult) + #[DataProvider('languageIdsFromMaskProvider')] + public function testExtractLanguageIdsFromMask($langMask, array $expectedResult): void { $generator = $this->getMaskGenerator(); self::assertSame($expectedResult, $generator->extractLanguageIdsFromMask($langMask)); @@ -219,7 +214,7 @@ public function testExtractLanguageIdsFromMask($langMask, array $expectedResult) * * @return array */ - public function languageIdsFromMaskProvider() + public static function languageIdsFromMaskProvider(): array { return [ [ diff --git a/tests/lib/Persistence/Legacy/Content/LanguageAwareTestCase.php b/tests/lib/Persistence/Legacy/Content/LanguageAwareTestCase.php index 0c0c1b792f..e16e7263ce 100644 --- a/tests/lib/Persistence/Legacy/Content/LanguageAwareTestCase.php +++ b/tests/lib/Persistence/Legacy/Content/LanguageAwareTestCase.php @@ -117,7 +117,7 @@ protected function getFieldNameGeneratorMock() protected function getFullTextMapper(Persistence\Legacy\Content\Type\Handler $contentTypeHandler) { return new FullTextMapper( - $this->createMock(FieldRegistry::class), + self::createStub(FieldRegistry::class), $contentTypeHandler ); } diff --git a/tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php b/tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php index ce3d273c65..2ff5d41cb0 100644 --- a/tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php +++ b/tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTest.php @@ -17,10 +17,11 @@ use Ibexa\Core\Persistence\Legacy\Content\Location\Gateway\DoctrineDatabase; use Ibexa\Core\Search\Legacy\Content; use Ibexa\Tests\Core\Persistence\Legacy\Content\LanguageAwareTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; -/** - * @covers \DoctrineDatabase - */ +#[CoversClass(DoctrineDatabase::class)] class DoctrineDatabaseTest extends LanguageAwareTestCase { protected function getLocationGateway() @@ -65,7 +66,7 @@ private function assertLoadLocationProperties(array $locationData): void } } - public function testLoadLocationByRemoteId() + public function testLoadLocationByRemoteId(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); @@ -74,7 +75,7 @@ public function testLoadLocationByRemoteId() self::assertLoadLocationProperties($data); } - public function testLoadLocation() + public function testLoadLocation(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); @@ -83,7 +84,7 @@ public function testLoadLocation() self::assertLoadLocationProperties($data); } - public function testLoadLocationList() + public function testLoadLocationList(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); @@ -96,7 +97,7 @@ public function testLoadLocationList() self::assertLoadLocationProperties($locationRow); } - public function testLoadInvalidLocation() + public function testLoadInvalidLocation(): void { $this->expectException(NotFoundException::class); @@ -105,7 +106,7 @@ public function testLoadInvalidLocation() $gateway->getBasicNodeData(1337); } - public function testLoadLocationDataByContent() + public function testLoadLocationDataByContent(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); @@ -120,7 +121,7 @@ public function testLoadLocationDataByContent() self::assertLoadLocationProperties($locationRow); } - public function testLoadParentLocationDataForDraftContentAll() + public function testLoadParentLocationDataForDraftContentAll(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); @@ -135,7 +136,7 @@ public function testLoadParentLocationDataForDraftContentAll() self::assertLoadLocationProperties($locationRow); } - public function testLoadLocationDataByContentLimitSubtree() + public function testLoadLocationDataByContentLimitSubtree(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); @@ -146,7 +147,7 @@ public function testLoadLocationDataByContentLimitSubtree() self::assertCount(0, $locationsData); } - public function testMoveSubtreePathUpdate() + public function testMoveSubtreePathUpdate(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); @@ -191,7 +192,7 @@ public function testMoveSubtreePathUpdate() ); } - public function testMoveHiddenDestinationUpdate() + public function testMoveHiddenDestinationUpdate(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); @@ -237,7 +238,7 @@ public function testMoveHiddenDestinationUpdate() ); } - public function testMoveHiddenSourceUpdate() + public function testMoveHiddenSourceUpdate(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); @@ -283,7 +284,7 @@ public function testMoveHiddenSourceUpdate() ); } - public function testMoveHiddenSourceChildUpdate() + public function testMoveHiddenSourceChildUpdate(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); @@ -334,7 +335,7 @@ public function testMoveHiddenSourceChildUpdate() /** * @throws \Exception */ - public function testMoveSubtreeAssignmentUpdate() + public function testMoveSubtreeAssignmentUpdate(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); @@ -366,7 +367,7 @@ public function testMoveSubtreeAssignmentUpdate() ); } - public function testHideUpdateHidden() + public function testHideUpdateHidden(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); @@ -388,10 +389,8 @@ public function testHideUpdateHidden() ); } - /** - * @depends testHideUpdateHidden - */ - public function testHideUnhideUpdateHidden() + #[Depends('testHideUpdateHidden')] + public function testHideUnhideUpdateHidden(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); @@ -414,10 +413,8 @@ public function testHideUnhideUpdateHidden() ); } - /** - * @depends testHideUpdateHidden - */ - public function testHideUnhideParentTree() + #[Depends('testHideUpdateHidden')] + public function testHideUnhideParentTree(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); @@ -443,10 +440,8 @@ public function testHideUnhideParentTree() ); } - /** - * @depends testHideUpdateHidden - */ - public function testHideUnhidePartialSubtree() + #[Depends('testHideUpdateHidden')] + public function testHideUnhidePartialSubtree(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); @@ -472,7 +467,7 @@ public function testHideUnhidePartialSubtree() ); } - public function testSwapLocations() + public function testSwapLocations(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); @@ -492,7 +487,7 @@ public function testSwapLocations() ); } - public function testCreateLocation() + public function testCreateLocation(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); @@ -525,10 +520,8 @@ public function testCreateLocation() ); } - /** - * @depends testCreateLocation - */ - public function testGetMainNodeId() + #[Depends('testCreateLocation')] + public function testGetMainNodeId(): void { $gateway = $this->getLocationGateway(); @@ -570,7 +563,10 @@ public function testGetMainNodeId() self::assertEquals($mainLocation->id, $res = $methodReflection->invoke($gateway, 68)); } - public static function getCreateLocationValues() + /** + * @return array + */ + public static function getCreateLocationValues(): array { return [ ['contentobject_id', 68], @@ -589,12 +585,9 @@ public static function getCreateLocationValues() ]; } - /** - * @depends testCreateLocation - * - * @dataProvider getCreateLocationValues - */ - public function testCreateLocationValues($field, $value) + #[Depends('testCreateLocation')] + #[DataProvider('getCreateLocationValues')] + public function testCreateLocationValues($field, $value): void { if ($value === null) { self::markTestIncomplete('Proper value setting yet unknown.'); @@ -631,7 +624,10 @@ public function testCreateLocationValues($field, $value) ); } - public static function getCreateLocationReturnValues() + /** + * @return array + */ + public static function getCreateLocationReturnValues(): array { return [ ['id', 228], @@ -648,12 +644,9 @@ public static function getCreateLocationReturnValues() ]; } - /** - * @depends testCreateLocation - * - * @dataProvider getCreateLocationReturnValues - */ - public function testCreateLocationReturnValues($field, $value) + #[Depends('testCreateLocation')] + #[DataProvider('getCreateLocationReturnValues')] + public function testCreateLocationReturnValues($field, $value): void { if ($value === null) { self::markTestIncomplete('Proper value setting yet unknown.'); @@ -684,7 +677,10 @@ public function testCreateLocationReturnValues($field, $value) self::assertEquals($value, $location->$field); } - public static function getUpdateLocationData() + /** + * @return array + */ + public static function getUpdateLocationData(): array { return [ ['priority', 23], @@ -694,10 +690,8 @@ public static function getUpdateLocationData() ]; } - /** - * @dataProvider getUpdateLocationData - */ - public function testUpdateLocation($field, $value) + #[DataProvider('getUpdateLocationData')] + public function testUpdateLocation($field, $value): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); @@ -723,7 +717,10 @@ public function testUpdateLocation($field, $value) ); } - public static function getNodeAssignmentValues() + /** + * @return array + */ + public static function getNodeAssignmentValues(): array { return [ ['contentobject_version', [1]], @@ -799,14 +796,12 @@ private function buildContentTreeSelectContentWithParentQuery( } /** - * @depends testCreateLocation - * - * @dataProvider getNodeAssignmentValues - * * @param string $field * @param array $expectedResult */ - public function testCreateLocationNodeAssignmentCreation(string $field, array $expectedResult) + #[Depends('testCreateLocation')] + #[DataProvider('getNodeAssignmentValues')] + public function testCreateLocationNodeAssignmentCreation(string $field, array $expectedResult): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); @@ -833,10 +828,8 @@ public function testCreateLocationNodeAssignmentCreation(string $field, array $e ); } - /** - * @depends testCreateLocation - */ - public function testCreateLocationNodeAssignmentCreationMainLocation() + #[Depends('testCreateLocation')] + public function testCreateLocationNodeAssignmentCreationMainLocation(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); @@ -862,7 +855,7 @@ public function testCreateLocationNodeAssignmentCreationMainLocation() ); } - public function testUpdateLocationsContentVersionNo() + public function testUpdateLocationsContentVersionNo(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); @@ -902,7 +895,7 @@ public function testUpdateLocationsContentVersionNo() ); } - public function testDeleteNodeAssignment() + public function testDeleteNodeAssignment(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); @@ -921,7 +914,7 @@ public function testDeleteNodeAssignment() ); } - public function testDeleteNodeAssignmentWithSecondArgument() + public function testDeleteNodeAssignmentWithSecondArgument(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); @@ -950,7 +943,10 @@ public function testDeleteNodeAssignmentWithSecondArgument() ); } - public static function getConvertNodeAssignmentsLocationValues() + /** + * @return array + */ + public static function getConvertNodeAssignmentsLocationValues(): array { return [ ['contentobject_id', '68'], @@ -971,12 +967,9 @@ public static function getConvertNodeAssignmentsLocationValues() ]; } - /** - * @depends testCreateLocationNodeAssignmentCreation - * - * @dataProvider getConvertNodeAssignmentsLocationValues - */ - public function testConvertNodeAssignments($field, $value) + #[Depends('testCreateLocationNodeAssignmentCreation')] + #[DataProvider('getConvertNodeAssignmentsLocationValues')] + public function testConvertNodeAssignments($field, $value): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); @@ -1033,10 +1026,8 @@ public function testConvertNodeAssignments($field, $value) } } - /** - * @depends testCreateLocationNodeAssignmentCreation - */ - public function testConvertNodeAssignmentsMainLocation() + #[Depends('testCreateLocationNodeAssignmentCreation')] + public function testConvertNodeAssignmentsMainLocation(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); @@ -1069,10 +1060,8 @@ public function testConvertNodeAssignmentsMainLocation() ); } - /** - * @depends testCreateLocationNodeAssignmentCreation - */ - public function testConvertNodeAssignmentsParentHidden() + #[Depends('testCreateLocationNodeAssignmentCreation')] + public function testConvertNodeAssignmentsParentHidden(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); @@ -1109,10 +1098,8 @@ public function testConvertNodeAssignmentsParentHidden() ); } - /** - * @depends testCreateLocationNodeAssignmentCreation - */ - public function testConvertNodeAssignmentsParentInvisible() + #[Depends('testCreateLocationNodeAssignmentCreation')] + public function testConvertNodeAssignmentsParentInvisible(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); @@ -1149,10 +1136,8 @@ public function testConvertNodeAssignmentsParentInvisible() ); } - /** - * @depends testCreateLocationNodeAssignmentCreation - */ - public function testConvertNodeAssignmentsUpdateAssignment() + #[Depends('testCreateLocationNodeAssignmentCreation')] + public function testConvertNodeAssignmentsUpdateAssignment(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); @@ -1184,7 +1169,7 @@ public function testConvertNodeAssignmentsUpdateAssignment() /** * Test for the setSectionForSubtree() method. */ - public function testSetSectionForSubtree() + public function testSetSectionForSubtree(): void { $this->insertDatabaseFixture(__DIR__ . '/../../_fixtures/contentobjects.php'); $gateway = $this->getLocationGateway(); @@ -1208,7 +1193,7 @@ public function testSetSectionForSubtree() * * @throws \Doctrine\DBAL\Exception */ - public function testChangeMainLocation() + public function testChangeMainLocation(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); // Create additional location and assignment for test purpose @@ -1343,7 +1328,7 @@ public function testChangeMainLocation() /** * Test for the getChildren() method. */ - public function testGetChildren() + public function testGetChildren(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); @@ -1407,7 +1392,7 @@ public function testGetFallbackMainNodeData(): void /** * Test for the removeLocation() method. */ - public function testRemoveLocation() + public function testRemoveLocation(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); @@ -1422,7 +1407,10 @@ public function testRemoveLocation() } } - public function providerForTestUpdatePathIdentificationString() + /** + * @return array + */ + public static function providerForTestUpdatePathIdentificationString(): array { return [ [77, 2, 'new_solutions', 'new_solutions'], @@ -1432,16 +1420,14 @@ public function providerForTestUpdatePathIdentificationString() /** * Test for the updatePathIdentificationString() method. - * - * - * @dataProvider providerForTestUpdatePathIdentificationString */ + #[DataProvider('providerForTestUpdatePathIdentificationString')] public function testUpdatePathIdentificationString( $locationId, $parentLocationId, $text, $expected - ) { + ): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $gateway = $this->getLocationGateway(); diff --git a/tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php b/tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php index bd7a083373..fc2bcc5842 100644 --- a/tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php +++ b/tests/lib/Persistence/Legacy/Content/Location/Gateway/DoctrineDatabaseTrashTest.php @@ -14,10 +14,10 @@ use Ibexa\Core\Persistence\Legacy\Content\Location\Gateway; use Ibexa\Core\Persistence\Legacy\Content\Location\Gateway\DoctrineDatabase; use Ibexa\Tests\Core\Persistence\Legacy\Content\LanguageAwareTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\Location\Gateway\DoctrineDatabase - */ +#[CoversClass(DoctrineDatabase::class)] class DoctrineDatabaseTrashTest extends LanguageAwareTestCase { protected function getLocationGateway() @@ -34,7 +34,7 @@ protected function getLocationGateway() /** * @todo test updated content status */ - public function testTrashLocation() + public function testTrashLocation(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $handler = $this->getLocationGateway(); @@ -55,7 +55,7 @@ public function testTrashLocation() ); } - public function testTrashLocationUpdateTrashTable() + public function testTrashLocationUpdateTrashTable(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $handler = $this->getLocationGateway(); @@ -72,7 +72,10 @@ public function testTrashLocationUpdateTrashTable() ); } - public static function getUntrashedLocationValues() + /** + * @return array + */ + public static function getUntrashedLocationValues(): array { return [ ['contentobject_is_published', 1], @@ -92,10 +95,8 @@ public static function getUntrashedLocationValues() ]; } - /** - * @dataProvider getUntrashedLocationValues - */ - public function testUntrashLocationDefault($property, $value) + #[DataProvider('getUntrashedLocationValues')] + public function testUntrashLocationDefault($property, $value): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $handler = $this->getLocationGateway(); @@ -113,7 +114,7 @@ public function testUntrashLocationDefault($property, $value) ); } - public function testUntrashLocationNewParent() + public function testUntrashLocationNewParent(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $handler = $this->getLocationGateway(); @@ -131,7 +132,7 @@ public function testUntrashLocationNewParent() ); } - public function testUntrashInvalidLocation() + public function testUntrashInvalidLocation(): void { $this->expectException(NotFoundException::class); @@ -141,7 +142,7 @@ public function testUntrashInvalidLocation() $handler->untrashLocation(23); } - public function testUntrashLocationInvalidParent() + public function testUntrashLocationInvalidParent(): void { $this->expectException(NotFoundException::class); @@ -152,7 +153,7 @@ public function testUntrashLocationInvalidParent() $handler->untrashLocation(71, 1337); } - public function testUntrashLocationInvalidOldParent() + public function testUntrashLocationInvalidOldParent(): void { $this->expectException(NotFoundException::class); @@ -165,7 +166,10 @@ public function testUntrashLocationInvalidOldParent() $handler->untrashLocation(71); } - public static function getLoadTrashValues() + /** + * @return array + */ + public static function getLoadTrashValues(): array { return [ ['node_id', 71], @@ -185,10 +189,8 @@ public static function getLoadTrashValues() ]; } - /** - * @dataProvider getLoadTrashValues - */ - public function testLoadTrashByLocationId($field, $value) + #[DataProvider('getLoadTrashValues')] + public function testLoadTrashByLocationId($field, $value): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $handler = $this->getLocationGateway(); @@ -203,7 +205,7 @@ public function testLoadTrashByLocationId($field, $value) ); } - public function testCountTrashed() + public function testCountTrashed(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $handler = $this->getLocationGateway(); @@ -221,7 +223,7 @@ public function testCountTrashed() ); } - public function testListEmptyTrash() + public function testListEmptyTrash(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $handler = $this->getLocationGateway(); @@ -245,7 +247,7 @@ protected function trashSubtree() $handler->trashLocation(76); } - public function testListFullTrash() + public function testListFullTrash(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $handler = $this->getLocationGateway(); @@ -257,7 +259,7 @@ public function testListFullTrash() ); } - public function testListTrashLimited() + public function testListTrashLimited(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $handler = $this->getLocationGateway(); @@ -269,7 +271,10 @@ public function testListTrashLimited() ); } - public static function getTrashValues() + /** + * @return array + */ + public static function getTrashValues(): array { return [ ['contentobject_id', 67], @@ -290,10 +295,8 @@ public static function getTrashValues() ]; } - /** - * @dataProvider getTrashValues - */ - public function testListTrashItem($key, $value) + #[DataProvider('getTrashValues')] + public function testListTrashItem($key, $value): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $handler = $this->getLocationGateway(); @@ -303,7 +306,7 @@ public function testListTrashItem($key, $value) self::assertEquals($value, $trashList[0][$key]); } - public function testListTrashSortedPathStringDesc() + public function testListTrashSortedPathStringDesc(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $handler = $this->getLocationGateway(); @@ -335,7 +338,7 @@ static function ($trashItem) { ); } - public function testListTrashSortedDepth() + public function testListTrashSortedDepth(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $handler = $this->getLocationGateway(); @@ -368,7 +371,7 @@ static function ($trashItem) { ); } - public function testCleanupTrash() + public function testCleanupTrash(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $handler = $this->getLocationGateway(); @@ -384,7 +387,7 @@ public function testCleanupTrash() ); } - public function testRemoveElementFromTrash() + public function testRemoveElementFromTrash(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $handler = $this->getLocationGateway(); @@ -401,7 +404,7 @@ public function testRemoveElementFromTrash() ); } - public function testCountLocationsByContentId() + public function testCountLocationsByContentId(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); $handler = $this->getLocationGateway(); diff --git a/tests/lib/Persistence/Legacy/Content/Location/MapperTest.php b/tests/lib/Persistence/Legacy/Content/Location/MapperTest.php index b4b66a462c..e379181e6f 100644 --- a/tests/lib/Persistence/Legacy/Content/Location/MapperTest.php +++ b/tests/lib/Persistence/Legacy/Content/Location/MapperTest.php @@ -11,10 +11,9 @@ use Ibexa\Contracts\Core\Persistence\Content\Location\Trashed; use Ibexa\Core\Persistence\Legacy\Content\Location\Mapper; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\Location\Mapper - */ +#[CoversClass(Mapper::class)] class MapperTest extends TestCase { /** @@ -75,7 +74,7 @@ class MapperTest extends TestCase 'sortOrder' => 1, ]; - public function testCreateLocationFromRow() + public function testCreateLocationFromRow(): void { $mapper = new Mapper(); @@ -89,7 +88,7 @@ public function testCreateLocationFromRow() ); } - public function testCreateLocationsFromRows() + public function testCreateLocationsFromRows(): void { $inputRows = []; for ($i = 0; $i < 3; ++$i) { @@ -111,7 +110,7 @@ public function testCreateLocationsFromRows() } } - public function testCreateTrashedFromRow() + public function testCreateTrashedFromRow(): void { $mapper = new Mapper(); @@ -128,7 +127,7 @@ public function testCreateTrashedFromRow() ); } - public function testCreateLocationFromRowWithPrefix() + public function testCreateLocationFromRowWithPrefix(): void { $prefix = 'some_prefix_'; @@ -147,7 +146,7 @@ public function testCreateLocationFromRowWithPrefix() ); } - public function testGetLocationCreateStruct() + public function testGetLocationCreateStruct(): void { $mapper = new Mapper(); diff --git a/tests/lib/Persistence/Legacy/Content/Location/TrashHandlerTest.php b/tests/lib/Persistence/Legacy/Content/Location/TrashHandlerTest.php index 3a4beafc3f..130fa96d08 100644 --- a/tests/lib/Persistence/Legacy/Content/Location/TrashHandlerTest.php +++ b/tests/lib/Persistence/Legacy/Content/Location/TrashHandlerTest.php @@ -14,10 +14,9 @@ use Ibexa\Core\Persistence\Legacy\Content as CoreContent; use Ibexa\Core\Persistence\Legacy\Content\Location\Trash\Handler; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\Location\Trash\Handler - */ +#[CoversClass(Handler::class)] class TrashHandlerTest extends TestCase { /** @@ -58,12 +57,12 @@ protected function getTrashHandler() ); } - public function testTrashSubtree() + public function testTrashSubtree(): void { $handler = $this->getTrashHandler(); $this->locationGateway - ->expects(self::at(0)) + ->expects(self::once()) ->method('getSubtreeContent') ->with(20) ->will( @@ -85,30 +84,34 @@ public function testTrashSubtree() ) ); + $countLocationsByContentIdMatcher = self::exactly(2); $this->locationGateway - ->expects(self::at(1)) + ->expects($countLocationsByContentIdMatcher) ->method('countLocationsByContentId') - ->with(10) - ->will(self::returnValue(1)); + ->willReturnCallback(static function ($contentId) use ($countLocationsByContentIdMatcher) { + if ($countLocationsByContentIdMatcher->numberOfInvocations() === 1) { + self::assertSame(10, $contentId); + + return 1; + } + + self::assertSame(11, $contentId); + + return 2; + }); $this->locationGateway - ->expects(self::at(2)) + ->expects(self::once()) ->method('trashLocation') ->with(20); $this->locationGateway - ->expects(self::at(3)) - ->method('countLocationsByContentId') - ->with(11) - ->will(self::returnValue(2)); - - $this->locationGateway - ->expects(self::at(4)) + ->expects(self::once()) ->method('removeLocation') ->with(21); $this->locationGateway - ->expects(self::at(5)) + ->expects(self::once()) ->method('loadTrashByLocation') ->with(20) ->will(self::returnValue($array = ['data…'])); @@ -124,12 +127,12 @@ public function testTrashSubtree() self::assertSame(20, $trashedObject->id); } - public function testTrashSubtreeReturnsNull() + public function testTrashSubtreeReturnsNull(): void { $handler = $this->getTrashHandler(); $this->locationGateway - ->expects(self::at(0)) + ->expects(self::once()) ->method('getSubtreeContent') ->with(20) ->will( @@ -151,25 +154,29 @@ public function testTrashSubtreeReturnsNull() ) ); + $countLocationsByContentIdMatcher = self::exactly(2); $this->locationGateway - ->expects(self::at(1)) + ->expects($countLocationsByContentIdMatcher) ->method('countLocationsByContentId') - ->with(10) - ->will(self::returnValue(2)); + ->willReturnCallback(static function ($contentId) use ($countLocationsByContentIdMatcher) { + if ($countLocationsByContentIdMatcher->numberOfInvocations() === 1) { + self::assertSame(10, $contentId); + + return 2; + } + + self::assertSame(11, $contentId); + + return 1; + }); $this->locationGateway - ->expects(self::at(2)) + ->expects(self::once()) ->method('removeLocation') ->with(20); $this->locationGateway - ->expects(self::at(3)) - ->method('countLocationsByContentId') - ->with(11) - ->will(self::returnValue(1)); - - $this->locationGateway - ->expects(self::at(4)) + ->expects(self::once()) ->method('trashLocation') ->with(21); @@ -177,12 +184,12 @@ public function testTrashSubtreeReturnsNull() self::assertNull($returnValue); } - public function testTrashSubtreeUpdatesMainLocation() + public function testTrashSubtreeUpdatesMainLocation(): void { $handler = $this->getTrashHandler(); $this->locationGateway - ->expects(self::at(0)) + ->expects(self::once()) ->method('getSubtreeContent') ->with(20) ->will( @@ -204,30 +211,34 @@ public function testTrashSubtreeUpdatesMainLocation() ) ); + $countLocationsByContentIdMatcher = self::exactly(2); $this->locationGateway - ->expects(self::at(1)) + ->expects($countLocationsByContentIdMatcher) ->method('countLocationsByContentId') - ->with(10) - ->will(self::returnValue(1)); + ->willReturnCallback(static function ($contentId) use ($countLocationsByContentIdMatcher) { + if ($countLocationsByContentIdMatcher->numberOfInvocations() === 1) { + self::assertSame(10, $contentId); + + return 1; + } + + self::assertSame(11, $contentId); + + return 2; + }); $this->locationGateway - ->expects(self::at(2)) + ->expects(self::once()) ->method('trashLocation') ->with(20); $this->locationGateway - ->expects(self::at(3)) - ->method('countLocationsByContentId') - ->with(11) - ->will(self::returnValue(2)); - - $this->locationGateway - ->expects(self::at(4)) + ->expects(self::once()) ->method('removeLocation') ->with(21); $this->locationGateway - ->expects(self::at(5)) + ->expects(self::once()) ->method('getFallbackMainNodeData') ->with(11, 21) ->will( @@ -246,7 +257,7 @@ public function testTrashSubtreeUpdatesMainLocation() ->with(11, 100); $this->locationGateway - ->expects(self::at(6)) + ->expects(self::once()) ->method('loadTrashByLocation') ->with(20) ->will(self::returnValue($array = ['data…'])); @@ -262,12 +273,12 @@ public function testTrashSubtreeUpdatesMainLocation() self::assertSame(20, $trashedObject->id); } - public function testRecover() + public function testRecover(): void { $handler = $this->getTrashHandler(); $this->locationGateway - ->expects(self::at(0)) + ->expects(self::once()) ->method('untrashLocation') ->with(69, 23) ->will( @@ -279,18 +290,18 @@ public function testRecover() self::assertSame(70, $handler->recover(69, 23)); } - public function testLoadTrashItem() + public function testLoadTrashItem(): void { $handler = $this->getTrashHandler(); $this->locationGateway - ->expects(self::at(0)) + ->expects(self::once()) ->method('loadTrashByLocation') ->with(69) ->will(self::returnValue($array = ['data…'])); $this->locationMapper - ->expects(self::at(0)) + ->expects(self::once()) ->method('createLocationFromRow') ->with($array, null, new Trashed()); @@ -314,62 +325,76 @@ public function testEmptyTrash(): void ], ]; - // Index for locationGateway calls - $i = 0; - // Index for contentHandler calls - $iContent = 0; - // Index for locationMapper calls - $iLocation = 0; - $this->locationGateway - ->expects(self::at($i++)) + ->expects(self::once()) ->method('countTrashed') ->willReturn(2); $this->locationGateway - ->expects(self::at($i++)) + ->expects(self::once()) ->method('listTrashed') ->willReturn($expectedTrashed); - $trashedItemIds = []; - $trashedContentIds = []; + $createLocationFromRowMatcher = self::exactly(count($expectedTrashed)); + $this->locationMapper + ->expects($createLocationFromRowMatcher) + ->method('createLocationFromRow') + ->willReturnCallback(static function () use ($createLocationFromRowMatcher, $expectedTrashed): Trashed { + $trashedElement = $expectedTrashed[$createLocationFromRowMatcher->numberOfInvocations() - 1]; - foreach ($expectedTrashed as $trashedElement) { - $this->locationMapper - ->expects(self::at($iLocation++)) - ->method('createLocationFromRow') - ->willReturn( - new Trashed( - [ - 'id' => $trashedElement['node_id'], - 'contentId' => $trashedElement['contentobject_id'], - 'pathString' => $trashedElement['path_string'], - ] - ) + return new Trashed( + [ + 'id' => $trashedElement['node_id'], + 'contentId' => $trashedElement['contentobject_id'], + 'pathString' => $trashedElement['path_string'], + ] ); + }); + + $loadReverseRelationsMatcher = self::exactly(count($expectedTrashed)); + $this->contentHandler + ->expects($loadReverseRelationsMatcher) + ->method('loadReverseRelations') + ->willReturnCallback(static function ($contentId) use ($loadReverseRelationsMatcher, $expectedTrashed): array { + $trashedElement = $expectedTrashed[$loadReverseRelationsMatcher->numberOfInvocations() - 1]; + self::assertSame($trashedElement['contentobject_id'], $contentId); + + return []; + }); + + $removeElementFromTrashMatcher = self::exactly(count($expectedTrashed)); + $this->locationGateway + ->expects($removeElementFromTrashMatcher) + ->method('removeElementFromTrash') + ->willReturnCallback(static function ($nodeId) use ($removeElementFromTrashMatcher, $expectedTrashed): void { + $trashedElement = $expectedTrashed[$removeElementFromTrashMatcher->numberOfInvocations() - 1]; + self::assertSame($trashedElement['node_id'], $nodeId); + }); - $this->contentHandler - ->expects(self::at($iContent++)) - ->method('loadReverseRelations') - ->with($trashedElement['contentobject_id']) - ->willReturn([]); + $countLocationsByContentIdMatcher = self::exactly(count($expectedTrashed)); + $this->locationGateway + ->expects($countLocationsByContentIdMatcher) + ->method('countLocationsByContentId') + ->willReturnCallback(static function ($contentId) use ($countLocationsByContentIdMatcher, $expectedTrashed) { + $trashedElement = $expectedTrashed[$countLocationsByContentIdMatcher->numberOfInvocations() - 1]; + self::assertSame($trashedElement['contentobject_id'], $contentId); - $this->locationGateway - ->expects(self::at($i++)) - ->method('removeElementFromTrash') - ->with($trashedElement['node_id']); + return 0; + }); - $this->locationGateway - ->expects(self::at($i++)) - ->method('countLocationsByContentId') - ->with($trashedElement['contentobject_id']) - ->willReturn(0); + $deleteContentMatcher = self::exactly(count($expectedTrashed)); + $this->contentHandler + ->expects($deleteContentMatcher) + ->method('deleteContent') + ->willReturnCallback(static function ($contentId) use ($deleteContentMatcher, $expectedTrashed): void { + $trashedElement = $expectedTrashed[$deleteContentMatcher->numberOfInvocations() - 1]; + self::assertSame($trashedElement['contentobject_id'], $contentId); + }); - $this->contentHandler - ->expects(self::at($iContent++)) - ->method('deleteContent') - ->with($trashedElement['contentobject_id']); + $trashedItemIds = []; + $trashedContentIds = []; + foreach ($expectedTrashed as $trashedElement) { $trashedItemIds[] = $trashedElement['node_id']; $trashedContentIds[] = $trashedElement['contentobject_id']; } @@ -446,7 +471,7 @@ public function testDeleteTrashItemNoMoreLocations(): void self::assertTrue($trashItemDeleteResult->contentRemoved); } - public function testDeleteTrashItemStillHaveLocations() + public function testDeleteTrashItemStillHaveLocations(): void { $handler = $this->getTrashHandler(); @@ -504,7 +529,7 @@ public function testDeleteTrashItemStillHaveLocations() self::assertFalse($trashItemDeleteResult->contentRemoved); } - public function testFindTrashItemsWhenEmpty() + public function testFindTrashItemsWhenEmpty(): void { $handler = $this->getTrashHandler(); @@ -531,7 +556,7 @@ public function testFindTrashItemsWhenEmpty() self::assertCount(0, $trashResult);// Can't assert as empty, however we can count it. } - public function testFindTrashItemsWithLimits() + public function testFindTrashItemsWithLimits(): void { $handler = $this->getTrashHandler(); diff --git a/tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php b/tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php index 3809898d80..b6e083dbe0 100644 --- a/tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php +++ b/tests/lib/Persistence/Legacy/Content/LocationHandlerTest.php @@ -23,10 +23,10 @@ use Ibexa\Core\Persistence\Legacy\Content\ObjectState\Handler as ObjectStateHandler; use Ibexa\Core\Persistence\Legacy\Content\TreeHandler; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Depends; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\Location\Handler - */ +#[CoversClass(Handler::class)] class LocationHandlerTest extends TestCase { /** @@ -80,12 +80,12 @@ protected function getLocationHandler() $this->locationGateway, $this->locationMapper, $this->contentHandler, - $this->createMock(ObjectStateHandler::class), + self::createStub(ObjectStateHandler::class), $this->treeHandler ); } - public function testLoadLocation() + public function testLoadLocation(): void { $handler = $this->getLocationHandler(); @@ -100,7 +100,7 @@ public function testLoadLocation() self::assertInstanceOf(Location::class, $location); } - public function testLoadLocationSubtree() + public function testLoadLocationSubtree(): void { $this->locationGateway ->expects(self::once()) @@ -116,7 +116,7 @@ public function testLoadLocationSubtree() self::assertCount(2, $this->getLocationHandler()->loadSubtreeIds(77)); } - public function testLoadLocationByRemoteId() + public function testLoadLocationByRemoteId(): void { $handler = $this->getLocationHandler(); @@ -141,7 +141,7 @@ public function testLoadLocationByRemoteId() self::assertInstanceOf(Location::class, $location); } - public function testLoadLocationsByContent() + public function testLoadLocationsByContent(): void { $handler = $this->getLocationHandler(); @@ -191,7 +191,7 @@ public function loadParentLocationsForDraftContent() self::assertIsArray($locations); } - public function testMoveSubtree() + public function testMoveSubtree(): void { $handler = $this->getLocationHandler(); @@ -201,22 +201,24 @@ public function testMoveSubtree() 'parent_node_id' => 2, 'contentobject_id' => 67, ]; - $this->locationGateway - ->expects(self::at(0)) - ->method('getBasicNodeData') - ->with(69) - ->will(self::returnValue($sourceData)); - $destinationData = [ 'node_id' => 77, 'path_string' => '/1/2/77/', 'contentobject_id' => 68, ]; + + $getBasicNodeDataMatcher = self::exactly(2); $this->locationGateway - ->expects(self::at(1)) + ->expects($getBasicNodeDataMatcher) ->method('getBasicNodeData') - ->with(77) - ->will(self::returnValue($destinationData)); + ->willReturnCallback(static function (int $nodeId) use ($getBasicNodeDataMatcher, $sourceData, $destinationData) { + $expectedArgs = [$sourceData['node_id'], $destinationData['node_id']]; + $returnValues = [$sourceData, $destinationData]; + $index = $getBasicNodeDataMatcher->numberOfInvocations() - 1; + self::assertSame($expectedArgs[$index], $nodeId); + + return $returnValues[$index]; + }); $this->locationGateway ->expects(self::once()) @@ -228,36 +230,40 @@ public function testMoveSubtree() ->method('updateNodeAssignment') ->with(67, 2, 77, 5); + $loadLocationMatcher = self::exactly(2); $this->treeHandler - ->expects(self::at(0)) + ->expects($loadLocationMatcher) ->method('loadLocation') - ->with($sourceData['node_id']) - ->will(self::returnValue( - new Location( - [ + ->willReturnCallback(static function (int $nodeId) use ($loadLocationMatcher, $sourceData, $destinationData) { + $expectedArgs = [$sourceData['node_id'], $destinationData['node_id']]; + $returnValues = [ + new Location([ 'id' => $sourceData['node_id'], 'contentId' => $sourceData['contentobject_id'], - ] - ) - )); - - $this->treeHandler - ->expects(self::at(1)) - ->method('loadLocation') - ->with($destinationData['node_id']) - ->will(self::returnValue(new Location(['contentId' => $destinationData['contentobject_id']]))); + ]), + new Location(['contentId' => $destinationData['contentobject_id']]), + ]; + $index = $loadLocationMatcher->numberOfInvocations() - 1; + self::assertSame($expectedArgs[$index], $nodeId); - $this->contentHandler - ->expects(self::at(0)) - ->method('loadContentInfo') - ->with($destinationData['contentobject_id']) - ->will(self::returnValue(new ContentInfo(['sectionId' => 12345]))); + return $returnValues[$index]; + }); + $loadContentInfoMatcher = self::exactly(2); $this->contentHandler - ->expects(self::at(1)) + ->expects($loadContentInfoMatcher) ->method('loadContentInfo') - ->with($sourceData['contentobject_id']) - ->will(self::returnValue(new ContentInfo(['mainLocationId' => 69]))); + ->willReturnCallback(static function (int $contentId) use ($loadContentInfoMatcher, $sourceData, $destinationData) { + $expectedArgs = [$destinationData['contentobject_id'], $sourceData['contentobject_id']]; + $returnValues = [ + new ContentInfo(['sectionId' => 12345]), + new ContentInfo(['mainLocationId' => 69]), + ]; + $index = $loadContentInfoMatcher->numberOfInvocations() - 1; + self::assertSame($expectedArgs[$index], $contentId); + + return $returnValues[$index]; + }); $this->treeHandler ->expects(self::once()) @@ -267,12 +273,12 @@ public function testMoveSubtree() $handler->move(69, 77); } - public function testHideUpdateHidden() + public function testHideUpdateHidden(): void { $handler = $this->getLocationHandler(); $this->locationGateway - ->expects(self::at(0)) + ->expects(self::once()) ->method('getBasicNodeData') ->with(69) ->will( @@ -293,15 +299,13 @@ public function testHideUpdateHidden() $handler->hide(69); } - /** - * @depends testHideUpdateHidden - */ - public function testHideUnhideUpdateHidden() + #[Depends('testHideUpdateHidden')] + public function testHideUnhideUpdateHidden(): void { $handler = $this->getLocationHandler(); $this->locationGateway - ->expects(self::at(0)) + ->expects(self::once()) ->method('getBasicNodeData') ->with(69) ->will( @@ -322,7 +326,7 @@ public function testHideUnhideUpdateHidden() $handler->unhide(69); } - public function testSwapLocations() + public function testSwapLocations(): void { $handler = $this->getLocationHandler(); @@ -334,7 +338,7 @@ public function testSwapLocations() $handler->swap(70, 78); } - public function testCreateLocation() + public function testCreateLocation(): void { $handler = $this->getLocationHandler(); @@ -372,7 +376,7 @@ public function testCreateLocation() $handler->create($createStruct); } - public function testUpdateLocation() + public function testUpdateLocation(): void { $handler = $this->getLocationHandler(); @@ -387,7 +391,7 @@ public function testUpdateLocation() $handler->update($updateStruct, 23); } - public function testSetSectionForSubtree() + public function testSetSectionForSubtree(): void { $handler = $this->getLocationHandler(); @@ -399,7 +403,7 @@ public function testSetSectionForSubtree() $handler->setSectionForSubtree(69, 3); } - public function testChangeMainLocation() + public function testChangeMainLocation(): void { $handler = $this->getLocationHandler(); @@ -414,7 +418,7 @@ public function testChangeMainLocation() /** * Test for the removeSubtree() method. */ - public function testRemoveSubtree() + public function testRemoveSubtree(): void { $handler = $this->getLocationHandler(); @@ -441,7 +445,7 @@ public function testDeleteChildrenDrafts(): void /** * Test for the copySubtree() method. */ - public function testCopySubtree() + public function testCopySubtree(): void { $handler = $this->getPartlyMockedHandler( [ @@ -476,39 +480,6 @@ public function testCopySubtree() ->with($destinationData['node_id']) ->will(self::returnValue($destinationData)); - $objectStateHandlerCall = 0; - $this->objectStateHandler->expects(self::at($objectStateHandlerCall++)) - ->method('loadAllGroups') - ->will( - self::returnValue( - [ - new ObjectStateGroup(['id' => 10]), - new ObjectStateGroup(['id' => 20]), - ] - ) - ); - $this->objectStateHandler->expects(self::at($objectStateHandlerCall++)) - ->method('loadObjectStates') - ->with(self::equalTo(10)) - ->will( - self::returnValue( - [ - new ObjectState(['id' => 11, 'groupId' => 10]), - new ObjectState(['id' => 12, 'groupId' => 10]), - ] - ) - ); - $this->objectStateHandler->expects(self::at($objectStateHandlerCall++)) - ->method('loadObjectStates') - ->with(self::equalTo(20)) - ->will( - self::returnValue( - [ - new ObjectState(['id' => 21, 'groupId' => 20]), - new ObjectState(['id' => 22, 'groupId' => 20]), - ] - ) - ); $defaultObjectStates = [ new ObjectState(['id' => 11, 'groupId' => 10]), new ObjectState(['id' => 21, 'groupId' => 20]), @@ -519,100 +490,180 @@ public function testCopySubtree() array_column($subtreeContentRows, 'contentobject_id') ) ); - foreach ($contentIds as $index => $contentId) { - $this->contentHandler - ->expects(self::at($index * 2)) - ->method('copy') - ->with($contentId, 1) - ->will( - self::returnValue( - new Content( - [ - 'versionInfo' => new VersionInfo( - [ - 'contentInfo' => new ContentInfo( - [ - 'id' => $contentId + $offset, - 'currentVersionNo' => 1, - ] - ), - ] - ), - ] - ) - ) - ); + // loadAllGroups(), loadObjectStates() and setContentState() are all called on the same + // mock in a single global order: loadAllGroups() once, loadObjectStates() twice (once per + // object state group), then setContentState() once per content id per default object state. + $objectStateHandlerInvocationOrder = 0; + + $setContentStateExpectedArgs = []; + foreach ($contentIds as $contentId) { foreach ($defaultObjectStates as $objectState) { - $this->objectStateHandler->expects(self::at($objectStateHandlerCall++)) - ->method('setContentState') - ->with( - $contentId + $offset, - $objectState->groupId, - $objectState->id - ); + $setContentStateExpectedArgs[] = [$contentId + $offset, $objectState->groupId, $objectState->id]; } + } - $this->contentHandler - ->expects(self::at($index * 2 + 1)) - ->method('publish') - ->with( - $contentId + $offset, - 1, - self::isInstanceOf(Content\MetadataUpdateStruct::class) - ) - ->will( - self::returnValue( - new Content( - [ - 'versionInfo' => new VersionInfo( - [ - 'contentInfo' => new ContentInfo( - [ - 'id' => ($contentId + $offset), - ] - ), - ] - ), - ] - ) - ) - ); + $this->objectStateHandler + ->expects(self::once()) + ->method('loadAllGroups') + ->willReturnCallback(static function () use (&$objectStateHandlerInvocationOrder) { + self::assertSame(0, $objectStateHandlerInvocationOrder++); + + return [ + new ObjectStateGroup(['id' => 10]), + new ObjectStateGroup(['id' => 20]), + ]; + }); + + $this->objectStateHandler + ->expects(self::exactly(2)) + ->method('loadObjectStates') + ->willReturnCallback(static function (int $groupId) use (&$objectStateHandlerInvocationOrder) { + $order = $objectStateHandlerInvocationOrder++; + switch ($order) { + case 1: + self::assertSame(10, $groupId); + + return [ + new ObjectState(['id' => 11, 'groupId' => 10]), + new ObjectState(['id' => 12, 'groupId' => 10]), + ]; + case 2: + self::assertSame(20, $groupId); + + return [ + new ObjectState(['id' => 21, 'groupId' => 20]), + new ObjectState(['id' => 22, 'groupId' => 20]), + ]; + default: + self::fail(sprintf('Unexpected invocation order %d for loadObjectStates()', $order)); + } + }); + + $this->objectStateHandler + ->expects(self::exactly(count($setContentStateExpectedArgs))) + ->method('setContentState') + ->willReturnCallback(static function (int $contentId, int $groupId, int $stateId) use (&$objectStateHandlerInvocationOrder, $setContentStateExpectedArgs) { + $order = $objectStateHandlerInvocationOrder++; + $index = $order - 3; + self::assertArrayHasKey($index, $setContentStateExpectedArgs); + self::assertSame($setContentStateExpectedArgs[$index], [$contentId, $groupId, $stateId]); + + return true; + }); + + // copy(), publish() and (later) loadContentInfo() are all called on the content handler + // mock in a single global order: copy()/publish() alternate per content id, then + // loadContentInfo() is called twice at the end. + $contentHandlerInvocationOrder = 0; + + $copyExpectedArgs = []; + $copyReturnValues = []; + $publishExpectedArgs = []; + $publishReturnValues = []; + foreach ($contentIds as $contentId) { + $copyExpectedArgs[] = [$contentId, 1]; + $copyReturnValues[] = new Content( + [ + 'versionInfo' => new VersionInfo( + [ + 'contentInfo' => new ContentInfo( + [ + 'id' => $contentId + $offset, + 'currentVersionNo' => 1, + ] + ), + ] + ), + ] + ); + $publishExpectedArgs[] = [$contentId + $offset, 1]; + $publishReturnValues[] = new Content( + [ + 'versionInfo' => new VersionInfo( + [ + 'contentInfo' => new ContentInfo( + [ + 'id' => $contentId + $offset, + ] + ), + ] + ), + ] + ); } - $lastContentHandlerIndex = $index * 2 + 1; + $this->contentHandler + ->expects(self::exactly(count($contentIds))) + ->method('copy') + ->willReturnCallback(static function (int $contentId, int $versionNo) use (&$contentHandlerInvocationOrder, $copyExpectedArgs, $copyReturnValues) { + $order = $contentHandlerInvocationOrder++; + self::assertSame(0, $order % 2, sprintf('Expected copy() at an even invocation order, got %d', $order)); + $index = intdiv($order, 2); + self::assertSame($copyExpectedArgs[$index], [$contentId, $versionNo]); + + return $copyReturnValues[$index]; + }); + + $this->contentHandler + ->expects(self::exactly(count($contentIds))) + ->method('publish') + ->willReturnCallback(static function (int $contentId, int $versionNo, Content\MetadataUpdateStruct $metadataUpdateStruct) use (&$contentHandlerInvocationOrder, $publishExpectedArgs, $publishReturnValues) { + $order = $contentHandlerInvocationOrder++; + self::assertSame(1, $order % 2, sprintf('Expected publish() at an odd invocation order, got %d', $order)); + $index = intdiv($order, 2); + self::assertSame($publishExpectedArgs[$index], [$contentId, $versionNo]); + + return $publishReturnValues[$index]; + }); + + $locationCreateStructReturnValues = []; + $expectedCreateStructArgs = []; + $createReturnValues = []; foreach ($subtreeContentRows as $index => $row) { $mapper = new Mapper(); $createStruct = $mapper->getLocationCreateStruct($row); - $this->locationMapper - ->expects(self::at($index)) - ->method('getLocationCreateStruct') - ->with($row) - ->will(self::returnValue($createStruct)); - - $createStruct = clone $createStruct; - $createStruct->contentId = $createStruct->contentId + $offset; - $createStruct->parentId = $index === 0 ? $destinationData['node_id'] : $createStruct->parentId + $offset; - $createStruct->invisible = true; - $createStruct->mainLocationId = $mainLocationsMap[$index]; - $handler - ->expects(self::at($index)) - ->method('create') - ->with($createStruct) - ->will( - self::returnValue( - new Location( - [ - 'id' => $row['node_id'] + $offset, - 'contentId' => $row['contentobject_id'], - 'hidden' => false, - 'invisible' => true, - ] - ) - ) - ); + $locationCreateStructReturnValues[$index] = $createStruct; + + $expectedCreateStruct = clone $createStruct; + $expectedCreateStruct->contentId = $expectedCreateStruct->contentId + $offset; + $expectedCreateStruct->parentId = $index === 0 ? $destinationData['node_id'] : $expectedCreateStruct->parentId + $offset; + $expectedCreateStruct->invisible = true; + $expectedCreateStruct->mainLocationId = $mainLocationsMap[$index]; + $expectedCreateStructArgs[$index] = $expectedCreateStruct; + + $createReturnValues[$index] = new Location( + [ + 'id' => $row['node_id'] + $offset, + 'contentId' => $row['contentobject_id'], + 'hidden' => false, + 'invisible' => true, + ] + ); } + $getLocationCreateStructMatcher = self::exactly(count($subtreeContentRows)); + $this->locationMapper + ->expects($getLocationCreateStructMatcher) + ->method('getLocationCreateStruct') + ->willReturnCallback(static function (array $row) use ($getLocationCreateStructMatcher, $subtreeContentRows, $locationCreateStructReturnValues) { + $index = $getLocationCreateStructMatcher->numberOfInvocations() - 1; + self::assertSame($subtreeContentRows[$index], $row); + + return $locationCreateStructReturnValues[$index]; + }); + + $createMatcher = self::exactly(count($subtreeContentRows)); + $handler + ->expects($createMatcher) + ->method('create') + ->willReturnCallback(static function (CreateStruct $createStruct) use ($createMatcher, $expectedCreateStructArgs, $createReturnValues) { + $index = $createMatcher->numberOfInvocations() - 1; + self::assertEquals($expectedCreateStructArgs[$index], $createStruct); + + return $createReturnValues[$index]; + }); + foreach ($updateMainLocationsMap as $contentId => $locationId) { $handler ->expects(self::any()) @@ -627,16 +678,23 @@ public function testCopySubtree() ->will(self::returnValue(new Location(['contentId' => $destinationData['contentobject_id']]))); $this->contentHandler - ->expects(self::at($lastContentHandlerIndex + 1)) + ->expects(self::exactly(2)) ->method('loadContentInfo') - ->with($destinationData['contentobject_id']) - ->will(self::returnValue(new ContentInfo(['sectionId' => 12345]))); - - $this->contentHandler - ->expects(self::at($lastContentHandlerIndex + 2)) - ->method('loadContentInfo') - ->with(21) - ->will(self::returnValue(new ContentInfo(['mainLocationId' => 1010]))); + ->willReturnCallback(static function (int $contentId) use (&$contentHandlerInvocationOrder, $contentIds, $destinationData) { + $order = $contentHandlerInvocationOrder++; + switch ($order) { + case count($contentIds) * 2: + self::assertSame($destinationData['contentobject_id'], $contentId); + + return new ContentInfo(['sectionId' => 12345]); + case count($contentIds) * 2 + 1: + self::assertSame(21, $contentId); + + return new ContentInfo(['mainLocationId' => 1010]); + default: + self::fail(sprintf('Unexpected invocation order %d for loadContentInfo()', $order)); + } + }); $handler ->expects(self::once()) @@ -649,9 +707,6 @@ public function testCopySubtree() ); } - /** - * @covers \Ibexa\Contracts\Core\Persistence\Content\Location\Handler::countLocationsByContent - */ public function testCountLocationsByContent(): void { $handler = $this->getLocationHandler(); @@ -676,7 +731,6 @@ public function testCountLocationsByContent(): void protected function getPartlyMockedHandler(array $methods) { return $this->getMockBuilder(LocationHandler::class) - ->setMethods($methods) ->setConstructorArgs( [ $this->locationGateway = $this->createMock(Gateway::class), @@ -686,6 +740,7 @@ protected function getPartlyMockedHandler(array $methods) $this->treeHandler = $this->createMock(TreeHandler::class), ] ) + ->onlyMethods(array_values($methods)) ->getMock(); } } diff --git a/tests/lib/Persistence/Legacy/Content/Mapper/ResolveVirtualFieldSubscriberTest.php b/tests/lib/Persistence/Legacy/Content/Mapper/ResolveVirtualFieldSubscriberTest.php index 90d22e8f3d..0534b6f3e8 100644 --- a/tests/lib/Persistence/Legacy/Content/Mapper/ResolveVirtualFieldSubscriberTest.php +++ b/tests/lib/Persistence/Legacy/Content/Mapper/ResolveVirtualFieldSubscriberTest.php @@ -317,7 +317,7 @@ private function getConverterRegistry(): ConverterRegistry { $converterRegistry = $this->createMock(ConverterRegistry::class); $converterRegistry->method('getConverter') - ->willReturn($this->createMock(Converter::class)); + ->willReturn(self::createStub(Converter::class)); return $converterRegistry; } diff --git a/tests/lib/Persistence/Legacy/Content/MapperTest.php b/tests/lib/Persistence/Legacy/Content/MapperTest.php index 076136a45b..51095e6e4b 100644 --- a/tests/lib/Persistence/Legacy/Content/MapperTest.php +++ b/tests/lib/Persistence/Legacy/Content/MapperTest.php @@ -29,12 +29,13 @@ use Ibexa\Core\Persistence\Legacy\Content\Mapper\ResolveVirtualFieldSubscriber; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldValue; use Ibexa\Core\Persistence\Legacy\Content\StorageRegistry; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; use Symfony\Component\EventDispatcher\EventDispatcher; use Symfony\Contracts\EventDispatcher\EventDispatcherInterface; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\Mapper - */ +#[CoversClass(Mapper::class)] class MapperTest extends LanguageAwareTestCase { /** @@ -72,7 +73,7 @@ protected function getCreateStructFixture() return $struct; } - public function testCreateVersionInfoForContent() + public function testCreateVersionInfoForContent(): void { $content = $this->getFullContentFixture(); $time = time(); @@ -129,7 +130,7 @@ protected function getFullContentFixture() return $content; } - public function testConvertToStorageValue() + public function testConvertToStorageValue(): void { $convMock = $this->createMock(Converter::class); $convMock->expects(self::once()) @@ -164,9 +165,9 @@ public function testConvertToStorageValue() ); } - public function testExtractContentFromRows() + public function testExtractContentFromRows(): void { - $rowsFixture = $this->getContentExtractFixture(); + $rowsFixture = self::getContentExtractFixture(); $nameRowsFixture = $this->getNamesExtractFixture(); $contentType = $this->getContentTypeFromRows($rowsFixture); @@ -202,7 +203,7 @@ public function testExtractContentFromRows() public function testExtractContentFromRowsWithNewFieldDefinitions(): void { - $rowsFixture = $this->getContentExtractFixture(); + $rowsFixture = self::getContentExtractFixture(); $nameRowsFixture = $this->getNamesExtractFixture(); $contentType = $this->getContentTypeFromRows($rowsFixture); @@ -250,7 +251,7 @@ public function testExtractContentFromRowsWithNewFieldDefinitions(): void public function testExtractContentFromRowsWithRemovedFieldDefinitions(): void { - $rowsFixture = $this->getContentExtractFixture(); + $rowsFixture = self::getContentExtractFixture(); $nameRowsFixture = $this->getNamesExtractFixture(); $contentType = $this->getContentTypeFromRows($rowsFixture); @@ -297,7 +298,7 @@ static function (Content\Type\FieldDefinition $fieldDefinition): bool { ); } - public function testExtractContentFromRowsMultipleVersions() + public function testExtractContentFromRowsMultipleVersions(): void { $convMock = $this->createMock(Converter::class); $convMock->expects(self::any()) @@ -397,10 +398,8 @@ public function testCreateCreateStructFromContent() // fields } - /** - * @depends testCreateCreateStructFromContent - */ - public function testCreateCreateStructFromContentBasicProperties($data) + #[Depends('testCreateCreateStructFromContent')] + public function testCreateCreateStructFromContentBasicProperties($data): void { $content = $data['original']; $struct = $data['result']; @@ -417,10 +416,8 @@ public function testCreateCreateStructFromContentBasicProperties($data) self::assertGreaterThanOrEqual($time, $struct->modified); } - /** - * @depends testCreateCreateStructFromContent - */ - public function testCreateCreateStructFromContentParentLocationsEmpty($data) + #[Depends('testCreateCreateStructFromContent')] + public function testCreateCreateStructFromContentParentLocationsEmpty($data): void { self::assertEquals( [], @@ -428,10 +425,8 @@ public function testCreateCreateStructFromContentParentLocationsEmpty($data) ); } - /** - * @depends testCreateCreateStructFromContent - */ - public function testCreateCreateStructFromContentFieldCount($data) + #[Depends('testCreateCreateStructFromContent')] + public function testCreateCreateStructFromContentFieldCount($data): void { self::assertEquals( count($data['original']->fields), @@ -439,17 +434,15 @@ public function testCreateCreateStructFromContentFieldCount($data) ); } - /** - * @depends testCreateCreateStructFromContent - */ - public function testCreateCreateStructFromContentFieldsNoId($data) + #[Depends('testCreateCreateStructFromContent')] + public function testCreateCreateStructFromContentFieldsNoId($data): void { foreach ($data['result']->fields as $field) { self::assertNull($field->id); } } - public function testExtractRelationsFromRows() + public function testExtractRelationsFromRows(): void { $mapper = $this->getMapper(); @@ -463,7 +456,7 @@ public function testExtractRelationsFromRows() ); } - public function testCreateCreateStructFromContentWithPreserveOriginalLanguage() + public function testCreateCreateStructFromContentWithPreserveOriginalLanguage(): void { $time = time(); $mapper = $this->getMapper(); @@ -484,12 +477,11 @@ public function testCreateCreateStructFromContentWithPreserveOriginalLanguage() } /** - * @dataProvider extractContentInfoFromRowProvider - * * @param array $fixtures * @param string $prefix */ - public function testExtractContentInfoFromRow(array $fixtures, $prefix) + #[DataProvider('extractContentInfoFromRowProvider')] + public function testExtractContentInfoFromRow(array $fixtures, $prefix): void { $contentInfoReference = $this->getContentExtractReference()->versionInfo->contentInfo; $mapper = new Mapper( @@ -507,9 +499,9 @@ public function testExtractContentInfoFromRow(array $fixtures, $prefix) * * @return array */ - public function extractContentInfoFromRowProvider() + public static function extractContentInfoFromRowProvider(): array { - $fixtures = $this->getContentExtractFixture(); + $fixtures = self::getContentExtractFixture(); $fixturesNoPrefix = []; foreach ($fixtures[0] as $key => $value) { $keyNoPrefix = $key === 'content_tree_main_node_id' @@ -524,7 +516,7 @@ public function extractContentInfoFromRowProvider() ]; } - public function testCreateRelationFromCreateStruct() + public function testCreateRelationFromCreateStruct(): void { $struct = $this->getRelationCreateStructFixture(); @@ -544,7 +536,7 @@ public function testCreateRelationFromCreateStruct() */ public function extractVersionInfoFromRowProvider() { - $fixturesAll = $this->getContentExtractFixture(); + $fixturesAll = self::getContentExtractFixture(); $fixtures = $fixturesAll[0]; $fixtures['content_version_names'] = [ ['content_translation' => 'eng-US', 'name' => 'Something'], @@ -570,7 +562,7 @@ public function extractVersionInfoFromRowProvider() * * @return array */ - protected function getContentExtractFixture() + protected static function getContentExtractFixture() { return require __DIR__ . '/_fixtures/extract_content_from_rows.php'; } @@ -670,7 +662,6 @@ protected function getValueConverterRegistryMock() { if (!isset($this->valueConverterRegistryMock)) { $this->valueConverterRegistryMock = $this->getMockBuilder(Registry::class) - ->setMethods([]) ->getMock(); $this->valueConverterRegistryMock @@ -703,8 +694,8 @@ protected function getEventDispatcher(): EventDispatcherInterface $eventDispatcher->addSubscriber( new ResolveVirtualFieldSubscriber( $this->getValueConverterRegistryMock(), - $this->createMock(StorageRegistry::class), - $this->createMock(Gateway::class) + self::createStub(StorageRegistry::class), + self::createStub(Gateway::class) ) ); diff --git a/tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php b/tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php index 92ec9e8d05..ebd6fb587c 100644 --- a/tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php +++ b/tests/lib/Persistence/Legacy/Content/ObjectState/Gateway/DoctrineDatabaseTest.php @@ -12,10 +12,9 @@ use Ibexa\Core\Persistence\Legacy\Content\ObjectState\Gateway; use Ibexa\Core\Persistence\Legacy\Content\ObjectState\Gateway\DoctrineDatabase; use Ibexa\Tests\Core\Persistence\Legacy\Content\LanguageAwareTestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\ObjectState\Gateway\DoctrineDatabase - */ +#[CoversClass(DoctrineDatabase::class)] class DoctrineDatabaseTest extends LanguageAwareTestCase { /** @@ -48,7 +47,7 @@ protected function setUp(): void ); } - public function testLoadObjectStateData() + public function testLoadObjectStateData(): void { $gateway = $this->getDatabaseGateway(); @@ -72,7 +71,7 @@ public function testLoadObjectStateData() ); } - public function testLoadObjectStateDataByIdentifier() + public function testLoadObjectStateDataByIdentifier(): void { $gateway = $this->getDatabaseGateway(); @@ -96,7 +95,7 @@ public function testLoadObjectStateDataByIdentifier() ); } - public function testLoadObjectStateListData() + public function testLoadObjectStateListData(): void { $gateway = $this->getDatabaseGateway(); @@ -135,7 +134,7 @@ public function testLoadObjectStateListData() ); } - public function testLoadObjectStateGroupData() + public function testLoadObjectStateGroupData(): void { $gateway = $this->getDatabaseGateway(); @@ -158,7 +157,7 @@ public function testLoadObjectStateGroupData() ); } - public function testLoadObjectStateGroupDataByIdentifier() + public function testLoadObjectStateGroupDataByIdentifier(): void { $gateway = $this->getDatabaseGateway(); @@ -181,7 +180,7 @@ public function testLoadObjectStateGroupDataByIdentifier() ); } - public function testLoadObjectStateGroupListData() + public function testLoadObjectStateGroupListData(): void { $gateway = $this->getDatabaseGateway(); @@ -206,7 +205,7 @@ public function testLoadObjectStateGroupListData() ); } - public function testInsertObjectState() + public function testInsertObjectState(): void { $gateway = $this->getDatabaseGateway(); @@ -233,7 +232,7 @@ public function testInsertObjectState() ); } - public function testInsertObjectStateInEmptyGroup() + public function testInsertObjectStateInEmptyGroup(): void { $gateway = $this->getDatabaseGateway(); @@ -268,7 +267,7 @@ public function testInsertObjectStateInEmptyGroup() ); } - public function testUpdateObjectState() + public function testUpdateObjectState(): void { $gateway = $this->getDatabaseGateway(); @@ -295,7 +294,7 @@ public function testUpdateObjectState() ); } - public function testDeleteObjectState() + public function testDeleteObjectState(): void { $gateway = $this->getDatabaseGateway(); @@ -307,7 +306,7 @@ public function testDeleteObjectState() ); } - public function testUpdateObjectStateLinks() + public function testUpdateObjectStateLinks(): void { $gateway = $this->getDatabaseGateway(); @@ -317,7 +316,7 @@ public function testUpdateObjectStateLinks() self::assertSame(185, $gateway->getContentCount(2)); } - public function testDeleteObjectStateLinks() + public function testDeleteObjectStateLinks(): void { $gateway = $this->getDatabaseGateway(); @@ -326,7 +325,7 @@ public function testDeleteObjectStateLinks() self::assertSame(0, $gateway->getContentCount(1)); } - public function testInsertObjectStateGroup() + public function testInsertObjectStateGroup(): void { $gateway = $this->getDatabaseGateway(); @@ -351,7 +350,7 @@ public function testInsertObjectStateGroup() ); } - public function testUpdateObjectStateGroup() + public function testUpdateObjectStateGroup(): void { $gateway = $this->getDatabaseGateway(); @@ -377,7 +376,7 @@ public function testUpdateObjectStateGroup() ); } - public function testDeleteObjectStateGroup() + public function testDeleteObjectStateGroup(): void { $gateway = $this->getDatabaseGateway(); @@ -389,7 +388,7 @@ public function testDeleteObjectStateGroup() ); } - public function testSetContentState() + public function testSetContentState(): void { $gateway = $this->getDatabaseGateway(); @@ -409,7 +408,7 @@ public function testSetContentState() ); } - public function testLoadObjectStateDataForContent() + public function testLoadObjectStateDataForContent(): void { $gateway = $this->getDatabaseGateway(); @@ -433,7 +432,7 @@ public function testLoadObjectStateDataForContent() ); } - public function testGetContentCount() + public function testGetContentCount(): void { $gateway = $this->getDatabaseGateway(); @@ -443,7 +442,7 @@ public function testGetContentCount() self::assertEquals(185, $result); } - public function testUpdateObjectStatePriority() + public function testUpdateObjectStatePriority(): void { $gateway = $this->getDatabaseGateway(); diff --git a/tests/lib/Persistence/Legacy/Content/ObjectState/MapperTest.php b/tests/lib/Persistence/Legacy/Content/ObjectState/MapperTest.php index d91c48aecb..4551ed08d3 100644 --- a/tests/lib/Persistence/Legacy/Content/ObjectState/MapperTest.php +++ b/tests/lib/Persistence/Legacy/Content/ObjectState/MapperTest.php @@ -12,13 +12,12 @@ use Ibexa\Contracts\Core\Persistence\Content\ObjectState\InputStruct; use Ibexa\Core\Persistence\Legacy\Content\ObjectState\Mapper; use Ibexa\Tests\Core\Persistence\Legacy\Content\LanguageAwareTestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\ObjectState\Mapper - */ +#[CoversClass(Mapper::class)] class MapperTest extends LanguageAwareTestCase { - public function testCreateObjectStateFromData() + public function testCreateObjectStateFromData(): void { $mapper = $this->getMapper(); @@ -33,7 +32,7 @@ public function testCreateObjectStateFromData() ); } - public function testCreateObjectStateListFromData() + public function testCreateObjectStateListFromData(): void { $mapper = $this->getMapper(); @@ -48,7 +47,7 @@ public function testCreateObjectStateListFromData() ); } - public function testCreateObjectStateGroupFromData() + public function testCreateObjectStateGroupFromData(): void { $mapper = $this->getMapper(); @@ -63,7 +62,7 @@ public function testCreateObjectStateGroupFromData() ); } - public function testCreateObjectStateGroupListFromData() + public function testCreateObjectStateGroupListFromData(): void { $mapper = $this->getMapper(); @@ -78,7 +77,7 @@ public function testCreateObjectStateGroupListFromData() ); } - public function testCreateObjectStateFromInputStruct() + public function testCreateObjectStateFromInputStruct(): void { $mapper = $this->getMapper(); @@ -93,7 +92,7 @@ public function testCreateObjectStateFromInputStruct() ); } - public function testCreateObjectStateGroupFromInputStruct() + public function testCreateObjectStateGroupFromInputStruct(): void { $mapper = $this->getMapper(); diff --git a/tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php b/tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php index 8d1fc3f9ba..df32013d9c 100644 --- a/tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php +++ b/tests/lib/Persistence/Legacy/Content/ObjectState/ObjectStateHandlerTest.php @@ -16,10 +16,9 @@ use Ibexa\Core\Persistence\Legacy\Content\ObjectState\Mapper; use Ibexa\Tests\Core\Persistence\Legacy\Content\LanguageAwareTestCase; use Ibexa\Tests\Integration\Core\Repository\BaseTestCase as APIBaseTest; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\ObjectState\Handler - */ +#[CoversClass(Handler::class)] class ObjectStateHandlerTest extends LanguageAwareTestCase { /** @@ -43,7 +42,7 @@ class ObjectStateHandlerTest extends LanguageAwareTestCase */ protected $mapperMock; - public function testCreateGroup() + public function testCreateGroup(): void { $handler = $this->getObjectStateHandler(); $mapperMock = $this->getMapperMock(); @@ -67,7 +66,7 @@ public function testCreateGroup() ); } - public function testLoadGroup() + public function testLoadGroup(): void { $handler = $this->getObjectStateHandler(); $mapperMock = $this->getMapperMock(); @@ -91,7 +90,7 @@ public function testLoadGroup() ); } - public function testLoadGroupThrowsNotFoundException() + public function testLoadGroupThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -106,7 +105,7 @@ public function testLoadGroupThrowsNotFoundException() $handler->loadGroup(APIBaseTest::DB_INT_MAX); } - public function testLoadGroupByIdentifier() + public function testLoadGroupByIdentifier(): void { $handler = $this->getObjectStateHandler(); $mapperMock = $this->getMapperMock(); @@ -130,7 +129,7 @@ public function testLoadGroupByIdentifier() ); } - public function testLoadGroupByIdentifierThrowsNotFoundException() + public function testLoadGroupByIdentifierThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -145,7 +144,7 @@ public function testLoadGroupByIdentifierThrowsNotFoundException() $handler->loadGroupByIdentifier('unknown'); } - public function testLoadAllGroups() + public function testLoadAllGroups(): void { $handler = $this->getObjectStateHandler(); $mapperMock = $this->getMapperMock(); @@ -171,7 +170,7 @@ public function testLoadAllGroups() } } - public function testLoadObjectStates() + public function testLoadObjectStates(): void { $handler = $this->getObjectStateHandler(); $mapperMock = $this->getMapperMock(); @@ -197,7 +196,7 @@ public function testLoadObjectStates() } } - public function testUpdateGroup() + public function testUpdateGroup(): void { $handler = $this->getObjectStateHandler(); $mapperMock = $this->getMapperMock(); @@ -230,7 +229,7 @@ public function testUpdateGroup() ); } - public function testDeleteGroup() + public function testDeleteGroup(): void { $handler = $this->getObjectStateHandler(); $mapperMock = $this->getMapperMock(); @@ -253,36 +252,38 @@ public function testDeleteGroup() ) ); - $gatewayMock->expects(self::exactly(2)) - ->method('deleteObjectStateLinks'); + $calls = []; $gatewayMock->expects(self::exactly(2)) - ->method('deleteObjectState'); - - $gatewayMock->expects(self::at(1)) ->method('deleteObjectStateLinks') - ->with(self::equalTo(1)); - - $gatewayMock->expects(self::at(2)) - ->method('deleteObjectState') - ->with(self::equalTo(1)); - - $gatewayMock->expects(self::at(3)) - ->method('deleteObjectStateLinks') - ->with(self::equalTo(2)); + ->willReturnCallback(static function (int $stateId) use (&$calls): void { + $calls[] = ['deleteObjectStateLinks', $stateId]; + }); - $gatewayMock->expects(self::at(4)) + $gatewayMock->expects(self::exactly(2)) ->method('deleteObjectState') - ->with(self::equalTo(2)); + ->willReturnCallback(static function (int $stateId) use (&$calls): void { + $calls[] = ['deleteObjectState', $stateId]; + }); $gatewayMock->expects(self::once()) ->method('deleteObjectStateGroup') ->with(self::equalTo(2)); $handler->deleteGroup(2); + + self::assertSame( + [ + ['deleteObjectStateLinks', 1], + ['deleteObjectState', 1], + ['deleteObjectStateLinks', 2], + ['deleteObjectState', 2], + ], + $calls + ); } - public function testCreate() + public function testCreate(): void { $handler = $this->getObjectStateHandler(); $mapperMock = $this->getMapperMock(); @@ -306,7 +307,7 @@ public function testCreate() ); } - public function testLoad() + public function testLoad(): void { $handler = $this->getObjectStateHandler(); $mapperMock = $this->getMapperMock(); @@ -330,7 +331,7 @@ public function testLoad() ); } - public function testLoadThrowsNotFoundException() + public function testLoadThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -345,7 +346,7 @@ public function testLoadThrowsNotFoundException() $handler->load(APIBaseTest::DB_INT_MAX); } - public function testLoadByIdentifier() + public function testLoadByIdentifier(): void { $handler = $this->getObjectStateHandler(); $mapperMock = $this->getMapperMock(); @@ -369,7 +370,7 @@ public function testLoadByIdentifier() ); } - public function testLoadByIdentifierThrowsNotFoundException() + public function testLoadByIdentifierThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -384,7 +385,7 @@ public function testLoadByIdentifierThrowsNotFoundException() $handler->loadByIdentifier('unknown', 2); } - public function testUpdate() + public function testUpdate(): void { $handler = $this->getObjectStateHandler(); $mapperMock = $this->getMapperMock(); @@ -417,7 +418,7 @@ public function testUpdate() ); } - public function testSetPriority() + public function testSetPriority(): void { $handler = $this->getObjectStateHandler(); $mapperMock = $this->getMapperMock(); @@ -451,25 +452,23 @@ public function testSetPriority() ) ); - $gatewayMock->expects(self::exactly(3)) - ->method('updateObjectStatePriority'); - - $gatewayMock->expects(self::at(2)) - ->method('updateObjectStatePriority') - ->with(self::equalTo(2), self::equalTo(0)); - - $gatewayMock->expects(self::at(3)) - ->method('updateObjectStatePriority') - ->with(self::equalTo(1), self::equalTo(1)); - - $gatewayMock->expects(self::at(4)) + $updateObjectStatePriorityMatcher = self::exactly(3); + $gatewayMock->expects($updateObjectStatePriorityMatcher) ->method('updateObjectStatePriority') - ->with(self::equalTo(3), self::equalTo(2)); + ->willReturnCallback(static function ($stateId, $priority) use ($updateObjectStatePriorityMatcher): void { + [$expectedStateId, $expectedPriority] = match ($updateObjectStatePriorityMatcher->numberOfInvocations()) { + 1 => [2, 0], + 2 => [1, 1], + 3 => [3, 2], + }; + self::assertSame($expectedStateId, $stateId); + self::assertSame($expectedPriority, $priority); + }); $handler->setPriority(2, 0); } - public function testDelete() + public function testDelete(): void { $handler = $this->getObjectStateHandler(); $mapperMock = $this->getMapperMock(); @@ -510,7 +509,7 @@ public function testDelete() $handler->delete(1); } - public function testDeleteThrowsNotFoundException() + public function testDeleteThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -525,7 +524,7 @@ public function testDeleteThrowsNotFoundException() $handler->delete(APIBaseTest::DB_INT_MAX); } - public function testSetContentState() + public function testSetContentState(): void { $handler = $this->getObjectStateHandler(); $gatewayMock = $this->getGatewayMock(); @@ -539,7 +538,7 @@ public function testSetContentState() self::assertTrue($result); } - public function testGetContentState() + public function testGetContentState(): void { $handler = $this->getObjectStateHandler(); $mapperMock = $this->getMapperMock(); @@ -563,7 +562,7 @@ public function testGetContentState() ); } - public function testGetContentCount() + public function testGetContentCount(): void { $handler = $this->getObjectStateHandler(); $gatewayMock = $this->getGatewayMock(); @@ -635,7 +634,6 @@ protected function getMapperMock() if (!isset($this->mapperMock)) { $this->mapperMock = $this->getMockBuilder(Mapper::class) ->setConstructorArgs([$this->getLanguageHandler()]) - ->setMethods([]) ->getMock(); } diff --git a/tests/lib/Persistence/Legacy/Content/Section/Gateway/DoctrineDatabaseTest.php b/tests/lib/Persistence/Legacy/Content/Section/Gateway/DoctrineDatabaseTest.php index 3b647a309d..91e2327c82 100644 --- a/tests/lib/Persistence/Legacy/Content/Section/Gateway/DoctrineDatabaseTest.php +++ b/tests/lib/Persistence/Legacy/Content/Section/Gateway/DoctrineDatabaseTest.php @@ -10,10 +10,10 @@ use Ibexa\Core\Persistence\Legacy\Content\Section\Gateway; use Ibexa\Core\Persistence\Legacy\Content\Section\Gateway\DoctrineDatabase; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Depends; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\Section\Gateway\DoctrineDatabase::insertSection - */ +#[CoversClass(DoctrineDatabase::class)] class DoctrineDatabaseTest extends TestCase { /** @@ -35,7 +35,7 @@ protected function setUp(): void ); } - public function testInsertSection() + public function testInsertSection(): void { $gateway = $this->getDatabaseGateway(); @@ -63,7 +63,7 @@ public function testInsertSection() ); } - public function testUpdateSection() + public function testUpdateSection(): void { $gateway = $this->getDatabaseGateway(); @@ -85,7 +85,7 @@ public function testUpdateSection() ); } - public function testLoadSectionData() + public function testLoadSectionData(): void { $gateway = $this->getDatabaseGateway(); @@ -103,7 +103,7 @@ public function testLoadSectionData() ); } - public function testLoadAllSectionData() + public function testLoadAllSectionData(): void { $gateway = $this->getDatabaseGateway(); @@ -152,7 +152,7 @@ public function testLoadAllSectionData() ); } - public function testLoadSectionDataByIdentifier() + public function testLoadSectionDataByIdentifier(): void { $gateway = $this->getDatabaseGateway(); @@ -170,7 +170,7 @@ public function testLoadSectionDataByIdentifier() ); } - public function testCountContentObjectsInSection() + public function testCountContentObjectsInSection(): void { $this->insertDatabaseFixture( __DIR__ . '/../../_fixtures/contentobjects.php' @@ -186,7 +186,7 @@ public function testCountContentObjectsInSection() ); } - public function testCountRoleAssignmentsUsingSection() + public function testCountRoleAssignmentsUsingSection(): void { $this->insertDatabaseFixture( __DIR__ . '/../../../User/_fixtures/roles.php' @@ -202,7 +202,7 @@ public function testCountRoleAssignmentsUsingSection() ); } - public function testDeleteSection() + public function testDeleteSection(): void { $gateway = $this->getDatabaseGateway(); @@ -232,10 +232,8 @@ public function testDeleteSection() ); } - /** - * @depends testCountContentObjectsInSection - */ - public function testAssignSectionToContent() + #[Depends('testCountContentObjectsInSection')] + public function testAssignSectionToContent(): void { $this->insertDatabaseFixture( __DIR__ . '/../../_fixtures/contentobjects.php' diff --git a/tests/lib/Persistence/Legacy/Content/Section/SectionHandlerTest.php b/tests/lib/Persistence/Legacy/Content/Section/SectionHandlerTest.php index 21b5808771..ee0f2240fd 100644 --- a/tests/lib/Persistence/Legacy/Content/Section/SectionHandlerTest.php +++ b/tests/lib/Persistence/Legacy/Content/Section/SectionHandlerTest.php @@ -11,10 +11,9 @@ use Ibexa\Core\Persistence\Legacy\Content\Section\Gateway; use Ibexa\Core\Persistence\Legacy\Content\Section\Handler; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\Section\Handler - */ +#[CoversClass(Handler::class)] class SectionHandlerTest extends TestCase { /** @@ -31,7 +30,7 @@ class SectionHandlerTest extends TestCase */ protected $gatewayMock; - public function testCreate() + public function testCreate(): void { $handler = $this->getSectionHandler(); @@ -57,7 +56,7 @@ public function testCreate() ); } - public function testUpdate() + public function testUpdate(): void { $handler = $this->getSectionHandler(); @@ -84,7 +83,7 @@ public function testUpdate() ); } - public function testLoad() + public function testLoad(): void { $handler = $this->getSectionHandler(); @@ -119,7 +118,7 @@ public function testLoad() ); } - public function testLoadAll() + public function testLoadAll(): void { $handler = $this->getSectionHandler(); @@ -162,7 +161,7 @@ public function testLoadAll() ); } - public function testLoadByIdentifier() + public function testLoadByIdentifier(): void { $handler = $this->getSectionHandler(); @@ -197,7 +196,7 @@ public function testLoadByIdentifier() ); } - public function testDelete() + public function testDelete(): void { $handler = $this->getSectionHandler(); @@ -217,7 +216,7 @@ public function testDelete() $result = $handler->delete(23); } - public function testDeleteFailure() + public function testDeleteFailure(): void { $this->expectException(\RuntimeException::class); @@ -236,7 +235,7 @@ public function testDeleteFailure() $result = $handler->delete(23); } - public function testAssign() + public function testAssign(): void { $handler = $this->getSectionHandler(); @@ -252,7 +251,7 @@ public function testAssign() $result = $handler->assign(23, 42); } - public function testPoliciesCount() + public function testPoliciesCount(): void { $handler = $this->getSectionHandler(); @@ -270,7 +269,7 @@ public function testPoliciesCount() $result = $handler->policiesCount(1); } - public function testCountRoleAssignmentsUsingSection() + public function testCountRoleAssignmentsUsingSection(): void { $handler = $this->getSectionHandler(); diff --git a/tests/lib/Persistence/Legacy/Content/StorageHandlerTest.php b/tests/lib/Persistence/Legacy/Content/StorageHandlerTest.php index 414f8e75df..1783ce96c4 100644 --- a/tests/lib/Persistence/Legacy/Content/StorageHandlerTest.php +++ b/tests/lib/Persistence/Legacy/Content/StorageHandlerTest.php @@ -16,10 +16,9 @@ use Ibexa\Core\Persistence\Legacy\Content\StorageHandler; use Ibexa\Core\Persistence\Legacy\Content\StorageRegistry; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\StorageHandler - */ +#[CoversClass(StorageHandler::class)] class StorageHandlerTest extends TestCase { /** @var \Ibexa\Core\Persistence\Legacy\Content\StorageRegistry&\PHPUnit\Framework\MockObject\MockObject */ @@ -248,7 +247,6 @@ protected function getStorageRegistryMock(): StorageRegistry if (!isset($this->storageRegistryMock)) { $this->storageRegistryMock = $this->getMockBuilder(StorageRegistry::class) ->setConstructorArgs([[]]) - ->setMethods([]) ->getMock(); } diff --git a/tests/lib/Persistence/Legacy/Content/StorageRegistryTest.php b/tests/lib/Persistence/Legacy/Content/StorageRegistryTest.php index 1b3b31a113..f38885a35c 100644 --- a/tests/lib/Persistence/Legacy/Content/StorageRegistryTest.php +++ b/tests/lib/Persistence/Legacy/Content/StorageRegistryTest.php @@ -11,10 +11,9 @@ use Ibexa\Core\FieldType\NullStorage; use Ibexa\Core\Persistence\Legacy\Content\StorageRegistry; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\StorageRegistry - */ +#[CoversClass(StorageRegistry::class)] class StorageRegistryTest extends TestCase { private const TYPE_NAME = 'some-type'; @@ -27,7 +26,7 @@ public function testRegister(): void self::assertSame($storage, $registry->getStorage(self::TYPE_NAME)); } - public function testGetStorage() + public function testGetStorage(): void { $storage = $this->getStorageMock(); $registry = new StorageRegistry([self::TYPE_NAME => $storage]); @@ -40,7 +39,7 @@ public function testGetStorage() ); } - public function testGetNotFound() + public function testGetNotFound(): void { $registry = new StorageRegistry([]); self::assertInstanceOf( diff --git a/tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php b/tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php index 6c2b0f1ba8..69acb8a88f 100644 --- a/tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php +++ b/tests/lib/Persistence/Legacy/Content/TreeHandlerTest.php @@ -23,7 +23,7 @@ */ class TreeHandlerTest extends TestCase { - public function testLoadContentInfoByRemoteId() + public function testLoadContentInfoByRemoteId(): void { $contentInfoData = [new ContentInfo()]; @@ -45,7 +45,7 @@ public function testLoadContentInfoByRemoteId() ); } - public function testListVersions() + public function testListVersions(): void { $this->getContentGatewayMock() ->expects(self::once()) @@ -73,7 +73,7 @@ public function testListVersions() ); } - public function testRemoveRawContent() + public function testRemoveRawContent(): void { $treeHandler = $this->getPartlyMockedTreeHandler( [ @@ -125,7 +125,7 @@ public function testRemoveRawContent() $treeHandler->removeRawContent(23); } - public function testRemoveSubtree() + public function testRemoveSubtree(): void { $treeHandler = $this->getPartlyMockedTreeHandler( [ @@ -134,137 +134,161 @@ public function testRemoveSubtree() ] ); - // Original call - $this->getLocationGatewayMock() - ->expects(self::at(0)) - ->method('getBasicNodeData') - ->with(42) - ->will( - self::returnValue( - [ - 'contentobject_id' => 100, - 'main_node_id' => 200, - ] - ) - ); - $this->getLocationGatewayMock() - ->expects(self::at(1)) - ->method('getChildren') - ->with(42) - ->will( - self::returnValue( - [ - ['node_id' => 201], - ['node_id' => 202], - ] - ) - ); + // Calls to getBasicNodeData(), getChildren(), countLocationsByContentId(), removeLocation() + // and deleteNodeAssignment() interleave across the original call and both recursive calls, + // so a single shared counter tracks the global invocation order across all of them. + $invocationOrder = 0; - // First recursive call $this->getLocationGatewayMock() - ->expects(self::at(2)) + ->expects(self::exactly(3)) ->method('getBasicNodeData') - ->with(201) - ->will( - self::returnValue( - [ - 'contentobject_id' => 101, - 'main_node_id' => 201, - ] - ) - ); + ->willReturnCallback(static function (int $nodeId) use (&$invocationOrder) { + $order = $invocationOrder++; + switch ($order) { + case 0: + self::assertSame(42, $nodeId); + + return [ + 'contentobject_id' => 100, + 'main_node_id' => 200, + ]; + case 2: + self::assertSame(201, $nodeId); + + return [ + 'contentobject_id' => 101, + 'main_node_id' => 201, + ]; + case 7: + self::assertSame(202, $nodeId); + + return [ + 'contentobject_id' => 102, + 'main_node_id' => 202, + ]; + default: + self::fail(sprintf('Unexpected invocation order %d for getBasicNodeData()', $order)); + } + }); + $this->getLocationGatewayMock() - ->expects(self::at(3)) + ->expects(self::exactly(3)) ->method('getChildren') - ->with(201) - ->will(self::returnValue([])); + ->willReturnCallback(static function (int $nodeId) use (&$invocationOrder) { + $order = $invocationOrder++; + switch ($order) { + case 1: + self::assertSame(42, $nodeId); + + return [ + ['node_id' => 201], + ['node_id' => 202], + ]; + case 3: + self::assertSame(201, $nodeId); + + return []; + case 8: + self::assertSame(202, $nodeId); + + return []; + default: + self::fail(sprintf('Unexpected invocation order %d for getChildren()', $order)); + } + }); + $this->getLocationGatewayMock() - ->expects(self::at(4)) + ->expects(self::exactly(2)) ->method('countLocationsByContentId') - ->with(101) - ->will(self::returnValue(1)); + ->willReturnCallback(static function (int $contentId) use (&$invocationOrder) { + $order = $invocationOrder++; + switch ($order) { + case 4: + self::assertSame(101, $contentId); + + return 1; + case 9: + self::assertSame(102, $contentId); + + return 2; + default: + self::fail(sprintf('Unexpected invocation order %d for countLocationsByContentId()', $order)); + } + }); + $treeHandler ->expects(self::once()) ->method('removeRawContent') ->with(101); + $this->getLocationGatewayMock() - ->expects(self::at(5)) + ->expects(self::exactly(3)) ->method('removeLocation') - ->with(201); + ->willReturnCallback(static function (int $nodeId) use (&$invocationOrder) { + $order = $invocationOrder++; + switch ($order) { + case 5: + self::assertSame(201, $nodeId); + break; + case 11: + self::assertSame(202, $nodeId); + break; + case 13: + self::assertSame(42, $nodeId); + break; + default: + self::fail(sprintf('Unexpected invocation order %d for removeLocation()', $order)); + } + }); + $this->getLocationGatewayMock() - ->expects(self::at(6)) + ->expects(self::exactly(3)) ->method('deleteNodeAssignment') - ->with(101); + ->willReturnCallback(static function (int $contentId) use (&$invocationOrder) { + $order = $invocationOrder++; + switch ($order) { + case 6: + self::assertSame(101, $contentId); + break; + case 12: + self::assertSame(102, $contentId); + break; + case 14: + self::assertSame(100, $contentId); + break; + default: + self::fail(sprintf('Unexpected invocation order %d for deleteNodeAssignment()', $order)); + } + }); - // Second recursive call $this->getLocationGatewayMock() - ->expects(self::at(7)) - ->method('getBasicNodeData') - ->with(202) - ->will( - self::returnValue( - [ - 'contentobject_id' => 102, - 'main_node_id' => 202, - ] - ) - ); - $this->getLocationGatewayMock() - ->expects(self::at(8)) - ->method('getChildren') - ->with(202) - ->will(self::returnValue([])); - $this->getLocationGatewayMock() - ->expects(self::at(9)) - ->method('countLocationsByContentId') - ->with(102) - ->will(self::returnValue(2)); - $this->getLocationGatewayMock() - ->expects(self::at(10)) + ->expects(self::once()) ->method('getFallbackMainNodeData') ->with(102, 202) - ->will( - self::returnValue( - [ - 'node_id' => 203, - 'contentobject_version' => 1, - 'parent_node_id' => 204, - ] - ) - ); + ->willReturnCallback(static function () use (&$invocationOrder) { + self::assertSame(10, $invocationOrder++); + + return [ + 'node_id' => 203, + 'contentobject_version' => 1, + 'parent_node_id' => 204, + ]; + }); $treeHandler ->expects(self::once()) ->method('changeMainLocation') ->with(102, 203); - $this->getLocationGatewayMock() - ->expects(self::at(11)) - ->method('removeLocation') - ->with(202); - $this->getLocationGatewayMock() - ->expects(self::at(12)) - ->method('deleteNodeAssignment') - ->with(102); - - // Continuation of the original call - $this->getLocationGatewayMock() - ->expects(self::at(13)) - ->method('removeLocation') - ->with(42); - $this->getLocationGatewayMock() - ->expects(self::at(14)) - ->method('deleteNodeAssignment') - ->with(100); // Start $treeHandler->removeSubtree(42); } - public function testSetSectionForSubtree() + public function testSetSectionForSubtree(): void { $treeHandler = $this->getTreeHandler(); $this->getLocationGatewayMock() - ->expects(self::at(0)) + ->expects(self::once()) ->method('getBasicNodeData') ->with(69) ->will( @@ -285,7 +309,7 @@ public function testSetSectionForSubtree() $treeHandler->setSectionForSubtree(69, 3); } - public function testChangeMainLocation() + public function testChangeMainLocation(): void { $treeHandler = $this->getPartlyMockedTreeHandler( [ @@ -295,29 +319,47 @@ public function testChangeMainLocation() ] ); - $treeHandler - ->expects(self::at(0)) - ->method('loadLocation') - ->with(34) - ->will(self::returnValue(new Location(['parentId' => 42]))); + // loadLocation() and loadContentInfo() are called on the same partial mock in an + // interleaved order, so a shared counter tracks the global invocation order. + $invocationOrder = 0; $treeHandler - ->expects(self::at(1)) - ->method('loadContentInfo') - ->with('12') - ->will(self::returnValue(new ContentInfo(['currentVersionNo' => 1]))); - - $treeHandler - ->expects(self::at(2)) + ->expects(self::exactly(2)) ->method('loadLocation') - ->with(42) - ->will(self::returnValue(new Location(['contentId' => 84]))); + ->willReturnCallback(static function (int $locationId) use (&$invocationOrder) { + $order = $invocationOrder++; + switch ($order) { + case 0: + self::assertSame(34, $locationId); + + return new Location(['parentId' => 42]); + case 2: + self::assertSame(42, $locationId); + + return new Location(['contentId' => 84]); + default: + self::fail(sprintf('Unexpected invocation order %d for loadLocation()', $order)); + } + }); $treeHandler - ->expects(self::at(3)) + ->expects(self::exactly(2)) ->method('loadContentInfo') - ->with('84') - ->will(self::returnValue(new ContentInfo(['sectionId' => 4]))); + ->willReturnCallback(static function ($contentId) use (&$invocationOrder) { + $order = $invocationOrder++; + switch ($order) { + case 1: + self::assertEquals('12', $contentId); + + return new ContentInfo(['currentVersionNo' => 1]); + case 3: + self::assertEquals('84', $contentId); + + return new ContentInfo(['sectionId' => 4]); + default: + self::fail(sprintf('Unexpected invocation order %d for loadContentInfo()', $order)); + } + }); $this->getLocationGatewayMock() ->expects(self::once()) @@ -332,7 +374,7 @@ public function testChangeMainLocation() $treeHandler->changeMainLocation(12, 34); } - public function testChangeMainLocationToLocationWithoutContentInfo() + public function testChangeMainLocationToLocationWithoutContentInfo(): void { $treeHandler = $this->getPartlyMockedTreeHandler( [ @@ -342,29 +384,47 @@ public function testChangeMainLocationToLocationWithoutContentInfo() ] ); - $treeHandler - ->expects(self::at(0)) - ->method('loadLocation') - ->with(34) - ->will(self::returnValue(new Location(['parentId' => 1]))); + // loadLocation() and loadContentInfo() are called on the same partial mock in an + // interleaved order, so a shared counter tracks the global invocation order. + $invocationOrder = 0; $treeHandler - ->expects(self::at(1)) - ->method('loadContentInfo') - ->with('12') - ->will(self::returnValue(new ContentInfo(['currentVersionNo' => 1]))); - - $treeHandler - ->expects(self::at(2)) + ->expects(self::exactly(2)) ->method('loadLocation') - ->with(1) - ->will(self::returnValue(new Location(['contentId' => 84]))); + ->willReturnCallback(static function (int $locationId) use (&$invocationOrder) { + $order = $invocationOrder++; + switch ($order) { + case 0: + self::assertSame(34, $locationId); + + return new Location(['parentId' => 1]); + case 2: + self::assertSame(1, $locationId); + + return new Location(['contentId' => 84]); + default: + self::fail(sprintf('Unexpected invocation order %d for loadLocation()', $order)); + } + }); $treeHandler - ->expects(self::at(3)) + ->expects(self::exactly(2)) ->method('loadContentInfo') - ->with('84') - ->will(self::returnValue(new ContentInfo(['sectionId' => 4]))); + ->willReturnCallback(static function ($contentId) use (&$invocationOrder) { + $order = $invocationOrder++; + switch ($order) { + case 1: + self::assertEquals('12', $contentId); + + return new ContentInfo(['currentVersionNo' => 1]); + case 3: + self::assertEquals('84', $contentId); + + return new ContentInfo(['sectionId' => 4]); + default: + self::fail(sprintf('Unexpected invocation order %d for loadContentInfo()', $order)); + } + }); $this->getLocationGatewayMock() ->expects(self::once()) @@ -374,7 +434,7 @@ public function testChangeMainLocationToLocationWithoutContentInfo() $treeHandler->changeMainLocation(12, 34); } - public function testLoadLocation() + public function testLoadLocation(): void { $treeHandler = $this->getTreeHandler(); @@ -549,7 +609,6 @@ protected function getFieldHandlerMock() protected function getPartlyMockedTreeHandler(array $methods) { return $this->getMockBuilder(TreeHandler::class) - ->setMethods($methods) ->setConstructorArgs( [ $this->getLocationGatewayMock(), @@ -559,6 +618,7 @@ protected function getPartlyMockedTreeHandler(array $methods) $this->getFieldHandlerMock(), ] ) + ->onlyMethods(array_values($methods)) ->getMock(); } diff --git a/tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php b/tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php index b6ccbd287b..d1d4803faf 100644 --- a/tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php +++ b/tests/lib/Persistence/Legacy/Content/Type/ContentTypeHandlerTest.php @@ -25,11 +25,10 @@ use Ibexa\Core\Persistence\Legacy\Content\Type\StorageDispatcherInterface; use Ibexa\Core\Persistence\Legacy\Content\Type\Update\Handler as UpdateHandler; use Ibexa\Core\Persistence\Legacy\Exception; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\Type\Handler - */ +#[CoversClass(Handler::class)] class ContentTypeHandlerTest extends TestCase { /** @@ -56,7 +55,7 @@ class ContentTypeHandlerTest extends TestCase /** @var \Ibexa\Core\Persistence\Legacy\Content\Type\StorageDispatcherInterface&\PHPUnit\Framework\MockObject\MockObject */ protected $storageDispatcherMock; - public function testCreateGroup() + public function testCreateGroup(): void { $createStruct = new GroupCreateStruct(); @@ -97,7 +96,7 @@ public function testCreateGroup() ); } - public function testUpdateGroup() + public function testUpdateGroup(): void { $updateStruct = new GroupUpdateStruct(); $updateStruct->id = 23; @@ -114,7 +113,6 @@ public function testUpdateGroup() ); $handlerMock = $this->getMockBuilder(Handler::class) - ->setMethods(['loadGroup']) ->setConstructorArgs([ $gatewayMock, $mapperMock, @@ -122,6 +120,7 @@ public function testUpdateGroup() $this->getStorageDispatcherMock(), $this->getFieldTypeAliasResolver(), ]) + ->onlyMethods(['loadGroup']) ->getMock(); $handlerMock->expects(self::once()) @@ -142,7 +141,7 @@ public function testUpdateGroup() ); } - public function testDeleteGroupSuccess() + public function testDeleteGroupSuccess(): void { $gatewayMock = $this->getGatewayMock(); $gatewayMock->expects(self::once()) @@ -157,7 +156,7 @@ public function testDeleteGroupSuccess() $handler->deleteGroup(23); } - public function testDeleteGroupFailure() + public function testDeleteGroupFailure(): void { $this->expectException(Exception\GroupNotEmpty::class); $this->expectExceptionMessage('Group with ID "23" is not empty.'); @@ -174,7 +173,7 @@ public function testDeleteGroupFailure() $handler->deleteGroup(23); } - public function testLoadGroup() + public function testLoadGroup(): void { $gatewayMock = $this->getGatewayMock(); $gatewayMock->expects(self::once()) @@ -197,7 +196,7 @@ public function testLoadGroup() ); } - public function testLoadGroupByIdentifier() + public function testLoadGroupByIdentifier(): void { $gatewayMock = $this->getGatewayMock(); $gatewayMock->expects(self::once()) @@ -220,7 +219,7 @@ public function testLoadGroupByIdentifier() ); } - public function testLoadAllGroups() + public function testLoadAllGroups(): void { $gatewayMock = $this->getGatewayMock(); $gatewayMock->expects(self::once()) @@ -242,7 +241,7 @@ public function testLoadAllGroups() ); } - public function testLoadContentTypes() + public function testLoadContentTypes(): void { $gatewayMock = $this->getGatewayMock(); $gatewayMock->expects(self::once()) @@ -313,7 +312,7 @@ public function testLoadContentTypesByFieldDefinitionIdentifier(): void ); } - public function testLoad() + public function testLoad(): void { $gatewayMock = $this->getGatewayMock(); $gatewayMock->expects(self::once()) @@ -344,7 +343,7 @@ public function testLoad() ); } - public function testLoadNotFound() + public function testLoadNotFound(): void { $this->expectException(Exception\TypeNotFound::class); @@ -371,7 +370,7 @@ public function testLoadNotFound() $type = $handler->load(23, 1); } - public function testLoadDefaultVersion() + public function testLoadDefaultVersion(): void { $gatewayMock = $this->getGatewayMock(); $gatewayMock->expects(self::once()) @@ -401,7 +400,7 @@ public function testLoadDefaultVersion() ); } - public function testLoadByIdentifier() + public function testLoadByIdentifier(): void { $gatewayMock = $this->getGatewayMock(); $gatewayMock->expects(self::once()) @@ -431,7 +430,7 @@ public function testLoadByIdentifier() ); } - public function testLoadByRemoteId() + public function testLoadByRemoteId(): void { $gatewayMock = $this->getGatewayMock(); $gatewayMock->expects(self::once()) @@ -461,7 +460,7 @@ public function testLoadByRemoteId() ); } - public function testCreate() + public function testCreate(): void { $createStructFix = $this->getContentTypeCreateStructFixture(); $createStructClone = clone $createStructFix; @@ -538,7 +537,7 @@ public function testCreate() ); } - public function testUpdate() + public function testUpdate(): void { $gatewayMock = $this->getGatewayMock(); $gatewayMock->expects(self::once()) @@ -552,7 +551,6 @@ public function testUpdate() ); $handlerMock = $this->getMockBuilder(Handler::class) - ->setMethods(['load']) ->setConstructorArgs([ $gatewayMock, $this->getMapperMock(), @@ -560,6 +558,7 @@ public function testUpdate() $this->getStorageDispatcherMock(), $this->getFieldTypeAliasResolver(), ]) + ->onlyMethods(['load']) ->getMock(); $handlerMock->expects(self::once()) @@ -578,7 +577,7 @@ public function testUpdate() ); } - public function testDeleteSuccess() + public function testDeleteSuccess(): void { $gatewayMock = $this->getGatewayMock(); @@ -612,7 +611,7 @@ public function testDeleteSuccess() self::assertTrue($res); } - public function testDeleteThrowsBadStateException() + public function testDeleteThrowsBadStateException(): void { $this->expectException(BadStateException::class); @@ -634,7 +633,7 @@ public function testDeleteThrowsBadStateException() $res = $handler->delete(23, 0); } - public function testCreateVersion() + public function testCreateVersion(): void { $userId = 42; $contentTypeId = 23; @@ -652,7 +651,6 @@ public function testCreateVersion() ); $handlerMock = $this->getMockBuilder(Handler::class) - ->setMethods(['load', 'internalCreate']) ->setConstructorArgs([ $gatewayMock, $mapperMock, @@ -660,6 +658,7 @@ public function testCreateVersion() $this->getStorageDispatcherMock(), $this->getFieldTypeAliasResolver(), ]) + ->onlyMethods(['load', 'internalCreate']) ->getMock(); $handlerMock->expects(self::once()) @@ -691,7 +690,7 @@ public function testCreateVersion() ); } - public function testCopy() + public function testCopy(): void { $gatewayMock = $this->getGatewayMock(); $mapperMock = $this->getMapperMock(['createCreateStructFromType']); @@ -706,7 +705,6 @@ public function testCopy() ); $handlerMock = $this->getMockBuilder(Handler::class) - ->setMethods(['load', 'internalCreate', 'update']) ->setConstructorArgs([ $gatewayMock, $mapperMock, @@ -714,6 +712,7 @@ public function testCopy() $this->getStorageDispatcherMock(), $this->getFieldTypeAliasResolver(), ]) + ->onlyMethods(['load', 'internalCreate', 'update']) ->getMock(); $userId = 42; @@ -763,7 +762,7 @@ public function testCopy() ); } - public function testLink() + public function testLink(): void { $gatewayMock = $this->getGatewayMock(); $gatewayMock->expects(self::once()) @@ -782,7 +781,7 @@ public function testLink() self::assertTrue($res); } - public function testUnlinkSuccess() + public function testUnlinkSuccess(): void { $gatewayMock = $this->getGatewayMock(); $gatewayMock->expects(self::once()) @@ -808,7 +807,7 @@ public function testUnlinkSuccess() self::assertTrue($res); } - public function testUnlinkFailure() + public function testUnlinkFailure(): void { $this->expectException(Exception\RemoveLastGroupFromType::class); $this->expectExceptionMessage('Type with ID "23" in status "1" cannot be unlinked from its last group.'); @@ -829,7 +828,7 @@ public function testUnlinkFailure() $res = $handler->unlink(3, 23, 1); } - public function testGetFieldDefinition() + public function testGetFieldDefinition(): void { $mapperMock = $this->getMapperMock( [ @@ -876,7 +875,7 @@ public function testGetFieldDefinition() ); } - public function testAddFieldDefinition() + public function testAddFieldDefinition(): void { $mapperMock = $this->getMapperMock( ['toStorageFieldDefinition'] @@ -925,7 +924,7 @@ public function testAddFieldDefinition() ); } - public function testGetContentCount() + public function testGetContentCount(): void { $gatewayMock = $this->getGatewayMock(); $gatewayMock->expects(self::once()) @@ -944,7 +943,7 @@ public function testGetContentCount() ); } - public function testRemoveFieldDefinition() + public function testRemoveFieldDefinition(): void { $storageDispatcherMock = $this->getStorageDispatcherMock(); $storageDispatcherMock @@ -965,7 +964,7 @@ public function testRemoveFieldDefinition() $handler->removeFieldDefinition(23, 1, new FieldDefinition(['id' => 42, 'fieldType' => 'ibexa_string'])); } - public function testUpdateFieldDefinition() + public function testUpdateFieldDefinition(): void { $fieldDef = new FieldDefinition(); @@ -998,7 +997,7 @@ public function testUpdateFieldDefinition() $handler->updateFieldDefinition(23, 1, $fieldDef); } - public function testPublish() + public function testPublish(): void { $handler = $this->getPartlyMockedHandler(['load']); $updateHandlerMock = $this->getUpdateHandlerMock(); @@ -1032,28 +1031,25 @@ public function testPublish() $handler->publish(23); } - public function testPublishNoOldType() + public function testPublishNoOldType(): void { $handler = $this->getPartlyMockedHandler(['load']); $updateHandlerMock = $this->getUpdateHandlerMock(); - $handler->expects(self::at(0)) + $matcher = self::exactly(2); + $handler->expects($matcher) ->method('load') - ->with( - self::equalTo(23), - self::equalTo(1) - )->will( - self::returnValue(new Type()) - ); + ->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame([23, 1], $parameters); - $handler->expects(self::at(1)) - ->method('load') - ->with( - self::equalTo(23), - self::equalTo(0) - )->will( - self::throwException(new Exception\TypeNotFound((string)23, 0)) - ); + return new Type(); + } + + $this->assertSame([23, 0], $parameters); + + throw new Exception\TypeNotFound((string)23, 0); + }); $updateHandlerMock->expects(self::never()) ->method('updateContentObjects'); @@ -1095,7 +1091,6 @@ protected function getHandler() protected function getPartlyMockedHandler(array $methods) { return $this->getMockBuilder(Handler::class) - ->setMethods($methods) ->setConstructorArgs( [ $this->getGatewayMock(), @@ -1105,6 +1100,7 @@ protected function getPartlyMockedHandler(array $methods) $this->getFieldTypeAliasResolver(), ] ) + ->onlyMethods(array_values($methods)) ->getMock(); } @@ -1134,10 +1130,12 @@ protected function getGatewayMock() protected function getMapperMock($methods = []) { if (!isset($this->mapperMock)) { - $this->mapperMock = $this->getMockBuilder(Mapper::class) - ->disableOriginalConstructor() - ->setMethods($methods) - ->getMock(); + $builder = $this->getMockBuilder(Mapper::class) + ->disableOriginalConstructor(); + if ($methods !== []) { + $builder->onlyMethods(array_values($methods)); + } + $this->mapperMock = $builder->getMock(); } return $this->mapperMock; @@ -1153,7 +1151,6 @@ public function getUpdateHandlerMock() if (!isset($this->updateHandlerMock)) { $this->updateHandlerMock = $this->getMockBuilder(UpdateHandler::class) ->disableOriginalConstructor() - ->setMethods([]) ->getMock(); } @@ -1206,7 +1203,7 @@ protected function getContentTypeCreateStructFixture() return $struct; } - public function testRemoveContentTypeTranslation() + public function testRemoveContentTypeTranslation(): void { $mapperMock = $this->getMapperMock(); $mapperMock->expects(self::once()) @@ -1221,7 +1218,6 @@ public function testRemoveContentTypeTranslation() ); $handlerMock = $this->getMockBuilder(Handler::class) - ->setMethods(['load', 'update']) ->setConstructorArgs([ $this->getGatewayMock(), $mapperMock, @@ -1229,6 +1225,7 @@ public function testRemoveContentTypeTranslation() $this->getStorageDispatcherMock(), $this->getFieldTypeAliasResolver(), ]) + ->onlyMethods(['load', 'update']) ->getMock(); $handlerMock->expects(self::once()) diff --git a/tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php b/tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php index d084762f64..9598581a70 100644 --- a/tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php +++ b/tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/AddFieldTest.php @@ -14,13 +14,16 @@ use Ibexa\Core\Persistence\Legacy\Content\Mapper as ContentMapper; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldValue; use Ibexa\Core\Persistence\Legacy\Content\StorageHandler; +use Ibexa\Core\Persistence\Legacy\Content\Type\ContentUpdater; use Ibexa\Core\Persistence\Legacy\Content\Type\ContentUpdater\Action\AddField; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; use ReflectionObject; /** * Test case for content type Updater. */ +#[CoversClass(ContentUpdater::class)] class AddFieldTest extends TestCase { /** @@ -54,10 +57,7 @@ class AddFieldTest extends TestCase */ protected $addFieldAction; - /** - * @covers \Ibexa\Core\Persistence\Legacy\Content\Type\ContentUpdater::__construct - */ - public function testConstructor() + public function testConstructor(): void { $action = new AddField( $this->getContentGatewayMock(), @@ -70,7 +70,7 @@ public function testConstructor() self::assertInstanceOf(AddField::class, $action); } - public function testApplySingleVersionSingleTranslation() + public function testApplySingleVersionSingleTranslation(): void { $contentId = 42; $versionNumbers = [1]; @@ -90,7 +90,7 @@ public function testApplySingleVersionSingleTranslation() ->will(self::returnValue([])); $this->getContentGatewayMock() - ->expects(self::at(2)) + ->expects(self::once()) ->method('load') ->with($contentId, 1) ->will(self::returnValue([])); @@ -110,7 +110,7 @@ public function testApplySingleVersionSingleTranslation() $action->apply($contentId); } - public function testApplySingleVersionMultipleTranslations() + public function testApplySingleVersionMultipleTranslations(): void { $contentId = 42; $versionNumbers = [1]; @@ -130,7 +130,7 @@ public function testApplySingleVersionMultipleTranslations() ->will(self::returnValue([])); $this->getContentGatewayMock() - ->expects(self::at(2)) + ->expects(self::once()) ->method('load') ->with($contentId, 1) ->will(self::returnValue([])); @@ -141,22 +141,26 @@ public function testApplySingleVersionMultipleTranslations() ->with([], []) ->will(self::returnValue([$content])); + $matcher = self::exactly(2); $action - ->expects(self::at(0)) + ->expects($matcher) ->method('insertField') - ->with($content, $this->getFieldReference(null, 1, 'eng-GB')) - ->will(self::returnValue('fieldId1')); + ->willReturnCallback(function (...$parameters) use ($matcher, $content) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertEquals([$content, $this->getFieldReference(null, 1, 'eng-GB')], $parameters); - $action - ->expects(self::at(1)) - ->method('insertField') - ->with($content, $this->getFieldReference(null, 1, 'ger-DE')) - ->will(self::returnValue('fieldId2')); + return 'fieldId1'; + } + + $this->assertEquals([$content, $this->getFieldReference(null, 1, 'ger-DE')], $parameters); + + return 'fieldId2'; + }); $action->apply($contentId); } - public function testApplyMultipleVersionsSingleTranslation() + public function testApplyMultipleVersionsSingleTranslation(): void { $contentId = 42; $versionNumbers = [1, 2]; @@ -176,46 +180,44 @@ public function testApplyMultipleVersionsSingleTranslation() ->with(self::equalTo([['id' => $contentId, 'version' => 1], ['id' => $contentId, 'version' => 2]])) ->will(self::returnValue([])); + $loadMatcher = self::exactly(2); $this->getContentGatewayMock() - ->expects(self::at(2)) + ->expects($loadMatcher) ->method('load') - ->with($contentId, 1) - ->will(self::returnValue([])); + ->willReturnCallback(function (...$parameters) use ($loadMatcher, $contentId) { + $this->assertSame([$contentId, $loadMatcher->numberOfInvocations(), null], $parameters); - $this->getContentMapperMock() - ->expects(self::at(0)) - ->method('extractContentFromRows') - ->with([], []) - ->will(self::returnValue([$content1])); - - $this->getContentGatewayMock() - ->expects(self::at(3)) - ->method('load') - ->with($contentId, 2) - ->will(self::returnValue([])); + return []; + }); + $extractMatcher = self::exactly(2); $this->getContentMapperMock() - ->expects(self::at(1)) + ->expects($extractMatcher) ->method('extractContentFromRows') - ->with([], []) - ->will(self::returnValue([$content2])); + ->willReturnCallback(function (...$parameters) use ($extractMatcher, $content1, $content2) { + $this->assertSame([[], [], 'content_', null], $parameters); - $action - ->expects(self::at(0)) - ->method('insertField') - ->with($content1, $this->getFieldReference(null, 1, 'eng-GB')) - ->will(self::returnValue('fieldId1')); + return $extractMatcher->numberOfInvocations() === 1 ? [$content1] : [$content2]; + }); + $insertMatcher = self::exactly(2); $action - ->expects(self::at(1)) + ->expects($insertMatcher) ->method('insertField') - ->with($content2, $this->getFieldReference('fieldId1', 2, 'eng-GB')) - ->will(self::returnValue('fieldId1')); + ->willReturnCallback(function (...$parameters) use ($insertMatcher, $content1, $content2) { + if ($insertMatcher->numberOfInvocations() === 1) { + $this->assertEquals([$content1, $this->getFieldReference(null, 1, 'eng-GB')], $parameters); + } else { + $this->assertEquals([$content2, $this->getFieldReference('fieldId1', 2, 'eng-GB')], $parameters); + } + + return 'fieldId1'; + }); $action->apply($contentId); } - public function testApplyMultipleVersionsMultipleTranslations() + public function testApplyMultipleVersionsMultipleTranslations(): void { $contentId = 42; $versionNumbers = [1, 2]; @@ -235,58 +237,55 @@ public function testApplyMultipleVersionsMultipleTranslations() ->with(self::equalTo([['id' => $contentId, 'version' => 1], ['id' => $contentId, 'version' => 2]])) ->will(self::returnValue([])); + $loadMatcher = self::exactly(2); $this->getContentGatewayMock() - ->expects(self::at(2)) + ->expects($loadMatcher) ->method('load') - ->with($contentId, 1) - ->will(self::returnValue([])); - - $this->getContentMapperMock() - ->expects(self::at(0)) - ->method('extractContentFromRows') - ->with([], []) - ->will(self::returnValue([$content1])); + ->willReturnCallback(function (...$parameters) use ($loadMatcher, $contentId) { + $this->assertSame([$contentId, $loadMatcher->numberOfInvocations(), null], $parameters); - $this->getContentGatewayMock() - ->expects(self::at(3)) - ->method('load') - ->with($contentId, 2) - ->will(self::returnValue([])); + return []; + }); + $extractMatcher = self::exactly(2); $this->getContentMapperMock() - ->expects(self::at(1)) + ->expects($extractMatcher) ->method('extractContentFromRows') - ->with([], []) - ->will(self::returnValue([$content2])); + ->willReturnCallback(function (...$parameters) use ($extractMatcher, $content1, $content2) { + $this->assertSame([[], [], 'content_', null], $parameters); - $action - ->expects(self::at(0)) - ->method('insertField') - ->with($content1, $this->getFieldReference(null, 1, 'eng-GB')) - ->will(self::returnValue('fieldId1')); + return $extractMatcher->numberOfInvocations() === 1 ? [$content1] : [$content2]; + }); + $insertMatcher = self::exactly(4); $action - ->expects(self::at(1)) + ->expects($insertMatcher) ->method('insertField') - ->with($content1, $this->getFieldReference(null, 1, 'ger-DE')) - ->will(self::returnValue('fieldId2')); + ->willReturnCallback(function (...$parameters) use ($insertMatcher, $content1, $content2) { + switch ($insertMatcher->numberOfInvocations()) { + case 1: + $this->assertEquals([$content1, $this->getFieldReference(null, 1, 'eng-GB')], $parameters); - $action - ->expects(self::at(2)) - ->method('insertField') - ->with($content2, $this->getFieldReference('fieldId1', 2, 'eng-GB')) - ->will(self::returnValue('fieldId1')); + return 'fieldId1'; + case 2: + $this->assertEquals([$content1, $this->getFieldReference(null, 1, 'ger-DE')], $parameters); - $action - ->expects(self::at(3)) - ->method('insertField') - ->with($content2, $this->getFieldReference('fieldId2', 2, 'ger-DE')) - ->will(self::returnValue('fieldId2')); + return 'fieldId2'; + case 3: + $this->assertEquals([$content2, $this->getFieldReference('fieldId1', 2, 'eng-GB')], $parameters); + + return 'fieldId1'; + default: + $this->assertEquals([$content2, $this->getFieldReference('fieldId2', 2, 'ger-DE')], $parameters); + + return 'fieldId2'; + } + }); $action->apply($contentId); } - public function testInsertNewField() + public function testInsertNewField(): void { $versionInfo = new Content\VersionInfo(); $content = new Content(); @@ -335,7 +334,7 @@ public function testInsertNewField() self::assertEquals(23, $field->id); } - public function testInsertNewFieldUpdating() + public function testInsertNewFieldUpdating(): void { $versionInfo = new Content\VersionInfo(); $content = new Content(); @@ -390,7 +389,7 @@ public function testInsertNewFieldUpdating() self::assertEquals(23, $field->id); } - public function testInsertExistingField() + public function testInsertExistingField(): void { $versionInfo = new Content\VersionInfo(); $content = new Content(); @@ -438,7 +437,7 @@ public function testInsertExistingField() self::assertEquals(32, $field->id); } - public function testInsertExistingFieldUpdating() + public function testInsertExistingFieldUpdating(): void { $versionInfo = new Content\VersionInfo(); $content = new Content(); @@ -623,9 +622,8 @@ public function getFieldReference($id, $versionNo, $languageCode) */ protected function getMockedAction($methods = []) { - return $this + $builder = $this ->getMockBuilder(AddField::class) - ->setMethods((array)$methods) ->setConstructorArgs( [ $this->getContentGatewayMock(), @@ -634,7 +632,12 @@ protected function getMockedAction($methods = []) $this->getContentStorageHandlerMock(), $this->getContentMapperMock(), ] - ) - ->getMock(); + ); + + if ($methods !== []) { + $builder->onlyMethods($methods); + } + + return $builder->getMock(); } } diff --git a/tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php b/tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php index 0588db6fe2..857e7fc1d3 100644 --- a/tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php +++ b/tests/lib/Persistence/Legacy/Content/Type/ContentUpdater/Action/RemoveFieldTest.php @@ -12,11 +12,10 @@ use Ibexa\Core\Persistence\Legacy\Content\Mapper as ContentMapper; use Ibexa\Core\Persistence\Legacy\Content\StorageHandler; use Ibexa\Core\Persistence\Legacy\Content\Type\ContentUpdater\Action\RemoveField; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\Type\ContentUpdater\Action\RemoveField - */ +#[CoversClass(RemoveField::class)] class RemoveFieldTest extends TestCase { /** @@ -43,7 +42,7 @@ class RemoveFieldTest extends TestCase */ protected $removeFieldAction; - public function testApplySingleVersionSingleTranslation() + public function testApplySingleVersionSingleTranslation(): void { $contentId = 42; $versionNumbers = [1]; @@ -64,7 +63,7 @@ public function testApplySingleVersionSingleTranslation() ->will(self::returnValue([])); $this->getContentGatewayMock() - ->expects(self::at(2)) + ->expects(self::once()) ->method('load') ->with($contentId, 1) ->will(self::returnValue([])); @@ -91,7 +90,7 @@ public function testApplySingleVersionSingleTranslation() $action->apply($contentId); } - public function testApplyMultipleVersionsSingleTranslation() + public function testApplyMultipleVersionsSingleTranslation(): void { $contentId = 42; $versionNumbers = [1, 2]; @@ -112,57 +111,46 @@ public function testApplyMultipleVersionsSingleTranslation() ->with(self::equalTo([['id' => $contentId, 'version' => 1], ['id' => $contentId, 'version' => 2]])) ->will(self::returnValue([])); + $loadMatcher = self::exactly(2); $this->getContentGatewayMock() - ->expects(self::at(2)) + ->expects($loadMatcher) ->method('load') - ->with($contentId, 1) - ->will(self::returnValue([])); - - $this->getContentMapperMock() - ->expects(self::at(0)) - ->method('extractContentFromRows') - ->with([], []) - ->will(self::returnValue([$content1])); + ->willReturnCallback(function (...$parameters) use ($loadMatcher, $contentId) { + $this->assertSame([$contentId, $loadMatcher->numberOfInvocations(), null], $parameters); - $this->getContentGatewayMock() - ->expects(self::at(3)) - ->method('load') - ->with($contentId, 2) - ->will(self::returnValue([])); + return []; + }); + $extractMatcher = self::exactly(2); $this->getContentMapperMock() - ->expects(self::at(1)) + ->expects($extractMatcher) ->method('extractContentFromRows') - ->with([], []) - ->will(self::returnValue([$content2])); + ->willReturnCallback(function (...$parameters) use ($extractMatcher, $content1, $content2) { + $this->assertSame([[], [], 'content_', null], $parameters); + + return $extractMatcher->numberOfInvocations() === 1 ? [$content1] : [$content2]; + }); $this->getContentGatewayMock() ->expects(self::once()) ->method('deleteField') ->with(self::equalTo($fieldId)); + $deleteFieldDataMatcher = self::exactly(2); $this->getContentStorageHandlerMock() - ->expects(self::at(0)) + ->expects($deleteFieldDataMatcher) ->method('deleteFieldData') - ->with( - self::equalTo('ibexa_string'), - $content1->versionInfo, - self::equalTo([$fieldId]) - ); - - $this->getContentStorageHandlerMock() - ->expects(self::at(1)) - ->method('deleteFieldData') - ->with( - self::equalTo('ibexa_string'), - $content2->versionInfo, - self::equalTo([$fieldId]) - ); + ->willReturnCallback(function (...$parameters) use ($deleteFieldDataMatcher, $content1, $content2, $fieldId) { + $expectedVersionInfo = $deleteFieldDataMatcher->numberOfInvocations() === 1 + ? $content1->versionInfo + : $content2->versionInfo; + $this->assertSame(['ibexa_string', $expectedVersionInfo, [$fieldId]], $parameters); + }); $action->apply($contentId); } - public function testApplyMultipleVersionsMultipleTranslations() + public function testApplyMultipleVersionsMultipleTranslations(): void { $contentId = 42; $versionNumbers = [1, 2]; @@ -184,60 +172,48 @@ public function testApplyMultipleVersionsMultipleTranslations() ->with(self::equalTo([['id' => $contentId, 'version' => 1], ['id' => $contentId, 'version' => 2]])) ->will(self::returnValue([])); + $loadMatcher = self::exactly(2); $this->getContentGatewayMock() - ->expects(self::at(2)) + ->expects($loadMatcher) ->method('load') - ->with($contentId, 1) - ->will(self::returnValue([])); - - $this->getContentMapperMock() - ->expects(self::at(0)) - ->method('extractContentFromRows') - ->with([], []) - ->will(self::returnValue([$content1])); + ->willReturnCallback(function (...$parameters) use ($loadMatcher, $contentId) { + $this->assertSame([$contentId, $loadMatcher->numberOfInvocations(), null], $parameters); - $this->getContentGatewayMock() - ->expects(self::at(3)) - ->method('load') - ->with($contentId, 2) - ->will(self::returnValue([])); + return []; + }); + $extractMatcher = self::exactly(2); $this->getContentMapperMock() - ->expects(self::at(1)) + ->expects($extractMatcher) ->method('extractContentFromRows') - ->with([], []) - ->will(self::returnValue([$content2])); + ->willReturnCallback(function (...$parameters) use ($extractMatcher, $content1, $content2) { + $this->assertSame([[], [], 'content_', null], $parameters); - $this->getContentGatewayMock() - ->expects(self::at(5)) - ->method('deleteField') - ->with(self::equalTo($fieldId1)); + return $extractMatcher->numberOfInvocations() === 1 ? [$content1] : [$content2]; + }); + $deleteFieldMatcher = self::exactly(2); $this->getContentGatewayMock() - ->expects(self::at(6)) + ->expects($deleteFieldMatcher) ->method('deleteField') - ->with(self::equalTo($fieldId2)); + ->willReturnCallback(function (...$parameters) use ($deleteFieldMatcher, $fieldId1, $fieldId2) { + $expected = $deleteFieldMatcher->numberOfInvocations() === 1 ? $fieldId1 : $fieldId2; + $this->assertSame([$expected], $parameters); + }); + $deleteFieldDataMatcher = self::exactly(2); $this->getContentStorageHandlerMock() - ->expects(self::at(0)) + ->expects($deleteFieldDataMatcher) ->method('deleteFieldData') - ->with( - self::equalTo('ibexa_string'), - $content1->versionInfo, - self::equalTo([$fieldId1, $fieldId2]) - ); - - $this->getContentStorageHandlerMock() - ->expects(self::at(1)) - ->method('deleteFieldData') - ->with( - self::equalTo('ibexa_string'), - $content2->versionInfo, - self::equalTo([$fieldId1, $fieldId2]) - ); + ->willReturnCallback(function (...$parameters) use ($deleteFieldDataMatcher, $content1, $content2, $fieldId1, $fieldId2) { + $expectedVersionInfo = $deleteFieldDataMatcher->numberOfInvocations() === 1 + ? $content1->versionInfo + : $content2->versionInfo; + $this->assertSame(['ibexa_string', $expectedVersionInfo, [$fieldId1, $fieldId2]], $parameters); + }); $this->getContentGatewayMock() - ->expects(self::at(4)) + ->expects(self::once()) ->method('removeRelationsByFieldDefinitionId') ->with(self::equalTo(42)); diff --git a/tests/lib/Persistence/Legacy/Content/Type/ContentUpdaterTest.php b/tests/lib/Persistence/Legacy/Content/Type/ContentUpdaterTest.php index 2dec5f8da7..4c509f10a1 100644 --- a/tests/lib/Persistence/Legacy/Content/Type/ContentUpdaterTest.php +++ b/tests/lib/Persistence/Legacy/Content/Type/ContentUpdaterTest.php @@ -15,11 +15,10 @@ use Ibexa\Core\Persistence\Legacy\Content\StorageHandler; use Ibexa\Core\Persistence\Legacy\Content\Type\ContentUpdater; use Ibexa\Core\Persistence\Legacy\Content\Type\ContentUpdater\Action; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\Type\ContentUpdater - */ +#[CoversClass(ContentUpdater::class)] class ContentUpdaterTest extends TestCase { /** @@ -60,7 +59,7 @@ class ContentUpdaterTest extends TestCase /** @var \Ibexa\Core\Persistence\Legacy\Content\Mapper */ protected $contentMapperMock; - public function testDetermineActions() + public function testDetermineActions(): void { $fromType = $this->getFromTypeFixture(); $toType = $this->getToTypeFixture(); @@ -99,7 +98,7 @@ public function testDetermineActions() ); } - public function testApplyUpdates() + public function testApplyUpdates(): void { $updater = $this->getContentUpdater(); @@ -109,24 +108,24 @@ public function testApplyUpdates() '', false ); - $actionA->expects(self::at(0)) + $actionAMatcher = self::exactly(2); + $actionA->expects($actionAMatcher) ->method('apply') - ->with(11); - $actionA->expects(self::at(1)) - ->method('apply') - ->with(22); + ->willReturnCallback(function (...$parameters) use ($actionAMatcher) { + $this->assertSame([$actionAMatcher->numberOfInvocations() === 1 ? 11 : 22], $parameters); + }); $actionB = $this->getMockForAbstractClass( Action::class, [], '', false ); - $actionB->expects(self::at(0)) - ->method('apply') - ->with(11); - $actionB->expects(self::at(1)) + $actionBMatcher = self::exactly(2); + $actionB->expects($actionBMatcher) ->method('apply') - ->with(22); + ->willReturnCallback(function (...$parameters) use ($actionBMatcher) { + $this->assertSame([$actionBMatcher->numberOfInvocations() === 1 ? 11 : 22], $parameters); + }); $actions = [$actionA, $actionB]; diff --git a/tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php b/tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php index 6176991da8..8ddc307ec5 100644 --- a/tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php +++ b/tests/lib/Persistence/Legacy/Content/Type/Gateway/DoctrineDatabaseTest.php @@ -18,10 +18,10 @@ use Ibexa\Core\Persistence\Legacy\Content\Type\Gateway; use Ibexa\Core\Persistence\Legacy\Content\Type\Gateway\DoctrineDatabase; use Ibexa\Tests\Core\Persistence\Legacy\Content\LanguageAwareTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\Type\Gateway\DoctrineDatabase - */ +#[CoversClass(DoctrineDatabase::class)] class DoctrineDatabaseTest extends LanguageAwareTestCase { /** @@ -38,7 +38,7 @@ protected function setUp(): void $this->insertDatabaseFixture(__DIR__ . '/_fixtures/languages.php'); } - public function testInsertGroup() + public function testInsertGroup(): void { $gateway = $this->getGateway(); @@ -96,7 +96,7 @@ protected function getGroupFixture() return $group; } - public function testUpdateGroup() + public function testUpdateGroup(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_groups.php' @@ -193,7 +193,7 @@ protected function getGroupUpdateStructFixture() return $struct; } - public function testCountTypesInGroup() + public function testCountTypesInGroup(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_types.php' @@ -211,7 +211,7 @@ public function testCountTypesInGroup() ); } - public function testCountGroupsForType() + public function testCountGroupsForType(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_types.php' @@ -229,7 +229,7 @@ public function testCountGroupsForType() ); } - public function testDeleteGroup() + public function testDeleteGroup(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_groups.php' @@ -251,7 +251,7 @@ public function testDeleteGroup() ); } - public function testLoadGroupData() + public function testLoadGroupData(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_groups.php' @@ -276,7 +276,7 @@ public function testLoadGroupData() ); } - public function testLoadGroupDataByIdentifier() + public function testLoadGroupDataByIdentifier(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_groups.php' @@ -301,7 +301,7 @@ public function testLoadGroupDataByIdentifier() ); } - public function testLoadAllGroupsData() + public function testLoadAllGroupsData(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_groups.php' @@ -329,7 +329,7 @@ public function testLoadAllGroupsData() ); } - public function testLoadTypesDataForGroup() + public function testLoadTypesDataForGroup(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_types.php' @@ -344,7 +344,7 @@ public function testLoadTypesDataForGroup() ); } - public function testLoadTypeData() + public function testLoadTypeData(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_types.php' @@ -372,7 +372,7 @@ public function testLoadTypeData() */ } - public function testLoadTypeDataByIdentifier() + public function testLoadTypeDataByIdentifier(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_types.php' @@ -391,7 +391,7 @@ public function testLoadTypeDataByIdentifier() ); } - public function testLoadTypeDataByRemoteId() + public function testLoadTypeDataByRemoteId(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_types.php' @@ -415,7 +415,7 @@ public function testLoadTypeDataByRemoteId() * * @return string[][] */ - public static function getTypeCreationExpectations() + public static function getTypeCreationExpectations(): array { return [ ['always_available', 0], @@ -438,10 +438,8 @@ public static function getTypeCreationExpectations() ]; } - /** - * @dataProvider getTypeCreationExpectations - */ - public function testInsertType($column, $expectation) + #[DataProvider('getTypeCreationExpectations')] + public function testInsertType($column, $expectation): void { $gateway = $this->getGateway(); $type = $this->getTypeFixture(); @@ -462,7 +460,7 @@ public function testInsertType($column, $expectation) * * @return string[][] */ - public static function getTypeCreationContentClassNameExpectations() + public static function getTypeCreationContentClassNameExpectations(): array { return [ ['content_type_status', [0, 0]], @@ -472,10 +470,8 @@ public static function getTypeCreationContentClassNameExpectations() ]; } - /** - * @dataProvider getTypeCreationContentClassNameExpectations - */ - public function testInsertTypeContentClassName($column, $expectation) + #[DataProvider('getTypeCreationContentClassNameExpectations')] + public function testInsertTypeContentClassName($column, $expectation): void { $gateway = $this->getGateway(); $type = $this->getTypeFixture(); @@ -535,7 +531,7 @@ protected function getTypeFixture() return $type; } - public function testInsertFieldDefinition() + public function testInsertFieldDefinition(): void { $gateway = $this->getGateway(); @@ -673,7 +669,7 @@ protected function getStorageFieldDefinitionFixture() return $fieldDef; } - public function testDeleteFieldDefinition() + public function testDeleteFieldDefinition(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_types.php' @@ -691,7 +687,7 @@ public function testDeleteFieldDefinition() ); } - public function testUpdateFieldDefinition() + public function testUpdateFieldDefinition(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_types.php' @@ -763,7 +759,7 @@ public function testUpdateFieldDefinition() ); } - public function testInsertGroupAssignment() + public function testInsertGroupAssignment(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_groups.php' @@ -792,7 +788,7 @@ public function testInsertGroupAssignment() ); } - public function testDeleteGroupAssignment() + public function testDeleteGroupAssignment(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_types.php' @@ -812,10 +808,8 @@ public function testDeleteGroupAssignment() ); } - /** - * @dataProvider getTypeUpdateExpectations - */ - public function testUpdateType($fieldName, $expectedValue) + #[DataProvider('getTypeUpdateExpectations')] + public function testUpdateType($fieldName, $expectedValue): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_types.php' @@ -842,7 +836,7 @@ public function testUpdateType($fieldName, $expectedValue) ); } - public function testUpdateTypeName() + public function testUpdateTypeName(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_types.php' @@ -885,7 +879,7 @@ public function testUpdateTypeName() * * @return string[][] */ - public static function getTypeUpdateExpectations() + public static function getTypeUpdateExpectations(): array { return [ ['serialized_name_list', 'a:3:{s:16:"always-available";s:6:"eng-US";s:6:"eng-US";s:10:"New Folder";s:6:"eng-GB";s:18:"New Folder for you";}'], @@ -935,7 +929,7 @@ protected function getUpdateTypeFixture(): Type return $type; } - public function testCountInstancesOfTypeExist() + public function testCountInstancesOfTypeExist(): void { $this->insertDatabaseFixture( // Fixture for content objects @@ -951,7 +945,7 @@ public function testCountInstancesOfTypeExist() ); } - public function testCountInstancesOfTypeNotExist() + public function testCountInstancesOfTypeNotExist(): void { $this->insertDatabaseFixture( // Fixture for content objects @@ -967,7 +961,7 @@ public function testCountInstancesOfTypeNotExist() ); } - public function testDeleteFieldDefinitionsForTypeExisting() + public function testDeleteFieldDefinitionsForTypeExisting(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_types.php' @@ -1003,7 +997,7 @@ public function testDeleteFieldDefinitionsForTypeExisting() ); } - public function testDeleteFieldDefinitionsForTypeNotExisting() + public function testDeleteFieldDefinitionsForTypeNotExisting(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_types.php' @@ -1023,7 +1017,7 @@ public function testDeleteFieldDefinitionsForTypeNotExisting() ); } - public function testDeleteGroupAssignmentsForTypeExisting() + public function testDeleteGroupAssignmentsForTypeExisting(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_types.php' @@ -1043,7 +1037,7 @@ public function testDeleteGroupAssignmentsForTypeExisting() ); } - public function testDeleteGroupAssignmentsForTypeNotExisting() + public function testDeleteGroupAssignmentsForTypeNotExisting(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_types.php' @@ -1063,7 +1057,7 @@ public function testDeleteGroupAssignmentsForTypeNotExisting() ); } - public function testDeleteTypeExisting() + public function testDeleteTypeExisting(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_types.php' @@ -1083,7 +1077,7 @@ public function testDeleteTypeExisting() ); } - public function testDeleteTypeNotExisting() + public function testDeleteTypeNotExisting(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/existing_types.php' @@ -1103,7 +1097,7 @@ public function testDeleteTypeNotExisting() ); } - public function testPublishTypeAndFields() + public function testPublishTypeAndFields(): void { $this->insertDatabaseFixture( __DIR__ . '/_fixtures/type_to_publish.php' diff --git a/tests/lib/Persistence/Legacy/Content/Type/MapperTest.php b/tests/lib/Persistence/Legacy/Content/Type/MapperTest.php index 489113a6d1..ee0fec59f5 100644 --- a/tests/lib/Persistence/Legacy/Content/Type/MapperTest.php +++ b/tests/lib/Persistence/Legacy/Content/Type/MapperTest.php @@ -25,13 +25,12 @@ use Ibexa\Core\Persistence\Legacy\Content\Type\Mapper; use Ibexa\Core\Persistence\Legacy\Content\Type\StorageDispatcherInterface; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\Type\Mapper - */ +#[CoversClass(Mapper::class)] class MapperTest extends TestCase { - public function testCreateGroupFromCreateStruct() + public function testCreateGroupFromCreateStruct(): void { $createStruct = $this->getGroupCreateStructFixture(); @@ -87,7 +86,7 @@ protected function getGroupCreateStructFixture() return $struct; } - public function testTypeFromCreateStruct() + public function testTypeFromCreateStruct(): void { $struct = $this->getContentTypeCreateStructFixture(); @@ -108,7 +107,7 @@ public function testTypeFromCreateStruct() } } - public function testTypeFromUpdateStruct() + public function testTypeFromUpdateStruct(): void { $struct = $this->getContentTypeUpdateStructFixture(); @@ -198,7 +197,7 @@ protected function getContentTypeUpdateStructFixture(): UpdateStruct return $struct; } - public function testCreateStructFromType() + public function testCreateStructFromType(): void { $type = $this->getContentTypeFixture(); @@ -266,7 +265,7 @@ protected function getContentTypeFixture() return $type; } - public function testExtractGroupsFromRows() + public function testExtractGroupsFromRows(): void { $rows = $this->getLoadGroupFixture(); @@ -302,7 +301,7 @@ public function testExtractGroupsFromRows() ); } - public function testExtractTypesFromRowsSingle() + public function testExtractTypesFromRowsSingle(): void { $rows = $this->getLoadTypeFixture(); @@ -383,7 +382,7 @@ public function testExtractTypesFromRowsSingle() ); } - public function testToStorageFieldDefinition() + public function testToStorageFieldDefinition(): void { $converterMock = $this->createMock(Converter::class); $converterMock->expects(self::once()) @@ -417,7 +416,7 @@ public function testToStorageFieldDefinition() $mapper->toStorageFieldDefinition($fieldDef, $storageFieldDef); } - public function testToFieldDefinition() + public function testToFieldDefinition(): void { $storageFieldDef = new StorageFieldDefinition(); @@ -454,13 +453,13 @@ public function testToFieldDefinition() protected function getNonConvertingMapper() { $mapper = $this->getMockBuilder(Mapper::class) - ->setMethods(['toFieldDefinition']) ->setConstructorArgs([ $this->getConverterRegistryMock(), $this->getMaskGeneratorMock(), $this->getStorageDispatcherMock(), $this->getFieldTypeAliasResolver(), ]) + ->onlyMethods(['toFieldDefinition']) ->getMock(); // Dedicatedly tested test diff --git a/tests/lib/Persistence/Legacy/Content/Type/StorageDispatcherTest.php b/tests/lib/Persistence/Legacy/Content/Type/StorageDispatcherTest.php index c99c84d98d..4973f61734 100644 --- a/tests/lib/Persistence/Legacy/Content/Type/StorageDispatcherTest.php +++ b/tests/lib/Persistence/Legacy/Content/Type/StorageDispatcherTest.php @@ -42,7 +42,7 @@ public function testPublishFieldConstraintsData(): void public function testStoreFieldConstraintsData(): void { $status = ContentType::STATUS_DEFINED; - $constraints = $this->createMock(FieldTypeConstraints::class); + $constraints = self::createStub(FieldTypeConstraints::class); $storage = $this->createMock(FieldConstraintsStorage::class); $storage @@ -77,7 +77,7 @@ public function testStoreFieldConstraintsDataForNonSupportedFieldType(): void public function testLoadFieldConstraintsData(): void { - $constraints = $this->createMock(FieldTypeConstraints::class); + $constraints = self::createStub(FieldTypeConstraints::class); $storage = $this->createMock(FieldConstraintsStorage::class); $storage @@ -103,7 +103,7 @@ public function testLoadFieldConstraintsData(): void public function testLoadFieldConstraintsDataForNonSupportedFieldType(): void { - $constraints = $this->createMock(FieldTypeConstraints::class); + $constraints = self::createStub(FieldTypeConstraints::class); $fieldDefinition = new FieldDefinition(); $fieldDefinition->id = self::EXAMPLE_FIELD_DEFINITION_ID; diff --git a/tests/lib/Persistence/Legacy/Content/Type/StorageRegistryTest.php b/tests/lib/Persistence/Legacy/Content/Type/StorageRegistryTest.php index b887e38273..ae31320a38 100644 --- a/tests/lib/Persistence/Legacy/Content/Type/StorageRegistryTest.php +++ b/tests/lib/Persistence/Legacy/Content/Type/StorageRegistryTest.php @@ -18,8 +18,8 @@ final class StorageRegistryTest extends TestCase public function testHasStorage(): void { $registry = new StorageRegistry([ - 'foo' => $this->createMock(FieldConstraintsStorage::class), - 'bar' => $this->createMock(FieldConstraintsStorage::class), + 'foo' => self::createStub(FieldConstraintsStorage::class), + 'bar' => self::createStub(FieldConstraintsStorage::class), ]); self::assertTrue($registry->hasStorage('foo')); @@ -31,8 +31,8 @@ public function testHasStorage(): void public function testGetStorage(): void { $storages = [ - 'foo' => $this->createMock(FieldConstraintsStorage::class), - 'bar' => $this->createMock(FieldConstraintsStorage::class), + 'foo' => self::createStub(FieldConstraintsStorage::class), + 'bar' => self::createStub(FieldConstraintsStorage::class), ]; $registry = new StorageRegistry($storages); @@ -44,11 +44,11 @@ public function testGetStorage(): void public function testGetStorageForNonSupportedFieldType(): void { $this->expectException(InvalidArgumentException::class); - $this->expectErrorMessage('Argument \'$typeName\' is invalid: Undefined Ibexa\Contracts\Core\FieldType\FieldConstraintsStorage for "baz" field type'); + $this->expectExceptionMessage('Argument \'$typeName\' is invalid: Undefined Ibexa\Contracts\Core\FieldType\FieldConstraintsStorage for "baz" field type'); $registry = new StorageRegistry([ - 'foo' => $this->createMock(FieldConstraintsStorage::class), - 'bar' => $this->createMock(FieldConstraintsStorage::class), + 'foo' => self::createStub(FieldConstraintsStorage::class), + 'bar' => self::createStub(FieldConstraintsStorage::class), ]); $registry->getStorage('baz'); } diff --git a/tests/lib/Persistence/Legacy/Content/Type/Update/Handler/DoctrineDatabaseTest.php b/tests/lib/Persistence/Legacy/Content/Type/Update/Handler/DoctrineDatabaseTest.php index 32485ecfe9..ab2d295736 100644 --- a/tests/lib/Persistence/Legacy/Content/Type/Update/Handler/DoctrineDatabaseTest.php +++ b/tests/lib/Persistence/Legacy/Content/Type/Update/Handler/DoctrineDatabaseTest.php @@ -11,11 +11,10 @@ use Ibexa\Core\Persistence\Legacy\Content\Type\ContentUpdater; use Ibexa\Core\Persistence\Legacy\Content\Type\Gateway; use Ibexa\Core\Persistence\Legacy\Content\Type\Update\Handler\DoctrineDatabase; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\Type\Update\Handler\DoctrineDatabase - */ +#[CoversClass(DoctrineDatabase::class)] class DoctrineDatabaseTest extends TestCase { /** @@ -32,7 +31,7 @@ class DoctrineDatabaseTest extends TestCase */ protected $contentUpdaterMock; - public function testUpdateContentObjects() + public function testUpdateContentObjects(): void { $handler = $this->getUpdateHandler(); @@ -49,7 +48,7 @@ public function testUpdateContentObjects() $handler->updateContentObjects($types['from'], $types['to']); } - public function testDeleteOldType() + public function testDeleteOldType(): void { $handler = $this->getUpdateHandler(); @@ -67,7 +66,7 @@ public function testDeleteOldType() $handler->deleteOldType($types['from'], $types['to']); } - public function testPublishNewType() + public function testPublishNewType(): void { $handler = $this->getUpdateHandler(); diff --git a/tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php b/tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php index f059eda39a..d6c3ff3362 100644 --- a/tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php +++ b/tests/lib/Persistence/Legacy/Content/UrlAlias/Gateway/DoctrineDatabaseTest.php @@ -13,12 +13,12 @@ use Ibexa\Core\Persistence\Legacy\Content\Language\MaskGenerator as LanguageMaskGenerator; use Ibexa\Core\Persistence\Legacy\Content\UrlAlias\Gateway\DoctrineDatabase; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\UrlAlias\Gateway\DoctrineDatabase - * - * @group urlalias-gateway - */ +#[CoversClass(DoctrineDatabase::class)] +#[Group('urlalias-gateway')] class DoctrineDatabaseTest extends TestCase { /** @@ -31,7 +31,7 @@ class DoctrineDatabaseTest extends TestCase /** * Test for the loadUrlAliasData() method. */ - public function testLoadUrlaliasDataNonExistent() + public function testLoadUrlaliasDataNonExistent(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_simple.php'); $gateway = $this->getGateway(); @@ -44,7 +44,7 @@ public function testLoadUrlaliasDataNonExistent() /** * Test for the loadUrlAliasData() method. */ - public function testLoadUrlaliasData() + public function testLoadUrlaliasData(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_simple.php'); $gateway = $this->getGateway(); @@ -85,7 +85,7 @@ public function testLoadUrlaliasData() * * Test with fixture containing language mask with multiple languages. */ - public function testLoadUrlaliasDataMultipleLanguages() + public function testLoadUrlaliasDataMultipleLanguages(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_multilang.php'); $gateway = $this->getGateway(); @@ -124,7 +124,7 @@ public function testLoadUrlaliasDataMultipleLanguages() /** * @return array */ - public function providerForTestLoadPathData() + public static function providerForTestLoadPathData(): array { return [ [ @@ -169,11 +169,9 @@ public function providerForTestLoadPathData() /** * Test for the loadPathData() method. - * - * - * @dataProvider providerForTestLoadPathData */ - public function testLoadPathData($id, $pathData) + #[DataProvider('providerForTestLoadPathData')] + public function testLoadPathData($id, $pathData): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_fallback.php'); $gateway = $this->getGateway(); @@ -189,7 +187,7 @@ public function testLoadPathData($id, $pathData) /** * @return array */ - public function providerForTestLoadPathDataMultipleLanguages() + public static function providerForTestLoadPathDataMultipleLanguages(): array { return [ [ @@ -231,11 +229,9 @@ public function providerForTestLoadPathDataMultipleLanguages() /** * Test for the loadPathData() method. - * - * - * @dataProvider providerForTestLoadPathDataMultipleLanguages */ - public function testLoadPathDataMultipleLanguages($id, $pathData) + #[DataProvider('providerForTestLoadPathDataMultipleLanguages')] + public function testLoadPathDataMultipleLanguages($id, $pathData): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_multilang.php'); $gateway = $this->getGateway(); @@ -251,7 +247,7 @@ public function testLoadPathDataMultipleLanguages($id, $pathData) /** * @return array */ - public function providerForTestCleanupAfterPublishHistorize() + public static function providerForTestCleanupAfterPublishHistorize(): array { return [ [ @@ -276,7 +272,7 @@ public function providerForTestCleanupAfterPublishHistorize() * * @return array */ - public function providerForTestArchiveUrlAliasesForDeletedTranslations() + public static function providerForTestArchiveUrlAliasesForDeletedTranslations(): array { return [ [314, [2]], @@ -289,12 +285,9 @@ public function providerForTestArchiveUrlAliasesForDeletedTranslations() /** * Test for the cleanupAfterPublish() method. - * - * - * - * @dataProvider providerForTestCleanupAfterPublishHistorize */ - public function testCleanupAfterPublishHistorize($action, $languageId, $parentId, $textMD5) + #[DataProvider('providerForTestCleanupAfterPublishHistorize')] + public function testCleanupAfterPublishHistorize($action, $languageId, $parentId, $textMD5): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_downgrade.php'); $gateway = $this->getGateway(); @@ -314,7 +307,7 @@ public function testCleanupAfterPublishHistorize($action, $languageId, $parentId /** * @return array */ - public function providerForTestCleanupAfterPublishRemovesLanguage() + public static function providerForTestCleanupAfterPublishRemovesLanguage(): array { return [ [ @@ -334,12 +327,9 @@ public function providerForTestCleanupAfterPublishRemovesLanguage() /** * Test for the cleanupAfterPublish() method. - * - * - * - * @dataProvider providerForTestCleanupAfterPublishRemovesLanguage */ - public function testCleanupAfterPublishRemovesLanguage($action, $languageId, $parentId, $textMD5) + #[DataProvider('providerForTestCleanupAfterPublishRemovesLanguage')] + public function testCleanupAfterPublishRemovesLanguage($action, $languageId, $parentId, $textMD5): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_downgrade.php'); $gateway = $this->getGateway(); @@ -359,7 +349,7 @@ public function testCleanupAfterPublishRemovesLanguage($action, $languageId, $pa * * @todo document */ - public function testReparent() + public function testReparent(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_simple.php'); $gateway = $this->getGateway(); @@ -387,7 +377,7 @@ public function testReparent() /** * Test for the remove() method. */ - public function testRemove() + public function testRemove(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_remove.php'); $gateway = $this->getGateway(); @@ -405,7 +395,7 @@ public function testRemove() /** * Test for the remove() method. */ - public function testRemoveWithId() + public function testRemoveWithId(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_remove.php'); $gateway = $this->getGateway(); @@ -423,7 +413,7 @@ public function testRemoveWithId() /** * Test for the removeCustomAlias() method. */ - public function testRemoveCustomAlias() + public function testRemoveCustomAlias(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_remove.php'); $gateway = $this->getGateway(); @@ -439,7 +429,7 @@ public function testRemoveCustomAlias() /** * Test for the removeByAction() method. */ - public function testRemoveCustomAliasFails() + public function testRemoveCustomAliasFails(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_remove.php'); $gateway = $this->getGateway(); @@ -453,7 +443,7 @@ public function testRemoveCustomAliasFails() /** * Test for the getNextId() method. */ - public function testGetNextId() + public function testGetNextId(): void { $gateway = $this->getGateway(); @@ -462,12 +452,11 @@ public function testGetNextId() } /** - * @dataProvider providerForTestArchiveUrlAliasesForDeletedTranslations - * * @param int $locationId * @param int[] $removedLanguageIds */ - public function testArchiveUrlAliasesForDeletedTranslations($locationId, array $removedLanguageIds) + #[DataProvider('providerForTestArchiveUrlAliasesForDeletedTranslations')] + public function testArchiveUrlAliasesForDeletedTranslations($locationId, array $removedLanguageIds): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_multilang.php'); $gateway = $this->getGateway(); diff --git a/tests/lib/Persistence/Legacy/Content/UrlAlias/SlugConverterTest.php b/tests/lib/Persistence/Legacy/Content/UrlAlias/SlugConverterTest.php index d51152291f..742857c5e8 100644 --- a/tests/lib/Persistence/Legacy/Content/UrlAlias/SlugConverterTest.php +++ b/tests/lib/Persistence/Legacy/Content/UrlAlias/SlugConverterTest.php @@ -14,12 +14,13 @@ use Ibexa\Core\Persistence\TransformationProcessor\PreprocessedBased; use Ibexa\Core\Persistence\Utf8Converter; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; use PHPUnit\Framework\MockObject\MockObject; use ReflectionMethod; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\UrlAlias\SlugConverter - */ +#[CoversClass(SlugConverter::class)] final class SlugConverterTest extends TestCase { /** @var array */ @@ -116,9 +117,8 @@ public static function providerForTestGetUniqueCounterValue(): iterable /** * Test for the getUniqueCounterValue() method. - * - * @dataProvider providerForTestGetUniqueCounterValue */ + #[DataProvider('providerForTestGetUniqueCounterValue')] public function testGetUniqueCounterValue(string $text, bool $isRootLevel, int $returnValue): void { $slugConverter = $this->getSlugConverter(); @@ -153,9 +153,8 @@ public static function cleanupTextData(): iterable /** * Test for the cleanupText() method. - * - * @dataProvider cleanupTextData */ + #[DataProvider('cleanupTextData')] public function testCleanupText(string $text, string $method, string $expected): void { $testMethod = new ReflectionMethod( @@ -197,11 +196,8 @@ public static function convertData(): iterable ]; } - /** - * @dataProvider convertData - * - * @depends testCleanupText - */ + #[Depends('testCleanupText')] + #[DataProvider('convertData')] public function testConvertNoMocking(string $text, string $defaultText, string $transformation, string $expected): void { $transformationsDirectory = dirname(__DIR__, 6) . '/src/lib/Resources/slug_converter/transformations'; @@ -243,7 +239,7 @@ protected function getSlugConverterMock(array $methods = []): SlugConverter & Mo { if (!isset($this->slugConverterMock)) { $this->slugConverterMock = $this->getMockBuilder(SlugConverter::class) - ->onlyMethods($methods) + ->onlyMethods(array_values($methods)) ->setConstructorArgs( [ $this->getTransformationProcessorMock(), diff --git a/tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php b/tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php index 216cf15741..434526fb5d 100644 --- a/tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php +++ b/tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasHandlerTest.php @@ -30,26 +30,26 @@ use Ibexa\Core\Persistence\Utf8Converter; use Ibexa\Core\Search\Legacy\Content; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\Group; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\UrlAlias\Handler - * - * @group urlalias-handler - */ +#[CoversClass(Handler::class)] +#[Group('urlalias-handler')] class UrlAliasHandlerTest extends TestCase { /** * Test for the lookup() method. * * Simple lookup case. - * - * @group location - * @group virtual - * @group resource - * @group case-correction - * @group multiple-languages */ - public function testLookup() + #[Group('location')] + #[Group('virtual')] + #[Group('resource')] + #[Group('case-correction')] + #[Group('multiple-languages')] + public function testLookup(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_location.php'); @@ -62,13 +62,11 @@ public function testLookup() * Test for the lookup() method. * * Trying to lookup non existent URL alias throws NotFoundException. - * - * - * @group location - * @group virtual - * @group resource */ - public function testLookupThrowsNotFoundException() + #[Group('location')] + #[Group('virtual')] + #[Group('resource')] + public function testLookupThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -80,11 +78,10 @@ public function testLookupThrowsNotFoundException() * Test for the lookup() method. * * Trying to lookup URL alias with exceeded path segments limit - * - * @group location - * @group case-correction */ - public function testLookupThrowsInvalidArgumentException() + #[Group('location')] + #[Group('case-correction')] + public function testLookupThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -92,7 +89,10 @@ public function testLookupThrowsInvalidArgumentException() $handler->lookup(str_repeat('/1', 99)); } - public function providerForTestLookupLocationUrlAlias() + /** + * @return array + */ + public static function providerForTestLookupLocationUrlAlias(): array { return [ [ @@ -341,13 +341,10 @@ public function providerForTestLookupLocationUrlAlias() * Test for the lookup() method. * * Testing that UrlAlias is found and has expected state. - * - * @dataProvider providerForTestLookupLocationUrlAlias - * - * @depends testLookup - * - * @group location */ + #[Depends('testLookup')] + #[Group('location')] + #[DataProvider('providerForTestLookupLocationUrlAlias')] public function testLookupLocationUrlAlias( $url, array $pathData, @@ -355,7 +352,7 @@ public function testLookupLocationUrlAlias( $alwaysAvailable, $locationId, $id - ) { + ): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_location.php'); @@ -392,15 +389,15 @@ public function testLookupLocationUrlAlias( * to is available in it. * * - * @dataProvider providerForTestLookupLocationUrlAlias * - * @depends testLookup * - * @group case-correction - * @group location * * @todo refactor, only forward pertinent */ + #[Depends('testLookup')] + #[Group('case-correction')] + #[Group('location')] + #[DataProvider('providerForTestLookupLocationUrlAlias')] public function testLookupLocationCaseCorrection( $url, array $pathData, @@ -408,7 +405,7 @@ public function testLookupLocationCaseCorrection( $alwaysAvailable, $locationId, $id - ) { + ): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_location.php'); @@ -433,7 +430,10 @@ public function testLookupLocationCaseCorrection( ); } - public function providerForTestLookupLocationMultipleLanguages() + /** + * @return array + */ + public static function providerForTestLookupLocationMultipleLanguages(): array { return [ [ @@ -521,14 +521,11 @@ public function providerForTestLookupLocationMultipleLanguages() /** * Test for the lookup() method. - * - * @dataProvider providerForTestLookupLocationMultipleLanguages - * - * @depends testLookup - * - * @group multiple-languages - * @group location */ + #[Depends('testLookup')] + #[Group('multiple-languages')] + #[Group('location')] + #[DataProvider('providerForTestLookupLocationMultipleLanguages')] public function testLookupLocationMultipleLanguages( $url, array $pathData, @@ -536,7 +533,7 @@ public function testLookupLocationMultipleLanguages( $alwaysAvailable, $locationId, $id - ) { + ): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_location_multilang.php'); @@ -565,13 +562,11 @@ public function testLookupLocationMultipleLanguages( * Test for the lookup() method. * * @todo document - * - * @depends testLookup - * - * @group history - * @group location */ - public function testLookupLocationHistoryUrlAlias() + #[Depends('testLookup')] + #[Group('history')] + #[Group('location')] + public function testLookupLocationHistoryUrlAlias(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_location.php'); @@ -584,7 +579,10 @@ public function testLookupLocationHistoryUrlAlias() ); } - public function providerForTestLookupCustomLocationUrlAlias() + /** + * @return array + */ + public static function providerForTestLookupCustomLocationUrlAlias(): array { return [ [ @@ -704,14 +702,11 @@ public function providerForTestLookupCustomLocationUrlAlias() * Test for the lookup() method. * * Testing that UrlAlias is found and has expected state. - * - * @dataProvider providerForTestLookupCustomLocationUrlAlias - * - * @depends testLookup - * - * @group location - * @group custom */ + #[Depends('testLookup')] + #[Group('location')] + #[Group('custom')] + #[DataProvider('providerForTestLookupCustomLocationUrlAlias')] public function testLookupCustomLocationUrlAlias( $url, array $pathData, @@ -720,7 +715,7 @@ public function testLookupCustomLocationUrlAlias( $alwaysAvailable, $destination, $id - ) { + ): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_location_custom.php'); @@ -748,14 +743,11 @@ public function testLookupCustomLocationUrlAlias( * Test for the lookup() method. * * Testing that UrlAlias is found and has expected state. - * - * @dataProvider providerForTestLookupCustomLocationUrlAlias - * - * @depends testLookup - * - * @group location - * @group custom */ + #[Depends('testLookup')] + #[Group('location')] + #[Group('custom')] + #[DataProvider('providerForTestLookupCustomLocationUrlAlias')] public function testLookupCustomLocationUrlAliasCaseCorrection( $url, array $pathData, @@ -764,7 +756,7 @@ public function testLookupCustomLocationUrlAliasCaseCorrection( $alwaysAvailable, $destination, $id - ) { + ): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_location_custom.php'); @@ -789,7 +781,10 @@ public function testLookupCustomLocationUrlAliasCaseCorrection( ); } - public function providerForTestLookupVirtualUrlAlias() + /** + * @return array + */ + public static function providerForTestLookupVirtualUrlAlias(): array { return [ [ @@ -807,14 +802,11 @@ public function providerForTestLookupVirtualUrlAlias() * Test for the lookup() method. * * Testing that NOP action redirects to site root. - * - * @dataProvider providerForTestLookupVirtualUrlAlias - * - * @depends testLookup - * - * @group virtual */ - public function testLookupVirtualUrlAlias($url, $id) + #[Depends('testLookup')] + #[Group('virtual')] + #[DataProvider('providerForTestLookupVirtualUrlAlias')] + public function testLookupVirtualUrlAlias($url, $id): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_location_custom.php'); @@ -824,7 +816,10 @@ public function testLookupVirtualUrlAlias($url, $id) $this->assertVirtualUrlAliasValid($urlAlias, $id); } - public function providerForTestLookupResourceUrlAlias() + /** + * @return array + */ + public static function providerForTestLookupResourceUrlAlias(): array { return [ [ @@ -878,13 +873,10 @@ public function providerForTestLookupResourceUrlAlias() * Test for the lookup() method. * * Testing that UrlAlias is found and has expected state. - * - * @dataProvider providerForTestLookupResourceUrlAlias - * - * @depends testLookup - * - * @group resource */ + #[Depends('testLookup')] + #[Group('resource')] + #[DataProvider('providerForTestLookupResourceUrlAlias')] public function testLookupResourceUrlAlias( $url, $pathData, @@ -893,7 +885,7 @@ public function testLookupResourceUrlAlias( $alwaysAvailable, $destination, $id - ) { + ): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_resource.php'); @@ -922,13 +914,10 @@ public function testLookupResourceUrlAlias( * Test for the lookup() method. * * Testing that UrlAlias is found and has expected state. - * - * @dataProvider providerForTestLookupResourceUrlAlias - * - * @depends testLookup - * - * @group resource */ + #[Depends('testLookup')] + #[Group('resource')] + #[DataProvider('providerForTestLookupResourceUrlAlias')] public function testLookupResourceUrlAliasCaseInsensitive( $url, $pathData, @@ -937,7 +926,7 @@ public function testLookupResourceUrlAliasCaseInsensitive( $alwaysAvailable, $destination, $id - ) { + ): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_resource.php'); @@ -964,11 +953,9 @@ public function testLookupResourceUrlAliasCaseInsensitive( /** * Test for the lookup() method with uppercase utf8 characters. - * - * - * @depends testLookup */ - public function testLookupUppercaseIri() + #[Depends('testLookup')] + public function testLookupUppercaseIri(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_location_iri.php'); @@ -987,7 +974,7 @@ protected function assertVirtualUrlAliasValid(UrlAlias $urlAlias, $id) /** * Test for the listURLAliasesForLocation() method. */ - public function testListURLAliasesForLocation() + public function testListURLAliasesForLocation(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_location.php'); @@ -1055,12 +1042,10 @@ public function testListURLAliasesForLocation() * Test for the publishUrlAliasForLocation() method. * * @todo document - * - * @depends testLookupLocationUrlAlias - * - * @group publish */ - public function testPublishUrlAliasForLocation() + #[Depends('testLookupLocationUrlAlias')] + #[Group('publish')] + public function testPublishUrlAliasForLocation(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/publish_base.php'); @@ -1099,12 +1084,10 @@ public function testPublishUrlAliasForLocation() * Test for the publishUrlAliasForLocation() method. * * @todo document - * - * @depends testPublishUrlAliasForLocation - * - * @group publish */ - public function testPublishUrlAliasForLocationRepublish() + #[Depends('testPublishUrlAliasForLocation')] + #[Group('publish')] + public function testPublishUrlAliasForLocationRepublish(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/publish_base.php'); @@ -1125,12 +1108,10 @@ public function testPublishUrlAliasForLocationRepublish() * Test for the publishUrlAliasForLocation() method. * * @todo document - * - * @depends testPublishUrlAliasForLocation - * - * @group publish */ - public function testPublishUrlAliasCreatesUniqueAlias() + #[Depends('testPublishUrlAliasForLocation')] + #[Group('publish')] + public function testPublishUrlAliasCreatesUniqueAlias(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/publish_base.php'); @@ -1168,22 +1149,19 @@ public function testPublishUrlAliasCreatesUniqueAlias() /** * @return array */ - public function providerForTestPublishUrlAliasForLocationComplex() + public static function providerForTestPublishUrlAliasForLocationComplex(): array { - return $this->providerForTestLookupLocationUrlAlias(); + return self::providerForTestLookupLocationUrlAlias(); } /** * Test for the publishUrlAliasForLocation() method. * * @todo document - * - * @dataProvider providerForTestPublishUrlAliasForLocationComplex - * - * @depends testPublishUrlAliasForLocation - * - * @group publish */ + #[Depends('testPublishUrlAliasForLocation')] + #[Group('publish')] + #[DataProvider('providerForTestPublishUrlAliasForLocationComplex')] public function testPublishUrlAliasForLocationComplex( $url, $pathData, @@ -1191,7 +1169,7 @@ public function testPublishUrlAliasForLocationComplex( $alwaysAvailable, $locationId, $id - ) { + ): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/publish_base.php'); @@ -1227,12 +1205,10 @@ public function testPublishUrlAliasForLocationComplex( * Test for the publishUrlAliasForLocation() method. * * @todo document - * - * @depends testPublishUrlAliasForLocation - * - * @group publish */ - public function testPublishUrlAliasForLocationSameAliasForMultipleLanguages() + #[Depends('testPublishUrlAliasForLocation')] + #[Group('publish')] + public function testPublishUrlAliasForLocationSameAliasForMultipleLanguages(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/publish_base.php'); @@ -1276,12 +1252,10 @@ public function testPublishUrlAliasForLocationSameAliasForMultipleLanguages() * Test for the publishUrlAliasForLocation() method. * * @todo document - * - * @depends testPublishUrlAliasForLocation - * - * @group publish */ - public function testPublishUrlAliasForLocationDowngradesOldEntryToHistory() + #[Depends('testPublishUrlAliasForLocation')] + #[Group('publish')] + public function testPublishUrlAliasForLocationDowngradesOldEntryToHistory(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/publish_base.php'); @@ -1348,14 +1322,12 @@ public function testPublishUrlAliasForLocationDowngradesOldEntryToHistory() * Test for the publishUrlAliasForLocation() method. * * @todo document - * - * @depends testPublishUrlAliasForLocation - * @depends testPublishUrlAliasForLocationSameAliasForMultipleLanguages - * - * @group publish - * @group downgrade */ - public function testPublishUrlAliasForLocationDowngradesOldEntryRemovesLanguage() + #[Depends('testPublishUrlAliasForLocation')] + #[Depends('testPublishUrlAliasForLocationSameAliasForMultipleLanguages')] + #[Group('publish')] + #[Group('downgrade')] + public function testPublishUrlAliasForLocationDowngradesOldEntryRemovesLanguage(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/publish_base.php'); @@ -1423,13 +1395,11 @@ public function testPublishUrlAliasForLocationDowngradesOldEntryRemovesLanguage( * Test for the publishUrlAliasForLocation() method. * * @todo document - * - * @depends testPublishUrlAliasForLocation - * @depends testPublishUrlAliasForLocationDowngradesOldEntryToHistory - * - * @group publish */ - public function testPublishUrlAliasForLocationReusesHistory() + #[Depends('testPublishUrlAliasForLocation')] + #[Depends('testPublishUrlAliasForLocationDowngradesOldEntryToHistory')] + #[Group('publish')] + public function testPublishUrlAliasForLocationReusesHistory(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/publish_base.php'); @@ -1456,13 +1426,11 @@ public function testPublishUrlAliasForLocationReusesHistory() * Test for the publishUrlAliasForLocation() method. * * @todo document - * - * @depends testPublishUrlAliasForLocation - * @depends testPublishUrlAliasForLocationDowngradesOldEntryToHistory - * - * @group publish */ - public function testPublishUrlAliasForLocationReusesHistoryOfDifferentLanguage() + #[Depends('testPublishUrlAliasForLocation')] + #[Depends('testPublishUrlAliasForLocationDowngradesOldEntryToHistory')] + #[Group('publish')] + public function testPublishUrlAliasForLocationReusesHistoryOfDifferentLanguage(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/publish_base.php'); @@ -1509,12 +1477,10 @@ public function testPublishUrlAliasForLocationReusesHistoryOfDifferentLanguage() * Test for the publishUrlAliasForLocation() method. * * @todo document - * - * @depends testPublishUrlAliasForLocation - * - * @group publish */ - public function testPublishUrlAliasForLocationReusesCustomAlias() + #[Depends('testPublishUrlAliasForLocation')] + #[Group('publish')] + public function testPublishUrlAliasForLocationReusesCustomAlias(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_reusing.php'); @@ -1534,10 +1500,9 @@ public function testPublishUrlAliasForLocationReusesCustomAlias() * Test for the publishUrlAliasForLocation() method. * * @todo document - * - * @depends testPublishUrlAliasForLocation */ - public function testPublishUrlAliasForLocationReusingNopElement() + #[Depends('testPublishUrlAliasForLocation')] + public function testPublishUrlAliasForLocationReusingNopElement(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_reusing.php'); @@ -1604,11 +1569,10 @@ public function testPublishUrlAliasForLocationReusingNopElement() * Test for the publishUrlAliasForLocation() method. * * @todo document - * - * @depends testPublishUrlAliasForLocation - * @depends testPublishUrlAliasForLocationReusingNopElement */ - public function testPublishUrlAliasForLocationReusingNopElementChangesCustomPath() + #[Depends('testPublishUrlAliasForLocation')] + #[Depends('testPublishUrlAliasForLocationReusingNopElement')] + public function testPublishUrlAliasForLocationReusingNopElementChangesCustomPath(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_reusing.php'); @@ -1652,11 +1616,10 @@ public function testPublishUrlAliasForLocationReusingNopElementChangesCustomPath * Test for the publishUrlAliasForLocation() method. * * @todo document - * - * @depends testPublishUrlAliasForLocation - * @depends testPublishUrlAliasForLocationReusingNopElementChangesCustomPath */ - public function testPublishUrlAliasForLocationReusingNopElementChangesCustomPathAndCreatesHistory() + #[Depends('testPublishUrlAliasForLocation')] + #[Depends('testPublishUrlAliasForLocationReusingNopElementChangesCustomPath')] + public function testPublishUrlAliasForLocationReusingNopElementChangesCustomPathAndCreatesHistory(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_reusing.php'); @@ -1678,7 +1641,7 @@ public function testPublishUrlAliasForLocationReusingNopElementChangesCustomPath /** * Test for the publishUrlAliasForLocation() method. */ - public function testPublishUrlAliasForLocationUpdatesLocationPathIdentificationString() + public function testPublishUrlAliasForLocationUpdatesLocationPathIdentificationString(): void { $handler = $this->getHandler(); $locationGateway = $this->getLocationGateway(); @@ -1694,10 +1657,9 @@ public function testPublishUrlAliasForLocationUpdatesLocationPathIdentificationS /** * Test for the publishUrlAliasForLocation() method. - * - * @group cleanup */ - public function testPublishUrlAliasReuseNopCleanupCustomAliasIsDestroyed() + #[Group('cleanup')] + public function testPublishUrlAliasReuseNopCleanupCustomAliasIsDestroyed(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_cleanup_nop.php'); @@ -1768,10 +1730,9 @@ public function testPublishUrlAliasReuseNopCleanupCustomAliasIsDestroyed() /** * Test for the publishUrlAliasForLocation() method. - * - * @group cleanup */ - public function testPublishUrlAliasReuseHistoryCleanup() + #[Group('cleanup')] + public function testPublishUrlAliasReuseHistoryCleanup(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_cleanup_history.php'); @@ -1832,10 +1793,9 @@ public function testPublishUrlAliasReuseHistoryCleanup() /** * Test for the publishUrlAliasForLocation() method. - * - * @group cleanup */ - public function testPublishUrlAliasReuseAutogeneratedCleanup() + #[Group('cleanup')] + public function testPublishUrlAliasReuseAutogeneratedCleanup(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_cleanup_reusing.php'); @@ -1897,12 +1857,10 @@ public function testPublishUrlAliasReuseAutogeneratedCleanup() /** * Test for the createCustomUrlAlias() method. - * - * - * @group create - * @group custom */ - public function testCreateCustomUrlAliasBehaviour() + #[Group('create')] + #[Group('custom')] + public function testCreateCustomUrlAliasBehaviour(): void { $handlerMock = $this->getPartlyMockedHandler(['createUrlAlias']); @@ -1930,12 +1888,10 @@ public function testCreateCustomUrlAliasBehaviour() /** * Test for the createGlobalUrlAlias() method. - * - * - * @group create - * @group global */ - public function testCreateGlobalUrlAliasBehaviour() + #[Group('create')] + #[Group('global')] + public function testCreateGlobalUrlAliasBehaviour(): void { $handlerMock = $this->getPartlyMockedHandler(['createUrlAlias']); @@ -1963,12 +1919,10 @@ public function testCreateGlobalUrlAliasBehaviour() /** * Test for the createUrlAlias() method. - * - * - * @group create - * @group custom */ - public function testCreateCustomUrlAlias() + #[Group('create')] + #[Group('custom')] + public function testCreateCustomUrlAlias(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/publish_base.php'); @@ -2010,12 +1964,10 @@ public function testCreateCustomUrlAlias() /** * Test for the createUrlAlias() method. - * - * - * @group create - * @group custom */ - public function testCreateCustomUrlAliasWithNonameParts() + #[Group('create')] + #[Group('custom')] + public function testCreateCustomUrlAliasWithNonameParts(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/publish_base.php'); @@ -2084,12 +2036,12 @@ public function testCreateCustomUrlAliasWithNonameParts() * Test for the createUrlAlias() method. * * - * @group create - * @group custom * * @todo pathData */ - public function testCreatedCustomUrlAliasIsLoadable() + #[Group('create')] + #[Group('custom')] + public function testCreatedCustomUrlAliasIsLoadable(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/publish_base.php'); @@ -2128,11 +2080,9 @@ public function testCreatedCustomUrlAliasIsLoadable() /** * Test for the createUrlAlias() method. - * - * - * @group create - * @group custom */ + #[Group('create')] + #[Group('custom')] public function testCreateCustomUrlAliasWithNopElement(): void { $handler = $this->getHandler(); @@ -2190,12 +2140,10 @@ public function testCreateCustomUrlAliasWithNopElement(): void /** * Test for the createUrlAlias() method. - * - * - * @group create - * @group custom */ - public function testCreateCustomUrlAliasReusesHistory() + #[Group('create')] + #[Group('custom')] + public function testCreateCustomUrlAliasReusesHistory(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_reusing.php'); @@ -2236,10 +2184,8 @@ public function testCreateCustomUrlAliasReusesHistory() ); } - /** - * @group create - * @group custom - */ + #[Group('create')] + #[Group('custom')] public function testCreateCustomUrlAliasAddLanguage(): void { $handler = $this->getHandler(); @@ -2289,12 +2235,10 @@ public function testCreateCustomUrlAliasAddLanguage(): void /** * Test for the createUrlAlias() method. - * - * - * @group create - * @group custom */ - public function testCreateCustomUrlAliasReusesHistoryOfDifferentLanguage() + #[Group('create')] + #[Group('custom')] + public function testCreateCustomUrlAliasReusesHistoryOfDifferentLanguage(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_reusing.php'); @@ -2337,12 +2281,10 @@ public function testCreateCustomUrlAliasReusesHistoryOfDifferentLanguage() /** * Test for the createUrlAlias() method. - * - * - * @group create - * @group custom */ - public function testCreateCustomUrlAliasReusesNopElement() + #[Group('create')] + #[Group('custom')] + public function testCreateCustomUrlAliasReusesNopElement(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_reusing.php'); @@ -2391,12 +2333,10 @@ public function testCreateCustomUrlAliasReusesNopElement() /** * Test for the createUrlAlias() method. - * - * - * @group create - * @group custom */ - public function testCreateCustomUrlAliasReusesLocationElement() + #[Group('create')] + #[Group('custom')] + public function testCreateCustomUrlAliasReusesLocationElement(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_reusing.php'); @@ -2425,11 +2365,9 @@ public function testCreateCustomUrlAliasReusesLocationElement() /** * Test for the listGlobalURLAliases() method. - * - * - * @depends testLookupResourceUrlAlias */ - public function testListGlobalURLAliases() + #[Depends('testLookupResourceUrlAlias')] + public function testListGlobalURLAliases(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_resource.php'); @@ -2448,11 +2386,9 @@ public function testListGlobalURLAliases() /** * Test for the listGlobalURLAliases() method. - * - * - * @depends testLookupResourceUrlAlias */ - public function testListGlobalURLAliasesWithLanguageCode() + #[Depends('testLookupResourceUrlAlias')] + public function testListGlobalURLAliasesWithLanguageCode(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_resource.php'); @@ -2470,11 +2406,9 @@ public function testListGlobalURLAliasesWithLanguageCode() /** * Test for the listGlobalURLAliases() method. - * - * - * @depends testLookupResourceUrlAlias */ - public function testListGlobalURLAliasesWithOffset() + #[Depends('testLookupResourceUrlAlias')] + public function testListGlobalURLAliasesWithOffset(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_resource.php'); @@ -2491,11 +2425,9 @@ public function testListGlobalURLAliasesWithOffset() /** * Test for the listGlobalURLAliases() method. - * - * - * @depends testLookupResourceUrlAlias */ - public function testListGlobalURLAliasesWithOffsetAndLimit() + #[Depends('testLookupResourceUrlAlias')] + public function testListGlobalURLAliasesWithOffsetAndLimit(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_resource.php'); @@ -2513,7 +2445,7 @@ public function testListGlobalURLAliasesWithOffsetAndLimit() /** * Test for the locationDeleted() method. */ - public function testLocationDeleted() + public function testLocationDeleted(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_location_delete.php'); @@ -2566,7 +2498,7 @@ public function testLocationDeleted() /** * Test for the locationMoved() method. */ - public function testLocationMovedHistorize() + public function testLocationMovedHistorize(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_move.php'); @@ -2601,7 +2533,7 @@ public function testLocationMovedHistorize() /** * Test for the locationMoved() method. */ - public function testLocationMovedHistory() + public function testLocationMovedHistory(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_move.php'); @@ -2636,7 +2568,7 @@ public function testLocationMovedHistory() /** * Test for the locationMoved() method. */ - public function testLocationMovedHistorySubtree() + public function testLocationMovedHistorySubtree(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_move.php'); @@ -2679,7 +2611,7 @@ public function testLocationMovedHistorySubtree() /** * Test for the locationMoved() method. */ - public function testLocationMovedReparent() + public function testLocationMovedReparent(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_move.php'); @@ -2722,7 +2654,7 @@ public function testLocationMovedReparent() /** * Test for the locationMoved() method. */ - public function testLocationMovedReparentHistory() + public function testLocationMovedReparentHistory(): void { $this->expectException(NotFoundException::class); @@ -2738,7 +2670,7 @@ public function testLocationMovedReparentHistory() /** * Test for the locationMoved() method. */ - public function testLocationMovedReparentSubtree() + public function testLocationMovedReparentSubtree(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_move.php'); @@ -2785,7 +2717,7 @@ public function testLocationMovedReparentSubtree() /** * Test for the locationMoved() method. */ - public function testLocationMovedReparentSubtreeHistory() + public function testLocationMovedReparentSubtreeHistory(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_move.php'); @@ -2899,7 +2831,7 @@ public function testLocationMovedReparentWithCustomAlias(): void /** * Test for the locationCopied() method. */ - public function testLocationCopiedCopiedLocationAliasIsValid() + public function testLocationCopiedCopiedLocationAliasIsValid(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_copy.php'); @@ -2917,7 +2849,7 @@ public function testLocationCopiedCopiedLocationAliasIsValid() /** * Test for the locationCopied() method. */ - public function testLocationCopiedCopiedSubtreeIsValid() + public function testLocationCopiedCopiedSubtreeIsValid(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_copy.php'); @@ -2935,7 +2867,7 @@ public function testLocationCopiedCopiedSubtreeIsValid() /** * Test for the locationCopied() method. */ - public function testLocationCopiedHistoryNotCopied() + public function testLocationCopiedHistoryNotCopied(): void { $this->expectException(NotFoundException::class); @@ -2950,7 +2882,7 @@ public function testLocationCopiedHistoryNotCopied() /** * Test for the locationCopied() method. */ - public function testLocationCopiedSubtreeHistoryNotCopied() + public function testLocationCopiedSubtreeHistoryNotCopied(): void { $this->expectException(NotFoundException::class); @@ -2965,7 +2897,7 @@ public function testLocationCopiedSubtreeHistoryNotCopied() /** * Test for the locationCopied() method. */ - public function testLocationCopiedSubtree() + public function testLocationCopiedSubtree(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_copy.php'); @@ -3017,10 +2949,8 @@ public function testLocationCopiedSubtree() /** * Test for the loadUrlAlias() method. - * - * - * @dataProvider providerForTestLookupLocationMultipleLanguages */ + #[DataProvider('providerForTestLookupLocationMultipleLanguages')] public function testLoadAutogeneratedUrlAlias( $url, array $pathData, @@ -3028,7 +2958,7 @@ public function testLoadAutogeneratedUrlAlias( $alwaysAvailable, $locationId, $id - ) { + ): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_location_multilang.php'); @@ -3055,10 +2985,8 @@ public function testLoadAutogeneratedUrlAlias( /** * Test for the loadUrlAlias() method. - * - * - * @dataProvider providerForTestLookupResourceUrlAlias */ + #[DataProvider('providerForTestLookupResourceUrlAlias')] public function testLoadResourceUrlAlias( $url, $pathData, @@ -3067,7 +2995,7 @@ public function testLoadResourceUrlAlias( $alwaysAvailable, $destination, $id - ) { + ): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_resource.php'); @@ -3094,11 +3022,9 @@ public function testLoadResourceUrlAlias( /** * Test for the loadUrlAlias() method. - * - * - * @dataProvider providerForTestLookupVirtualUrlAlias */ - public function testLoadVirtualUrlAlias($url, $id) + #[DataProvider('providerForTestLookupVirtualUrlAlias')] + public function testLoadVirtualUrlAlias($url, $id): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_location_custom.php'); @@ -3146,7 +3072,7 @@ protected function getHistoryAlias() /** * Test for the loadUrlAlias() method. */ - public function testLoadHistoryUrlAlias() + public function testLoadHistoryUrlAlias(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_location.php'); @@ -3163,7 +3089,7 @@ public function testLoadHistoryUrlAlias() /** * Test for the loadUrlAlias() method. */ - public function testLoadUrlAliasThrowsNotFoundException() + public function testLoadUrlAliasThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -3172,7 +3098,10 @@ public function testLoadUrlAliasThrowsNotFoundException() $handler->loadUrlAlias('non-existent'); } - public function providerForTestPublishUrlAliasForLocationSkipsReservedWord() + /** + * @return array + */ + public static function providerForTestPublishUrlAliasForLocationSkipsReservedWord(): array { return [ [ @@ -3188,14 +3117,10 @@ public function providerForTestPublishUrlAliasForLocationSkipsReservedWord() /** * Test for the publishUrlAliasForLocation() method. - * - * @dataProvider providerForTestPublishUrlAliasForLocationSkipsReservedWord - * - * @covers \Ibexa\Core\Persistence\Legacy\Content\UrlAlias\Handler::publishUrlAliasForLocation - * - * @group publish */ - public function testPublishUrlAliasForLocationSkipsReservedWord($text, $alias) + #[Group('publish')] + #[DataProvider('providerForTestPublishUrlAliasForLocationSkipsReservedWord')] + public function testPublishUrlAliasForLocationSkipsReservedWord($text, $alias): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/publish_base.php'); @@ -3210,10 +3135,9 @@ public function testPublishUrlAliasForLocationSkipsReservedWord($text, $alias) /** * Test for the locationSwapped() method. - * - * @group swap */ - public function testLocationSwappedSimple() + #[Group('swap')] + public function testLocationSwappedSimple(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_swap_simple.php'); @@ -3296,10 +3220,9 @@ public function testLocationSwappedSimple() /** * Test for the locationSwapped() method. - * - * @group swap */ - public function testLocationSwappedSimpleWithHistory() + #[Group('swap')] + public function testLocationSwappedSimpleWithHistory(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_swap_simple_history.php'); @@ -3448,10 +3371,9 @@ public function testLocationSwappedSimpleWithHistory() /** * Test for the locationSwapped() method. - * - * @group swap */ - public function testLocationSwappedSimpleWithConflict() + #[Group('swap')] + public function testLocationSwappedSimpleWithConflict(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_swap_simple_conflict.php'); @@ -3554,10 +3476,9 @@ public function testLocationSwappedSimpleWithConflict() /** * Test for the locationSwapped() method. - * - * @group swap */ - public function testLocationSwappedSiblingsSimple() + #[Group('swap')] + public function testLocationSwappedSiblingsSimple(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_swap_siblings_simple.php'); @@ -3628,10 +3549,9 @@ public function testLocationSwappedSiblingsSimple() /** * Test for the locationSwapped() method. - * - * @group swap */ - public function testLocationSwappedSiblingsSimpleReverse() + #[Group('swap')] + public function testLocationSwappedSiblingsSimpleReverse(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_swap_siblings_simple.php'); @@ -3702,10 +3622,9 @@ public function testLocationSwappedSiblingsSimpleReverse() /** * Test for the locationSwapped() method. - * - * @group swap */ - public function testLocationSwappedSiblingsSimpleWithHistory() + #[Group('swap')] + public function testLocationSwappedSiblingsSimpleWithHistory(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_swap_siblings_simple_history.php'); @@ -3830,10 +3749,9 @@ public function testLocationSwappedSiblingsSimpleWithHistory() /** * Test for the locationSwapped() method. - * - * @group swap */ - public function testLocationSwappedSiblingsSimpleWithHistoryReverse() + #[Group('swap')] + public function testLocationSwappedSiblingsSimpleWithHistoryReverse(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_swap_siblings_simple_history.php'); @@ -3958,10 +3876,9 @@ public function testLocationSwappedSiblingsSimpleWithHistoryReverse() /** * Test for the locationSwapped() method. - * - * @group swap */ - public function testLocationSwappedSiblingsSameName() + #[Group('swap')] + public function testLocationSwappedSiblingsSameName(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_swap_siblings_same_name.php'); @@ -4032,10 +3949,9 @@ public function testLocationSwappedSiblingsSameName() /** * Test for the locationSwapped() method. - * - * @group swap */ - public function testLocationSwappedSiblingsSameNameReverse() + #[Group('swap')] + public function testLocationSwappedSiblingsSameNameReverse(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_swap_siblings_same_name.php'); @@ -4106,10 +4022,9 @@ public function testLocationSwappedSiblingsSameNameReverse() /** * Test for the locationSwapped() method. - * - * @group swap */ - public function testLocationSwappedSiblingsSameNameMultipleLanguages() + #[Group('swap')] + public function testLocationSwappedSiblingsSameNameMultipleLanguages(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_swap_siblings_same_name_multilang.php'); @@ -4238,10 +4153,9 @@ public function testLocationSwappedSiblingsSameNameMultipleLanguages() /** * Test for the locationSwapped() method. - * - * @group swap */ - public function testLocationSwappedMultipleLanguagesSimple() + #[Group('swap')] + public function testLocationSwappedMultipleLanguagesSimple(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_swap_multilang_simple.php'); @@ -4273,10 +4187,9 @@ public function testLocationSwappedMultipleLanguagesSimple() /** * Test for the locationSwapped() method. - * - * @group swap */ - public function testLocationSwappedMultipleLanguagesDifferentLanguagesSimple() + #[Group('swap')] + public function testLocationSwappedMultipleLanguagesDifferentLanguagesSimple(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_swap_multilang_diff_simple.php'); @@ -4495,10 +4408,9 @@ public function testLocationSwappedMultipleLanguagesDifferentLanguagesSimple() /** * Test for the locationSwapped() method. - * - * @group swap */ - public function testLocationSwappedMultipleLanguagesDifferentLanguages() + #[Group('swap')] + public function testLocationSwappedMultipleLanguagesDifferentLanguages(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_swap_multilang_diff.php'); @@ -4653,10 +4565,9 @@ public function testLocationSwappedMultipleLanguagesDifferentLanguages() /** * Test for the locationSwapped() method. - * - * @group swap */ - public function testLocationSwappedMultipleLanguagesWithCompositeHistory() + #[Group('swap')] + public function testLocationSwappedMultipleLanguagesWithCompositeHistory(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_swap_multilang_cleanup_composite.php'); @@ -4946,10 +4857,9 @@ public function testLocationSwappedMultipleLanguagesWithCompositeHistory() /** * Test for the locationSwapped() method. - * - * @group swap */ - public function testLocationSwappedWithReusingExternalHistory() + #[Group('swap')] + public function testLocationSwappedWithReusingExternalHistory(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_swap_reusing_external_history.php'); @@ -5098,10 +5008,9 @@ public function testLocationSwappedWithReusingExternalHistory() /** * Test for the locationSwapped() method. - * - * @group swap */ - public function testLocationSwappedWithReusingNopEntry() + #[Group('swap')] + public function testLocationSwappedWithReusingNopEntry(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_swap_reusing_nop.php'); @@ -5250,12 +5159,10 @@ public function testLocationSwappedWithReusingNopEntry() /** * Test for the locationSwapped() method. - * - * @depends testLocationSwappedWithReusingNopEntry - * - * @group swap */ - public function testLocationSwappedWithReusingNopEntryCustomAliasIsDestroyed() + #[Depends('testLocationSwappedWithReusingNopEntry')] + #[Group('swap')] + public function testLocationSwappedWithReusingNopEntryCustomAliasIsDestroyed(): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_swap_reusing_nop.php'); @@ -5275,10 +5182,9 @@ public function testLocationSwappedWithReusingNopEntryCustomAliasIsDestroyed() /** * Test for the locationSwapped() method. - * - * @group swap */ - public function testLocationSwappedUpdatesLocationPathIdentificationString() + #[Group('swap')] + public function testLocationSwappedUpdatesLocationPathIdentificationString(): void { $handler = $this->getHandler(); $locationGateway = $this->getLocationGateway(); @@ -5302,10 +5208,9 @@ public function testLocationSwappedUpdatesLocationPathIdentificationString() /** * Test for the locationSwapped() method. - * - * @group swap */ - public function testLocationSwappedMultipleLanguagesUpdatesLocationPathIdentificationString() + #[Group('swap')] + public function testLocationSwappedMultipleLanguagesUpdatesLocationPathIdentificationString(): void { $handler = $this->getHandler(); $locationGateway = $this->getLocationGateway(); @@ -5359,17 +5264,17 @@ protected function getPartlyMockedHandler(array $methods) return $this->getMockBuilder(Handler::class) ->setConstructorArgs( [ - $this->createMock(UrlAliasGateway::class), - $this->createMock(Mapper::class), - $this->createMock(LocationGateway::class), - $this->createMock(LanguageHandler::class), - $this->createMock(SlugConverter::class), - $this->createMock(Gateway::class), - $this->createMock(LanguageMaskGenerator::class), - $this->createMock(TransactionHandler::class), + self::createStub(UrlAliasGateway::class), + self::createStub(Mapper::class), + self::createStub(LocationGateway::class), + self::createStub(LanguageHandler::class), + self::createStub(SlugConverter::class), + self::createStub(Gateway::class), + self::createStub(LanguageMaskGenerator::class), + self::createStub(TransactionHandler::class), ] ) - ->setMethods($methods) + ->onlyMethods(array_values($methods)) ->getMock(); } @@ -5405,7 +5310,7 @@ protected function getHandler(): Handler $slugConverter, $contentGateway, $languageMaskGenerator, - $this->createMock(TransactionHandler::class) + self::createStub(TransactionHandler::class) ); } @@ -5477,7 +5382,7 @@ public function getProcessor() * * @return array */ - public function providerForArchiveUrlAliasesForDeletedTranslations() + public static function providerForArchiveUrlAliasesForDeletedTranslations(): array { return [ [2, ['eng-GB', 'pol-PL'], 'pol-PL'], @@ -5486,17 +5391,16 @@ public function providerForArchiveUrlAliasesForDeletedTranslations() } /** - * @dataProvider providerForArchiveUrlAliasesForDeletedTranslations - * * @param int $locationId * @param string[] $expectedLanguages expected language codes before deleting * @param string $removeLanguage language code to be deleted */ + #[DataProvider('providerForArchiveUrlAliasesForDeletedTranslations')] public function testArchiveUrlAliasesForDeletedTranslations( $locationId, array $expectedLanguages, $removeLanguage - ) { + ): void { $handler = $this->getHandler(); $this->insertDatabaseFixture(__DIR__ . '/_fixtures/publish_multilingual.php'); diff --git a/tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasMapperTest.php b/tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasMapperTest.php index 1831d801aa..c9c6c4681d 100644 --- a/tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasMapperTest.php +++ b/tests/lib/Persistence/Legacy/Content/UrlAlias/UrlAliasMapperTest.php @@ -11,10 +11,11 @@ use Ibexa\Core\Persistence\Legacy\Content\Language\MaskGenerator as LanguageMaskGenerator; use Ibexa\Core\Persistence\Legacy\Content\UrlAlias\Mapper; use Ibexa\Tests\Core\Persistence\Legacy\Content\LanguageAwareTestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\UrlAlias\Mapper - */ +#[CoversClass(Mapper::class)] class UrlAliasMapperTest extends LanguageAwareTestCase { protected $fixture = [ @@ -229,17 +230,19 @@ protected function getExpectation() ]; } - public function providerForTestExtractUrlAliasFromData() + /** + * @return array + */ + public static function providerForTestExtractUrlAliasFromData(): array { return [[0], [1], [2], [3]]; } /** * Test for the extractUrlAliasFromData() method. - * - * @dataProvider providerForTestExtractUrlAliasFromData */ - public function testExtractUrlAliasFromData($index) + #[DataProvider('providerForTestExtractUrlAliasFromData')] + public function testExtractUrlAliasFromData($index): void { $mapper = $this->getMapper(); @@ -254,10 +257,9 @@ public function testExtractUrlAliasFromData($index) /** * Test for the extractUrlAliasListFromData() method. - * - * @depends testExtractUrlAliasFromData */ - public function testExtractUrlAliasListFromData() + #[Depends('testExtractUrlAliasFromData')] + public function testExtractUrlAliasListFromData(): void { $mapper = $this->getMapper(); @@ -270,7 +272,7 @@ public function testExtractUrlAliasListFromData() /** * Test for the extractLanguageCodesFromData method. */ - public function testExtractLanguageCodesFromData() + public function testExtractLanguageCodesFromData(): void { $mapper = $this->getMapper(); diff --git a/tests/lib/Persistence/Legacy/Content/UrlWildcard/Gateway/DoctrineDatabaseTest.php b/tests/lib/Persistence/Legacy/Content/UrlWildcard/Gateway/DoctrineDatabaseTest.php index 80fa3a7c28..ff5a993173 100644 --- a/tests/lib/Persistence/Legacy/Content/UrlWildcard/Gateway/DoctrineDatabaseTest.php +++ b/tests/lib/Persistence/Legacy/Content/UrlWildcard/Gateway/DoctrineDatabaseTest.php @@ -13,10 +13,10 @@ use Ibexa\Core\Persistence\Legacy\Content\UrlWildcard\Query\CriteriaConverter; use Ibexa\Core\Persistence\Legacy\Content\UrlWildcard\Query\CriterionHandler\MatchAll; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Depends; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\UrlWildcard\Gateway\DoctrineDatabase - */ +#[CoversClass(DoctrineDatabase::class)] class DoctrineDatabaseTest extends TestCase { /** @@ -50,7 +50,7 @@ class DoctrineDatabaseTest extends TestCase /** * Test for the loadUrlWildcardData() method. */ - public function testLoadUrlWildcardData() + public function testLoadUrlWildcardData(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlwildcards.php'); $gateway = $this->getGateway(); @@ -66,7 +66,7 @@ public function testLoadUrlWildcardData() /** * Test for the loadUrlWildcardsData() method. */ - public function testLoadUrlWildcardsData() + public function testLoadUrlWildcardsData(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlwildcards.php'); $gateway = $this->getGateway(); @@ -82,7 +82,7 @@ public function testLoadUrlWildcardsData() /** * Test for the loadUrlWildcardsData() method. */ - public function testLoadUrlWildcardsDataWithOffset() + public function testLoadUrlWildcardsDataWithOffset(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlwildcards.php'); $gateway = $this->getGateway(); @@ -101,7 +101,7 @@ public function testLoadUrlWildcardsDataWithOffset() /** * Test for the loadUrlWildcardsData() method. */ - public function testLoadUrlWildcardsDataWithOffsetAndLimit() + public function testLoadUrlWildcardsDataWithOffsetAndLimit(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlwildcards.php'); $gateway = $this->getGateway(); @@ -118,10 +118,9 @@ public function testLoadUrlWildcardsDataWithOffsetAndLimit() /** * Test for the insertUrlWildcard() method. - * - * @depends testLoadUrlWildcardData */ - public function testInsertUrlWildcard() + #[Depends('testLoadUrlWildcardData')] + public function testInsertUrlWildcard(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlwildcards.php'); $gateway = $this->getGateway(); @@ -149,10 +148,9 @@ public function testInsertUrlWildcard() /** * Test for the deleteUrlWildcard() method. - * - * @depends testLoadUrlWildcardData */ - public function testDeleteUrlWildcard() + #[Depends('testLoadUrlWildcardData')] + public function testDeleteUrlWildcard(): void { $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlwildcards.php'); $gateway = $this->getGateway(); diff --git a/tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardHandlerTest.php b/tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardHandlerTest.php index 0662322bd3..83a1bde9d2 100644 --- a/tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardHandlerTest.php +++ b/tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardHandlerTest.php @@ -16,13 +16,13 @@ use Ibexa\Core\Persistence\Legacy\Content\UrlWildcard\Query\CriteriaConverter; use Ibexa\Core\Persistence\Legacy\Content\UrlWildcard\Query\CriterionHandler\MatchAll; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Depends; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\UrlWildcard\Handler - */ +#[CoversClass(Handler::class)] class UrlWildcardHandlerTest extends TestCase { - public function testLoad() + public function testLoad(): void { $this->insertDatabaseFixture(__DIR__ . '/Gateway/_fixtures/urlwildcards.php'); $handler = $this->getHandler(); @@ -45,7 +45,7 @@ public function testLoad() /** * Test for the load() method. */ - public function testLoadThrowsNotFoundException() + public function testLoadThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -57,11 +57,9 @@ public function testLoadThrowsNotFoundException() /** * Test for the create() method. - * - * - * @depends testLoad */ - public function testCreate() + #[Depends('testLoad')] + public function testCreate(): void { $this->insertDatabaseFixture(__DIR__ . '/Gateway/_fixtures/urlwildcards.php'); $handler = $this->getHandler(); @@ -90,9 +88,7 @@ public function testCreate() ); } - /** - * @depends testLoad - */ + #[Depends('testLoad')] public function testUpdate(): void { $this->insertDatabaseFixture(__DIR__ . '/Gateway/_fixtures/urlwildcards.php'); @@ -127,10 +123,9 @@ public function testUpdate(): void /** * Test for the remove() method. - * - * @depends testLoad */ - public function testRemove() + #[Depends('testLoad')] + public function testRemove(): void { $this->expectException(NotFoundException::class); @@ -144,7 +139,7 @@ public function testRemove() /** * Test for the loadAll() method. */ - public function testLoadAll() + public function testLoadAll(): void { $this->insertDatabaseFixture(__DIR__ . '/Gateway/_fixtures/urlwildcards.php'); $handler = $this->getHandler(); @@ -164,7 +159,7 @@ public function testLoadAll() /** * Test for the loadAll() method. */ - public function testLoadAllWithOffset() + public function testLoadAllWithOffset(): void { $this->insertDatabaseFixture(__DIR__ . '/Gateway/_fixtures/urlwildcards.php'); $handler = $this->getHandler(); @@ -182,7 +177,7 @@ public function testLoadAllWithOffset() /** * Test for the loadAll() method. */ - public function testLoadAllWithOffsetAndLimit() + public function testLoadAllWithOffsetAndLimit(): void { $this->insertDatabaseFixture(__DIR__ . '/Gateway/_fixtures/urlwildcards.php'); $handler = $this->getHandler(); diff --git a/tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardMapperTest.php b/tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardMapperTest.php index 3f334bed5b..3e8c46e244 100644 --- a/tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardMapperTest.php +++ b/tests/lib/Persistence/Legacy/Content/UrlWildcard/UrlWildcardMapperTest.php @@ -10,16 +10,15 @@ use Ibexa\Contracts\Core\Persistence\Content\UrlWildcard; use Ibexa\Core\Persistence\Legacy\Content\UrlWildcard\Mapper; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Content\UrlWildcard\Mapper - */ +#[CoversClass(Mapper::class)] class UrlWildcardMapperTest extends TestCase { /** * Test for the createUrlWildcard() method. */ - public function testCreateUrlWildcard() + public function testCreateUrlWildcard(): void { $mapper = $this->getMapper(); @@ -45,7 +44,7 @@ public function testCreateUrlWildcard() /** * Test for the extractUrlWildcardFromRow() method. */ - public function testExtractUrlWildcardFromRow() + public function testExtractUrlWildcardFromRow(): void { $mapper = $this->getMapper(); $row = [ @@ -73,7 +72,7 @@ public function testExtractUrlWildcardFromRow() /** * Test for the extractUrlWildcardFromRow() method. */ - public function testExtractUrlWildcardsFromRows() + public function testExtractUrlWildcardsFromRows(): void { $mapper = $this->getMapper(); $rows = [ diff --git a/tests/lib/Persistence/Legacy/FieldValue/Converter/ImageConverterTest.php b/tests/lib/Persistence/Legacy/FieldValue/Converter/ImageConverterTest.php index 63f2e0f41f..988467f9be 100644 --- a/tests/lib/Persistence/Legacy/FieldValue/Converter/ImageConverterTest.php +++ b/tests/lib/Persistence/Legacy/FieldValue/Converter/ImageConverterTest.php @@ -14,6 +14,7 @@ use Ibexa\Core\IO\Values\BinaryFile; use Ibexa\Core\Persistence\Legacy\Content\FieldValue\Converter\ImageConverter; use Ibexa\Core\Persistence\Legacy\Content\StorageFieldValue; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Bridge\PhpUnit\ClockMock; @@ -39,9 +40,7 @@ protected function setUp(): void ); } - /** - * @dataProvider fieldValueToXmlProvider - */ + #[DataProvider('fieldValueToXmlProvider')] public function testToStorageValue(FieldValue $fieldValue, string $expectedXml): void { ClockMock::register(ImageConverter::class); @@ -68,7 +67,7 @@ public function testToStorageValue(FieldValue $fieldValue, string $expectedXml): ClockMock::withClockMock(false); } - public function fieldValueToXmlProvider(): array + public static function fieldValueToXmlProvider(): array { $pathToImg = __DIR__ . '/../_fixtures/ibexa_fav.png'; $dir = __DIR__ . '/../_fixtures'; @@ -132,9 +131,7 @@ public function fieldValueToXmlProvider(): array ]; } - /** - * @dataProvider xmlToFieldValueProvider - */ + #[DataProvider('xmlToFieldValueProvider')] public function testToFieldValue(string $xml, FieldValue $expectedFieldValue): void { ClockMock::register(ImageConverter::class); @@ -162,7 +159,7 @@ public function testToFieldValue(string $xml, FieldValue $expectedFieldValue): v ClockMock::withClockMock(false); } - public function xmlToFieldValueProvider(): array + public static function xmlToFieldValueProvider(): array { $pathToImg = __DIR__ . '/../_fixtures/ibexa_fav.png'; $dir = __DIR__ . '/../_fixtures'; diff --git a/tests/lib/Persistence/Legacy/Filter/BaseCriterionVisitorQueryBuilderTestCase.php b/tests/lib/Persistence/Legacy/Filter/BaseCriterionVisitorQueryBuilderTestCase.php index c6585e001f..2b3fdb7096 100644 --- a/tests/lib/Persistence/Legacy/Filter/BaseCriterionVisitorQueryBuilderTestCase.php +++ b/tests/lib/Persistence/Legacy/Filter/BaseCriterionVisitorQueryBuilderTestCase.php @@ -13,9 +13,18 @@ use Ibexa\Contracts\Core\Persistence\Filter\Doctrine\FilteringQueryBuilder; use Ibexa\Contracts\Core\Repository\Values\Filter\FilteringCriterion; use Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder; +use Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\LogicalAndQueryBuilder; +use Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\LogicalNotQueryBuilder; +use Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\LogicalOrQueryBuilder; use Ibexa\Core\Persistence\Legacy\Filter\CriterionVisitor; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; +#[CoversClass(LogicalAndQueryBuilder::class)] +#[CoversClass(LogicalOrQueryBuilder::class)] +#[CoversClass(LogicalNotQueryBuilder::class)] +#[CoversClass(CriterionVisitor::class)] abstract class BaseCriterionVisitorQueryBuilderTestCase extends TestCase { /** @var \Ibexa\Core\Persistence\Legacy\Filter\CriterionVisitor */ @@ -29,7 +38,7 @@ abstract protected function getCriterionQueryBuilders(): iterable; /** * Data provider for {@see testVisitCriteriaProducesQuery}. */ - abstract public function getFilteringCriteriaQueryData(): iterable; + abstract public static function getFilteringCriteriaQueryData(): iterable; protected function setUp(): void { @@ -43,14 +52,9 @@ protected function setUp(): void } /** - * @dataProvider getFilteringCriteriaQueryData - * - * @covers \Ibexa\Contracts\Core\Repository\Values\Filter\CriterionQueryBuilder::buildQueryConstraint - * @covers \Ibexa\Contracts\Core\Repository\Values\Filter\CriterionQueryBuilder::accepts - * @covers \Ibexa\Core\Persistence\Legacy\Filter\CriterionVisitor::visitCriteria - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\NotImplementedException */ + #[DataProvider('getFilteringCriteriaQueryData')] public function testVisitCriteriaProducesQuery( FilteringCriterion $criterion, string $expectedQuery, diff --git a/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Content/LanguageCodeQueryBuilderQueryBuilderTest.php b/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Content/LanguageCodeQueryBuilderQueryBuilderTest.php index 70f3f71754..ce326b5437 100644 --- a/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Content/LanguageCodeQueryBuilderQueryBuilderTest.php +++ b/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Content/LanguageCodeQueryBuilderQueryBuilderTest.php @@ -11,13 +11,12 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion; use Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\Content\LanguageCodeQueryBuilder; use Ibexa\Tests\Core\Persistence\Legacy\Filter\BaseCriterionVisitorQueryBuilderTestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\Content\LanguageCodeQueryBuilder - */ +#[CoversClass(LanguageCodeQueryBuilder::class)] final class LanguageCodeQueryBuilderQueryBuilderTest extends BaseCriterionVisitorQueryBuilderTestCase { - public function getFilteringCriteriaQueryData(): iterable + public static function getFilteringCriteriaQueryData(): iterable { yield 'Language Code IN (eng-GB, eng-US), match always available' => [ new Criterion\LanguageCode(['eng-GB', 'eng-US']), diff --git a/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Content/Type/ContentTypeGroupIdQueryBuilderTest.php b/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Content/Type/ContentTypeGroupIdQueryBuilderTest.php index b4379d12ef..fed132c333 100644 --- a/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Content/Type/ContentTypeGroupIdQueryBuilderTest.php +++ b/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Content/Type/ContentTypeGroupIdQueryBuilderTest.php @@ -11,13 +11,12 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\ContentTypeGroupId; use Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\Content\Type\GroupIdQueryBuilder; use Ibexa\Tests\Core\Persistence\Legacy\Filter\BaseCriterionVisitorQueryBuilderTestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\Content\Type\GroupIdQueryBuilder - */ +#[CoversClass(GroupIdQueryBuilder::class)] class ContentTypeGroupIdQueryBuilderTest extends BaseCriterionVisitorQueryBuilderTestCase { - public function getFilteringCriteriaQueryData(): iterable + public static function getFilteringCriteriaQueryData(): iterable { yield 'Content type group ID=1' => [ new ContentTypeGroupId(1), diff --git a/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Content/Type/ContentTypeQueryBuildersTest.php b/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Content/Type/ContentTypeQueryBuildersTest.php index cf0b6d1fe3..f94f28ef2f 100644 --- a/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Content/Type/ContentTypeQueryBuildersTest.php +++ b/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Content/Type/ContentTypeQueryBuildersTest.php @@ -12,14 +12,13 @@ use Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\Content\Type\IdentifierQueryBuilder; use Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\Content\Type\IdQueryBuilder; use Ibexa\Tests\Core\Persistence\Legacy\Filter\BaseCriterionVisitorQueryBuilderTestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\Content\Type\IdentifierQueryBuilder - * @covers \Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\Content\Type\IdQueryBuilder - */ +#[CoversClass(IdentifierQueryBuilder::class)] +#[CoversClass(IdQueryBuilder::class)] final class ContentTypeQueryBuildersTest extends BaseCriterionVisitorQueryBuilderTestCase { - public function getFilteringCriteriaQueryData(): iterable + public static function getFilteringCriteriaQueryData(): iterable { yield 'Content type identifier=article' => [ new Criterion\ContentTypeIdentifier('article'), diff --git a/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/AncestorQueryBuilderTest.php b/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/AncestorQueryBuilderTest.php index c344364c4a..651fad364c 100644 --- a/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/AncestorQueryBuilderTest.php +++ b/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/AncestorQueryBuilderTest.php @@ -19,7 +19,7 @@ protected function getCriterionQueryBuilders(): iterable return [new AncestorQueryBuilder()]; } - public function getFilteringCriteriaQueryData(): iterable + public static function getFilteringCriteriaQueryData(): iterable { yield 'Ancestor=/1/2/' => [ new Ancestor('/1/2/'), diff --git a/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/IsBookmarkedQueryBuilderTest.php b/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/IsBookmarkedQueryBuilderTest.php index dcc45fc75c..60420aac90 100644 --- a/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/IsBookmarkedQueryBuilderTest.php +++ b/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/IsBookmarkedQueryBuilderTest.php @@ -13,10 +13,9 @@ use Ibexa\Contracts\Core\Repository\Values\User\UserReference; use Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\Location\IsBookmarkedQueryBuilder; use Ibexa\Tests\Core\Persistence\Legacy\Filter\BaseCriterionVisitorQueryBuilderTestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\Location\IsBookmarkedQueryBuilder - */ +#[CoversClass(IsBookmarkedQueryBuilder::class)] final class IsBookmarkedQueryBuilderTest extends BaseCriterionVisitorQueryBuilderTestCase { private const CURRENT_USER_ID = 14; @@ -29,7 +28,7 @@ final class IsBookmarkedQueryBuilderTest extends BaseCriterionVisitorQueryBuilde * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidCriterionArgumentException */ - public function getFilteringCriteriaQueryData(): iterable + public static function getFilteringCriteriaQueryData(): iterable { yield 'IsBookmarked(true)' => [ new Criterion\Location\IsBookmarked(true), diff --git a/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/LocationIdQueryBuilderTest.php b/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/LocationIdQueryBuilderTest.php index f305e7a407..e88c6a9ec1 100644 --- a/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/LocationIdQueryBuilderTest.php +++ b/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/LocationIdQueryBuilderTest.php @@ -10,14 +10,14 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion; use Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\Location\IdQueryBuilder; +use Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\Location\ParentLocationIdQueryBuilder; use Ibexa\Tests\Core\Persistence\Legacy\Filter\BaseCriterionVisitorQueryBuilderTestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\Location\ParentLocationIdQueryBuilder - */ +#[CoversClass(ParentLocationIdQueryBuilder::class)] final class LocationIdQueryBuilderTest extends BaseCriterionVisitorQueryBuilderTestCase { - public function getFilteringCriteriaQueryData(): iterable + public static function getFilteringCriteriaQueryData(): iterable { yield 'Location ID=1' => [ new Criterion\LocationId(1), diff --git a/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/ParentLocationQueryBuilderTest.php b/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/ParentLocationQueryBuilderTest.php index d1b74ad548..8e86b979dc 100644 --- a/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/ParentLocationQueryBuilderTest.php +++ b/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/Location/ParentLocationQueryBuilderTest.php @@ -11,13 +11,12 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion; use Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\Location\ParentLocationIdQueryBuilder; use Ibexa\Tests\Core\Persistence\Legacy\Filter\BaseCriterionVisitorQueryBuilderTestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\Location\ParentLocationIdQueryBuilder - */ +#[CoversClass(ParentLocationIdQueryBuilder::class)] final class ParentLocationQueryBuilderTest extends BaseCriterionVisitorQueryBuilderTestCase { - public function getFilteringCriteriaQueryData(): iterable + public static function getFilteringCriteriaQueryData(): iterable { yield 'Parent Location ID=1' => [ new Criterion\ParentLocationId(1), diff --git a/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/LogicalOperatorQueryBuilderQueryBuilderTest.php b/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/LogicalOperatorQueryBuilderQueryBuilderTest.php index 8c46ee4156..64d2480406 100644 --- a/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/LogicalOperatorQueryBuilderQueryBuilderTest.php +++ b/tests/lib/Persistence/Legacy/Filter/CriterionQueryBuilder/LogicalOperatorQueryBuilderQueryBuilderTest.php @@ -12,16 +12,18 @@ use Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\Content\ContentIdQueryBuilder; use Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\Content\LanguageCodeQueryBuilder; use Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\Location\ParentLocationIdQueryBuilder; +use Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\LogicalAndQueryBuilder; +use Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\LogicalNotQueryBuilder; +use Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\LogicalOrQueryBuilder; use Ibexa\Tests\Core\Persistence\Legacy\Filter\BaseCriterionVisitorQueryBuilderTestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\LogicalAndQueryBuilder - * @covers \Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\LogicalOrQueryBuilder - * @covers \Ibexa\Core\Persistence\Legacy\Filter\CriterionQueryBuilder\LogicalNotQueryBuilder - */ +#[CoversClass(LogicalAndQueryBuilder::class)] +#[CoversClass(LogicalOrQueryBuilder::class)] +#[CoversClass(LogicalNotQueryBuilder::class)] final class LogicalOperatorQueryBuilderQueryBuilderTest extends BaseCriterionVisitorQueryBuilderTestCase { - public function getFilteringCriteriaQueryData(): iterable + public static function getFilteringCriteriaQueryData(): iterable { yield 'Parent Location ID=1 AND Language Code=eng-GB' => [ new Criterion\LogicalAnd( diff --git a/tests/lib/Persistence/Legacy/Filter/Query/LimitedCountQueryBuilderTest.php b/tests/lib/Persistence/Legacy/Filter/Query/LimitedCountQueryBuilderTest.php index ac9e666a08..6c2d3d78b2 100644 --- a/tests/lib/Persistence/Legacy/Filter/Query/LimitedCountQueryBuilderTest.php +++ b/tests/lib/Persistence/Legacy/Filter/Query/LimitedCountQueryBuilderTest.php @@ -11,10 +11,9 @@ use Ibexa\Core\Base\Exceptions\InvalidArgumentException; use Ibexa\Core\Persistence\Legacy\Filter\Query\LimitedCountQueryBuilder; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Filter\Query\LimitedCountQueryBuilder - */ +#[CoversClass(LimitedCountQueryBuilder::class)] final class LimitedCountQueryBuilderTest extends TestCase { private LimitedCountQueryBuilder $limitedCountQueryBuilder; @@ -35,9 +34,6 @@ public function testWrapThrowsExceptionOnZeroLimit(): void $this->limitedCountQueryBuilder->wrap($qb, 'someField', 0); } - /** - * @covers \Ibexa\Core\Persistence\Legacy\Filter\Query\LimitedCountQueryBuilder::wrap - */ public function testWrapDoesNotChangeQueryBuilderIfLimitIsNull(): void { $qb = $this->getDatabaseConnection()->createQueryBuilder(); diff --git a/tests/lib/Persistence/Legacy/Filter/SortClauseQueryBuilder/Location/Bookmark/IdSortClauseQueryBuilderTest.php b/tests/lib/Persistence/Legacy/Filter/SortClauseQueryBuilder/Location/Bookmark/IdSortClauseQueryBuilderTest.php index f31817a6d2..0cdfa208e0 100644 --- a/tests/lib/Persistence/Legacy/Filter/SortClauseQueryBuilder/Location/Bookmark/IdSortClauseQueryBuilderTest.php +++ b/tests/lib/Persistence/Legacy/Filter/SortClauseQueryBuilder/Location/Bookmark/IdSortClauseQueryBuilderTest.php @@ -17,11 +17,11 @@ use Ibexa\Core\Persistence\Legacy\Bookmark\Gateway\DoctrineDatabase; use Ibexa\Core\Persistence\Legacy\Content\Location\Gateway as LocationGateway; use Ibexa\Core\Persistence\Legacy\Filter\SortClauseQueryBuilder\Location\Bookmark\IdSortClauseQueryBuilder; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Filter\SortClauseQueryBuilder\Location\Bookmark\IdSortClauseQueryBuilder - */ +#[CoversClass(IdSortClauseQueryBuilder::class)] final class IdSortClauseQueryBuilderTest extends TestCase { private const CURRENT_USER_ID = 14; @@ -45,33 +45,30 @@ public function testBuildQueryInLocationFilteringContext(): void $builder->buildQuery($queryBuilder, $sortClause); - self::assertContains( + $sql = $queryBuilder->getSQL(); + + self::assertStringContainsString( sprintf('%s.id AS %s', self::BOOKMARK_ALIAS, self::SORT_ALIAS), - $queryBuilder->getQueryPart('select') + $sql ); - $joins = $queryBuilder->getQueryPart('join'); - self::assertArrayHasKey('location', $joins); - - $bookmarkJoin = $this->findJoinByAlias($joins['location'], self::BOOKMARK_ALIAS); - self::assertNotNull($bookmarkJoin, 'Bookmarks table was not joined against "location"'); - self::assertSame(DoctrineDatabase::TABLE_BOOKMARKS, $bookmarkJoin['joinTable']); + // bookmarks table is joined directly against "location" self::assertSame( sprintf( '(location.node_id = %1$s.node_id) AND (%1$s.user_id = :dcValue1)', self::BOOKMARK_ALIAS ), - (string)$bookmarkJoin['joinCondition'] + $queryBuilder->getExistingTableAliasJoinCondition(self::BOOKMARK_ALIAS) ); self::assertSame(['dcValue1' => self::CURRENT_USER_ID], $queryBuilder->getParameters()); - self::assertSame( - [self::SORT_ALIAS . ' DESC'], - $queryBuilder->getQueryPart('orderBy') + self::assertStringContainsString( + sprintf('ORDER BY %s DESC', self::SORT_ALIAS), + $sql ); // the whole join graph has to resolve - self::assertStringContainsString(self::BOOKMARK_ALIAS, $queryBuilder->getSQL()); + self::assertStringContainsString(self::BOOKMARK_ALIAS, $sql); } /** @@ -84,56 +81,58 @@ public function testBuildQueryInContentFilteringContext(): void $this->createBuilder()->buildQuery($queryBuilder, new Id(Query::SORT_DESC)); - $joins = $queryBuilder->getQueryPart('join'); + $sql = $queryBuilder->getSQL(); // main Location joined off the "content" FROM table... - self::assertArrayHasKey('content', $joins); - self::assertSame(LocationGateway::CONTENT_TREE_TABLE, $joins['content'][0]['joinTable']); - self::assertSame(self::CONTENT_LOCATION_ALIAS, $joins['content'][0]['joinAlias']); - - // ...and bookmarks joined off that alias, not off a hardcoded "location" - self::assertArrayHasKey(self::CONTENT_LOCATION_ALIAS, $joins); self::assertSame( - DoctrineDatabase::TABLE_BOOKMARKS, - $joins[self::CONTENT_LOCATION_ALIAS][0]['joinTable'] + sprintf( + '(content.id = %1$s.contentobject_id) AND (%1$s.node_id = %1$s.main_node_id)', + self::CONTENT_LOCATION_ALIAS + ), + $queryBuilder->getExistingTableAliasJoinCondition(self::CONTENT_LOCATION_ALIAS) ); - self::assertSame( - self::BOOKMARK_ALIAS, - $joins[self::CONTENT_LOCATION_ALIAS][0]['joinAlias'] + self::assertStringContainsString( + sprintf('%s %s', LocationGateway::CONTENT_TREE_TABLE, self::CONTENT_LOCATION_ALIAS), + $sql ); + + // ...and bookmarks joined off that alias, not off a hardcoded "location" self::assertSame( sprintf( '(%1$s.node_id = %2$s.node_id) AND (%2$s.user_id = :dcValue1)', self::CONTENT_LOCATION_ALIAS, self::BOOKMARK_ALIAS ), - (string)$joins[self::CONTENT_LOCATION_ALIAS][0]['joinCondition'] + $queryBuilder->getExistingTableAliasJoinCondition(self::BOOKMARK_ALIAS) + ); + self::assertStringContainsString( + sprintf('%s %s', DoctrineDatabase::TABLE_BOOKMARKS, self::BOOKMARK_ALIAS), + $sql ); - self::assertArrayNotHasKey('location', $joins); + self::assertFalse($queryBuilder->hasFromAlias('location')); - self::assertSame( - [self::SORT_ALIAS . ' DESC'], - $queryBuilder->getQueryPart('orderBy') + self::assertStringContainsString( + sprintf('ORDER BY %s DESC', self::SORT_ALIAS), + $sql ); - self::assertStringContainsString(self::BOOKMARK_ALIAS, $queryBuilder->getSQL()); + self::assertStringContainsString(self::BOOKMARK_ALIAS, $sql); } /** * @return iterable */ - public function standaloneContextProvider(): iterable + public static function standaloneContextProvider(): iterable { - yield 'Location filtering' => [$this->createLocationFilteringQueryBuilder()]; - yield 'Content filtering' => [$this->createContentFilteringQueryBuilder()]; + yield 'Location filtering' => [self::createLocationFilteringQueryBuilder()]; + yield 'Content filtering' => [self::createContentFilteringQueryBuilder()]; } /** * Test that sort clause works without an IsBookmarked criterion having joined anything first. - * - * @dataProvider standaloneContextProvider */ + #[DataProvider('standaloneContextProvider')] public function testBuildQueryStandaloneProducesResolvableSql( FilteringQueryBuilder $queryBuilder ): void { @@ -145,22 +144,6 @@ public function testBuildQueryStandaloneProducesResolvableSql( self::assertStringContainsString('ORDER BY ' . self::SORT_ALIAS . ' ASC', $sql); } - /** - * @param array> $joins - * - * @return array|null - */ - private function findJoinByAlias(array $joins, string $joinAlias): ?array - { - foreach ($joins as $join) { - if ($join['joinAlias'] === $joinAlias) { - return $join; - } - } - - return null; - } - private function createBuilder(): IdSortClauseQueryBuilder { $userReference = $this->createMock(UserReference::class); @@ -177,9 +160,9 @@ private function createBuilder(): IdSortClauseQueryBuilder * {@see \Ibexa\Core\Persistence\Legacy\Filter\Gateway\Location\Doctrine\DoctrineGateway}: * "location" is the FROM table and "content" is joined off it. */ - private function createLocationFilteringQueryBuilder(): FilteringQueryBuilder + private static function createLocationFilteringQueryBuilder(): FilteringQueryBuilder { - $queryBuilder = new FilteringQueryBuilder($this->createInMemoryConnection()); + $queryBuilder = new FilteringQueryBuilder(self::createInMemoryConnection()); $queryBuilder ->select('location.node_id') ->from(LocationGateway::CONTENT_TREE_TABLE, 'location') @@ -198,9 +181,9 @@ private function createLocationFilteringQueryBuilder(): FilteringQueryBuilder * {@see \Ibexa\Core\Persistence\Legacy\Filter\Gateway\Content\Doctrine\DoctrineGateway}: * "content" is the FROM table and there is no "location" alias at all. */ - private function createContentFilteringQueryBuilder(): FilteringQueryBuilder + private static function createContentFilteringQueryBuilder(): FilteringQueryBuilder { - $queryBuilder = new FilteringQueryBuilder($this->createInMemoryConnection()); + $queryBuilder = new FilteringQueryBuilder(self::createInMemoryConnection()); $queryBuilder ->select('content.id') ->from(self::CONTENT_ITEM_TABLE, 'content'); @@ -208,8 +191,8 @@ private function createContentFilteringQueryBuilder(): FilteringQueryBuilder return $queryBuilder; } - private function createInMemoryConnection(): \Doctrine\DBAL\Connection + private static function createInMemoryConnection(): \Doctrine\DBAL\Connection { - return DriverManager::getConnection(['url' => 'sqlite:///:memory:']); + return DriverManager::getConnection(['driver' => 'pdo_sqlite', 'memory' => true]); } } diff --git a/tests/lib/Persistence/Legacy/HandlerTest.php b/tests/lib/Persistence/Legacy/HandlerTest.php index c13aba4c7e..87d4b908ed 100644 --- a/tests/lib/Persistence/Legacy/HandlerTest.php +++ b/tests/lib/Persistence/Legacy/HandlerTest.php @@ -26,10 +26,9 @@ use Ibexa\Core\Persistence\Legacy\TransactionHandler; use Ibexa\Core\Persistence\Legacy\User\Handler as UserHandler; use Ibexa\Tests\Integration\Core\LegacyTestContainerBuilder; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Handler::contentHandler - */ +#[CoversClass(Handler::class)] class HandlerTest extends TestCase { public function testContentHandler(): void diff --git a/tests/lib/Persistence/Legacy/Notification/Gateway/DoctrineDatabaseTest.php b/tests/lib/Persistence/Legacy/Notification/Gateway/DoctrineDatabaseTest.php index ad719bd357..85ba1e0ecf 100644 --- a/tests/lib/Persistence/Legacy/Notification/Gateway/DoctrineDatabaseTest.php +++ b/tests/lib/Persistence/Legacy/Notification/Gateway/DoctrineDatabaseTest.php @@ -18,10 +18,9 @@ use Ibexa\Core\Persistence\Legacy\Notification\Gateway\CriterionHandler\TypeCriterionHandler; use Ibexa\Core\Persistence\Legacy\Notification\Gateway\DoctrineDatabase; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Notification\Gateway\DoctrineDatabase::insert - */ +#[CoversClass(DoctrineDatabase::class)] class DoctrineDatabaseTest extends TestCase { public const EXISTING_NOTIFICATION_ID = 1; @@ -43,7 +42,7 @@ protected function setUp(): void ); } - public function testInsert() + public function testInsert(): void { $id = $this->getGateway()->insert(new CreateStruct([ 'ownerId' => 14, @@ -65,7 +64,7 @@ public function testInsert() ], $data); } - public function testGetNotificationById() + public function testGetNotificationById(): void { $data = $this->getGateway()->getNotificationById(self::EXISTING_NOTIFICATION_ID); @@ -74,7 +73,7 @@ public function testGetNotificationById() ], $data); } - public function testUpdateNotification() + public function testUpdateNotification(): void { $notification = new Notification([ 'id' => self::EXISTING_NOTIFICATION_ID, @@ -97,7 +96,7 @@ public function testUpdateNotification() ], $this->loadNotification(self::EXISTING_NOTIFICATION_ID)); } - public function testCountUserNotifications() + public function testCountUserNotifications(): void { self::assertEquals( 5, @@ -107,7 +106,7 @@ public function testCountUserNotifications() ); } - public function testCountUserPendingNotifications() + public function testCountUserPendingNotifications(): void { self::assertEquals( 3, @@ -218,7 +217,7 @@ public function testFindUserNotifications(): void self::assertEquals([], $resultsWithNoResults); } - public function testDelete() + public function testDelete(): void { $this->getGateway()->delete(self::EXISTING_NOTIFICATION_ID); diff --git a/tests/lib/Persistence/Legacy/Notification/HandlerTest.php b/tests/lib/Persistence/Legacy/Notification/HandlerTest.php index 0c85dc9867..ca9506e2b8 100644 --- a/tests/lib/Persistence/Legacy/Notification/HandlerTest.php +++ b/tests/lib/Persistence/Legacy/Notification/HandlerTest.php @@ -17,11 +17,10 @@ use Ibexa\Core\Persistence\Legacy\Notification\Gateway; use Ibexa\Core\Persistence\Legacy\Notification\Handler; use Ibexa\Core\Persistence\Legacy\Notification\Mapper; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Notification\Handler - */ +#[CoversClass(Handler::class)] class HandlerTest extends TestCase { public const NOTIFICATION_ID = 1; @@ -42,7 +41,7 @@ protected function setUp(): void $this->handler = new Handler($this->gateway, $this->mapper); } - public function testCreateNotification() + public function testCreateNotification(): void { $createStruct = new CreateStruct([ 'ownerId' => 5, @@ -70,7 +69,7 @@ public function testCreateNotification() self::assertEquals($notification->id, self::NOTIFICATION_ID); } - public function testCountPendingNotifications() + public function testCountPendingNotifications(): void { $ownerId = 10; $expectedCount = 12; @@ -84,7 +83,7 @@ public function testCountPendingNotifications() self::assertEquals($expectedCount, $this->handler->countPendingNotifications($ownerId)); } - public function testGetNotificationById() + public function testGetNotificationById(): void { $rows = [ [ @@ -134,7 +133,7 @@ public function testBulkUpdateUserNotifications(): void self::assertEquals([1, 2, 3], $result); } - public function testUpdateNotification() + public function testUpdateNotification(): void { $updateStruct = new UpdateStruct([ 'isPending' => false, @@ -173,7 +172,7 @@ public function testUpdateNotification() $this->handler->updateNotification($apiNotification, $updateStruct); } - public function testCountNotifications() + public function testCountNotifications(): void { $ownerId = 10; $expectedCount = 12; @@ -262,7 +261,7 @@ public function testFindUserNotifications(): void self::assertEquals($objects, $this->handler->findUserNotifications($ownerId, $query)); } - public function testDelete() + public function testDelete(): void { $notification = new APINotification([ 'id' => self::NOTIFICATION_ID, /* ... */ diff --git a/tests/lib/Persistence/Legacy/Notification/MapperTest.php b/tests/lib/Persistence/Legacy/Notification/MapperTest.php index 9925250d1b..d4cc73b941 100644 --- a/tests/lib/Persistence/Legacy/Notification/MapperTest.php +++ b/tests/lib/Persistence/Legacy/Notification/MapperTest.php @@ -11,11 +11,10 @@ use Ibexa\Contracts\Core\Persistence\Notification\Notification; use Ibexa\Contracts\Core\Persistence\Notification\UpdateStruct; use Ibexa\Core\Persistence\Legacy\Notification\Mapper; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Notification\Mapper - */ +#[CoversClass(Mapper::class)] class MapperTest extends TestCase { /** @var \Ibexa\Core\Persistence\Legacy\Notification\Mapper */ @@ -26,7 +25,7 @@ protected function setUp(): void $this->mapper = new Mapper(); } - public function testExtractNotificationsFromRows() + public function testExtractNotificationsFromRows(): void { $rows = [ [ @@ -77,7 +76,7 @@ public function testExtractNotificationsFromRows() self::assertEquals($objects, $this->mapper->extractNotificationsFromRows($rows)); } - public function testExtractNotificationsFromRowsThrowsRuntimeException() + public function testExtractNotificationsFromRowsThrowsRuntimeException(): void { $this->expectException(\RuntimeException::class); @@ -95,7 +94,7 @@ public function testExtractNotificationsFromRowsThrowsRuntimeException() $this->mapper->extractNotificationsFromRows($rows); } - public function testCreateNotificationFromUpdateStruct() + public function testCreateNotificationFromUpdateStruct(): void { $updateStruct = new UpdateStruct([ 'isPending' => false, diff --git a/tests/lib/Persistence/Legacy/Setting/SettingHandlerTest.php b/tests/lib/Persistence/Legacy/Setting/SettingHandlerTest.php index 32feb226b5..a800d89437 100644 --- a/tests/lib/Persistence/Legacy/Setting/SettingHandlerTest.php +++ b/tests/lib/Persistence/Legacy/Setting/SettingHandlerTest.php @@ -12,11 +12,10 @@ use Ibexa\Core\Persistence\Legacy\Setting\Gateway; use Ibexa\Core\Persistence\Legacy\Setting\Handler; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\MockObject\MockObject; -/** - * @covers \Ibexa\Core\Persistence\Legacy\Setting\Handler::create - */ +#[CoversClass(Handler::class)] final class SettingHandlerTest extends TestCase { /** @var \Ibexa\Core\Persistence\Legacy\Setting\Handler */ diff --git a/tests/lib/Persistence/Legacy/SharedGateway/GatewayFactoryTest.php b/tests/lib/Persistence/Legacy/SharedGateway/GatewayFactoryTest.php index be52286391..90cfa90c9d 100644 --- a/tests/lib/Persistence/Legacy/SharedGateway/GatewayFactoryTest.php +++ b/tests/lib/Persistence/Legacy/SharedGateway/GatewayFactoryTest.php @@ -13,12 +13,12 @@ use Ibexa\Core\Persistence\Legacy\SharedGateway\DatabasePlatform\FallbackGateway; use Ibexa\Core\Persistence\Legacy\SharedGateway\DatabasePlatform\SqliteGateway; use Ibexa\Core\Persistence\Legacy\SharedGateway\GatewayFactory; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Traversable; -/** - * @covers \Ibexa\Core\Persistence\Legacy\SharedGateway\GatewayFactory - */ +#[CoversClass(GatewayFactory::class)] final class GatewayFactoryTest extends TestCase { /** @var \Ibexa\Core\Persistence\Legacy\SharedGateway\GatewayFactory */ @@ -30,23 +30,22 @@ final class GatewayFactoryTest extends TestCase public function setUp(): void { $gateways = [ - Platforms\SQLitePlatform::class => new SqliteGateway($this->createMock(Connection::class)), + Platforms\SQLitePlatform::class => new SqliteGateway(self::createStub(Connection::class)), ]; $this->factory = new GatewayFactory( - new FallbackGateway($this->createMock(Connection::class)), + new FallbackGateway(self::createStub(Connection::class)), $gateways, ); } /** - * @dataProvider getTestBuildSharedGatewayData - * * @param \Doctrine\DBAL\Connection $connectionMock * @param string $expectedInstance * * @throws \Doctrine\DBAL\Exception */ + #[DataProvider('getTestBuildSharedGatewayData')] public function testBuildSharedGateway( Connection $connectionMock, string $expectedInstance @@ -60,7 +59,7 @@ public function testBuildSharedGateway( /** * @return \Doctrine\DBAL\Connection[]|\PHPUnit\Framework\MockObject\MockObject[]|\Traversable */ - public function getTestBuildSharedGatewayData(): Traversable + public static function getTestBuildSharedGatewayData(): Traversable { $databasePlatformGatewayPairs = [ [new Platforms\SQLitePlatform(), SqliteGateway::class], @@ -71,10 +70,8 @@ public function getTestBuildSharedGatewayData(): Traversable foreach ($databasePlatformGatewayPairs as $databasePlatformGatewayPair) { [$databasePlatform, $sharedGateway] = $databasePlatformGatewayPair; - $connectionMock = $this - ->createMock(Connection::class); + $connectionMock = self::createStub(Connection::class); $connectionMock - ->expects(self::any()) ->method('getDatabasePlatform') ->willReturn($databasePlatform); diff --git a/tests/lib/Persistence/Legacy/TransactionHandlerTest.php b/tests/lib/Persistence/Legacy/TransactionHandlerTest.php index 98ae8e3372..e154530770 100644 --- a/tests/lib/Persistence/Legacy/TransactionHandlerTest.php +++ b/tests/lib/Persistence/Legacy/TransactionHandlerTest.php @@ -12,11 +12,10 @@ use Ibexa\Core\Persistence\Legacy\Content\Language\CachingHandler; use Ibexa\Core\Persistence\Legacy\Content\Type\MemoryCachingHandler; use Ibexa\Core\Persistence\Legacy\TransactionHandler; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\TransactionHandler - */ +#[CoversClass(TransactionHandler::class)] class TransactionHandlerTest extends TestCase { /** @@ -35,7 +34,7 @@ class TransactionHandlerTest extends TestCase /** @var \Ibexa\Contracts\Core\Persistence\Content\Language\Handler|\PHPUnit\Framework\MockObject\MockObject */ protected $languageHandlerMock; - public function testBeginTransaction() + public function testBeginTransaction(): void { $handler = $this->getTransactionHandler(); $this->getConnectionMock() @@ -51,7 +50,7 @@ public function testBeginTransaction() $handler->beginTransaction(); } - public function testCommit() + public function testCommit(): void { $handler = $this->getTransactionHandler(); $this->getConnectionMock() @@ -67,7 +66,7 @@ public function testCommit() $handler->commit(); } - public function testCommitException() + public function testCommitException(): void { $this->expectException(\RuntimeException::class); $this->expectExceptionMessage('test'); @@ -87,7 +86,7 @@ public function testCommitException() $handler->commit(); } - public function testRollback() + public function testRollback(): void { $handler = $this->getTransactionHandler(); $this->getConnectionMock() @@ -103,7 +102,7 @@ public function testRollback() $handler->rollback(); } - public function testRollbackException() + public function testRollbackException(): void { $this->expectException(\RuntimeException::class); $this->expectExceptionMessage('test'); diff --git a/tests/lib/Persistence/Legacy/URL/Gateway/DoctrineDatabaseTest.php b/tests/lib/Persistence/Legacy/URL/Gateway/DoctrineDatabaseTest.php index 0b59dbf9d9..37d4617df6 100644 --- a/tests/lib/Persistence/Legacy/URL/Gateway/DoctrineDatabaseTest.php +++ b/tests/lib/Persistence/Legacy/URL/Gateway/DoctrineDatabaseTest.php @@ -13,10 +13,9 @@ use Ibexa\Core\Persistence\Legacy\URL\Query\CriteriaConverter; use Ibexa\Core\Persistence\Legacy\URL\Query\CriterionHandler\MatchAll; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \DoctrineDatabase - */ +#[CoversClass(DoctrineDatabase::class)] class DoctrineDatabaseTest extends TestCase { /** diff --git a/tests/lib/Persistence/Legacy/URL/HandlerTest.php b/tests/lib/Persistence/Legacy/URL/HandlerTest.php index bcf3201ffc..ee318d1476 100644 --- a/tests/lib/Persistence/Legacy/URL/HandlerTest.php +++ b/tests/lib/Persistence/Legacy/URL/HandlerTest.php @@ -37,7 +37,7 @@ protected function setUp(): void $this->handler = new Handler($this->gateway, $this->mapper); } - public function testUpdateUrl() + public function testUpdateUrl(): void { $urlUpdateStruct = new URLUpdateStruct(); $url = $this->getUrl(1, 'http://ibexa.co'); @@ -56,7 +56,7 @@ public function testUpdateUrl() self::assertEquals($url, $this->handler->updateUrl($url->id, $urlUpdateStruct)); } - public function testFind() + public function testFind(): void { $query = new URLQuery(); $query->filter = new Criterion\Validity(true); @@ -98,7 +98,7 @@ public function testFind() self::assertEquals($expected, $this->handler->find($query)); } - public function testLoadByIdWithoutUrlData() + public function testLoadByIdWithoutUrlData(): void { $this->expectException(NotFoundException::class); @@ -119,7 +119,7 @@ public function testLoadByIdWithoutUrlData() $this->handler->loadById($id); } - public function testLoadByIdWithUrlData() + public function testLoadByIdWithUrlData(): void { $url = $this->getUrl(1, 'http://ibexa.co'); @@ -138,7 +138,7 @@ public function testLoadByIdWithUrlData() self::assertEquals($url, $this->handler->loadById($url->id)); } - public function testLoadByUrlWithoutUrlData() + public function testLoadByUrlWithoutUrlData(): void { $this->expectException(NotFoundException::class); @@ -159,7 +159,7 @@ public function testLoadByUrlWithoutUrlData() $this->handler->loadByUrl($url); } - public function testLoadByUrlWithUrlData() + public function testLoadByUrlWithUrlData(): void { $url = $this->getUrl(1, 'http://ibexa.co'); @@ -178,7 +178,7 @@ public function testLoadByUrlWithUrlData() self::assertEquals($url, $this->handler->loadByUrl($url->url)); } - public function testFindUsages() + public function testFindUsages(): void { $url = $this->getUrl(); $ids = [1, 2, 3]; diff --git a/tests/lib/Persistence/Legacy/URL/MapperTest.php b/tests/lib/Persistence/Legacy/URL/MapperTest.php index c60cd23725..d986201f67 100644 --- a/tests/lib/Persistence/Legacy/URL/MapperTest.php +++ b/tests/lib/Persistence/Legacy/URL/MapperTest.php @@ -23,7 +23,7 @@ protected function setUp(): void $this->mapper = new Mapper(); } - public function testCreateURLFromUpdateStruct() + public function testCreateURLFromUpdateStruct(): void { $urlUpdateStruct = new URLUpdateStruct(); $urlUpdateStruct->url = 'https://ibexa.co'; @@ -42,7 +42,7 @@ public function testCreateURLFromUpdateStruct() self::assertEquals($expected, $this->mapper->createURLFromUpdateStruct($urlUpdateStruct)); } - public function testExtractURLsFromRows() + public function testExtractURLsFromRows(): void { $rows = [ [ diff --git a/tests/lib/Persistence/Legacy/URL/Query/CriteriaConverterTest.php b/tests/lib/Persistence/Legacy/URL/Query/CriteriaConverterTest.php index 14f4d05609..d5ceeefc75 100644 --- a/tests/lib/Persistence/Legacy/URL/Query/CriteriaConverterTest.php +++ b/tests/lib/Persistence/Legacy/URL/Query/CriteriaConverterTest.php @@ -12,11 +12,11 @@ use Ibexa\Contracts\Core\Repository\Values\URL\Query\Criterion; use Ibexa\Core\Persistence\Legacy\URL\Query\CriteriaConverter; use Ibexa\Core\Persistence\Legacy\URL\Query\CriterionHandler; +use Ibexa\Core\Persistence\Legacy\User\Gateway\DoctrineDatabase; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\User\Gateway\DoctrineDatabase - */ +#[CoversClass(DoctrineDatabase::class)] class CriteriaConverterTest extends TestCase { /** @@ -32,9 +32,9 @@ public function testConvertCriteriaSuccess(): void $barCriterionHandler, ]); - $barCriterion = $this->createMock(Criterion::class); + $barCriterion = self::createStub(Criterion::class); - $selectQuery = $this->createMock(QueryBuilder::class); + $selectQuery = self::createStub(QueryBuilder::class); $fooCriterionHandler ->expects(self::once()) @@ -77,8 +77,8 @@ public function testConvertCriteriaFailure(): void $criteriaConverter = new CriteriaConverter(); $criteriaConverter->convertCriteria( - $this->createMock(QueryBuilder::class), - $this->createMock(Criterion::class) + self::createStub(QueryBuilder::class), + self::createStub(Criterion::class) ); } } diff --git a/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/CriterionHandlerTestCase.php b/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/CriterionHandlerTestCase.php index 00525ff4bd..def242edbc 100644 --- a/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/CriterionHandlerTestCase.php +++ b/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/CriterionHandlerTestCase.php @@ -17,9 +17,9 @@ abstract class CriterionHandlerTestCase extends TestCase { - abstract public function testAccept(); + abstract public function testAccept(): void; - abstract public function testHandle(); + abstract public function testHandle(): void; /** * Check if critetion handler accepts specyfied criterion class. @@ -29,7 +29,7 @@ abstract public function testHandle(); */ protected function assertHandlerAcceptsCriterion(CriterionHandler $handler, $criterionClass) { - self::assertTrue($handler->accept($this->createMock($criterionClass))); + self::assertTrue($handler->accept(self::createStub($criterionClass))); } /** @@ -40,7 +40,7 @@ protected function assertHandlerAcceptsCriterion(CriterionHandler $handler, $cri */ protected function assertHandlerRejectsCriterion(CriterionHandler $handler, $criterionClass) { - self::assertFalse($handler->accept($this->createMock($criterionClass))); + self::assertFalse($handler->accept(self::createStub($criterionClass))); } /** @@ -72,16 +72,21 @@ protected function mockConverterForLogicalOperator( ->willReturn($expressionBuilder); $converter = $this->createMock(CriteriaConverter::class); + $matcher = self::exactly(2); $converter - ->expects(self::at(0)) + ->expects($matcher) ->method('convertCriteria') - ->with($queryBuilder, $foo) - ->willReturn($fooExpr); - $converter - ->expects(self::at(1)) - ->method('convertCriteria') - ->with($queryBuilder, $bar) - ->willReturn($barExpr); + ->willReturnCallback(static function (QueryBuilder $actualQueryBuilder, Criterion $actualCriterion) use ($matcher, $queryBuilder, $foo, $bar, $fooExpr, $barExpr): string { + if ($matcher->numberOfInvocations() === 1) { + self::assertSame([$queryBuilder, $foo], [$actualQueryBuilder, $actualCriterion]); + + return $fooExpr; + } + + self::assertSame([$queryBuilder, $bar], [$actualQueryBuilder, $actualCriterion]); + + return $barExpr; + }); return $converter; } diff --git a/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/LogicalAndTest.php b/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/LogicalAndTest.php index bb5a6ec69c..5cb74779dd 100644 --- a/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/LogicalAndTest.php +++ b/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/LogicalAndTest.php @@ -18,12 +18,12 @@ class LogicalAndTest extends CriterionHandlerTestCase /** * {@inheritdoc} */ - public function testAccept() + public function testAccept(): void { $handler = new LogicalAndHandler(); - self::assertTrue($handler->accept($this->createMock(LogicalAnd::class))); - self::assertFalse($handler->accept($this->createMock(Criterion::class))); + self::assertTrue($handler->accept(self::createStub(LogicalAnd::class))); + self::assertFalse($handler->accept(self::createStub(Criterion::class))); } /** @@ -33,15 +33,15 @@ public function testAccept() */ public function testHandle(): void { - $foo = $this->createMock(Criterion::class); - $bar = $this->createMock(Criterion::class); + $foo = self::createStub(Criterion::class); + $bar = self::createStub(Criterion::class); $fooExpr = 'FOO'; $barExpr = 'BAR'; $expected = '(FOO) AND (BAR)'; - $queryBuilder = $this->createMock(QueryBuilder::class); + $queryBuilder = self::createStub(QueryBuilder::class); $converter = $this->mockConverterForLogicalOperator( CompositeExpression::TYPE_AND, $queryBuilder, diff --git a/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/LogicalNotTest.php b/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/LogicalNotTest.php index a5599e57ca..abf2796f30 100644 --- a/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/LogicalNotTest.php +++ b/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/LogicalNotTest.php @@ -18,7 +18,7 @@ class LogicalNotTest extends CriterionHandlerTestCase /** * {@inheritdoc} */ - public function testAccept() + public function testAccept(): void { $handler = new LogicalNotHandler(); @@ -33,15 +33,15 @@ public function testAccept() */ public function testHandle(): void { - $foo = $this->createMock(Criterion::class); + $foo = self::createStub(Criterion::class); $fooExpr = 'FOO'; $expected = 'NOT (FOO)'; - $queryBuilder = $this->createMock(QueryBuilder::class); + $queryBuilder = self::createStub(QueryBuilder::class); $converter = $this->createMock(CriteriaConverter::class); $converter - ->expects(self::at(0)) + ->expects(self::once()) ->method('convertCriteria') ->with($queryBuilder, $foo) ->willReturn($fooExpr); diff --git a/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/LogicalOrTest.php b/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/LogicalOrTest.php index c1574ec0e4..51901cea60 100644 --- a/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/LogicalOrTest.php +++ b/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/LogicalOrTest.php @@ -18,7 +18,7 @@ class LogicalOrTest extends CriterionHandlerTestCase /** * {@inheritdoc} */ - public function testAccept() + public function testAccept(): void { $handler = new LogicalOrHandler(); @@ -33,15 +33,15 @@ public function testAccept() */ public function testHandle(): void { - $foo = $this->createMock(Criterion::class); - $bar = $this->createMock(Criterion::class); + $foo = self::createStub(Criterion::class); + $bar = self::createStub(Criterion::class); $fooExpr = 'FOO'; $barExpr = 'BAR'; $expected = '(FOO) OR (BAR)'; - $queryBuilder = $this->createMock(QueryBuilder::class); + $queryBuilder = self::createStub(QueryBuilder::class); $converter = $this->mockConverterForLogicalOperator( CompositeExpression::TYPE_OR, $queryBuilder, diff --git a/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/MatchAllTest.php b/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/MatchAllTest.php index 20be7baa79..d8257928e6 100644 --- a/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/MatchAllTest.php +++ b/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/MatchAllTest.php @@ -18,7 +18,7 @@ class MatchAllTest extends CriterionHandlerTestCase /** * {@inheritdoc} */ - public function testAccept() + public function testAccept(): void { $handler = new MatchAllHandler(); @@ -29,13 +29,13 @@ public function testAccept() /** * {@inheritdoc} */ - public function testHandle() + public function testHandle(): void { $criterion = new MatchAll(); $expected = '1 = 1'; - $queryBuilder = $this->createMock(QueryBuilder::class); - $converter = $this->createMock(CriteriaConverter::class); + $queryBuilder = self::createStub(QueryBuilder::class); + $converter = self::createStub(CriteriaConverter::class); $handler = new MatchAllHandler(); $actual = $handler->handle($converter, $queryBuilder, $criterion); diff --git a/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/MatchNoneTest.php b/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/MatchNoneTest.php index dc052034c9..165229d31e 100644 --- a/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/MatchNoneTest.php +++ b/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/MatchNoneTest.php @@ -18,7 +18,7 @@ class MatchNoneTest extends CriterionHandlerTestCase /** * {@inheritdoc} */ - public function testAccept() + public function testAccept(): void { $handler = new MatchNoneHandler(); @@ -29,13 +29,13 @@ public function testAccept() /** * {@inheritdoc} */ - public function testHandle() + public function testHandle(): void { $criterion = new MatchNone(); $expected = '1 = 0'; - $query = $this->createMock(QueryBuilder::class); - $converter = $this->createMock(CriteriaConverter::class); + $query = self::createStub(QueryBuilder::class); + $converter = self::createStub(CriteriaConverter::class); $handler = new MatchNoneHandler(); $actual = $handler->handle($converter, $query, $criterion); diff --git a/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/PatternTest.php b/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/PatternTest.php index 9be6f3e55c..c2626e032f 100644 --- a/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/PatternTest.php +++ b/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/PatternTest.php @@ -20,7 +20,7 @@ class PatternTest extends CriterionHandlerTestCase /** * {@inheritdoc} */ - public function testAccept() + public function testAccept(): void { $handler = new PatternHandler(); @@ -31,7 +31,7 @@ public function testAccept() /** * {@inheritdoc} */ - public function testHandle() + public function testHandle(): void { $criterion = new Pattern('google.com'); $expected = 'url LIKE :pattern'; @@ -52,7 +52,7 @@ public function testHandle() ->with('%' . $criterion->pattern . '%', ParameterType::STRING, ':pattern') ->willReturn(':pattern'); - $converter = $this->createMock(CriteriaConverter::class); + $converter = self::createStub(CriteriaConverter::class); $handler = new PatternHandler(); $actual = $handler->handle($converter, $queryBuilder, $criterion); diff --git a/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/ValidityTest.php b/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/ValidityTest.php index d0b9518c5a..bbc63a43a0 100644 --- a/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/ValidityTest.php +++ b/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/ValidityTest.php @@ -20,7 +20,7 @@ class ValidityTest extends CriterionHandlerTestCase /** * {@inheritdoc} */ - public function testAccept() + public function testAccept(): void { $handler = new ValidityHandler(); @@ -31,7 +31,7 @@ public function testAccept() /** * {@inheritdoc} */ - public function testHandle() + public function testHandle(): void { $criterion = new Validity(true); $expected = 'is_valid = :is_valid'; @@ -54,7 +54,7 @@ public function testHandle() ->with((int)$criterion->isValid, ParameterType::INTEGER, ':is_valid') ->willReturn(':is_valid'); - $converter = $this->createMock(CriteriaConverter::class); + $converter = self::createStub(CriteriaConverter::class); $handler = new ValidityHandler(); $actual = $handler->handle($converter, $queryBuilder, $criterion); diff --git a/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/VisibleOnlyTest.php b/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/VisibleOnlyTest.php index 8dfa4a546f..0199b4697c 100644 --- a/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/VisibleOnlyTest.php +++ b/tests/lib/Persistence/Legacy/URL/Query/CriterionHandler/VisibleOnlyTest.php @@ -15,10 +15,9 @@ use Ibexa\Core\Persistence\Doctrine\JoinedTablesTracker; use Ibexa\Core\Persistence\Legacy\URL\Query\CriteriaConverter; use Ibexa\Core\Persistence\Legacy\URL\Query\CriterionHandler\VisibleOnly as VisibleOnlyHandler; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\URL\Query\CriterionHandler\VisibleOnly - */ +#[CoversClass(VisibleOnlyHandler::class)] class VisibleOnlyTest extends CriterionHandlerTestCase { /** @@ -43,7 +42,7 @@ public function testHandle(): void $criterion = new Criterion\VisibleOnly(); $handler = new VisibleOnlyHandler(new JoinedTablesTracker()); - $converter = $this->createMock(CriteriaConverter::class); + $converter = self::createStub(CriteriaConverter::class); $queryBuilder = $this->createDoctrineQueryBuilder(); $actual = $handler->handle($converter, $queryBuilder, $criterion); diff --git a/tests/lib/Persistence/Legacy/User/Gateway/DoctrineDatabaseTest.php b/tests/lib/Persistence/Legacy/User/Gateway/DoctrineDatabaseTest.php index 2d0d8ccffd..38cd26aa42 100644 --- a/tests/lib/Persistence/Legacy/User/Gateway/DoctrineDatabaseTest.php +++ b/tests/lib/Persistence/Legacy/User/Gateway/DoctrineDatabaseTest.php @@ -12,10 +12,9 @@ use Ibexa\Core\Persistence\Legacy\User\Gateway\DoctrineDatabase; use Ibexa\Core\Persistence\Legacy\User\Role\Gateway; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\User\Gateway\DoctrineDatabase - */ +#[CoversClass(DoctrineDatabase::class)] class DoctrineDatabaseTest extends TestCase { /** diff --git a/tests/lib/Persistence/Legacy/User/Role/Gateway/DoctrineDatabaseTest.php b/tests/lib/Persistence/Legacy/User/Role/Gateway/DoctrineDatabaseTest.php index 558f826822..96ce017ed2 100644 --- a/tests/lib/Persistence/Legacy/User/Role/Gateway/DoctrineDatabaseTest.php +++ b/tests/lib/Persistence/Legacy/User/Role/Gateway/DoctrineDatabaseTest.php @@ -13,10 +13,9 @@ use Ibexa\Core\Persistence\Legacy\User\Role\Gateway; use Ibexa\Core\Persistence\Legacy\User\Role\Gateway\DoctrineDatabase; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\User\Role\Gateway\DoctrineDatabase - */ +#[CoversClass(DoctrineDatabase::class)] class DoctrineDatabaseTest extends TestCase { /** @@ -165,9 +164,6 @@ public function testLoadRoleAssignmentsByRoleId(): void ); } - /** - * @covers \Ibexa\Core\Persistence\Legacy\User\Role\Gateway\DoctrineDatabase::loadRoleAssignmentsByRoleIdWithOffsetAndLimit - */ public function testLoadRoleAssignmentsByRoleIdWithOffsetAndLimit(): void { $gateway = $this->getDatabaseGateway(); diff --git a/tests/lib/Persistence/Legacy/User/Role/LimitationConverterTest.php b/tests/lib/Persistence/Legacy/User/Role/LimitationConverterTest.php index c8ba825884..21114719cb 100644 --- a/tests/lib/Persistence/Legacy/User/Role/LimitationConverterTest.php +++ b/tests/lib/Persistence/Legacy/User/Role/LimitationConverterTest.php @@ -28,7 +28,7 @@ protected function getLimitationConverter() /** * Test Object State from SPI value (supported by API) to legacy value (database). */ - public function testObjectStateToLegacy() + public function testObjectStateToLegacy(): void { $this->insertSharedDatabaseFixture(); @@ -81,7 +81,7 @@ public function testObjectStateToLegacy() /** * Test Object State from legacy value (database) to SPI value (supported by API). */ - public function testObjectStateToSPI() + public function testObjectStateToSPI(): void { $this->insertSharedDatabaseFixture(); diff --git a/tests/lib/Persistence/Legacy/User/UserHandlerTest.php b/tests/lib/Persistence/Legacy/User/UserHandlerTest.php index 62457f3e48..05566c107c 100644 --- a/tests/lib/Persistence/Legacy/User/UserHandlerTest.php +++ b/tests/lib/Persistence/Legacy/User/UserHandlerTest.php @@ -69,7 +69,7 @@ protected function getValidUserToken($time = null) return $userToken; } - public function testCreateUser() + public function testCreateUser(): void { $handler = $this->getUserHandler(); @@ -105,7 +105,7 @@ protected function getDummyUser( ]; } - public function testLoadUser() + public function testLoadUser(): void { $gatewayMock = $this ->createMock(User\Gateway::class); @@ -125,7 +125,7 @@ public function testLoadUser() ); } - public function testLoadUnknownUser() + public function testLoadUnknownUser(): void { $this->expectException(NotFoundException::class); $gatewayMock = $this @@ -141,7 +141,7 @@ public function testLoadUnknownUser() $handler->load(1337); } - public function testLoadUserByLogin() + public function testLoadUserByLogin(): void { $gatewayMock = $this ->createMock(User\Gateway::class); @@ -161,7 +161,7 @@ public function testLoadUserByLogin() ); } - public function testLoadMultipleUsersByLogin() + public function testLoadMultipleUsersByLogin(): void { $this->expectException(LogicException::class); @@ -182,7 +182,7 @@ public function testLoadMultipleUsersByLogin() $handler->loadByLogin($user->login); } - public function testLoadMultipleUsersByEmail() + public function testLoadMultipleUsersByEmail(): void { $this->expectException(LogicException::class); @@ -203,7 +203,7 @@ public function testLoadMultipleUsersByEmail() $handler->loadByEmail($user->email); } - public function testLoadUserByEmailNotFound() + public function testLoadUserByEmailNotFound(): void { $this->expectException(NotFoundException::class); @@ -213,7 +213,7 @@ public function testLoadUserByEmailNotFound() $handler->loadByLogin($user->email); } - public function testLoadUserByEmail() + public function testLoadUserByEmail(): void { $gatewayMock = $this ->createMock(User\Gateway::class); @@ -233,7 +233,7 @@ public function testLoadUserByEmail() ); } - public function testLoadUsersByEmail() + public function testLoadUsersByEmail(): void { $gatewayMock = $this ->createMock(User\Gateway::class); @@ -253,7 +253,7 @@ public function testLoadUsersByEmail() ); } - public function testLoadUserByTokenNotFound() + public function testLoadUserByTokenNotFound(): void { $this->expectException(NotFoundException::class); @@ -263,7 +263,7 @@ public function testLoadUserByTokenNotFound() $handler->loadUserByToken('asd'); } - public function testLoadUserByToken() + public function testLoadUserByToken(): void { $gatewayMock = $this ->createMock(User\Gateway::class); @@ -285,7 +285,7 @@ public function testLoadUserByToken() ); } - public function testUpdateUserToken() + public function testUpdateUserToken(): void { $handler = $this->getUserHandler(); @@ -316,7 +316,7 @@ public function testUpdateUserToken() ); } - public function testExpireUserToken() + public function testExpireUserToken(): void { $handler = $this->getUserHandler(); @@ -347,7 +347,7 @@ public function testExpireUserToken() ); } - public function testDeleteNonExistingUser() + public function testDeleteNonExistingUser(): void { $handler = $this->getUserHandler(); @@ -355,7 +355,7 @@ public function testDeleteNonExistingUser() $handler->delete(1337); } - public function testUpdateUser() + public function testUpdateUser(): void { $handler = $this->getUserHandler(); $user = $this->getValidUser(); @@ -365,7 +365,7 @@ public function testUpdateUser() $handler->update($user); } - public function testUpdateUserSettings() + public function testUpdateUserSettings(): void { $handler = $this->getUserHandler(); $user = $this->getValidUser(); @@ -375,7 +375,7 @@ public function testUpdateUserSettings() $handler->update($user); } - public function testCreateNewRoleWithoutPolicies() + public function testCreateNewRoleWithoutPolicies(): void { $handler = $this->getUserHandler(); @@ -395,7 +395,7 @@ public function testCreateNewRoleWithoutPolicies() ); } - public function testCreateRoleDraftWithoutPolicies() + public function testCreateRoleDraftWithoutPolicies(): void { $handler = $this->getUserHandler(); @@ -422,7 +422,7 @@ public function testCreateRoleDraftWithoutPolicies() ); } - public function testCreateNewRoleRoleId() + public function testCreateNewRoleRoleId(): void { $handler = $this->getUserHandler(); @@ -434,7 +434,7 @@ public function testCreateNewRoleRoleId() self::assertSame(1, $roleDraft->id); } - public function testLoadRole() + public function testLoadRole(): void { $handler = $this->getUserHandler(); @@ -451,7 +451,7 @@ public function testLoadRole() ); } - public function testLoadRoleWithPolicies() + public function testLoadRoleWithPolicies(): void { $handler = $this->getUserHandler(); @@ -485,7 +485,7 @@ public function testLoadRoleWithPolicies() ); } - public function testLoadRoleWithPoliciesAndGroups() + public function testLoadRoleWithPoliciesAndGroups(): void { $handler = $this->getUserHandler(); @@ -523,7 +523,7 @@ public function testLoadRoleWithPoliciesAndGroups() ); } - public function testLoadRoleWithPolicyLimitations() + public function testLoadRoleWithPolicyLimitations(): void { $handler = $this->getUserHandler(); @@ -564,7 +564,7 @@ public function testLoadRoleWithPolicyLimitations() ); } - public function testLoadRoles() + public function testLoadRoles(): void { $handler = $this->getUserHandler(); @@ -581,7 +581,7 @@ public function testLoadRoles() ); } - public function testUpdateRole() + public function testUpdateRole(): void { $handler = $this->getUserHandler(); @@ -600,7 +600,7 @@ public function testUpdateRole() ); } - public function testDeleteRole() + public function testDeleteRole(): void { $this->insertSharedDatabaseFixture(); $handler = $this->getUserHandler(); @@ -627,7 +627,7 @@ public function testDeleteRole() ); } - public function testDeleteRoleDraft() + public function testDeleteRoleDraft(): void { $this->insertSharedDatabaseFixture(); $handler = $this->getUserHandler(); @@ -655,7 +655,7 @@ public function testDeleteRoleDraft() ); } - public function testAddPolicyToRoleLimitations() + public function testAddPolicyToRoleLimitations(): void { $handler = $this->getUserHandler(); @@ -674,7 +674,7 @@ public function testAddPolicyToRoleLimitations() ); } - public function testAddPolicyPolicyId() + public function testAddPolicyPolicyId(): void { $handler = $this->getUserHandler(); @@ -689,7 +689,7 @@ public function testAddPolicyPolicyId() self::assertEquals(1, $policy->id); } - public function testAddPolicyLimitations() + public function testAddPolicyLimitations(): void { $this->createTestRoleWithTestPolicy(); @@ -703,7 +703,7 @@ public function testAddPolicyLimitations() ); } - public function testAddPolicyLimitationValues() + public function testAddPolicyLimitationValues(): void { $this->createTestRoleWithTestPolicy(); @@ -744,7 +744,7 @@ protected function createRole() return $handler->createRole($createStruct); } - public function testImplicitlyCreatePolicies() + public function testImplicitlyCreatePolicies(): void { $this->createRole(); @@ -758,7 +758,7 @@ public function testImplicitlyCreatePolicies() ); } - public function testDeletePolicy() + public function testDeletePolicy(): void { $handler = $this->getUserHandler(); @@ -775,7 +775,7 @@ public function testDeletePolicy() ); } - public function testDeletePolicyLimitations() + public function testDeletePolicyLimitations(): void { $handler = $this->getUserHandler(); @@ -788,7 +788,7 @@ public function testDeletePolicyLimitations() ); } - public function testDeletePolicyLimitationValues() + public function testDeletePolicyLimitationValues(): void { $handler = $this->getUserHandler(); @@ -801,7 +801,7 @@ public function testDeletePolicyLimitationValues() ); } - public function testUpdatePolicies() + public function testUpdatePolicies(): void { $handler = $this->getUserHandler(); @@ -831,7 +831,7 @@ public function testUpdatePolicies() ); } - public function testAddRoleToUser() + public function testAddRoleToUser(): void { $handler = $this->getUserHandler(); @@ -851,7 +851,7 @@ public function testAddRoleToUser() ); } - public function testAddRoleToUserWithLimitation() + public function testAddRoleToUserWithLimitation(): void { $handler = $this->getUserHandler(); @@ -877,7 +877,7 @@ public function testAddRoleToUserWithLimitation() ); } - public function testAddRoleToUserWithComplexLimitation() + public function testAddRoleToUserWithComplexLimitation(): void { $handler = $this->getUserHandler(); @@ -906,7 +906,7 @@ public function testAddRoleToUserWithComplexLimitation() ); } - public function testRemoveUserRoleAssociation() + public function testRemoveUserRoleAssociation(): void { $handler = $this->getUserHandler(); @@ -933,7 +933,7 @@ public function testRemoveUserRoleAssociation() ); } - public function testLoadRoleAssignmentsByGroupId() + public function testLoadRoleAssignmentsByGroupId(): void { $this->insertSharedDatabaseFixture(); $handler = $this->getUserHandler(); @@ -977,7 +977,7 @@ public function testLoadRoleAssignmentsByGroupId() ); } - public function testLoadRoleAssignmentsByGroupIdInherited() + public function testLoadRoleAssignmentsByGroupIdInherited(): void { $this->insertSharedDatabaseFixture(); $handler = $this->getUserHandler(); @@ -996,7 +996,7 @@ public function testLoadRoleAssignmentsByGroupIdInherited() ); } - public function testLoadComplexRoleAssignments() + public function testLoadComplexRoleAssignments(): void { $this->insertSharedDatabaseFixture(); $handler = $this->getUserHandler(); @@ -1123,7 +1123,7 @@ public function testLoadRoleAssignmentsByRoleIdWithOffsetAndLimit(): void ); } - public function testLoadRoleDraftByRoleId() + public function testLoadRoleDraftByRoleId(): void { $this->insertSharedDatabaseFixture(); $handler = $this->getUserHandler(); @@ -1136,7 +1136,7 @@ public function testLoadRoleDraftByRoleId() self::assertEquals($draft, $loadedDraft); } - public function testRoleDraftOnlyHavePolicyDraft() + public function testRoleDraftOnlyHavePolicyDraft(): void { $this->insertSharedDatabaseFixture(); $handler = $this->getUserHandler(); diff --git a/tests/lib/Persistence/Legacy/UserPreference/Gateway/DoctrineDatabaseTest.php b/tests/lib/Persistence/Legacy/UserPreference/Gateway/DoctrineDatabaseTest.php index 80f858cb26..b4017b7ce5 100644 --- a/tests/lib/Persistence/Legacy/UserPreference/Gateway/DoctrineDatabaseTest.php +++ b/tests/lib/Persistence/Legacy/UserPreference/Gateway/DoctrineDatabaseTest.php @@ -13,10 +13,9 @@ use Ibexa\Core\Persistence\Legacy\UserPreference\Gateway; use Ibexa\Core\Persistence\Legacy\UserPreference\Gateway\DoctrineDatabase; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Persistence\Legacy\UserPreference\Gateway - */ +#[CoversClass(Gateway::class)] class DoctrineDatabaseTest extends TestCase { public const EXISTING_USER_PREFERENCE_ID = 1; @@ -36,7 +35,7 @@ protected function setUp(): void ); } - public function testInsert() + public function testInsert(): void { $id = $this->getGateway()->setUserPreference(new UserPreferenceSetStruct([ 'userId' => 14, @@ -54,7 +53,7 @@ public function testInsert() ], $data); } - public function testUpdateUserPreference() + public function testUpdateUserPreference(): void { $userPreference = new UserPreferenceSetStruct([ 'userId' => 14, @@ -72,14 +71,14 @@ public function testUpdateUserPreference() ], $this->loadUserPreference(self::EXISTING_USER_PREFERENCE_ID)); } - public function testCountUserPreferences() + public function testCountUserPreferences(): void { self::assertEquals(3, $this->getGateway()->countUserPreferences( self::EXISTING_USER_PREFERENCE_DATA['user_id'] )); } - public function testLoadUserPreferences() + public function testLoadUserPreferences(): void { $userId = 14; $offset = 1; diff --git a/tests/lib/Persistence/Legacy/UserPreference/HandlerTest.php b/tests/lib/Persistence/Legacy/UserPreference/HandlerTest.php index 5a4f89fb28..114083a317 100644 --- a/tests/lib/Persistence/Legacy/UserPreference/HandlerTest.php +++ b/tests/lib/Persistence/Legacy/UserPreference/HandlerTest.php @@ -13,11 +13,10 @@ use Ibexa\Core\Persistence\Legacy\UserPreference\Gateway; use Ibexa\Core\Persistence\Legacy\UserPreference\Handler; use Ibexa\Core\Persistence\Legacy\UserPreference\Mapper; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\UserPreference\Handler - */ +#[CoversClass(Handler::class)] class HandlerTest extends TestCase { public const USER_PREFERENCE_ID = 1; @@ -38,7 +37,7 @@ protected function setUp(): void $this->handler = new Handler($this->gateway, $this->mapper); } - public function testSetUserPreference() + public function testSetUserPreference(): void { $setStruct = new UserPreferenceSetStruct([ 'userId' => 5, @@ -64,7 +63,7 @@ public function testSetUserPreference() self::assertEquals($userPreference->id, self::USER_PREFERENCE_ID); } - public function testCountUserPreferences() + public function testCountUserPreferences(): void { $ownerId = 10; $expectedCount = 12; @@ -78,7 +77,7 @@ public function testCountUserPreferences() self::assertEquals($expectedCount, $this->handler->countUserPreferences($ownerId)); } - public function testLoadUserPreferences() + public function testLoadUserPreferences(): void { $ownerId = 9; $limit = 5; diff --git a/tests/lib/Persistence/Legacy/UserPreference/MapperTest.php b/tests/lib/Persistence/Legacy/UserPreference/MapperTest.php index d0a6c322e1..9f25a840df 100644 --- a/tests/lib/Persistence/Legacy/UserPreference/MapperTest.php +++ b/tests/lib/Persistence/Legacy/UserPreference/MapperTest.php @@ -10,11 +10,10 @@ use Ibexa\Contracts\Core\Persistence\UserPreference\UserPreference; use Ibexa\Core\Persistence\Legacy\UserPreference\Mapper; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Persistence\Legacy\UserPreference\Mapper - */ +#[CoversClass(Mapper::class)] class MapperTest extends TestCase { /** @var \Ibexa\Core\Persistence\Legacy\UserPreference\Mapper */ @@ -25,7 +24,7 @@ protected function setUp(): void $this->mapper = new Mapper(); } - public function testExtractUserPreferencesFromRows() + public function testExtractUserPreferencesFromRows(): void { $rows = [ [ diff --git a/tests/lib/Persistence/Limitation/Target/Builder/VersionBuilderTest.php b/tests/lib/Persistence/Limitation/Target/Builder/VersionBuilderTest.php index d0c1506c8c..4853f26e21 100644 --- a/tests/lib/Persistence/Limitation/Target/Builder/VersionBuilderTest.php +++ b/tests/lib/Persistence/Limitation/Target/Builder/VersionBuilderTest.php @@ -12,11 +12,11 @@ use Ibexa\Contracts\Core\Limitation\Target\Builder\VersionBuilder; use Ibexa\Contracts\Core\Repository\Values\Content\Field; use Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Contracts\Core\Limitation\Target\Builder\VersionBuilder - */ +#[CoversClass(VersionBuilder::class)] class VersionBuilderTest extends TestCase { /** @var string */ @@ -35,7 +35,7 @@ class VersionBuilderTest extends TestCase * * @return array */ - public function providerForTestBuild(): array + public static function providerForTestBuild(): array { $versionStatuses = [ VersionInfo::STATUS_DRAFT, @@ -100,8 +100,6 @@ public function providerForTestBuild(): array } /** - * @dataProvider providerForTestBuild - * * @param \Ibexa\Contracts\Core\Limitation\Target\Version $expectedTargetVersion * @param int $newStatus * @param string $initialLanguageCode @@ -112,6 +110,7 @@ public function providerForTestBuild(): array * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ + #[DataProvider('providerForTestBuild')] public function testBuild( Target\Version $expectedTargetVersion, int $newStatus, diff --git a/tests/lib/Persistence/TransformationProcessor/TransformationProcessorDefinitionBasedParserTest.php b/tests/lib/Persistence/TransformationProcessor/TransformationProcessorDefinitionBasedParserTest.php index 998be78db3..0867124d91 100644 --- a/tests/lib/Persistence/TransformationProcessor/TransformationProcessorDefinitionBasedParserTest.php +++ b/tests/lib/Persistence/TransformationProcessor/TransformationProcessorDefinitionBasedParserTest.php @@ -9,6 +9,7 @@ use Ibexa\Core\Persistence; use Ibexa\Tests\Core\Persistence\Legacy\TestCase; +use PHPUnit\Framework\Attributes\DataProvider; final class TransformationProcessorDefinitionBasedParserTest extends TestCase { @@ -27,9 +28,7 @@ public static function getTestFiles(): iterable } } - /** - * @dataProvider getTestFiles - */ + #[DataProvider('getTestFiles')] public function testParse(string $file): void { $parser = new Persistence\TransformationProcessor\DefinitionBased\Parser(); diff --git a/tests/lib/Persistence/TransformationProcessor/TransformationProcessorDefinitionBasedTest.php b/tests/lib/Persistence/TransformationProcessor/TransformationProcessorDefinitionBasedTest.php index 448b6cd455..a718f9adde 100644 --- a/tests/lib/Persistence/TransformationProcessor/TransformationProcessorDefinitionBasedTest.php +++ b/tests/lib/Persistence/TransformationProcessor/TransformationProcessorDefinitionBasedTest.php @@ -28,7 +28,7 @@ public function getProcessor() ); } - public function testSimpleNormalizationLowercase() + public function testSimpleNormalizationLowercase(): void { $processor = $this->getProcessor(); @@ -38,7 +38,7 @@ public function testSimpleNormalizationLowercase() ); } - public function testSimpleNormalizationUppercase() + public function testSimpleNormalizationUppercase(): void { $processor = $this->getProcessor(); @@ -48,7 +48,7 @@ public function testSimpleNormalizationUppercase() ); } - public function testApplyAllLowercaseNormalizations() + public function testApplyAllLowercaseNormalizations(): void { $processor = $this->getProcessor(); @@ -63,7 +63,7 @@ public function testApplyAllLowercaseNormalizations() * available can be compiled without errors. The actual expectation is not * important. */ - public function testAllNormalizations() + public function testAllNormalizations(): void { $processor = $this->getProcessor(); diff --git a/tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php b/tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php index bda7c272a3..03dcf91940 100644 --- a/tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php +++ b/tests/lib/Persistence/TransformationProcessor/TransformationProcessorPcreCompilerTest.php @@ -34,7 +34,7 @@ protected function applyTransformations(array $transformations, $string) return $string; } - public function testCompileMap() + public function testCompileMap(): void { $parser = new Persistence\TransformationProcessor\DefinitionBased\Parser(self::getInstallationDir()); $compiler = new Persistence\TransformationProcessor\PcreCompiler(new Persistence\Utf8Converter()); @@ -52,7 +52,7 @@ public function testCompileMap() ); } - public function testCompileMapRemove() + public function testCompileMapRemove(): void { $parser = new Persistence\TransformationProcessor\DefinitionBased\Parser(self::getInstallationDir()); $compiler = new Persistence\TransformationProcessor\PcreCompiler(new Persistence\Utf8Converter()); @@ -70,7 +70,7 @@ public function testCompileMapRemove() ); } - public function testCompileMapKeep() + public function testCompileMapKeep(): void { $parser = new Persistence\TransformationProcessor\DefinitionBased\Parser(self::getInstallationDir()); $compiler = new Persistence\TransformationProcessor\PcreCompiler(new Persistence\Utf8Converter()); @@ -88,7 +88,7 @@ public function testCompileMapKeep() ); } - public function testCompileMapAscii() + public function testCompileMapAscii(): void { $parser = new Persistence\TransformationProcessor\DefinitionBased\Parser(self::getInstallationDir()); $compiler = new Persistence\TransformationProcessor\PcreCompiler(new Persistence\Utf8Converter()); @@ -106,7 +106,7 @@ public function testCompileMapAscii() ); } - public function testCompileMapUnicode() + public function testCompileMapUnicode(): void { $parser = new Persistence\TransformationProcessor\DefinitionBased\Parser(self::getInstallationDir()); $compiler = new Persistence\TransformationProcessor\PcreCompiler(new Persistence\Utf8Converter()); @@ -124,7 +124,7 @@ public function testCompileMapUnicode() ); } - public function testCompileReplace() + public function testCompileReplace(): void { $parser = new Persistence\TransformationProcessor\DefinitionBased\Parser(self::getInstallationDir()); $compiler = new Persistence\TransformationProcessor\PcreCompiler(new Persistence\Utf8Converter()); @@ -142,7 +142,7 @@ public function testCompileReplace() ); } - public function testCompileTranspose() + public function testCompileTranspose(): void { $parser = new Persistence\TransformationProcessor\DefinitionBased\Parser(self::getInstallationDir()); $compiler = new Persistence\TransformationProcessor\PcreCompiler(new Persistence\Utf8Converter()); @@ -160,7 +160,7 @@ public function testCompileTranspose() ); } - public function testCompileTransposeAsciiLowercase() + public function testCompileTransposeAsciiLowercase(): void { $parser = new Persistence\TransformationProcessor\DefinitionBased\Parser(self::getInstallationDir()); $compiler = new Persistence\TransformationProcessor\PcreCompiler(new Persistence\Utf8Converter()); @@ -178,7 +178,7 @@ public function testCompileTransposeAsciiLowercase() ); } - public function testCompileTransposePlus() + public function testCompileTransposePlus(): void { $parser = new Persistence\TransformationProcessor\DefinitionBased\Parser(self::getInstallationDir()); $compiler = new Persistence\TransformationProcessor\PcreCompiler(new Persistence\Utf8Converter()); @@ -196,7 +196,7 @@ public function testCompileTransposePlus() ); } - public function testCompileModuloTranspose() + public function testCompileModuloTranspose(): void { $parser = new Persistence\TransformationProcessor\DefinitionBased\Parser(self::getInstallationDir()); $compiler = new Persistence\TransformationProcessor\PcreCompiler(new Persistence\Utf8Converter()); diff --git a/tests/lib/Persistence/TransformationProcessor/TransformationProcessorPreprocessedBasedTest.php b/tests/lib/Persistence/TransformationProcessor/TransformationProcessorPreprocessedBasedTest.php index f94991fd5b..5d2e97690c 100644 --- a/tests/lib/Persistence/TransformationProcessor/TransformationProcessorPreprocessedBasedTest.php +++ b/tests/lib/Persistence/TransformationProcessor/TransformationProcessorPreprocessedBasedTest.php @@ -29,7 +29,7 @@ public function getProcessor() ); } - public function testSimpleNormalizationLowercase() + public function testSimpleNormalizationLowercase(): void { $processor = $this->getProcessor(); @@ -39,7 +39,7 @@ public function testSimpleNormalizationLowercase() ); } - public function testSimpleNormalizationUppercase() + public function testSimpleNormalizationUppercase(): void { $processor = $this->getProcessor(); @@ -54,7 +54,7 @@ public function testSimpleNormalizationUppercase() * available can be compiled without errors. The actual expectation is not * important. */ - public function testAllNormalizations() + public function testAllNormalizations(): void { $processor = $this->getProcessor(); diff --git a/tests/lib/QueryType/BuiltIn/AbstractQueryTypeTestCase.php b/tests/lib/QueryType/BuiltIn/AbstractQueryTypeTestCase.php index 915ab80aec..b84aa54265 100644 --- a/tests/lib/QueryType/BuiltIn/AbstractQueryTypeTestCase.php +++ b/tests/lib/QueryType/BuiltIn/AbstractQueryTypeTestCase.php @@ -15,6 +15,7 @@ use Ibexa\Core\QueryType\BuiltIn\SortClausesFactoryInterface; use Ibexa\Core\QueryType\QueryType; use Ibexa\Core\Repository\Values\Content\Location; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; abstract class AbstractQueryTypeTestCase extends TestCase @@ -65,9 +66,7 @@ protected function setUp(): void ); } - /** - * @dataProvider dataProviderForGetQuery - */ + #[DataProvider('dataProviderForGetQuery')] final public function testGetQuery(array $parameters, Query $expectedQuery): void { self::assertEquals($expectedQuery, $this->queryType->getQuery($parameters)); @@ -89,7 +88,7 @@ final public function testGetSupportedParameters(): void ); } - abstract public function dataProviderForGetQuery(): iterable; + abstract public static function dataProviderForGetQuery(): iterable; abstract protected function createQueryType( Repository $repository, diff --git a/tests/lib/QueryType/BuiltIn/AncestorsQueryTypeTest.php b/tests/lib/QueryType/BuiltIn/AncestorsQueryTypeTest.php index ece2de2af8..f9e38f610a 100644 --- a/tests/lib/QueryType/BuiltIn/AncestorsQueryTypeTest.php +++ b/tests/lib/QueryType/BuiltIn/AncestorsQueryTypeTest.php @@ -30,7 +30,7 @@ final class AncestorsQueryTypeTest extends AbstractQueryTypeTestCase private const EXAMPLE_LOCATION_ID = 54; private const EXAMPLE_LOCATION_PATH_STRING = '/1/2/54/'; - public function dataProviderForGetQuery(): iterable + public static function dataProviderForGetQuery(): iterable { $location = new Location([ 'id' => self::EXAMPLE_LOCATION_ID, diff --git a/tests/lib/QueryType/BuiltIn/ChildrenQueryTypeTest.php b/tests/lib/QueryType/BuiltIn/ChildrenQueryTypeTest.php index d9024eb63b..d2dd7fe44b 100644 --- a/tests/lib/QueryType/BuiltIn/ChildrenQueryTypeTest.php +++ b/tests/lib/QueryType/BuiltIn/ChildrenQueryTypeTest.php @@ -27,7 +27,7 @@ final class ChildrenQueryTypeTest extends AbstractQueryTypeTestCase { private const EXAMPLE_LOCATION_ID = 54; - public function dataProviderForGetQuery(): iterable + public static function dataProviderForGetQuery(): iterable { $location = new Location([ 'id' => self::EXAMPLE_LOCATION_ID, diff --git a/tests/lib/QueryType/BuiltIn/GeoLocationQueryTypeTest.php b/tests/lib/QueryType/BuiltIn/GeoLocationQueryTypeTest.php index d055c36711..47c2a5e600 100644 --- a/tests/lib/QueryType/BuiltIn/GeoLocationQueryTypeTest.php +++ b/tests/lib/QueryType/BuiltIn/GeoLocationQueryTypeTest.php @@ -29,7 +29,7 @@ final class GeoLocationQueryTypeTest extends AbstractQueryTypeTestCase private const EXAMPLE_LATITUDE = 50.06314; private const EXAMPLE_LONGITUDE = 19.929843; - public function dataProviderForGetQuery(): iterable + public static function dataProviderForGetQuery(): iterable { $parameters = [ 'field' => self::EXAMPLE_FIELD, diff --git a/tests/lib/QueryType/BuiltIn/RelatedToContentQueryTypeTest.php b/tests/lib/QueryType/BuiltIn/RelatedToContentQueryTypeTest.php index 99646e8e7e..ae125c452d 100644 --- a/tests/lib/QueryType/BuiltIn/RelatedToContentQueryTypeTest.php +++ b/tests/lib/QueryType/BuiltIn/RelatedToContentQueryTypeTest.php @@ -27,7 +27,7 @@ final class RelatedToContentQueryTypeTest extends AbstractQueryTypeTestCase private const EXAMPLE_CONTENT_ID = 52; private const EXAMPLE_FIELD = 'related'; - public function dataProviderForGetQuery(): iterable + public static function dataProviderForGetQuery(): iterable { yield 'basic' => [ [ diff --git a/tests/lib/QueryType/BuiltIn/SiblingsQueryTypeTest.php b/tests/lib/QueryType/BuiltIn/SiblingsQueryTypeTest.php index d9a1ff34ee..796993a514 100644 --- a/tests/lib/QueryType/BuiltIn/SiblingsQueryTypeTest.php +++ b/tests/lib/QueryType/BuiltIn/SiblingsQueryTypeTest.php @@ -27,7 +27,7 @@ final class SiblingsQueryTypeTest extends AbstractQueryTypeTestCase { private const EXAMPLE_LOCATION_ID = 54; - public function dataProviderForGetQuery(): iterable + public static function dataProviderForGetQuery(): iterable { $location = new Location([ 'id' => self::EXAMPLE_LOCATION_ID, diff --git a/tests/lib/QueryType/BuiltIn/SortSpec/SortClauseParser/DefaultSortClauseParserTest.php b/tests/lib/QueryType/BuiltIn/SortSpec/SortClauseParser/DefaultSortClauseParserTest.php index a59ee3c171..dbaf041a7a 100644 --- a/tests/lib/QueryType/BuiltIn/SortSpec/SortClauseParser/DefaultSortClauseParserTest.php +++ b/tests/lib/QueryType/BuiltIn/SortSpec/SortClauseParser/DefaultSortClauseParserTest.php @@ -55,7 +55,7 @@ public function testParseThrowsUnsupportedSortClauseException(): void )); $this->defaultSortClauseParser->parse( - $this->createMock(SortSpecParserInterface::class), + self::createStub(SortSpecParserInterface::class), 'unsupported' ); } diff --git a/tests/lib/QueryType/BuiltIn/SortSpec/SortClauseParser/FieldSortClauseParserTest.php b/tests/lib/QueryType/BuiltIn/SortSpec/SortClauseParser/FieldSortClauseParserTest.php index 82be846943..e6f1652df5 100644 --- a/tests/lib/QueryType/BuiltIn/SortSpec/SortClauseParser/FieldSortClauseParserTest.php +++ b/tests/lib/QueryType/BuiltIn/SortSpec/SortClauseParser/FieldSortClauseParserTest.php @@ -31,18 +31,25 @@ protected function setUp(): void public function testParse(): void { $parser = $this->createMock(SortSpecParserInterface::class); - $parser - ->method('match') - ->withConsecutive( - [Token::TYPE_ID], - [Token::TYPE_DOT], - [Token::TYPE_ID] - ) - ->willReturnOnConsecutiveCalls( - new Token(Token::TYPE_ID, self::EXAMPLE_CONTENT_TYPE_ID), - new Token(Token::TYPE_DOT), - new Token(Token::TYPE_ID, self::EXAMPLE_FIELD_ID) - ); + $matcher = $this->exactly(3); + $parser->expects($matcher) + ->method('match')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame(Token::TYPE_ID, $parameters[0]); + + return new Token(Token::TYPE_ID, self::EXAMPLE_CONTENT_TYPE_ID); + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame(Token::TYPE_DOT, $parameters[0]); + + return new Token(Token::TYPE_DOT); + } + if ($matcher->numberOfInvocations() === 3) { + $this->assertSame(Token::TYPE_ID, $parameters[0]); + + return new Token(Token::TYPE_ID, self::EXAMPLE_FIELD_ID); + } + }); $parser->method('parseSortDirection')->willReturn(Query::SORT_ASC); diff --git a/tests/lib/QueryType/BuiltIn/SortSpec/SortClauseParser/MapDistanceSortClauseParserTest.php b/tests/lib/QueryType/BuiltIn/SortSpec/SortClauseParser/MapDistanceSortClauseParserTest.php index d7bcdc903e..1755e42758 100644 --- a/tests/lib/QueryType/BuiltIn/SortSpec/SortClauseParser/MapDistanceSortClauseParserTest.php +++ b/tests/lib/QueryType/BuiltIn/SortSpec/SortClauseParser/MapDistanceSortClauseParserTest.php @@ -33,22 +33,35 @@ protected function setUp(): void public function testParse(): void { $parser = $this->createMock(SortSpecParserInterface::class); - $parser - ->method('match') - ->withConsecutive( - [Token::TYPE_ID], - [Token::TYPE_DOT], - [Token::TYPE_ID], - [Token::TYPE_FLOAT], - [Token::TYPE_FLOAT] - ) - ->willReturnOnConsecutiveCalls( - new Token(Token::TYPE_ID, self::EXAMPLE_CONTENT_TYPE_ID), - new Token(Token::TYPE_DOT), - new Token(Token::TYPE_ID, self::EXAMPLE_FIELD_ID), - new Token(Token::TYPE_FLOAT, (string)self::EXAMPLE_LAT), - new Token(Token::TYPE_FLOAT, (string)self::EXAMPLE_LON) - ); + $matcher = $this->exactly(5); + $parser->expects($matcher) + ->method('match')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame(Token::TYPE_ID, $parameters[0]); + + return new Token(Token::TYPE_ID, self::EXAMPLE_CONTENT_TYPE_ID); + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame(Token::TYPE_DOT, $parameters[0]); + + return new Token(Token::TYPE_DOT); + } + if ($matcher->numberOfInvocations() === 3) { + $this->assertSame(Token::TYPE_ID, $parameters[0]); + + return new Token(Token::TYPE_ID, self::EXAMPLE_FIELD_ID); + } + if ($matcher->numberOfInvocations() === 4) { + $this->assertSame(Token::TYPE_FLOAT, $parameters[0]); + + return new Token(Token::TYPE_FLOAT, (string)self::EXAMPLE_LAT); + } + if ($matcher->numberOfInvocations() === 5) { + $this->assertSame(Token::TYPE_FLOAT, $parameters[0]); + + return new Token(Token::TYPE_FLOAT, (string)self::EXAMPLE_LON); + } + }); $parser->method('parseSortDirection')->willReturn(Query::SORT_ASC); diff --git a/tests/lib/QueryType/BuiltIn/SortSpec/SortClauseParserDispatcherTest.php b/tests/lib/QueryType/BuiltIn/SortSpec/SortClauseParserDispatcherTest.php index 409c4e75d0..72b8231a24 100644 --- a/tests/lib/QueryType/BuiltIn/SortSpec/SortClauseParserDispatcherTest.php +++ b/tests/lib/QueryType/BuiltIn/SortSpec/SortClauseParserDispatcherTest.php @@ -21,8 +21,8 @@ final class SortClauseParserDispatcherTest extends TestCase public function testParse(): void { - $sortSpecParser = $this->createMock(SortSpecParserInterface::class); - $sortClause = $this->createMock(SortClause::class); + $sortSpecParser = self::createStub(SortSpecParserInterface::class); + $sortClause = self::createStub(SortClause::class); $parser = $this->createMock(SortClauseParserInterface::class); $parser->method('supports')->with(self::EXAMPLE_SORT_CLAUSE)->willReturn(true); @@ -49,7 +49,7 @@ public function testParseThrowsUnsupportedSortClauseException(): void $parser->method('supports')->with(self::EXAMPLE_SORT_CLAUSE)->willReturn(false); $dispatcher = new SortClauseParserDispatcher([$parser]); - $dispatcher->parse($this->createMock(SortSpecParserInterface::class), self::EXAMPLE_SORT_CLAUSE); + $dispatcher->parse(self::createStub(SortSpecParserInterface::class), self::EXAMPLE_SORT_CLAUSE); } public function testSupports(): void diff --git a/tests/lib/QueryType/BuiltIn/SortSpec/SortSpecLexerTest.php b/tests/lib/QueryType/BuiltIn/SortSpec/SortSpecLexerTest.php index bb7d8c41fa..ab24aa2863 100644 --- a/tests/lib/QueryType/BuiltIn/SortSpec/SortSpecLexerTest.php +++ b/tests/lib/QueryType/BuiltIn/SortSpec/SortSpecLexerTest.php @@ -10,13 +10,12 @@ use Ibexa\Core\QueryType\BuiltIn\SortSpec\SortSpecLexer; use Ibexa\Core\QueryType\BuiltIn\SortSpec\Token; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; final class SortSpecLexerTest extends TestCase { - /** - * @dataProvider dataProviderForTokenize - */ + #[DataProvider('dataProviderForTokenize')] public function testTokenize(string $input, iterable $expectedTokens): void { $lexer = new SortSpecLexer(); @@ -25,7 +24,7 @@ public function testTokenize(string $input, iterable $expectedTokens): void self::assertEquals($expectedTokens, $lexer->getAll()); } - public function dataProviderForTokenize(): iterable + public static function dataProviderForTokenize(): iterable { yield 'keyword: asc' => [ 'asc', diff --git a/tests/lib/QueryType/BuiltIn/SortSpec/SortSpecParserTest.php b/tests/lib/QueryType/BuiltIn/SortSpec/SortSpecParserTest.php index 848f179469..f72d3501f6 100644 --- a/tests/lib/QueryType/BuiltIn/SortSpec/SortSpecParserTest.php +++ b/tests/lib/QueryType/BuiltIn/SortSpec/SortSpecParserTest.php @@ -15,23 +15,22 @@ use Ibexa\Core\QueryType\BuiltIn\SortSpec\SortSpecParser; use Ibexa\Core\QueryType\BuiltIn\SortSpec\Token; use Ibexa\Tests\Core\Search\TestCase; +use PHPUnit\Framework\Attributes\DataProvider; final class SortSpecParserTest extends TestCase { private const EXAMPLE_SORT_CLAUSE_ID = 'id'; - /** - * @dataProvider dataProviderForParseSortDirection - */ + #[DataProvider('dataProviderForParseSortDirection')] public function testParseSortDirection(array $input, string $expectedDirection): void { $lexer = new SortSpecLexerStub($input); - $parser = new SortSpecParser($this->createMock(SortClauseParserInterface::class), $lexer); + $parser = new SortSpecParser(self::createStub(SortClauseParserInterface::class), $lexer); self::assertEquals($expectedDirection, $parser->parseSortDirection()); } - public function dataProviderForParseSortDirection(): iterable + public static function dataProviderForParseSortDirection(): iterable { yield 'asc' => [ [ @@ -69,8 +68,8 @@ public function testParseSortClauseList(): void $sortClauseArgsParser = $this->createMock(SortClauseParserInterface::class); $parser = new SortSpecParser($sortClauseArgsParser, $lexer); - $sortClauseA = $this->createMock(SortClause::class); - $sortClauseB = $this->createMock(SortClause::class); + $sortClauseA = self::createStub(SortClause::class); + $sortClauseB = self::createStub(SortClause::class); $sortClauseArgsParser ->method('parse') @@ -93,7 +92,7 @@ public function testParseSortClause(): void $sortClauseArgsParser = $this->createMock(SortClauseParserInterface::class); $parser = new SortSpecParser($sortClauseArgsParser, $lexer); - $sortClause = $this->createMock(SortClause::class); + $sortClause = self::createStub(SortClause::class); $sortClauseArgsParser ->expects(self::once()) ->method('parse') @@ -112,7 +111,7 @@ public function testMatch(): void $lexer->expects(self::once())->method('consume')->willReturn($token); $parser = new SortSpecParser( - $this->createMock(SortClauseParserInterface::class), + self::createStub(SortClauseParserInterface::class), $lexer ); @@ -128,7 +127,7 @@ public function testMatchAny(): void $lexer->expects(self::once())->method('consume')->willReturn($token); $parser = new SortSpecParser( - $this->createMock(SortClauseParserInterface::class), + self::createStub(SortClauseParserInterface::class), $lexer ); diff --git a/tests/lib/QueryType/BuiltIn/SubtreeQueryTest.php b/tests/lib/QueryType/BuiltIn/SubtreeQueryTest.php index 671c613bbe..426a41692f 100644 --- a/tests/lib/QueryType/BuiltIn/SubtreeQueryTest.php +++ b/tests/lib/QueryType/BuiltIn/SubtreeQueryTest.php @@ -30,7 +30,7 @@ final class SubtreeQueryTest extends AbstractQueryTypeTestCase private const EXAMPLE_LOCATION_PATH_STRING = '/1/2/54/'; private const EXAMPLE_LOCATION_DEPTH = 3; - public function dataProviderForGetQuery(): iterable + public static function dataProviderForGetQuery(): iterable { $location = new Location([ 'id' => self::EXAMPLE_LOCATION_ID, diff --git a/tests/lib/Repository/ContentService/RelationListFacadeTest.php b/tests/lib/Repository/ContentService/RelationListFacadeTest.php index 79a6477ee6..d6fba30090 100644 --- a/tests/lib/Repository/ContentService/RelationListFacadeTest.php +++ b/tests/lib/Repository/ContentService/RelationListFacadeTest.php @@ -15,6 +15,7 @@ use Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo; use Ibexa\Core\Repository\ContentService\RelationListFacade; use PHPUnit\Framework\MockObject\MockObject; +use PHPUnit\Framework\MockObject\Stub; use PHPUnit\Framework\TestCase; final class RelationListFacadeTest extends TestCase @@ -23,12 +24,12 @@ final class RelationListFacadeTest extends TestCase private RelationListFacade $relationListFacade; - private VersionInfo&MockObject $versionInfo; + private VersionInfo&Stub $versionInfo; protected function setUp(): void { $this->contentService = $this->createMock(ContentService::class); - $this->versionInfo = $this->createMock(VersionInfo::class); + $this->versionInfo = self::createStub(VersionInfo::class); $this->relationListFacade = new RelationListFacade($this->contentService); } @@ -73,7 +74,7 @@ public function testGetRelationsIgnoresItemsWithoutRelations(): void public function testGetRelationsYieldsRelationsWhenPresent(): void { - $relation = $this->createMock(Relation::class); + $relation = self::createStub(Relation::class); $relationListItem = $this->createMock(RelationListItemInterface::class); $relationListItem diff --git a/tests/lib/Repository/ContentServiceTest.php b/tests/lib/Repository/ContentServiceTest.php index 17ed2cd3a5..1e53e122c6 100644 --- a/tests/lib/Repository/ContentServiceTest.php +++ b/tests/lib/Repository/ContentServiceTest.php @@ -35,18 +35,18 @@ final class ContentServiceTest extends TestCase protected function setUp(): void { $this->contentService = new ContentService( - $this->createMock(Repository::class), - $this->createMock(PersistenceHandler::class), - $this->createMock(ContentDomainMapper::class), - $this->createMock(RelationProcessor::class), - $this->createMock(NameSchemaServiceInterface::class), - $this->createMock(FieldTypeRegistry::class), - $this->createMock(PermissionService::class), - $this->createMock(ContentMapper::class), - $this->createMock(ContentValidator::class), - $this->createMock(ContentFilteringHandler::class), + self::createStub(Repository::class), + self::createStub(PersistenceHandler::class), + self::createStub(ContentDomainMapper::class), + self::createStub(RelationProcessor::class), + self::createStub(NameSchemaServiceInterface::class), + self::createStub(FieldTypeRegistry::class), + self::createStub(PermissionService::class), + self::createStub(ContentMapper::class), + self::createStub(ContentValidator::class), + self::createStub(ContentFilteringHandler::class), new ContentCollector(), - $this->createMock(ValidatorInterface::class), + self::createStub(ValidatorInterface::class), ); } diff --git a/tests/lib/Repository/ContentThumbnail/StaticStrategyTest.php b/tests/lib/Repository/ContentThumbnail/StaticStrategyTest.php index 8466f7b65e..53603d92a1 100644 --- a/tests/lib/Repository/ContentThumbnail/StaticStrategyTest.php +++ b/tests/lib/Repository/ContentThumbnail/StaticStrategyTest.php @@ -16,17 +16,17 @@ class StaticStrategyTest extends TestCase { - public function testStaticStrategy() + public function testStaticStrategy(): void { $resource = 'static-test-resource'; $staticStrategy = new StaticStrategy($resource); - $contentTypeMock = $this->createMock(ContentType::class); + $contentTypeMock = self::createStub(ContentType::class); $fieldMocks = [ - $this->createMock(Field::class), - $this->createMock(Field::class), - $this->createMock(Field::class), + self::createStub(Field::class), + self::createStub(Field::class), + self::createStub(Field::class), ]; $result = $staticStrategy->getThumbnail( diff --git a/tests/lib/Repository/ContentThumbnail/ThumbnailChainStrategyTest.php b/tests/lib/Repository/ContentThumbnail/ThumbnailChainStrategyTest.php index b230a69629..fb0236604c 100644 --- a/tests/lib/Repository/ContentThumbnail/ThumbnailChainStrategyTest.php +++ b/tests/lib/Repository/ContentThumbnail/ThumbnailChainStrategyTest.php @@ -22,11 +22,11 @@ public function testThumbnailStrategyChaining(): void $firstStrategyMock = $this->createMock(ThumbnailStrategy::class); $secondStrategyMock = $this->createMock(ThumbnailStrategy::class); - $contentTypeMock = $this->createMock(ContentType::class); + $contentTypeMock = self::createStub(ContentType::class); $fieldMocks = [ - $this->createMock(Field::class), - $this->createMock(Field::class), - $this->createMock(Field::class), + self::createStub(Field::class), + self::createStub(Field::class), + self::createStub(Field::class), ]; $firstStrategyMock @@ -58,11 +58,11 @@ public function testThumbnailStrategyChainBreakOnThumbnailFound(): void $secondStrategyMock = $this->createMock(ThumbnailStrategy::class); $thirdStrategyMock = $this->createMock(ThumbnailStrategy::class); - $contentTypeMock = $this->createMock(ContentType::class); + $contentTypeMock = self::createStub(ContentType::class); $fieldMocks = [ - $this->createMock(Field::class), - $this->createMock(Field::class), - $this->createMock(Field::class), + self::createStub(Field::class), + self::createStub(Field::class), + self::createStub(Field::class), ]; $firstStrategyMock diff --git a/tests/lib/Repository/Decorator/BookmarkServiceDecoratorTest.php b/tests/lib/Repository/Decorator/BookmarkServiceDecoratorTest.php index f261461ddf..e68ccb5589 100644 --- a/tests/lib/Repository/Decorator/BookmarkServiceDecoratorTest.php +++ b/tests/lib/Repository/Decorator/BookmarkServiceDecoratorTest.php @@ -27,31 +27,31 @@ protected function createServiceMock(): MockObject return $this->createMock(BookmarkService::class); } - public function testCreateBookmarkDecorator() + public function testCreateBookmarkDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Location::class)]; + $parameters = [self::createStub(Location::class)]; $serviceMock->expects(self::once())->method('createBookmark')->with(...$parameters); $decoratedService->createBookmark(...$parameters); } - public function testDeleteBookmarkDecorator() + public function testDeleteBookmarkDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Location::class)]; + $parameters = [self::createStub(Location::class)]; $serviceMock->expects(self::once())->method('deleteBookmark')->with(...$parameters); $decoratedService->deleteBookmark(...$parameters); } - public function testLoadBookmarksDecorator() + public function testLoadBookmarksDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -66,12 +66,12 @@ public function testLoadBookmarksDecorator() $decoratedService->loadBookmarks(...$parameters); } - public function testIsBookmarkedDecorator() + public function testIsBookmarkedDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Location::class)]; + $parameters = [self::createStub(Location::class)]; $serviceMock->expects(self::once())->method('isBookmarked')->with(...$parameters); diff --git a/tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php b/tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php index 60d41317d4..9498b0d92b 100644 --- a/tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php +++ b/tests/lib/Repository/Decorator/ContentServiceDecoratorTest.php @@ -43,19 +43,19 @@ protected function createServiceMock(): ContentService&MockObject return $this->createMock(ContentService::class); } - public function testLoadContentInfoDecorator() + public function testLoadContentInfoDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [self::EXAMPLE_CONTENT_ID]; - $serviceMock->expects(self::once())->method('loadContentInfo')->with(...$parameters)->willReturn($this->createMock(ContentInfo::class)); + $serviceMock->expects(self::once())->method('loadContentInfo')->with(...$parameters)->willReturn(self::createStub(ContentInfo::class)); $decoratedService->loadContentInfo(...$parameters); } - public function testLoadContentInfoListDecorator() + public function testLoadContentInfoListDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -67,34 +67,34 @@ public function testLoadContentInfoListDecorator() $decoratedService->loadContentInfoList(...$parameters); } - public function testLoadContentInfoByRemoteIdDecorator() + public function testLoadContentInfoByRemoteIdDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = ['random_value_5ced05ce1541a6.54558542']; - $serviceMock->expects(self::once())->method('loadContentInfoByRemoteId')->with(...$parameters)->willReturn($this->createMock(ContentInfo::class)); + $serviceMock->expects(self::once())->method('loadContentInfoByRemoteId')->with(...$parameters)->willReturn(self::createStub(ContentInfo::class)); $decoratedService->loadContentInfoByRemoteId(...$parameters); } - public function testLoadVersionInfoDecorator() + public function testLoadVersionInfoDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentInfo::class), + self::createStub(ContentInfo::class), self::EXAMPLE_VERSION_NO, ]; - $serviceMock->expects(self::once())->method('loadVersionInfo')->with(...$parameters)->willReturn($this->createMock(VersionInfo::class)); + $serviceMock->expects(self::once())->method('loadVersionInfo')->with(...$parameters)->willReturn(self::createStub(VersionInfo::class)); $decoratedService->loadVersionInfo(...$parameters); } - public function testLoadVersionInfoByIdDecorator() + public function testLoadVersionInfoByIdDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -104,45 +104,45 @@ public function testLoadVersionInfoByIdDecorator() self::EXAMPLE_VERSION_NO, ]; - $serviceMock->expects(self::once())->method('loadVersionInfoById')->with(...$parameters)->willReturn($this->createMock(VersionInfo::class)); + $serviceMock->expects(self::once())->method('loadVersionInfoById')->with(...$parameters)->willReturn(self::createStub(VersionInfo::class)); $decoratedService->loadVersionInfoById(...$parameters); } - public function testLoadContentByContentInfoDecorator() + public function testLoadContentByContentInfoDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentInfo::class), + self::createStub(ContentInfo::class), [self::EXAMPLE_LANGUAGE_CODE], self::EXAMPLE_VERSION_NO, true, ]; - $serviceMock->expects(self::once())->method('loadContentByContentInfo')->with(...$parameters)->willReturn($this->createMock(Content::class)); + $serviceMock->expects(self::once())->method('loadContentByContentInfo')->with(...$parameters)->willReturn(self::createStub(Content::class)); $decoratedService->loadContentByContentInfo(...$parameters); } - public function testLoadContentByVersionInfoDecorator() + public function testLoadContentByVersionInfoDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(VersionInfo::class), + self::createStub(VersionInfo::class), [self::EXAMPLE_LANGUAGE_CODE], true, ]; - $serviceMock->expects(self::once())->method('loadContentByVersionInfo')->with(...$parameters)->willReturn($this->createMock(Content::class)); + $serviceMock->expects(self::once())->method('loadContentByVersionInfo')->with(...$parameters)->willReturn(self::createStub(Content::class)); $decoratedService->loadContentByVersionInfo(...$parameters); } - public function testLoadContentDecorator() + public function testLoadContentDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -154,12 +154,12 @@ public function testLoadContentDecorator() true, ]; - $serviceMock->expects(self::once())->method('loadContent')->with(...$parameters)->willReturn($this->createMock(Content::class)); + $serviceMock->expects(self::once())->method('loadContent')->with(...$parameters)->willReturn(self::createStub(Content::class)); $decoratedService->loadContent(...$parameters); } - public function testLoadContentByRemoteIdDecorator() + public function testLoadContentByRemoteIdDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -171,18 +171,18 @@ public function testLoadContentByRemoteIdDecorator() true, ]; - $serviceMock->expects(self::once())->method('loadContentByRemoteId')->with(...$parameters)->willReturn($this->createMock(Content::class)); + $serviceMock->expects(self::once())->method('loadContentByRemoteId')->with(...$parameters)->willReturn(self::createStub(Content::class)); $decoratedService->loadContentByRemoteId(...$parameters); } - public function testLoadContentListByContentInfoDecorator() + public function testLoadContentListByContentInfoDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - [$this->createMock(ContentInfo::class)], + [self::createStub(ContentInfo::class)], [self::EXAMPLE_LANGUAGE_CODE], true, ]; @@ -192,60 +192,60 @@ public function testLoadContentListByContentInfoDecorator() $decoratedService->loadContentListByContentInfo(...$parameters); } - public function testCreateContentDecorator() + public function testCreateContentDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentCreateStruct::class), + self::createStub(ContentCreateStruct::class), ['random_value_5ced05ce155881.06739513'], ]; - $serviceMock->expects(self::once())->method('createContent')->with(...$parameters)->willReturn($this->createMock(Content::class)); + $serviceMock->expects(self::once())->method('createContent')->with(...$parameters)->willReturn(self::createStub(Content::class)); $decoratedService->createContent(...$parameters); } - public function testUpdateContentMetadataDecorator() + public function testUpdateContentMetadataDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(ContentMetadataUpdateStruct::class), + self::createStub(ContentInfo::class), + self::createStub(ContentMetadataUpdateStruct::class), ]; - $serviceMock->expects(self::once())->method('updateContentMetadata')->with(...$parameters)->willReturn($this->createMock(Content::class)); + $serviceMock->expects(self::once())->method('updateContentMetadata')->with(...$parameters)->willReturn(self::createStub(Content::class)); $decoratedService->updateContentMetadata(...$parameters); } - public function testDeleteContentDecorator() + public function testDeleteContentDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(ContentInfo::class)]; + $parameters = [self::createStub(ContentInfo::class)]; $serviceMock->expects(self::once())->method('deleteContent')->with(...$parameters)->willReturn([]); $decoratedService->deleteContent(...$parameters); } - public function testCreateContentDraftDecorator() + public function testCreateContentDraftDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(VersionInfo::class), - $this->createMock(User::class), + self::createStub(ContentInfo::class), + self::createStub(VersionInfo::class), + self::createStub(User::class), ]; - $serviceMock->expects(self::once())->method('createContentDraft')->with(...$parameters)->willReturn($this->createMock(Content::class)); + $serviceMock->expects(self::once())->method('createContentDraft')->with(...$parameters)->willReturn(self::createStub(Content::class)); $decoratedService->createContentDraft(...$parameters); } @@ -255,76 +255,76 @@ public function testLoadContentDraftListDecorator(): void $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(User::class)]; + $parameters = [self::createStub(User::class)]; $serviceMock->expects(self::once())->method('loadContentDraftList')->with(...$parameters)->willReturn(new ContentDraftList()); $decoratedService->loadContentDraftList(...$parameters); } - public function testUpdateContentDecorator() + public function testUpdateContentDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(VersionInfo::class), - $this->createMock(ContentUpdateStruct::class), + self::createStub(VersionInfo::class), + self::createStub(ContentUpdateStruct::class), ]; - $serviceMock->expects(self::once())->method('updateContent')->with(...$parameters)->willReturn($this->createMock(Content::class)); + $serviceMock->expects(self::once())->method('updateContent')->with(...$parameters)->willReturn(self::createStub(Content::class)); $decoratedService->updateContent(...$parameters); } - public function testPublishVersionDecorator() + public function testPublishVersionDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(VersionInfo::class)]; + $parameters = [self::createStub(VersionInfo::class)]; - $serviceMock->expects(self::once())->method('publishVersion')->with(...$parameters)->willReturn($this->createMock(Content::class)); + $serviceMock->expects(self::once())->method('publishVersion')->with(...$parameters)->willReturn(self::createStub(Content::class)); $decoratedService->publishVersion(...$parameters); } - public function testDeleteVersionDecorator() + public function testDeleteVersionDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(VersionInfo::class)]; + $parameters = [self::createStub(VersionInfo::class)]; $serviceMock->expects(self::once())->method('deleteVersion')->with(...$parameters); $decoratedService->deleteVersion(...$parameters); } - public function testLoadVersionsDecorator() + public function testLoadVersionsDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(ContentInfo::class)]; + $parameters = [self::createStub(ContentInfo::class)]; $serviceMock->expects(self::once())->method('loadVersions')->with(...$parameters)->willReturn([]); $decoratedService->loadVersions(...$parameters); } - public function testCopyContentDecorator() + public function testCopyContentDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(LocationCreateStruct::class), - $this->createMock(VersionInfo::class), + self::createStub(ContentInfo::class), + self::createStub(LocationCreateStruct::class), + self::createStub(VersionInfo::class), ]; - $serviceMock->expects(self::once())->method('copyContent')->with(...$parameters)->willReturn($this->createMock(Content::class)); + $serviceMock->expects(self::once())->method('copyContent')->with(...$parameters)->willReturn(self::createStub(Content::class)); $decoratedService->copyContent(...$parameters); } @@ -334,48 +334,48 @@ public function testLoadRelationListDecorator(): void $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(VersionInfo::class)]; + $parameters = [self::createStub(VersionInfo::class)]; $serviceMock->expects(self::once())->method('loadRelationList')->with(...$parameters)->willReturn(new RelationList()); $decoratedService->loadRelationList(...$parameters); } - public function testLoadReverseRelationsDecorator() + public function testLoadReverseRelationsDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(ContentInfo::class)]; + $parameters = [self::createStub(ContentInfo::class)]; $serviceMock->expects(self::once())->method('loadReverseRelations')->with(...$parameters)->willReturn([]); $decoratedService->loadReverseRelations(...$parameters); } - public function testAddRelationDecorator() + public function testAddRelationDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(VersionInfo::class), - $this->createMock(ContentInfo::class), + self::createStub(VersionInfo::class), + self::createStub(ContentInfo::class), ]; - $serviceMock->expects(self::once())->method('addRelation')->with(...$parameters)->willReturn($this->createMock(Relation::class)); + $serviceMock->expects(self::once())->method('addRelation')->with(...$parameters)->willReturn(self::createStub(Relation::class)); $decoratedService->addRelation(...$parameters); } - public function testDeleteRelationDecorator() + public function testDeleteRelationDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(VersionInfo::class), - $this->createMock(ContentInfo::class), + self::createStub(VersionInfo::class), + self::createStub(ContentInfo::class), ]; $serviceMock->expects(self::once())->method('deleteRelation')->with(...$parameters); @@ -383,13 +383,13 @@ public function testDeleteRelationDecorator() $decoratedService->deleteRelation(...$parameters); } - public function testDeleteTranslationDecorator() + public function testDeleteTranslationDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentInfo::class), + self::createStub(ContentInfo::class), self::EXAMPLE_LANGUAGE_CODE, ]; @@ -398,80 +398,80 @@ public function testDeleteTranslationDecorator() $decoratedService->deleteTranslation(...$parameters); } - public function testDeleteTranslationFromDraftDecorator() + public function testDeleteTranslationFromDraftDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(VersionInfo::class), + self::createStub(VersionInfo::class), 'random_value_5ced05ce156d37.22902273', ]; - $serviceMock->expects(self::once())->method('deleteTranslationFromDraft')->with(...$parameters)->willReturn($this->createMock(Content::class)); + $serviceMock->expects(self::once())->method('deleteTranslationFromDraft')->with(...$parameters)->willReturn(self::createStub(Content::class)); $decoratedService->deleteTranslationFromDraft(...$parameters); } - public function testHideContentDecorator() + public function testHideContentDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(ContentInfo::class)]; + $parameters = [self::createStub(ContentInfo::class)]; $serviceMock->expects(self::once())->method('hideContent')->with(...$parameters); $decoratedService->hideContent(...$parameters); } - public function testRevealContentDecorator() + public function testRevealContentDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(ContentInfo::class)]; + $parameters = [self::createStub(ContentInfo::class)]; $serviceMock->expects(self::once())->method('revealContent')->with(...$parameters); $decoratedService->revealContent(...$parameters); } - public function testNewContentCreateStructDecorator() + public function testNewContentCreateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentType::class), + self::createStub(ContentType::class), 'random_value_5ced05ce156db7.87562997', ]; - $serviceMock->expects(self::once())->method('newContentCreateStruct')->with(...$parameters)->willReturn($this->createMock(ContentCreateStruct::class)); + $serviceMock->expects(self::once())->method('newContentCreateStruct')->with(...$parameters)->willReturn(self::createStub(ContentCreateStruct::class)); $decoratedService->newContentCreateStruct(...$parameters); } - public function testNewContentMetadataUpdateStructDecorator() + public function testNewContentMetadataUpdateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = []; - $serviceMock->expects(self::once())->method('newContentMetadataUpdateStruct')->with(...$parameters)->willReturn($this->createMock(ContentMetadataUpdateStruct::class)); + $serviceMock->expects(self::once())->method('newContentMetadataUpdateStruct')->with(...$parameters)->willReturn(self::createStub(ContentMetadataUpdateStruct::class)); $decoratedService->newContentMetadataUpdateStruct(...$parameters); } - public function testNewContentUpdateStructDecorator() + public function testNewContentUpdateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = []; - $serviceMock->expects(self::once())->method('newContentUpdateStruct')->with(...$parameters)->willReturn($this->createMock(ContentUpdateStruct::class)); + $serviceMock->expects(self::once())->method('newContentUpdateStruct')->with(...$parameters)->willReturn(self::createStub(ContentUpdateStruct::class)); $decoratedService->newContentUpdateStruct(...$parameters); } @@ -486,7 +486,7 @@ public function testLoadVersionInfoListByContentInfoDecorator(): void $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $argument = [$this->createMock(ContentInfo::class)]; + $argument = [self::createStub(ContentInfo::class)]; $serviceMock ->expects(self::once()) diff --git a/tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php b/tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php index 7a7b4c175b..e0a3a4a7c3 100644 --- a/tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php +++ b/tests/lib/Repository/Decorator/ContentTypeServiceDecoratorTest.php @@ -37,19 +37,19 @@ protected function createServiceMock(): MockObject return $this->createMock(ContentTypeService::class); } - public function testCreateContentTypeGroupDecorator() + public function testCreateContentTypeGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(ContentTypeGroupCreateStruct::class)]; + $parameters = [self::createStub(ContentTypeGroupCreateStruct::class)]; $serviceMock->expects(self::once())->method('createContentTypeGroup')->with(...$parameters); $decoratedService->createContentTypeGroup(...$parameters); } - public function testLoadContentTypeGroupDecorator() + public function testLoadContentTypeGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -64,7 +64,7 @@ public function testLoadContentTypeGroupDecorator() $decoratedService->loadContentTypeGroup(...$parameters); } - public function testLoadContentTypeGroupByIdentifierDecorator() + public function testLoadContentTypeGroupByIdentifierDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -79,7 +79,7 @@ public function testLoadContentTypeGroupByIdentifierDecorator() $decoratedService->loadContentTypeGroupByIdentifier(...$parameters); } - public function testLoadContentTypeGroupsDecorator() + public function testLoadContentTypeGroupsDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -91,14 +91,14 @@ public function testLoadContentTypeGroupsDecorator() $decoratedService->loadContentTypeGroups(...$parameters); } - public function testUpdateContentTypeGroupDecorator() + public function testUpdateContentTypeGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentTypeGroup::class), - $this->createMock(ContentTypeGroupUpdateStruct::class), + self::createStub(ContentTypeGroup::class), + self::createStub(ContentTypeGroupUpdateStruct::class), ]; $serviceMock->expects(self::once())->method('updateContentTypeGroup')->with(...$parameters); @@ -106,25 +106,25 @@ public function testUpdateContentTypeGroupDecorator() $decoratedService->updateContentTypeGroup(...$parameters); } - public function testDeleteContentTypeGroupDecorator() + public function testDeleteContentTypeGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(ContentTypeGroup::class)]; + $parameters = [self::createStub(ContentTypeGroup::class)]; $serviceMock->expects(self::once())->method('deleteContentTypeGroup')->with(...$parameters); $decoratedService->deleteContentTypeGroup(...$parameters); } - public function testCreateContentTypeDecorator() + public function testCreateContentTypeDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentTypeCreateStruct::class), + self::createStub(ContentTypeCreateStruct::class), ['content_type_group_identifier'], ]; @@ -133,7 +133,7 @@ public function testCreateContentTypeDecorator() $decoratedService->createContentType(...$parameters); } - public function testLoadContentTypeDecorator() + public function testLoadContentTypeDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -148,7 +148,7 @@ public function testLoadContentTypeDecorator() $decoratedService->loadContentType(...$parameters); } - public function testLoadContentTypeByIdentifierDecorator() + public function testLoadContentTypeByIdentifierDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -163,7 +163,7 @@ public function testLoadContentTypeByIdentifierDecorator() $decoratedService->loadContentTypeByIdentifier(...$parameters); } - public function testLoadContentTypeByRemoteIdDecorator() + public function testLoadContentTypeByRemoteIdDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -178,7 +178,7 @@ public function testLoadContentTypeByRemoteIdDecorator() $decoratedService->loadContentTypeByRemoteId(...$parameters); } - public function testLoadContentTypeDraftDecorator() + public function testLoadContentTypeDraftDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -190,7 +190,7 @@ public function testLoadContentTypeDraftDecorator() $decoratedService->loadContentTypeDraft(...$parameters); } - public function testLoadContentTypeListDecorator() + public function testLoadContentTypeListDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -205,13 +205,13 @@ public function testLoadContentTypeListDecorator() $decoratedService->loadContentTypeList(...$parameters); } - public function testLoadContentTypesDecorator() + public function testLoadContentTypesDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentTypeGroup::class), + self::createStub(ContentTypeGroup::class), ['random_value_5ced05ce1023d7.35531928'], ]; @@ -220,26 +220,26 @@ public function testLoadContentTypesDecorator() $decoratedService->loadContentTypes(...$parameters); } - public function testCreateContentTypeDraftDecorator() + public function testCreateContentTypeDraftDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(ContentType::class)]; + $parameters = [self::createStub(ContentType::class)]; $serviceMock->expects(self::once())->method('createContentTypeDraft')->with(...$parameters); $decoratedService->createContentTypeDraft(...$parameters); } - public function testUpdateContentTypeDraftDecorator() + public function testUpdateContentTypeDraftDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentTypeDraft::class), - $this->createMock(ContentTypeUpdateStruct::class), + self::createStub(ContentTypeDraft::class), + self::createStub(ContentTypeUpdateStruct::class), ]; $serviceMock->expects(self::once())->method('updateContentTypeDraft')->with(...$parameters); @@ -247,26 +247,26 @@ public function testUpdateContentTypeDraftDecorator() $decoratedService->updateContentTypeDraft(...$parameters); } - public function testDeleteContentTypeDecorator() + public function testDeleteContentTypeDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(ContentType::class)]; + $parameters = [self::createStub(ContentType::class)]; $serviceMock->expects(self::once())->method('deleteContentType')->with(...$parameters); $decoratedService->deleteContentType(...$parameters); } - public function testCopyContentTypeDecorator() + public function testCopyContentTypeDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentType::class), - $this->createMock(User::class), + self::createStub(ContentType::class), + self::createStub(User::class), ]; $serviceMock->expects(self::once())->method('copyContentType')->with(...$parameters); @@ -274,14 +274,14 @@ public function testCopyContentTypeDecorator() $decoratedService->copyContentType(...$parameters); } - public function testAssignContentTypeGroupDecorator() + public function testAssignContentTypeGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentType::class), - $this->createMock(ContentTypeGroup::class), + self::createStub(ContentType::class), + self::createStub(ContentTypeGroup::class), ]; $serviceMock->expects(self::once())->method('assignContentTypeGroup')->with(...$parameters); @@ -289,14 +289,14 @@ public function testAssignContentTypeGroupDecorator() $decoratedService->assignContentTypeGroup(...$parameters); } - public function testUnassignContentTypeGroupDecorator() + public function testUnassignContentTypeGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentType::class), - $this->createMock(ContentTypeGroup::class), + self::createStub(ContentType::class), + self::createStub(ContentTypeGroup::class), ]; $serviceMock->expects(self::once())->method('unassignContentTypeGroup')->with(...$parameters); @@ -304,14 +304,14 @@ public function testUnassignContentTypeGroupDecorator() $decoratedService->unassignContentTypeGroup(...$parameters); } - public function testAddFieldDefinitionDecorator() + public function testAddFieldDefinitionDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentTypeDraft::class), - $this->createMock(FieldDefinitionCreateStruct::class), + self::createStub(ContentTypeDraft::class), + self::createStub(FieldDefinitionCreateStruct::class), ]; $serviceMock->expects(self::once())->method('addFieldDefinition')->with(...$parameters); @@ -319,14 +319,14 @@ public function testAddFieldDefinitionDecorator() $decoratedService->addFieldDefinition(...$parameters); } - public function testRemoveFieldDefinitionDecorator() + public function testRemoveFieldDefinitionDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentTypeDraft::class), - $this->createMock(FieldDefinition::class), + self::createStub(ContentTypeDraft::class), + self::createStub(FieldDefinition::class), ]; $serviceMock->expects(self::once())->method('removeFieldDefinition')->with(...$parameters); @@ -334,15 +334,15 @@ public function testRemoveFieldDefinitionDecorator() $decoratedService->removeFieldDefinition(...$parameters); } - public function testUpdateFieldDefinitionDecorator() + public function testUpdateFieldDefinitionDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentTypeDraft::class), - $this->createMock(FieldDefinition::class), - $this->createMock(FieldDefinitionUpdateStruct::class), + self::createStub(ContentTypeDraft::class), + self::createStub(FieldDefinition::class), + self::createStub(FieldDefinitionUpdateStruct::class), ]; $serviceMock->expects(self::once())->method('updateFieldDefinition')->with(...$parameters); @@ -350,19 +350,19 @@ public function testUpdateFieldDefinitionDecorator() $decoratedService->updateFieldDefinition(...$parameters); } - public function testPublishContentTypeDraftDecorator() + public function testPublishContentTypeDraftDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(ContentTypeDraft::class)]; + $parameters = [self::createStub(ContentTypeDraft::class)]; $serviceMock->expects(self::once())->method('publishContentTypeDraft')->with(...$parameters); $decoratedService->publishContentTypeDraft(...$parameters); } - public function testNewContentTypeGroupCreateStructDecorator() + public function testNewContentTypeGroupCreateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -374,7 +374,7 @@ public function testNewContentTypeGroupCreateStructDecorator() $decoratedService->newContentTypeGroupCreateStruct(...$parameters); } - public function testNewContentTypeCreateStructDecorator() + public function testNewContentTypeCreateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -386,7 +386,7 @@ public function testNewContentTypeCreateStructDecorator() $decoratedService->newContentTypeCreateStruct(...$parameters); } - public function testNewContentTypeUpdateStructDecorator() + public function testNewContentTypeUpdateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -398,7 +398,7 @@ public function testNewContentTypeUpdateStructDecorator() $decoratedService->newContentTypeUpdateStruct(...$parameters); } - public function testNewContentTypeGroupUpdateStructDecorator() + public function testNewContentTypeGroupUpdateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -410,7 +410,7 @@ public function testNewContentTypeGroupUpdateStructDecorator() $decoratedService->newContentTypeGroupUpdateStruct(...$parameters); } - public function testNewFieldDefinitionCreateStructDecorator() + public function testNewFieldDefinitionCreateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -425,7 +425,7 @@ public function testNewFieldDefinitionCreateStructDecorator() $decoratedService->newFieldDefinitionCreateStruct(...$parameters); } - public function testNewFieldDefinitionUpdateStructDecorator() + public function testNewFieldDefinitionUpdateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -437,25 +437,25 @@ public function testNewFieldDefinitionUpdateStructDecorator() $decoratedService->newFieldDefinitionUpdateStruct(...$parameters); } - public function testIsContentTypeUsedDecorator() + public function testIsContentTypeUsedDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(ContentType::class)]; + $parameters = [self::createStub(ContentType::class)]; $serviceMock->expects(self::once())->method('isContentTypeUsed')->with(...$parameters); $decoratedService->isContentTypeUsed(...$parameters); } - public function testRemoveContentTypeTranslationDecorator() + public function testRemoveContentTypeTranslationDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentTypeDraft::class), + self::createStub(ContentTypeDraft::class), 'random_value_5ced05ce105c21.42399370', ]; diff --git a/tests/lib/Repository/Decorator/FieldTypeServiceDecoratorTest.php b/tests/lib/Repository/Decorator/FieldTypeServiceDecoratorTest.php index d26802b682..cf28c52084 100644 --- a/tests/lib/Repository/Decorator/FieldTypeServiceDecoratorTest.php +++ b/tests/lib/Repository/Decorator/FieldTypeServiceDecoratorTest.php @@ -26,7 +26,7 @@ protected function createServiceMock(): MockObject return $this->createMock(FieldTypeService::class); } - public function testGetFieldTypesDecorator() + public function testGetFieldTypesDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -38,7 +38,7 @@ public function testGetFieldTypesDecorator() $decoratedService->getFieldTypes(...$parameters); } - public function testGetFieldTypeDecorator() + public function testGetFieldTypeDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -50,7 +50,7 @@ public function testGetFieldTypeDecorator() $decoratedService->getFieldType(...$parameters); } - public function testHasFieldTypeDecorator() + public function testHasFieldTypeDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); diff --git a/tests/lib/Repository/Decorator/LanguageServiceDecoratorTest.php b/tests/lib/Repository/Decorator/LanguageServiceDecoratorTest.php index 5b7ccda1c5..c3b1394e17 100644 --- a/tests/lib/Repository/Decorator/LanguageServiceDecoratorTest.php +++ b/tests/lib/Repository/Decorator/LanguageServiceDecoratorTest.php @@ -28,25 +28,25 @@ protected function createServiceMock(): MockObject return $this->createMock(LanguageService::class); } - public function testCreateLanguageDecorator() + public function testCreateLanguageDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(LanguageCreateStruct::class)]; + $parameters = [self::createStub(LanguageCreateStruct::class)]; $serviceMock->expects(self::once())->method('createLanguage')->with(...$parameters); $decoratedService->createLanguage(...$parameters); } - public function testUpdateLanguageNameDecorator() + public function testUpdateLanguageNameDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(Language::class), + self::createStub(Language::class), 'random_value_5ced05ce0e4e45.35668562', ]; @@ -55,31 +55,31 @@ public function testUpdateLanguageNameDecorator() $decoratedService->updateLanguageName(...$parameters); } - public function testEnableLanguageDecorator() + public function testEnableLanguageDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Language::class)]; + $parameters = [self::createStub(Language::class)]; $serviceMock->expects(self::once())->method('enableLanguage')->with(...$parameters); $decoratedService->enableLanguage(...$parameters); } - public function testDisableLanguageDecorator() + public function testDisableLanguageDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Language::class)]; + $parameters = [self::createStub(Language::class)]; $serviceMock->expects(self::once())->method('disableLanguage')->with(...$parameters); $decoratedService->disableLanguage(...$parameters); } - public function testLoadLanguageDecorator() + public function testLoadLanguageDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -91,7 +91,7 @@ public function testLoadLanguageDecorator() $decoratedService->loadLanguage(...$parameters); } - public function testLoadLanguagesDecorator() + public function testLoadLanguagesDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -103,7 +103,7 @@ public function testLoadLanguagesDecorator() $decoratedService->loadLanguages(...$parameters); } - public function testLoadLanguageByIdDecorator() + public function testLoadLanguageByIdDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -115,7 +115,7 @@ public function testLoadLanguageByIdDecorator() $decoratedService->loadLanguageById(...$parameters); } - public function testLoadLanguageListByCodeDecorator() + public function testLoadLanguageListByCodeDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -127,7 +127,7 @@ public function testLoadLanguageListByCodeDecorator() $decoratedService->loadLanguageListByCode(...$parameters); } - public function testLoadLanguageListByIdDecorator() + public function testLoadLanguageListByIdDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -139,19 +139,19 @@ public function testLoadLanguageListByIdDecorator() $decoratedService->loadLanguageListById(...$parameters); } - public function testDeleteLanguageDecorator() + public function testDeleteLanguageDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Language::class)]; + $parameters = [self::createStub(Language::class)]; $serviceMock->expects(self::once())->method('deleteLanguage')->with(...$parameters); $decoratedService->deleteLanguage(...$parameters); } - public function testGetDefaultLanguageCodeDecorator() + public function testGetDefaultLanguageCodeDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -163,7 +163,7 @@ public function testGetDefaultLanguageCodeDecorator() $decoratedService->getDefaultLanguageCode(...$parameters); } - public function testNewLanguageCreateStructDecorator() + public function testNewLanguageCreateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); diff --git a/tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php b/tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php index cd175b1402..a8b57c8cec 100644 --- a/tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php +++ b/tests/lib/Repository/Decorator/LocationServiceDecoratorTest.php @@ -35,14 +35,14 @@ protected function createServiceMock(): MockObject return $this->createMock(LocationService::class); } - public function testCopySubtreeDecorator() + public function testCopySubtreeDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(Location::class), - $this->createMock(Location::class), + self::createStub(Location::class), + self::createStub(Location::class), ]; $serviceMock->expects(self::once())->method('copySubtree')->with(...$parameters); @@ -50,7 +50,7 @@ public function testCopySubtreeDecorator() $decoratedService->copySubtree(...$parameters); } - public function testLoadLocationDecorator() + public function testLoadLocationDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -66,7 +66,7 @@ public function testLoadLocationDecorator() $decoratedService->loadLocation(...$parameters); } - public function testLoadLocationListDecorator() + public function testLoadLocationListDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -82,7 +82,7 @@ public function testLoadLocationListDecorator() $decoratedService->loadLocationList(...$parameters); } - public function testLoadLocationByRemoteIdDecorator() + public function testLoadLocationByRemoteIdDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -98,14 +98,14 @@ public function testLoadLocationByRemoteIdDecorator() $decoratedService->loadLocationByRemoteId(...$parameters); } - public function testLoadLocationsDecorator() + public function testLoadLocationsDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(Location::class), + self::createStub(ContentInfo::class), + self::createStub(Location::class), ['random_value_5ced05ce1603f9.50138109'], ]; @@ -114,13 +114,13 @@ public function testLoadLocationsDecorator() $decoratedService->loadLocations(...$parameters); } - public function testLoadLocationChildrenDecorator() + public function testLoadLocationChildrenDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), self::EXAMPLE_OFFSET, self::EXAMPLE_LIMIT, ['random_value_5ced05ce160459.73858583'], @@ -131,13 +131,13 @@ public function testLoadLocationChildrenDecorator() $decoratedService->loadLocationChildren(...$parameters); } - public function testLoadParentLocationsForDraftContentDecorator() + public function testLoadParentLocationsForDraftContentDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(VersionInfo::class), + self::createStub(VersionInfo::class), ['random_value_5ced05ce160494.77580729'], ]; @@ -146,26 +146,26 @@ public function testLoadParentLocationsForDraftContentDecorator() $decoratedService->loadParentLocationsForDraftContent(...$parameters); } - public function testGetLocationChildCountDecorator() + public function testGetLocationChildCountDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Location::class), 8]; + $parameters = [self::createStub(Location::class), 8]; $serviceMock->expects(self::once())->method('getLocationChildCount')->with(...$parameters); $decoratedService->getLocationChildCount(...$parameters); } - public function testCreateLocationDecorator() + public function testCreateLocationDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(LocationCreateStruct::class), + self::createStub(ContentInfo::class), + self::createStub(LocationCreateStruct::class), ]; $serviceMock->expects(self::once())->method('createLocation')->with(...$parameters); @@ -173,14 +173,14 @@ public function testCreateLocationDecorator() $decoratedService->createLocation(...$parameters); } - public function testUpdateLocationDecorator() + public function testUpdateLocationDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(Location::class), - $this->createMock(LocationUpdateStruct::class), + self::createStub(Location::class), + self::createStub(LocationUpdateStruct::class), ]; $serviceMock->expects(self::once())->method('updateLocation')->with(...$parameters); @@ -188,14 +188,14 @@ public function testUpdateLocationDecorator() $decoratedService->updateLocation(...$parameters); } - public function testSwapLocationDecorator() + public function testSwapLocationDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(Location::class), - $this->createMock(Location::class), + self::createStub(Location::class), + self::createStub(Location::class), ]; $serviceMock->expects(self::once())->method('swapLocation')->with(...$parameters); @@ -203,38 +203,38 @@ public function testSwapLocationDecorator() $decoratedService->swapLocation(...$parameters); } - public function testHideLocationDecorator() + public function testHideLocationDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Location::class)]; + $parameters = [self::createStub(Location::class)]; $serviceMock->expects(self::once())->method('hideLocation')->with(...$parameters); $decoratedService->hideLocation(...$parameters); } - public function testUnhideLocationDecorator() + public function testUnhideLocationDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Location::class)]; + $parameters = [self::createStub(Location::class)]; $serviceMock->expects(self::once())->method('unhideLocation')->with(...$parameters); $decoratedService->unhideLocation(...$parameters); } - public function testMoveSubtreeDecorator() + public function testMoveSubtreeDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(Location::class), - $this->createMock(Location::class), + self::createStub(Location::class), + self::createStub(Location::class), ]; $serviceMock->expects(self::once())->method('moveSubtree')->with(...$parameters); @@ -242,19 +242,19 @@ public function testMoveSubtreeDecorator() $decoratedService->moveSubtree(...$parameters); } - public function testDeleteLocationDecorator() + public function testDeleteLocationDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Location::class)]; + $parameters = [self::createStub(Location::class)]; $serviceMock->expects(self::once())->method('deleteLocation')->with(...$parameters); $decoratedService->deleteLocation(...$parameters); } - public function testNewLocationCreateStructDecorator() + public function testNewLocationCreateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -266,7 +266,7 @@ public function testNewLocationCreateStructDecorator() $decoratedService->newLocationCreateStruct(...$parameters); } - public function testNewLocationUpdateStructDecorator() + public function testNewLocationUpdateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -278,7 +278,7 @@ public function testNewLocationUpdateStructDecorator() $decoratedService->newLocationUpdateStruct(...$parameters); } - public function testGetAllLocationsCountDecorator() + public function testGetAllLocationsCountDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -290,7 +290,7 @@ public function testGetAllLocationsCountDecorator() $decoratedService->getAllLocationsCount(...$parameters); } - public function testLoadAllLocationsDecorator() + public function testLoadAllLocationsDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); diff --git a/tests/lib/Repository/Decorator/NotificationServiceDecoratorTest.php b/tests/lib/Repository/Decorator/NotificationServiceDecoratorTest.php index 5dbb6753db..c70f3c9426 100644 --- a/tests/lib/Repository/Decorator/NotificationServiceDecoratorTest.php +++ b/tests/lib/Repository/Decorator/NotificationServiceDecoratorTest.php @@ -58,7 +58,7 @@ public function testFindNotificationsDecorator(): void $decoratedService->findNotifications($query); } - public function testGetNotificationDecorator() + public function testGetNotificationDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -80,12 +80,12 @@ public function testMarkUserNotificationsAsReadDecorator(): void $decoratedService->markUserNotificationsAsRead(); } - public function testMarkNotificationAsReadDecorator() + public function testMarkNotificationAsReadDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Notification::class)]; + $parameters = [self::createStub(Notification::class)]; $serviceMock->expects(self::once())->method('markNotificationAsRead')->with(...$parameters); @@ -97,14 +97,14 @@ public function testMarkNotificationAsUnreadDecorator(): void $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Notification::class)]; + $parameters = [self::createStub(Notification::class)]; $serviceMock->expects(self::once())->method('markNotificationAsUnread')->with(...$parameters); $decoratedService->markNotificationAsUnread(...$parameters); } - public function testGetPendingNotificationCountDecorator() + public function testGetPendingNotificationCountDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -116,7 +116,7 @@ public function testGetPendingNotificationCountDecorator() $decoratedService->getPendingNotificationCount(...$parameters); } - public function testGetNotificationCountDecorator() + public function testGetNotificationCountDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -128,24 +128,24 @@ public function testGetNotificationCountDecorator() $decoratedService->getNotificationCount(...$parameters); } - public function testCreateNotificationDecorator() + public function testCreateNotificationDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(CreateStruct::class)]; + $parameters = [self::createStub(CreateStruct::class)]; $serviceMock->expects(self::once())->method('createNotification')->with(...$parameters); $decoratedService->createNotification(...$parameters); } - public function testDeleteNotificationDecorator() + public function testDeleteNotificationDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Notification::class)]; + $parameters = [self::createStub(Notification::class)]; $serviceMock->expects(self::once())->method('deleteNotification')->with(...$parameters); diff --git a/tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php b/tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php index 61bd4700bc..4ba85422f1 100644 --- a/tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php +++ b/tests/lib/Repository/Decorator/ObjectStateServiceDecoratorTest.php @@ -33,19 +33,19 @@ protected function createServiceMock(): MockObject return $this->createMock(ObjectStateService::class); } - public function testCreateObjectStateGroupDecorator() + public function testCreateObjectStateGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(ObjectStateGroupCreateStruct::class)]; + $parameters = [self::createStub(ObjectStateGroupCreateStruct::class)]; $serviceMock->expects(self::once())->method('createObjectStateGroup')->with(...$parameters); $decoratedService->createObjectStateGroup(...$parameters); } - public function testLoadObjectStateGroupDecorator() + public function testLoadObjectStateGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -64,7 +64,7 @@ public function testLoadObjectStateGroupByIdentifierDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $expectedObjectStateGroup = $this->createMock(ObjectStateGroup::class); + $expectedObjectStateGroup = self::createStub(ObjectStateGroup::class); $parameters = [ 'ibexa_lock', @@ -85,7 +85,7 @@ public function testLoadObjectStateGroupByIdentifierDecorator(): void ); } - public function testLoadObjectStateGroupsDecorator() + public function testLoadObjectStateGroupsDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -101,13 +101,13 @@ public function testLoadObjectStateGroupsDecorator() $decoratedService->loadObjectStateGroups(...$parameters); } - public function testLoadObjectStatesDecorator() + public function testLoadObjectStatesDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ObjectStateGroup::class), + self::createStub(ObjectStateGroup::class), ['random_value_5ced05ce168263.48122762'], ]; @@ -116,14 +116,14 @@ public function testLoadObjectStatesDecorator() $decoratedService->loadObjectStates(...$parameters); } - public function testUpdateObjectStateGroupDecorator() + public function testUpdateObjectStateGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ObjectStateGroup::class), - $this->createMock(ObjectStateGroupUpdateStruct::class), + self::createStub(ObjectStateGroup::class), + self::createStub(ObjectStateGroupUpdateStruct::class), ]; $serviceMock->expects(self::once())->method('updateObjectStateGroup')->with(...$parameters); @@ -131,26 +131,26 @@ public function testUpdateObjectStateGroupDecorator() $decoratedService->updateObjectStateGroup(...$parameters); } - public function testDeleteObjectStateGroupDecorator() + public function testDeleteObjectStateGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(ObjectStateGroup::class)]; + $parameters = [self::createStub(ObjectStateGroup::class)]; $serviceMock->expects(self::once())->method('deleteObjectStateGroup')->with(...$parameters); $decoratedService->deleteObjectStateGroup(...$parameters); } - public function testCreateObjectStateDecorator() + public function testCreateObjectStateDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ObjectStateGroup::class), - $this->createMock(ObjectStateCreateStruct::class), + self::createStub(ObjectStateGroup::class), + self::createStub(ObjectStateCreateStruct::class), ]; $serviceMock->expects(self::once())->method('createObjectState')->with(...$parameters); @@ -158,7 +158,7 @@ public function testCreateObjectStateDecorator() $decoratedService->createObjectState(...$parameters); } - public function testLoadObjectStateDecorator() + public function testLoadObjectStateDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -177,10 +177,10 @@ public function testLoadObjectStateDecoratorByIdentifier(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $expectedObjectState = $this->createMock(ObjectState::class); + $expectedObjectState = self::createStub(ObjectState::class); $parameters = [ - $this->createMock(ObjectStateGroup::class), + self::createStub(ObjectStateGroup::class), 'locked', ['eng-GB'], ]; @@ -199,14 +199,14 @@ public function testLoadObjectStateDecoratorByIdentifier(): void ); } - public function testUpdateObjectStateDecorator() + public function testUpdateObjectStateDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ObjectState::class), - $this->createMock(ObjectStateUpdateStruct::class), + self::createStub(ObjectState::class), + self::createStub(ObjectStateUpdateStruct::class), ]; $serviceMock->expects(self::once())->method('updateObjectState')->with(...$parameters); @@ -214,13 +214,13 @@ public function testUpdateObjectStateDecorator() $decoratedService->updateObjectState(...$parameters); } - public function testSetPriorityOfObjectStateDecorator() + public function testSetPriorityOfObjectStateDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ObjectState::class), + self::createStub(ObjectState::class), 100, ]; @@ -229,27 +229,27 @@ public function testSetPriorityOfObjectStateDecorator() $decoratedService->setPriorityOfObjectState(...$parameters); } - public function testDeleteObjectStateDecorator() + public function testDeleteObjectStateDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(ObjectState::class)]; + $parameters = [self::createStub(ObjectState::class)]; $serviceMock->expects(self::once())->method('deleteObjectState')->with(...$parameters); $decoratedService->deleteObjectState(...$parameters); } - public function testSetContentStateDecorator() + public function testSetContentStateDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(ObjectStateGroup::class), - $this->createMock(ObjectState::class), + self::createStub(ContentInfo::class), + self::createStub(ObjectStateGroup::class), + self::createStub(ObjectState::class), ]; $serviceMock->expects(self::once())->method('setContentState')->with(...$parameters); @@ -257,14 +257,14 @@ public function testSetContentStateDecorator() $decoratedService->setContentState(...$parameters); } - public function testGetContentStateDecorator() + public function testGetContentStateDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(ObjectStateGroup::class), + self::createStub(ContentInfo::class), + self::createStub(ObjectStateGroup::class), ]; $serviceMock->expects(self::once())->method('getContentState')->with(...$parameters); @@ -272,19 +272,19 @@ public function testGetContentStateDecorator() $decoratedService->getContentState(...$parameters); } - public function testGetContentCountDecorator() + public function testGetContentCountDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(ObjectState::class)]; + $parameters = [self::createStub(ObjectState::class)]; $serviceMock->expects(self::once())->method('getContentCount')->with(...$parameters); $decoratedService->getContentCount(...$parameters); } - public function testNewObjectStateGroupCreateStructDecorator() + public function testNewObjectStateGroupCreateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -296,7 +296,7 @@ public function testNewObjectStateGroupCreateStructDecorator() $decoratedService->newObjectStateGroupCreateStruct(...$parameters); } - public function testNewObjectStateGroupUpdateStructDecorator() + public function testNewObjectStateGroupUpdateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -308,7 +308,7 @@ public function testNewObjectStateGroupUpdateStructDecorator() $decoratedService->newObjectStateGroupUpdateStruct(...$parameters); } - public function testNewObjectStateCreateStructDecorator() + public function testNewObjectStateCreateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -320,7 +320,7 @@ public function testNewObjectStateCreateStructDecorator() $decoratedService->newObjectStateCreateStruct(...$parameters); } - public function testNewObjectStateUpdateStructDecorator() + public function testNewObjectStateUpdateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); diff --git a/tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php b/tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php index d25283d6ab..4a71dec06d 100644 --- a/tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php +++ b/tests/lib/Repository/Decorator/RoleServiceDecoratorTest.php @@ -40,31 +40,31 @@ protected function createServiceMock(): MockObject return $this->createMock(RoleService::class); } - public function testCreateRoleDecorator() + public function testCreateRoleDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(RoleCreateStruct::class)]; + $parameters = [self::createStub(RoleCreateStruct::class)]; $serviceMock->expects(self::once())->method('createRole')->with(...$parameters); $decoratedService->createRole(...$parameters); } - public function testCreateRoleDraftDecorator() + public function testCreateRoleDraftDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Role::class)]; + $parameters = [self::createStub(Role::class)]; $serviceMock->expects(self::once())->method('createRoleDraft')->with(...$parameters); $decoratedService->createRoleDraft(...$parameters); } - public function testLoadRoleDraftDecorator() + public function testLoadRoleDraftDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -76,7 +76,7 @@ public function testLoadRoleDraftDecorator() $decoratedService->loadRoleDraft(...$parameters); } - public function testLoadRoleDraftByRoleIdDecorator() + public function testLoadRoleDraftByRoleIdDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -88,14 +88,14 @@ public function testLoadRoleDraftByRoleIdDecorator() $decoratedService->loadRoleDraftByRoleId(...$parameters); } - public function testUpdateRoleDraftDecorator() + public function testUpdateRoleDraftDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(RoleDraft::class), - $this->createMock(RoleUpdateStruct::class), + self::createStub(RoleDraft::class), + self::createStub(RoleUpdateStruct::class), ]; $serviceMock->expects(self::once())->method('updateRoleDraft')->with(...$parameters); @@ -103,14 +103,14 @@ public function testUpdateRoleDraftDecorator() $decoratedService->updateRoleDraft(...$parameters); } - public function testAddPolicyByRoleDraftDecorator() + public function testAddPolicyByRoleDraftDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(RoleDraft::class), - $this->createMock(PolicyCreateStruct::class), + self::createStub(RoleDraft::class), + self::createStub(PolicyCreateStruct::class), ]; $serviceMock->expects(self::once())->method('addPolicyByRoleDraft')->with(...$parameters); @@ -118,14 +118,14 @@ public function testAddPolicyByRoleDraftDecorator() $decoratedService->addPolicyByRoleDraft(...$parameters); } - public function testRemovePolicyByRoleDraftDecorator() + public function testRemovePolicyByRoleDraftDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(RoleDraft::class), - $this->createMock(PolicyDraft::class), + self::createStub(RoleDraft::class), + self::createStub(PolicyDraft::class), ]; $serviceMock->expects(self::once())->method('removePolicyByRoleDraft')->with(...$parameters); @@ -133,15 +133,15 @@ public function testRemovePolicyByRoleDraftDecorator() $decoratedService->removePolicyByRoleDraft(...$parameters); } - public function testUpdatePolicyByRoleDraftDecorator() + public function testUpdatePolicyByRoleDraftDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(RoleDraft::class), - $this->createMock(PolicyDraft::class), - $this->createMock(PolicyUpdateStruct::class), + self::createStub(RoleDraft::class), + self::createStub(PolicyDraft::class), + self::createStub(PolicyUpdateStruct::class), ]; $serviceMock->expects(self::once())->method('updatePolicyByRoleDraft')->with(...$parameters); @@ -149,31 +149,31 @@ public function testUpdatePolicyByRoleDraftDecorator() $decoratedService->updatePolicyByRoleDraft(...$parameters); } - public function testDeleteRoleDraftDecorator() + public function testDeleteRoleDraftDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(RoleDraft::class)]; + $parameters = [self::createStub(RoleDraft::class)]; $serviceMock->expects(self::once())->method('deleteRoleDraft')->with(...$parameters); $decoratedService->deleteRoleDraft(...$parameters); } - public function testPublishRoleDraftDecorator() + public function testPublishRoleDraftDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(RoleDraft::class)]; + $parameters = [self::createStub(RoleDraft::class)]; $serviceMock->expects(self::once())->method('publishRoleDraft')->with(...$parameters); $decoratedService->publishRoleDraft(...$parameters); } - public function testLoadRoleDecorator() + public function testLoadRoleDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -185,7 +185,7 @@ public function testLoadRoleDecorator() $decoratedService->loadRole(...$parameters); } - public function testLoadRoleByIdentifierDecorator() + public function testLoadRoleByIdentifierDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -197,7 +197,7 @@ public function testLoadRoleByIdentifierDecorator() $decoratedService->loadRoleByIdentifier(...$parameters); } - public function testLoadRolesDecorator() + public function testLoadRolesDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -209,27 +209,27 @@ public function testLoadRolesDecorator() $decoratedService->loadRoles(...$parameters); } - public function testDeleteRoleDecorator() + public function testDeleteRoleDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Role::class)]; + $parameters = [self::createStub(Role::class)]; $serviceMock->expects(self::once())->method('deleteRole')->with(...$parameters); $decoratedService->deleteRole(...$parameters); } - public function testAssignRoleToUserGroupDecorator() + public function testAssignRoleToUserGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(Role::class), - $this->createMock(UserGroup::class), - $this->createMock(RoleLimitation::class), + self::createStub(Role::class), + self::createStub(UserGroup::class), + self::createStub(RoleLimitation::class), ]; $serviceMock->expects(self::once())->method('assignRoleToUserGroup')->with(...$parameters); @@ -237,15 +237,15 @@ public function testAssignRoleToUserGroupDecorator() $decoratedService->assignRoleToUserGroup(...$parameters); } - public function testAssignRoleToUserDecorator() + public function testAssignRoleToUserDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(Role::class), - $this->createMock(User::class), - $this->createMock(RoleLimitation::class), + self::createStub(Role::class), + self::createStub(User::class), + self::createStub(RoleLimitation::class), ]; $serviceMock->expects(self::once())->method('assignRoleToUser')->with(...$parameters); @@ -253,7 +253,7 @@ public function testAssignRoleToUserDecorator() $decoratedService->assignRoleToUser(...$parameters); } - public function testLoadRoleAssignmentDecorator() + public function testLoadRoleAssignmentDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -265,25 +265,25 @@ public function testLoadRoleAssignmentDecorator() $decoratedService->loadRoleAssignment(...$parameters); } - public function testGetRoleAssignmentsDecorator() + public function testGetRoleAssignmentsDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Role::class)]; + $parameters = [self::createStub(Role::class)]; $serviceMock->expects(self::once())->method('getRoleAssignments')->with(...$parameters); $decoratedService->getRoleAssignments(...$parameters); } - public function testGetRoleAssignmentsForUserDecorator() + public function testGetRoleAssignmentsForUserDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(User::class), + self::createStub(User::class), true, ]; @@ -292,31 +292,31 @@ public function testGetRoleAssignmentsForUserDecorator() $decoratedService->getRoleAssignmentsForUser(...$parameters); } - public function testGetRoleAssignmentsForUserGroupDecorator() + public function testGetRoleAssignmentsForUserGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(UserGroup::class)]; + $parameters = [self::createStub(UserGroup::class)]; $serviceMock->expects(self::once())->method('getRoleAssignmentsForUserGroup')->with(...$parameters); $decoratedService->getRoleAssignmentsForUserGroup(...$parameters); } - public function testRemoveRoleAssignmentDecorator() + public function testRemoveRoleAssignmentDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(RoleAssignment::class)]; + $parameters = [self::createStub(RoleAssignment::class)]; $serviceMock->expects(self::once())->method('removeRoleAssignment')->with(...$parameters); $decoratedService->removeRoleAssignment(...$parameters); } - public function testNewRoleCreateStructDecorator() + public function testNewRoleCreateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -328,7 +328,7 @@ public function testNewRoleCreateStructDecorator() $decoratedService->newRoleCreateStruct(...$parameters); } - public function testNewPolicyCreateStructDecorator() + public function testNewPolicyCreateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -343,7 +343,7 @@ public function testNewPolicyCreateStructDecorator() $decoratedService->newPolicyCreateStruct(...$parameters); } - public function testNewPolicyUpdateStructDecorator() + public function testNewPolicyUpdateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -355,7 +355,7 @@ public function testNewPolicyUpdateStructDecorator() $decoratedService->newPolicyUpdateStruct(...$parameters); } - public function testNewRoleUpdateStructDecorator() + public function testNewRoleUpdateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -367,7 +367,7 @@ public function testNewRoleUpdateStructDecorator() $decoratedService->newRoleUpdateStruct(...$parameters); } - public function testGetLimitationTypeDecorator() + public function testGetLimitationTypeDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -379,7 +379,7 @@ public function testGetLimitationTypeDecorator() $decoratedService->getLimitationType(...$parameters); } - public function testGetLimitationTypesByModuleFunctionDecorator() + public function testGetLimitationTypesByModuleFunctionDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); diff --git a/tests/lib/Repository/Decorator/SearchServiceDecoratorTest.php b/tests/lib/Repository/Decorator/SearchServiceDecoratorTest.php index b761c104ce..628f97b56e 100644 --- a/tests/lib/Repository/Decorator/SearchServiceDecoratorTest.php +++ b/tests/lib/Repository/Decorator/SearchServiceDecoratorTest.php @@ -13,6 +13,7 @@ use Ibexa\Contracts\Core\Repository\Values\Content\LocationQuery; use Ibexa\Contracts\Core\Repository\Values\Content\Query; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; @@ -29,13 +30,13 @@ protected function createServiceMock(): MockObject return $this->createMock(SearchService::class); } - public function testFindContentDecorator() + public function testFindContentDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(Query::class), + self::createStub(Query::class), ['random_value_5ced05ce17d631.27870175'], true, ]; @@ -45,13 +46,13 @@ public function testFindContentDecorator() $decoratedService->findContent(...$parameters); } - public function testFindContentInfoDecorator() + public function testFindContentInfoDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(Query::class), + self::createStub(Query::class), ['random_value_5ced05ce17d6d9.76060657'], true, ]; @@ -61,13 +62,13 @@ public function testFindContentInfoDecorator() $decoratedService->findContentInfo(...$parameters); } - public function testFindSingleDecorator() + public function testFindSingleDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(Criterion::class), + self::createStub(Criterion::class), ['random_value_5ced05ce17ef80.90204500'], true, ]; @@ -77,7 +78,7 @@ public function testFindSingleDecorator() $decoratedService->findSingle(...$parameters); } - public function testSuggestDecorator() + public function testSuggestDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -86,7 +87,7 @@ public function testSuggestDecorator() 'random_value_5ced05ce17f030.62511430', ['random_value_5ced05ce17f044.48777415'], 10, - $this->createMock(Criterion::class), + self::createStub(Criterion::class), ]; $serviceMock->expects(self::once())->method('suggest')->with(...$parameters); @@ -94,13 +95,13 @@ public function testSuggestDecorator() $decoratedService->suggest(...$parameters); } - public function testFindLocationsDecorator() + public function testFindLocationsDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(LocationQuery::class), + self::createStub(LocationQuery::class), ['random_value_5ced05ce17f647.36429312'], true, ]; @@ -111,10 +112,9 @@ public function testFindLocationsDecorator() } /** - * @dataProvider getSearchEngineCapabilities - * * @param int $capability */ + #[DataProvider('getSearchEngineCapabilities')] public function testSupportsDecorator(int $capability): void { $serviceMock = $this->createServiceMock(); @@ -132,7 +132,7 @@ public function testSupportsDecorator(int $capability): void * * @return array */ - public function getSearchEngineCapabilities(): array + public static function getSearchEngineCapabilities(): array { return [ [SearchService::CAPABILITY_SCORING], diff --git a/tests/lib/Repository/Decorator/SectionServiceDecoratorTest.php b/tests/lib/Repository/Decorator/SectionServiceDecoratorTest.php index 39b9df17ff..2ce7bc89e5 100644 --- a/tests/lib/Repository/Decorator/SectionServiceDecoratorTest.php +++ b/tests/lib/Repository/Decorator/SectionServiceDecoratorTest.php @@ -33,26 +33,26 @@ protected function createServiceMock(): MockObject return $this->createMock(SectionService::class); } - public function testCreateSectionDecorator() + public function testCreateSectionDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(SectionCreateStruct::class)]; + $parameters = [self::createStub(SectionCreateStruct::class)]; $serviceMock->expects(self::once())->method('createSection')->with(...$parameters); $decoratedService->createSection(...$parameters); } - public function testUpdateSectionDecorator() + public function testUpdateSectionDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(Section::class), - $this->createMock(SectionUpdateStruct::class), + self::createStub(Section::class), + self::createStub(SectionUpdateStruct::class), ]; $serviceMock->expects(self::once())->method('updateSection')->with(...$parameters); @@ -60,7 +60,7 @@ public function testUpdateSectionDecorator() $decoratedService->updateSection(...$parameters); } - public function testLoadSectionDecorator() + public function testLoadSectionDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -72,7 +72,7 @@ public function testLoadSectionDecorator() $decoratedService->loadSection(...$parameters); } - public function testLoadSectionsDecorator() + public function testLoadSectionsDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -84,7 +84,7 @@ public function testLoadSectionsDecorator() $decoratedService->loadSections(...$parameters); } - public function testLoadSectionByIdentifierDecorator() + public function testLoadSectionByIdentifierDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -96,38 +96,38 @@ public function testLoadSectionByIdentifierDecorator() $decoratedService->loadSectionByIdentifier(...$parameters); } - public function testCountAssignedContentsDecorator() + public function testCountAssignedContentsDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Section::class)]; + $parameters = [self::createStub(Section::class)]; $serviceMock->expects(self::once())->method('countAssignedContents')->with(...$parameters); $decoratedService->countAssignedContents(...$parameters); } - public function testIsSectionUsedDecorator() + public function testIsSectionUsedDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Section::class)]; + $parameters = [self::createStub(Section::class)]; $serviceMock->expects(self::once())->method('isSectionUsed')->with(...$parameters); $decoratedService->isSectionUsed(...$parameters); } - public function testAssignSectionDecorator() + public function testAssignSectionDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(ContentInfo::class), - $this->createMock(Section::class), + self::createStub(ContentInfo::class), + self::createStub(Section::class), ]; $serviceMock->expects(self::once())->method('assignSection')->with(...$parameters); @@ -135,14 +135,14 @@ public function testAssignSectionDecorator() $decoratedService->assignSection(...$parameters); } - public function testAssignSectionToSubtreeDecorator() + public function testAssignSectionToSubtreeDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(Location::class), - $this->createMock(Section::class), + self::createStub(Location::class), + self::createStub(Section::class), ]; $serviceMock->expects(self::once())->method('assignSectionToSubtree')->with(...$parameters); @@ -150,19 +150,19 @@ public function testAssignSectionToSubtreeDecorator() $decoratedService->assignSectionToSubtree(...$parameters); } - public function testDeleteSectionDecorator() + public function testDeleteSectionDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Section::class)]; + $parameters = [self::createStub(Section::class)]; $serviceMock->expects(self::once())->method('deleteSection')->with(...$parameters); $decoratedService->deleteSection(...$parameters); } - public function testNewSectionCreateStructDecorator() + public function testNewSectionCreateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -174,7 +174,7 @@ public function testNewSectionCreateStructDecorator() $decoratedService->newSectionCreateStruct(...$parameters); } - public function testNewSectionUpdateStructDecorator() + public function testNewSectionUpdateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); diff --git a/tests/lib/Repository/Decorator/SettingServiceDecoratorTest.php b/tests/lib/Repository/Decorator/SettingServiceDecoratorTest.php index 3da5a68674..a1e76e0745 100644 --- a/tests/lib/Repository/Decorator/SettingServiceDecoratorTest.php +++ b/tests/lib/Repository/Decorator/SettingServiceDecoratorTest.php @@ -32,26 +32,26 @@ protected function createServiceMock(): MockObject return $this->createMock(SettingService::class); } - public function testCreateSettingDecorator() + public function testCreateSettingDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(SettingCreateStruct::class)]; + $parameters = [self::createStub(SettingCreateStruct::class)]; $serviceMock->expects(self::once())->method('createSetting')->with(...$parameters); $decoratedService->createSetting(...$parameters); } - public function testUpdateSettingDecorator() + public function testUpdateSettingDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(Setting::class), - $this->createMock(SettingUpdateStruct::class), + self::createStub(Setting::class), + self::createStub(SettingUpdateStruct::class), ]; $serviceMock->expects(self::once())->method('updateSetting')->with(...$parameters); @@ -59,7 +59,7 @@ public function testUpdateSettingDecorator() $decoratedService->updateSetting(...$parameters); } - public function testLoadSettingDecorator() + public function testLoadSettingDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -74,19 +74,19 @@ public function testLoadSettingDecorator() $decoratedService->loadSetting(...$parameters); } - public function testDeleteSettingDecorator() + public function testDeleteSettingDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Setting::class)]; + $parameters = [self::createStub(Setting::class)]; $serviceMock->expects(self::once())->method('deleteSetting')->with(...$parameters); $decoratedService->deleteSetting(...$parameters); } - public function testNewSettingCreateStructDecorator() + public function testNewSettingCreateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -98,7 +98,7 @@ public function testNewSettingCreateStructDecorator() $decoratedService->newSettingCreateStruct(...$parameters); } - public function testNewSettingUpdateStructDecorator() + public function testNewSettingUpdateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); diff --git a/tests/lib/Repository/Decorator/TranslationServiceDecoratorTest.php b/tests/lib/Repository/Decorator/TranslationServiceDecoratorTest.php index 3be4c7cc25..8297226567 100644 --- a/tests/lib/Repository/Decorator/TranslationServiceDecoratorTest.php +++ b/tests/lib/Repository/Decorator/TranslationServiceDecoratorTest.php @@ -27,13 +27,13 @@ protected function createServiceMock(): MockObject return $this->createMock(TranslationService::class); } - public function testTranslateDecorator() + public function testTranslateDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(Translation::class), + self::createStub(Translation::class), 'random_value_5ced05ce16efc3.57825052', ]; @@ -42,7 +42,7 @@ public function testTranslateDecorator() $decoratedService->translate(...$parameters); } - public function testTranslateStringDecorator() + public function testTranslateStringDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); diff --git a/tests/lib/Repository/Decorator/TrashServiceDecoratorTest.php b/tests/lib/Repository/Decorator/TrashServiceDecoratorTest.php index 65babf43c3..070983a1e9 100644 --- a/tests/lib/Repository/Decorator/TrashServiceDecoratorTest.php +++ b/tests/lib/Repository/Decorator/TrashServiceDecoratorTest.php @@ -29,7 +29,7 @@ protected function createServiceMock(): MockObject return $this->createMock(TrashService::class); } - public function testLoadTrashItemDecorator() + public function testLoadTrashItemDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -41,26 +41,26 @@ public function testLoadTrashItemDecorator() $decoratedService->loadTrashItem(...$parameters); } - public function testTrashDecorator() + public function testTrashDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Location::class)]; + $parameters = [self::createStub(Location::class)]; $serviceMock->expects(self::once())->method('trash')->with(...$parameters); $decoratedService->trash(...$parameters); } - public function testRecoverDecorator() + public function testRecoverDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(TrashItem::class), - $this->createMock(Location::class), + self::createStub(TrashItem::class), + self::createStub(Location::class), ]; $serviceMock->expects(self::once())->method('recover')->with(...$parameters); @@ -68,7 +68,7 @@ public function testRecoverDecorator() $decoratedService->recover(...$parameters); } - public function testEmptyTrashDecorator() + public function testEmptyTrashDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -80,24 +80,24 @@ public function testEmptyTrashDecorator() $decoratedService->emptyTrash(...$parameters); } - public function testDeleteTrashItemDecorator() + public function testDeleteTrashItemDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(TrashItem::class)]; + $parameters = [self::createStub(TrashItem::class)]; $serviceMock->expects(self::once())->method('deleteTrashItem')->with(...$parameters); $decoratedService->deleteTrashItem(...$parameters); } - public function testFindTrashItemsDecorator() + public function testFindTrashItemsDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Query::class)]; + $parameters = [self::createStub(Query::class)]; $serviceMock->expects(self::once())->method('findTrashItems')->with(...$parameters); diff --git a/tests/lib/Repository/Decorator/URLAliasServiceDecoratorTest.php b/tests/lib/Repository/Decorator/URLAliasServiceDecoratorTest.php index de9b5e2e69..25459e7905 100644 --- a/tests/lib/Repository/Decorator/URLAliasServiceDecoratorTest.php +++ b/tests/lib/Repository/Decorator/URLAliasServiceDecoratorTest.php @@ -30,13 +30,13 @@ protected function createServiceMock(): MockObject return $this->createMock(URLAliasService::class); } - public function testCreateUrlAliasDecorator() + public function testCreateUrlAliasDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), 'random_value_5ced05ce0f45c8.98320978', 'random_value_5ced05ce0f45f9.49337276', true, @@ -48,7 +48,7 @@ public function testCreateUrlAliasDecorator() $decoratedService->createUrlAlias(...$parameters); } - public function testCreateGlobalUrlAliasDecorator() + public function testCreateGlobalUrlAliasDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -66,13 +66,13 @@ public function testCreateGlobalUrlAliasDecorator() $decoratedService->createGlobalUrlAlias(...$parameters); } - public function testListLocationAliasesDecorator() + public function testListLocationAliasesDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), true, 'random_value_5ced05ce0f4720.32499208', ]; @@ -82,7 +82,7 @@ public function testListLocationAliasesDecorator() $decoratedService->listLocationAliases(...$parameters); } - public function testListGlobalAliasesDecorator() + public function testListGlobalAliasesDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -98,7 +98,7 @@ public function testListGlobalAliasesDecorator() $decoratedService->listGlobalAliases(...$parameters); } - public function testRemoveAliasesDecorator() + public function testRemoveAliasesDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -110,7 +110,7 @@ public function testRemoveAliasesDecorator() $decoratedService->removeAliases(...$parameters); } - public function testLookupDecorator() + public function testLookupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -125,13 +125,13 @@ public function testLookupDecorator() $decoratedService->lookup(...$parameters); } - public function testReverseLookupDecorator() + public function testReverseLookupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(Location::class), + self::createStub(Location::class), 'random_value_5ced05ce0f4803.92292057', ]; @@ -140,7 +140,7 @@ public function testReverseLookupDecorator() $decoratedService->reverseLookup(...$parameters); } - public function testLoadDecorator() + public function testLoadDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -152,19 +152,19 @@ public function testLoadDecorator() $decoratedService->load(...$parameters); } - public function testRefreshSystemUrlAliasesForLocationDecorator() + public function testRefreshSystemUrlAliasesForLocationDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Location::class)]; + $parameters = [self::createStub(Location::class)]; $serviceMock->expects(self::once())->method('refreshSystemUrlAliasesForLocation')->with(...$parameters); $decoratedService->refreshSystemUrlAliasesForLocation(...$parameters); } - public function testDeleteCorruptedUrlAliasesDecorator() + public function testDeleteCorruptedUrlAliasesDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); diff --git a/tests/lib/Repository/Decorator/URLServiceDecoratorTest.php b/tests/lib/Repository/Decorator/URLServiceDecoratorTest.php index 0214072cba..94cac0a834 100644 --- a/tests/lib/Repository/Decorator/URLServiceDecoratorTest.php +++ b/tests/lib/Repository/Decorator/URLServiceDecoratorTest.php @@ -29,7 +29,7 @@ protected function createServiceMock(): MockObject return $this->createMock(URLService::class); } - public function testCreateUpdateStructDecorator() + public function testCreateUpdateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -41,25 +41,25 @@ public function testCreateUpdateStructDecorator() $decoratedService->createUpdateStruct(...$parameters); } - public function testFindUrlsDecorator() + public function testFindUrlsDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(URLQuery::class)]; + $parameters = [self::createStub(URLQuery::class)]; $serviceMock->expects(self::once())->method('findUrls')->with(...$parameters); $decoratedService->findUrls(...$parameters); } - public function testFindUsagesDecorator() + public function testFindUsagesDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(URL::class), + self::createStub(URL::class), 10, 100, ]; @@ -69,7 +69,7 @@ public function testFindUsagesDecorator() $decoratedService->findUsages(...$parameters); } - public function testLoadByIdDecorator() + public function testLoadByIdDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -81,7 +81,7 @@ public function testLoadByIdDecorator() $decoratedService->loadById(...$parameters); } - public function testLoadByUrlDecorator() + public function testLoadByUrlDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -93,14 +93,14 @@ public function testLoadByUrlDecorator() $decoratedService->loadByUrl(...$parameters); } - public function testUpdateUrlDecorator() + public function testUpdateUrlDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(URL::class), - $this->createMock(URLUpdateStruct::class), + self::createStub(URL::class), + self::createStub(URLUpdateStruct::class), ]; $serviceMock->expects(self::once())->method('updateUrl')->with(...$parameters); diff --git a/tests/lib/Repository/Decorator/URLWildcardServiceDecoratorTest.php b/tests/lib/Repository/Decorator/URLWildcardServiceDecoratorTest.php index b0c7e05c7b..63df1dc030 100644 --- a/tests/lib/Repository/Decorator/URLWildcardServiceDecoratorTest.php +++ b/tests/lib/Repository/Decorator/URLWildcardServiceDecoratorTest.php @@ -27,7 +27,7 @@ protected function createServiceMock(): MockObject return $this->createMock(URLWildcardService::class); } - public function testCreateDecorator() + public function testCreateDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -43,19 +43,19 @@ public function testCreateDecorator() $decoratedService->create(...$parameters); } - public function testRemoveDecorator() + public function testRemoveDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(URLWildcard::class)]; + $parameters = [self::createStub(URLWildcard::class)]; $serviceMock->expects(self::once())->method('remove')->with(...$parameters); $decoratedService->remove(...$parameters); } - public function testLoadDecorator() + public function testLoadDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -67,7 +67,7 @@ public function testLoadDecorator() $decoratedService->load(...$parameters); } - public function testLoadAllDecorator() + public function testLoadAllDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -82,7 +82,7 @@ public function testLoadAllDecorator() $decoratedService->loadAll(...$parameters); } - public function testTranslateDecorator() + public function testTranslateDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); diff --git a/tests/lib/Repository/Decorator/UserPreferenceServiceDecoratorTest.php b/tests/lib/Repository/Decorator/UserPreferenceServiceDecoratorTest.php index 52943f41a9..f2282564cb 100644 --- a/tests/lib/Repository/Decorator/UserPreferenceServiceDecoratorTest.php +++ b/tests/lib/Repository/Decorator/UserPreferenceServiceDecoratorTest.php @@ -26,7 +26,7 @@ protected function createServiceMock(): MockObject return $this->createMock(UserPreferenceService::class); } - public function testSetUserPreferenceDecorator() + public function testSetUserPreferenceDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -38,7 +38,7 @@ public function testSetUserPreferenceDecorator() $decoratedService->setUserPreference(...$parameters); } - public function testGetUserPreferenceDecorator() + public function testGetUserPreferenceDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -50,7 +50,7 @@ public function testGetUserPreferenceDecorator() $decoratedService->getUserPreference(...$parameters); } - public function testLoadUserPreferencesDecorator() + public function testLoadUserPreferencesDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -65,7 +65,7 @@ public function testLoadUserPreferencesDecorator() $decoratedService->loadUserPreferences(...$parameters); } - public function testGetUserPreferenceCountDecorator() + public function testGetUserPreferenceCountDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); diff --git a/tests/lib/Repository/Decorator/UserServiceDecoratorTest.php b/tests/lib/Repository/Decorator/UserServiceDecoratorTest.php index ba068a783e..1abb0e157b 100644 --- a/tests/lib/Repository/Decorator/UserServiceDecoratorTest.php +++ b/tests/lib/Repository/Decorator/UserServiceDecoratorTest.php @@ -43,14 +43,14 @@ protected function createServiceMock(): MockObject return $this->createMock(UserService::class); } - public function testCreateUserGroupDecorator() + public function testCreateUserGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(UserGroupCreateStruct::class), - $this->createMock(UserGroup::class), + self::createStub(UserGroupCreateStruct::class), + self::createStub(UserGroup::class), ]; $serviceMock->expects(self::once())->method('createUserGroup')->with(...$parameters); @@ -58,7 +58,7 @@ public function testCreateUserGroupDecorator() $decoratedService->createUserGroup(...$parameters); } - public function testLoadUserGroupDecorator() + public function testLoadUserGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -88,13 +88,13 @@ public function testLoadUserGroupByRemoteIdDecorator(): void $decoratedService->loadUserGroupByRemoteId(...$parameters); } - public function testLoadSubUserGroupsDecorator() + public function testLoadSubUserGroupsDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(UserGroup::class), + self::createStub(UserGroup::class), self::EXAMPLE_OFFSET, self::EXAMPLE_LIMIT, ['random_value_5ced05ce176401.55725588'], @@ -105,26 +105,26 @@ public function testLoadSubUserGroupsDecorator() $decoratedService->loadSubUserGroups(...$parameters); } - public function testDeleteUserGroupDecorator() + public function testDeleteUserGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(UserGroup::class)]; + $parameters = [self::createStub(UserGroup::class)]; $serviceMock->expects(self::once())->method('deleteUserGroup')->with(...$parameters); $decoratedService->deleteUserGroup(...$parameters); } - public function testMoveUserGroupDecorator() + public function testMoveUserGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(UserGroup::class), - $this->createMock(UserGroup::class), + self::createStub(UserGroup::class), + self::createStub(UserGroup::class), ]; $serviceMock->expects(self::once())->method('moveUserGroup')->with(...$parameters); @@ -132,14 +132,14 @@ public function testMoveUserGroupDecorator() $decoratedService->moveUserGroup(...$parameters); } - public function testUpdateUserGroupDecorator() + public function testUpdateUserGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(UserGroup::class), - $this->createMock(UserGroupUpdateStruct::class), + self::createStub(UserGroup::class), + self::createStub(UserGroupUpdateStruct::class), ]; $serviceMock->expects(self::once())->method('updateUserGroup')->with(...$parameters); @@ -147,13 +147,13 @@ public function testUpdateUserGroupDecorator() $decoratedService->updateUserGroup(...$parameters); } - public function testCreateUserDecorator() + public function testCreateUserDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(UserCreateStruct::class), + self::createStub(UserCreateStruct::class), ['random_value_5ced05ce177102.13726421'], ]; @@ -162,7 +162,7 @@ public function testCreateUserDecorator() $decoratedService->createUser(...$parameters); } - public function testLoadUserDecorator() + public function testLoadUserDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -177,13 +177,13 @@ public function testLoadUserDecorator() $decoratedService->loadUser(...$parameters); } - public function testCheckUserCredentialsDecorator() + public function testCheckUserCredentialsDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(User::class), + self::createStub(User::class), 'random_value_5ced05ce1771c7.58152750', ]; @@ -192,7 +192,7 @@ public function testCheckUserCredentialsDecorator() $decoratedService->checkUserCredentials(...$parameters); } - public function testLoadUserByLoginDecorator() + public function testLoadUserByLoginDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -207,7 +207,7 @@ public function testLoadUserByLoginDecorator() $decoratedService->loadUserByLogin(...$parameters); } - public function testLoadUsersByEmailDecorator() + public function testLoadUsersByEmailDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -222,7 +222,7 @@ public function testLoadUsersByEmailDecorator() $decoratedService->loadUsersByEmail(...$parameters); } - public function testLoadUserByTokenDecorator() + public function testLoadUserByTokenDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -237,26 +237,26 @@ public function testLoadUserByTokenDecorator() $decoratedService->loadUserByToken(...$parameters); } - public function testDeleteUserDecorator() + public function testDeleteUserDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(User::class)]; + $parameters = [self::createStub(User::class)]; $serviceMock->expects(self::once())->method('deleteUser')->with(...$parameters); $decoratedService->deleteUser(...$parameters); } - public function testUpdateUserDecorator() + public function testUpdateUserDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(User::class), - $this->createMock(UserUpdateStruct::class), + self::createStub(User::class), + self::createStub(UserUpdateStruct::class), ]; $serviceMock->expects(self::once())->method('updateUser')->with(...$parameters); @@ -270,7 +270,7 @@ public function testUpdateUserPasswordDecorator(): void $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(User::class), + self::createStub(User::class), 'H@xi0r!', ]; @@ -279,14 +279,14 @@ public function testUpdateUserPasswordDecorator(): void $decoratedService->updateUserPassword(...$parameters); } - public function testUpdateUserTokenDecorator() + public function testUpdateUserTokenDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(User::class), - $this->createMock(UserTokenUpdateStruct::class), + self::createStub(User::class), + self::createStub(UserTokenUpdateStruct::class), ]; $serviceMock->expects(self::once())->method('updateUserToken')->with(...$parameters); @@ -294,7 +294,7 @@ public function testUpdateUserTokenDecorator() $decoratedService->updateUserToken(...$parameters); } - public function testExpireUserTokenDecorator() + public function testExpireUserTokenDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -306,14 +306,14 @@ public function testExpireUserTokenDecorator() $decoratedService->expireUserToken(...$parameters); } - public function testAssignUserToUserGroupDecorator() + public function testAssignUserToUserGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(User::class), - $this->createMock(UserGroup::class), + self::createStub(User::class), + self::createStub(UserGroup::class), ]; $serviceMock->expects(self::once())->method('assignUserToUserGroup')->with(...$parameters); @@ -321,14 +321,14 @@ public function testAssignUserToUserGroupDecorator() $decoratedService->assignUserToUserGroup(...$parameters); } - public function testUnAssignUserFromUserGroupDecorator() + public function testUnAssignUserFromUserGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(User::class), - $this->createMock(UserGroup::class), + self::createStub(User::class), + self::createStub(UserGroup::class), ]; $serviceMock->expects(self::once())->method('unAssignUserFromUserGroup')->with(...$parameters); @@ -336,13 +336,13 @@ public function testUnAssignUserFromUserGroupDecorator() $decoratedService->unAssignUserFromUserGroup(...$parameters); } - public function testLoadUserGroupsOfUserDecorator() + public function testLoadUserGroupsOfUserDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(User::class), + self::createStub(User::class), self::EXAMPLE_OFFSET, self::EXAMPLE_LIMIT, ['random_value_5ced05ce177f66.49237325'], @@ -353,13 +353,13 @@ public function testLoadUserGroupsOfUserDecorator() $decoratedService->loadUserGroupsOfUser(...$parameters); } - public function testLoadUsersOfUserGroupDecorator() + public function testLoadUsersOfUserGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ - $this->createMock(UserGroup::class), + self::createStub(UserGroup::class), self::EXAMPLE_OFFSET, self::EXAMPLE_LIMIT, ['random_value_5ced05ce177fc8.32448790'], @@ -370,31 +370,31 @@ public function testLoadUsersOfUserGroupDecorator() $decoratedService->loadUsersOfUserGroup(...$parameters); } - public function testIsUserDecorator() + public function testIsUserDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Content::class)]; + $parameters = [self::createStub(Content::class)]; $serviceMock->expects(self::once())->method('isUser')->with(...$parameters); $decoratedService->isUser(...$parameters); } - public function testIsUserGroupDecorator() + public function testIsUserGroupDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); - $parameters = [$this->createMock(Content::class)]; + $parameters = [self::createStub(Content::class)]; $serviceMock->expects(self::once())->method('isUserGroup')->with(...$parameters); $decoratedService->isUserGroup(...$parameters); } - public function testNewUserCreateStructDecorator() + public function testNewUserCreateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -404,7 +404,7 @@ public function testNewUserCreateStructDecorator() 'random_value_5ced05ce178049.06911955', 'random_value_5ced05ce178050.58319472', 'random_value_5ced05ce178063.84822784', - $this->createMock(ContentType::class), + self::createStub(ContentType::class), ]; $serviceMock->expects(self::once())->method('newUserCreateStruct')->with(...$parameters); @@ -412,14 +412,14 @@ public function testNewUserCreateStructDecorator() $decoratedService->newUserCreateStruct(...$parameters); } - public function testNewUserGroupCreateStructDecorator() + public function testNewUserGroupCreateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ 'random_value_5ced05ce178098.19193304', - $this->createMock(ContentType::class), + self::createStub(ContentType::class), ]; $serviceMock->expects(self::once())->method('newUserGroupCreateStruct')->with(...$parameters); @@ -427,7 +427,7 @@ public function testNewUserGroupCreateStructDecorator() $decoratedService->newUserGroupCreateStruct(...$parameters); } - public function testNewUserUpdateStructDecorator() + public function testNewUserUpdateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -439,7 +439,7 @@ public function testNewUserUpdateStructDecorator() $decoratedService->newUserUpdateStruct(...$parameters); } - public function testNewUserGroupUpdateStructDecorator() + public function testNewUserGroupUpdateStructDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); @@ -451,14 +451,14 @@ public function testNewUserGroupUpdateStructDecorator() $decoratedService->newUserGroupUpdateStruct(...$parameters); } - public function testValidatePasswordDecorator() + public function testValidatePasswordDecorator(): void { $serviceMock = $this->createServiceMock(); $decoratedService = $this->createDecorator($serviceMock); $parameters = [ 'random_value_5ced05ce1780f2.97072127', - $this->createMock(PasswordValidationContext::class), + self::createStub(PasswordValidationContext::class), ]; $serviceMock->expects(self::once())->method('validatePassword')->with(...$parameters); diff --git a/tests/lib/Repository/Helper/FieldTypeRegistryTest.php b/tests/lib/Repository/Helper/FieldTypeRegistryTest.php index e28e538d0d..d45a682902 100644 --- a/tests/lib/Repository/Helper/FieldTypeRegistryTest.php +++ b/tests/lib/Repository/Helper/FieldTypeRegistryTest.php @@ -19,7 +19,7 @@ class FieldTypeRegistryTest extends TestCase { private const FIELD_TYPE_ID = 'one'; - public function testConstructor() + public function testConstructor(): void { $fieldType = $this->getFieldTypeMock(); $fieldTypes = [self::FIELD_TYPE_ID => $fieldType]; @@ -33,7 +33,7 @@ protected function getFieldTypeMock() return $this->createMock(FieldType::class); } - public function testGetFieldType() + public function testGetFieldType(): void { $fieldTypes = [ self::FIELD_TYPE_ID => $this->getFieldTypeMock(), @@ -49,7 +49,7 @@ public function testGetFieldType() ); } - public function testGetFieldTypeThrowsNotFoundException() + public function testGetFieldTypeThrowsNotFoundException(): void { $this->expectException(FieldTypeNotFoundException::class); @@ -58,7 +58,7 @@ public function testGetFieldTypeThrowsNotFoundException() $registry->getFieldType('none'); } - public function testGetFieldTypeThrowsRuntimeExceptionIncorrectType() + public function testGetFieldTypeThrowsRuntimeExceptionIncorrectType(): void { $this->expectException(\TypeError::class); @@ -71,7 +71,7 @@ public function testGetFieldTypeThrowsRuntimeExceptionIncorrectType() $registry->getFieldType('none'); } - public function testGetFieldTypes() + public function testGetFieldTypes(): void { $fieldTypes = [ self::FIELD_TYPE_ID => $this->getFieldTypeMock(), diff --git a/tests/lib/Repository/Iterator/BatchIteratorAdapter/AbstractSearchAdapterTestCase.php b/tests/lib/Repository/Iterator/BatchIteratorAdapter/AbstractSearchAdapterTestCase.php index 7bbc46ce27..276d20009d 100644 --- a/tests/lib/Repository/Iterator/BatchIteratorAdapter/AbstractSearchAdapterTestCase.php +++ b/tests/lib/Repository/Iterator/BatchIteratorAdapter/AbstractSearchAdapterTestCase.php @@ -33,7 +33,7 @@ abstract class AbstractSearchAdapterTestCase extends TestCase final public function testFetch(): void { - $expectedIterator = $this->createMock(Iterator::class); + $expectedIterator = self::createStub(Iterator::class); $searchResults = $this->createMock(SearchResult::class); $searchResults->method('getIterator')->willReturn($expectedIterator); diff --git a/tests/lib/Repository/Iterator/BatchIteratorAdapter/ContentFilteringAdapterTest.php b/tests/lib/Repository/Iterator/BatchIteratorAdapter/ContentFilteringAdapterTest.php index 214a2a2d61..fc493fba04 100644 --- a/tests/lib/Repository/Iterator/BatchIteratorAdapter/ContentFilteringAdapterTest.php +++ b/tests/lib/Repository/Iterator/BatchIteratorAdapter/ContentFilteringAdapterTest.php @@ -28,9 +28,9 @@ final class ContentFilteringAdapterTest extends TestCase */ public function testFetch(): void { - $content1 = $this->createMock(Content::class); - $content2 = $this->createMock(Content::class); - $content3 = $this->createMock(Content::class); + $content1 = self::createStub(Content::class); + $content2 = self::createStub(Content::class); + $content3 = self::createStub(Content::class); $contentList = new ContentList(3, [ $content1, diff --git a/tests/lib/Repository/Iterator/BatchIteratorAdapter/LocationFilteringAdapterTest.php b/tests/lib/Repository/Iterator/BatchIteratorAdapter/LocationFilteringAdapterTest.php index 1df0c4efb1..db8eea7acd 100644 --- a/tests/lib/Repository/Iterator/BatchIteratorAdapter/LocationFilteringAdapterTest.php +++ b/tests/lib/Repository/Iterator/BatchIteratorAdapter/LocationFilteringAdapterTest.php @@ -28,9 +28,9 @@ final class LocationFilteringAdapterTest extends TestCase */ public function testFetch(): void { - $location1 = $this->createMock(Location::class); - $location2 = $this->createMock(Location::class); - $location3 = $this->createMock(Location::class); + $location1 = self::createStub(Location::class); + $location2 = self::createStub(Location::class); + $location3 = self::createStub(Location::class); $locationList = new LocationList([ 'locations' => [ diff --git a/tests/lib/Repository/LocationResolver/PermissionAwareLocationResolverTest.php b/tests/lib/Repository/LocationResolver/PermissionAwareLocationResolverTest.php index 1a100ef2f8..04d23d2829 100644 --- a/tests/lib/Repository/LocationResolver/PermissionAwareLocationResolverTest.php +++ b/tests/lib/Repository/LocationResolver/PermissionAwareLocationResolverTest.php @@ -15,11 +15,10 @@ use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; use Ibexa\Core\Repository\LocationResolver\PermissionAwareLocationResolver; use Ibexa\Core\Repository\Values\Content\Location; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Repository\LocationResolver\PermissionAwareLocationResolver - */ +#[CoversClass(PermissionAwareLocationResolver::class)] final class PermissionAwareLocationResolverTest extends TestCase { /** @var \Ibexa\Contracts\Core\Repository\LocationService */ diff --git a/tests/lib/Repository/LocationServiceTest.php b/tests/lib/Repository/LocationServiceTest.php index 443e4020ab..7a25dacb08 100644 --- a/tests/lib/Repository/LocationServiceTest.php +++ b/tests/lib/Repository/LocationServiceTest.php @@ -28,14 +28,14 @@ final class LocationServiceTest extends TestCase protected function setUp(): void { $this->locationService = new LocationService( - $this->createMock(Repository::class), - $this->createMock(PersistenceHandler::class), - $this->createMock(ContentDomainMapper::class), - $this->createMock(NameSchemaServiceInterface::class), - $this->createMock(PermissionCriterionResolver::class), - $this->createMock(PermissionResolver::class), - $this->createMock(LocationFilteringHandler::class), - $this->createMock(ContentTypeService::class) + self::createStub(Repository::class), + self::createStub(PersistenceHandler::class), + self::createStub(ContentDomainMapper::class), + self::createStub(NameSchemaServiceInterface::class), + self::createStub(PermissionCriterionResolver::class), + self::createStub(PermissionResolver::class), + self::createStub(LocationFilteringHandler::class), + self::createStub(ContentTypeService::class) ); } diff --git a/tests/lib/Repository/Mapper/ContentLocationMapper/DecoratedLocationServiceTest.php b/tests/lib/Repository/Mapper/ContentLocationMapper/DecoratedLocationServiceTest.php index 7904333c0c..edbe7189c1 100644 --- a/tests/lib/Repository/Mapper/ContentLocationMapper/DecoratedLocationServiceTest.php +++ b/tests/lib/Repository/Mapper/ContentLocationMapper/DecoratedLocationServiceTest.php @@ -83,11 +83,20 @@ public function testLoadLocationList(): void $this->innerLocationService ->method('loadLocationList') ->willReturn($locations); + $matcher = self::atLeastOnce(); $this->mapper - ->expects(self::atLeastOnce()) - ->method('setMapping') - ->withConsecutive([1, 2], [3, 4]); + ->expects($matcher) + ->method('setMapping')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame(1, $parameters[0]); + $this->assertSame(2, $parameters[1]); + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame(3, $parameters[0]); + $this->assertSame(4, $parameters[1]); + } + }); $actualLocations = $this->locationService->loadLocationList([1, 2]); @@ -126,11 +135,20 @@ public function testLoadLocations(): void ->method('loadLocations') ->with($contentInfo) ->willReturn($locations); + $matcher = self::atLeastOnce(); $this->mapper - ->expects(self::atLeastOnce()) - ->method('setMapping') - ->withConsecutive([1, 2], [3, 4]); + ->expects($matcher) + ->method('setMapping')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame(1, $parameters[0]); + $this->assertSame(2, $parameters[1]); + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame(3, $parameters[0]); + $this->assertSame(4, $parameters[1]); + } + }); $actualLocations = iterator_to_array($this->locationService->loadLocations($contentInfo)); @@ -171,11 +189,20 @@ public function testLoadLocationChildren(): void ->method('loadLocationChildren') ->with($location) ->willReturn($locationList); + $matcher = self::atLeastOnce(); $this->mapper - ->expects(self::atLeastOnce()) - ->method('setMapping') - ->withConsecutive([1, 2], [3, 4]); + ->expects($matcher) + ->method('setMapping')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame(1, $parameters[0]); + $this->assertSame(2, $parameters[1]); + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame(3, $parameters[0]); + $this->assertSame(4, $parameters[1]); + } + }); $actualLocations = $this->locationService->loadLocationChildren($location); @@ -210,11 +237,20 @@ public function testLoadAllLocations(): void $this->innerLocationService ->method('loadAllLocations') ->willReturn($locations); + $matcher = self::atLeastOnce(); $this->mapper - ->expects(self::atLeastOnce()) - ->method('setMapping') - ->withConsecutive([1, 2], [3, 4]); + ->expects($matcher) + ->method('setMapping')->willReturnCallback(function (...$parameters) use ($matcher) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame(1, $parameters[0]); + $this->assertSame(2, $parameters[1]); + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame(3, $parameters[0]); + $this->assertSame(4, $parameters[1]); + } + }); $actualLocations = $this->locationService->loadAllLocations(); diff --git a/tests/lib/Repository/Mapper/ContentMapperTest.php b/tests/lib/Repository/Mapper/ContentMapperTest.php index 0eaca26ba8..6d2903ae01 100644 --- a/tests/lib/Repository/Mapper/ContentMapperTest.php +++ b/tests/lib/Repository/Mapper/ContentMapperTest.php @@ -14,18 +14,21 @@ use Ibexa\Core\FieldType\FieldTypeRegistry; use Ibexa\Core\FieldType\TextLine; use Ibexa\Core\Persistence\Legacy\Content\Language\Handler; +use Ibexa\Core\Repository\ContentService; use Ibexa\Core\Repository\Mapper\ContentMapper; use Ibexa\Core\Repository\Values\Content\Content; use Ibexa\Core\Repository\Values\Content\VersionInfo; use Ibexa\Core\Repository\Values\ContentType\ContentType; use Ibexa\Core\Repository\Values\ContentType\FieldDefinition; use Ibexa\Core\Repository\Values\ContentType\FieldDefinitionCollection; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\MockObject\Stub; use PHPUnit\Framework\TestCase; +#[CoversClass(ContentService::class)] final class ContentMapperTest extends TestCase { - /** @var \Ibexa\Core\Persistence\Legacy\Content\Language\Handler&\PHPUnit\Framework\MockObject\MockObject */ - private Handler $contentLanguageHandler; + private Handler&Stub $contentLanguageHandler; /** @var \Ibexa\Core\FieldType\FieldTypeRegistry&\PHPUnit\Framework\MockObject\MockObject */ private FieldTypeRegistry $fieldTypeRegistry; @@ -34,7 +37,7 @@ final class ContentMapperTest extends TestCase protected function setUp(): void { - $this->contentLanguageHandler = $this->createMock(Handler::class); + $this->contentLanguageHandler = self::createStub(Handler::class); $this->fieldTypeRegistry = $this->createMock(FieldTypeRegistry::class); $this->contentMapper = new ContentMapper( @@ -44,8 +47,6 @@ protected function setUp(): void } /** - * @covers \Ibexa\Core\Repository\ContentService::updateContent - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\ContentValidationException */ public function testUpdateContentGetsProperFieldsToUpdate(): void diff --git a/tests/lib/Repository/NameSchema/NameSchemaServiceTest.php b/tests/lib/Repository/NameSchema/NameSchemaServiceTest.php index c2e3de0411..7e7c5b9c23 100644 --- a/tests/lib/Repository/NameSchema/NameSchemaServiceTest.php +++ b/tests/lib/Repository/NameSchema/NameSchemaServiceTest.php @@ -24,12 +24,12 @@ use Ibexa\Core\Repository\Values\ContentType\FieldDefinition; use Ibexa\Core\Repository\Values\ContentType\FieldDefinitionCollection; use Ibexa\Tests\Core\Repository\Service\Mock\Base as BaseServiceMockTest; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use Symfony\Contracts\EventDispatcher\EventDispatcherInterface; use Traversable; -/** - * @covers \Ibexa\Core\Repository\NameSchema\NameSchemaService - */ +#[CoversClass(NameSchemaService::class)] final class NameSchemaServiceTest extends BaseServiceMockTest { private const NAME_SCHEMA = ''; @@ -134,13 +134,12 @@ public static function getDataForTestResolveNameSchema(): iterable } /** - * @dataProvider getDataForTestResolveNameSchema - * * @param array> $fieldMap * @param array> $tokenValues * @param array $languageCodes * @param array> $expectedNames */ + #[DataProvider('getDataForTestResolveNameSchema')] public function testResolveNameSchema( array $fieldMap, array $tokenValues, @@ -258,14 +257,13 @@ public static function getDataForTestResolve(): array } /** - * @dataProvider getDataForTestResolve - * * @param array> $schemaIdentifiers * @param array $languageFieldValues field value translations * @param array> $fieldMap * @param array> $fieldTitles [language => [field_identifier => title]] * @param array{limit?: int, sequence?: string} $settings NameSchemaService settings */ + #[DataProvider('getDataForTestResolve')] public function testResolve( array $schemaIdentifiers, string $nameSchema, diff --git a/tests/lib/Repository/NameSchema/SchemaIdentifierExtractorTest.php b/tests/lib/Repository/NameSchema/SchemaIdentifierExtractorTest.php index 29517d557c..8a5a94b4d6 100644 --- a/tests/lib/Repository/NameSchema/SchemaIdentifierExtractorTest.php +++ b/tests/lib/Repository/NameSchema/SchemaIdentifierExtractorTest.php @@ -10,11 +10,11 @@ use Ibexa\Contracts\Core\Repository\NameSchema\SchemaIdentifierExtractorInterface; use Ibexa\Core\Repository\NameSchema\SchemaIdentifierExtractor; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Repository\NameSchema\SchemaIdentifierExtractor - */ +#[CoversClass(SchemaIdentifierExtractor::class)] final class SchemaIdentifierExtractorTest extends TestCase { private SchemaIdentifierExtractorInterface $extractor; @@ -22,7 +22,7 @@ final class SchemaIdentifierExtractorTest extends TestCase /** * @return iterable>}> */ - public function getDataForTestExtract(): iterable + public static function getDataForTestExtract(): iterable { $schemaString = ''; yield $schemaString => [ @@ -111,10 +111,9 @@ protected function setUp(): void } /** - * @dataProvider getDataForTestExtract - * * @param array> $expectedStrategyIdentifierMap */ + #[DataProvider('getDataForTestExtract')] public function testExtract(string $schemaString, array $expectedStrategyIdentifierMap): void { $extracted = $this->extractor->extract($schemaString); diff --git a/tests/lib/Repository/Permission/CachedPermissionServiceTest.php b/tests/lib/Repository/Permission/CachedPermissionServiceTest.php index 81e50df53e..1998771022 100644 --- a/tests/lib/Repository/Permission/CachedPermissionServiceTest.php +++ b/tests/lib/Repository/Permission/CachedPermissionServiceTest.php @@ -29,6 +29,7 @@ function time() use Ibexa\Contracts\Core\Repository\Values\User\UserReference; use Ibexa\Contracts\Core\Repository\Values\ValueObject; use Ibexa\Core\Repository\Permission\CachedPermissionService; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; /** @@ -36,22 +37,16 @@ function time() */ class CachedPermissionServiceTest extends TestCase { - public function providerForTestPermissionResolverPassTrough() + /** + * @return array + */ + public static function providerForTestPermissionResolverPassTrough(): array { - $valueObject = $this - ->getMockBuilder(ValueObject::class) - ->disableOriginalConstructor() - ->getMockForAbstractClass(); + $valueObject = self::createStub(ValueObject::class); - $userRef = $this - ->getMockBuilder(UserReference::class) - ->disableOriginalConstructor() - ->getMockForAbstractClass(); + $userRef = self::createStub(UserReference::class); - $repository = $this - ->getMockBuilder(Repository::class) - ->disableOriginalConstructor() - ->getMockForAbstractClass(); + $repository = self::createStub(Repository::class); return [ ['getCurrentUserReference', [], $userRef], @@ -65,13 +60,13 @@ public function providerForTestPermissionResolverPassTrough() /** * Test for all PermissionResolver methods when they just pass true to underlying service. * - * @dataProvider providerForTestPermissionResolverPassTrough * * @param $method * @param array $arguments * @param $expectedReturn */ - public function testPermissionResolverPassTrough($method, array $arguments, $expectedReturn) + #[DataProvider('providerForTestPermissionResolverPassTrough')] + public function testPermissionResolverPassTrough($method, array $arguments, $expectedReturn): void { if ($expectedReturn !== null) { $this->getPermissionResolverMock([$method]) @@ -92,7 +87,7 @@ public function testPermissionResolverPassTrough($method, array $arguments, $exp self::assertSame($expectedReturn, $actualReturn); } - public function testGetPermissionsCriterionPassTrough() + public function testGetPermissionsCriterionPassTrough(): void { $criterionMock = $this ->getMockBuilder(Criterion::class) @@ -111,7 +106,7 @@ public function testGetPermissionsCriterionPassTrough() self::assertSame($criterionMock, $actualReturn); } - public function testGetPermissionsCriterionCaching() + public function testGetPermissionsCriterionCaching(): void { $criterionMock = $this ->getMockBuilder(Criterion::class) @@ -189,8 +184,10 @@ protected function getPermissionResolverMock($methods = []) return $this->permissionResolverMock = $this ->getMockBuilder(PermissionResolver::class) - ->setMethods($methods) ->disableOriginalConstructor() + // sudo() is not part of the PermissionResolver interface but is called on the + // concrete implementation at runtime; addMethods() lets it be stubbed here too. + ->addMethods(['sudo']) ->getMockForAbstractClass(); } @@ -205,7 +202,6 @@ protected function getPermissionCriterionResolverMock($methods = []) return $this->permissionCriterionResolverMock = $this ->getMockBuilder(PermissionCriterionResolver::class) - ->setMethods($methods) ->disableOriginalConstructor() ->getMockForAbstractClass(); } diff --git a/tests/lib/Repository/Permission/PermissionCriterionResolverTest.php b/tests/lib/Repository/Permission/PermissionCriterionResolverTest.php index 693d62c45a..d8be23a311 100644 --- a/tests/lib/Repository/Permission/PermissionCriterionResolverTest.php +++ b/tests/lib/Repository/Permission/PermissionCriterionResolverTest.php @@ -16,6 +16,7 @@ use Ibexa\Core\Repository\Permission\LimitationService; use Ibexa\Core\Repository\Permission\PermissionCriterionResolver; use Ibexa\Core\Repository\Values\User\Policy; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; /** @@ -23,23 +24,19 @@ */ class PermissionCriterionResolverTest extends TestCase { - public function providerForTestGetPermissionsCriterion() + /** + * @return array + */ + public static function providerForTestGetPermissionsCriterion(): array { - $criterionMock = $this - ->getMockBuilder(Criterion::class) - ->disableOriginalConstructor() - ->getMock(); - $limitationMock = $this - ->getMockBuilder(Limitation::class) - ->getMockForAbstractClass(); + $criterionMock = self::createStub(Criterion::class); + $limitationMock = self::createStub(Limitation::class); $limitationMock - ->expects(self::any()) ->method('getIdentifier') - ->will(self::returnValue('limitationIdentifier')); + ->willReturn('limitationIdentifier'); - $targetOnlyLimitationMock = $this->createMock(Limitation::class); + $targetOnlyLimitationMock = self::createStub(Limitation::class); $targetOnlyLimitationMock - ->expects(self::any()) ->method('getIdentifier') ->willReturn('targetOnlyLimitationIdentifier'); @@ -287,15 +284,14 @@ protected function mockServices($criterionMock, $limitationCount, $permissionSet /** * Test for the getPermissionsCriterion() method. - * - * @dataProvider providerForTestGetPermissionsCriterion */ + #[DataProvider('providerForTestGetPermissionsCriterion')] public function testGetPermissionsCriterion( $criterionMock, $limitationCount, $permissionSets, $expectedCriterion - ) { + ): void { $this->mockServices($criterionMock, $limitationCount, $permissionSets); $criterionResolver = $this->getPermissionCriterionResolverMock(null); @@ -304,7 +300,10 @@ public function testGetPermissionsCriterion( self::assertEquals($expectedCriterion, $permissionsCriterion); } - public function providerForTestGetPermissionsCriterionBooleanPermissionSets() + /** + * @return array + */ + public static function providerForTestGetPermissionsCriterionBooleanPermissionSets(): array { return [ [true], @@ -314,10 +313,9 @@ public function providerForTestGetPermissionsCriterionBooleanPermissionSets() /** * Test for the getPermissionsCriterion() method. - * - * @dataProvider providerForTestGetPermissionsCriterionBooleanPermissionSets */ - public function testGetPermissionsCriterionBooleanPermissionSets($permissionSets) + #[DataProvider('providerForTestGetPermissionsCriterionBooleanPermissionSets')] + public function testGetPermissionsCriterionBooleanPermissionSets($permissionSets): void { $permissionResolverMock = $this->getPermissionResolverMock(['hasAccess']); $permissionResolverMock @@ -342,16 +340,21 @@ public function testGetPermissionsCriterionBooleanPermissionSets($permissionSets */ protected function getPermissionCriterionResolverMock($methods = []) { - return $this + $builder = $this ->getMockBuilder(PermissionCriterionResolver::class) - ->setMethods($methods) ->setConstructorArgs( [ $this->getPermissionResolverMock(), $this->getLimitationServiceMock(), ] - ) - ->getMock(); + ); + if ($methods === null) { + $builder->onlyMethods([]); + } elseif ($methods !== []) { + $builder->onlyMethods(array_values($methods)); + } + + return $builder->getMock(); } protected $permissionResolverMock; @@ -365,7 +368,6 @@ protected function getPermissionResolverMock($methods = []) return $this->permissionResolverMock = $this ->getMockBuilder(PermissionResolver::class) - ->setMethods($methods) ->disableOriginalConstructor() ->getMockForAbstractClass(); } @@ -379,10 +381,13 @@ protected function getLimitationServiceMock($methods = []) return $this->limitationServiceMock; } - return $this->limitationServiceMock = $this + $builder = $this ->getMockBuilder(LimitationService::class) - ->setMethods($methods) - ->disableOriginalConstructor() - ->getMock(); + ->disableOriginalConstructor(); + if ($methods !== []) { + $builder->onlyMethods(array_values($methods)); + } + + return $this->limitationServiceMock = $builder->getMock(); } } diff --git a/tests/lib/Repository/Service/Mock/Base.php b/tests/lib/Repository/Service/Mock/Base.php index 8fcb31a189..842be6d7d6 100644 --- a/tests/lib/Repository/Service/Mock/Base.php +++ b/tests/lib/Repository/Service/Mock/Base.php @@ -119,8 +119,8 @@ protected function getRepository(array $serviceSettings = []) new NullIndexer(), $this->getRelationProcessorMock(), $this->getFieldTypeRegistryMock(), - $this->createMock(PasswordHashService::class), - $this->createMock(ProxyDomainMapperFactoryInterface::class), + self::createStub(PasswordHashService::class), + self::createStub(ProxyDomainMapperFactoryInterface::class), $this->getContentDomainMapperMock(), $this->getContentTypeDomainMapperMock(), $this->getRoleDomainMapperMock(), @@ -131,12 +131,12 @@ protected function getRepository(array $serviceSettings = []) $this->getPermissionServiceMock(), $this->getContentFilteringHandlerMock(), $this->getLocationFilteringHandlerMock(), - $this->createMock(PasswordValidatorInterface::class), - $this->createMock(ConfigResolverInterface::class), - $this->createMock(NameSchemaServiceInterface::class), + self::createStub(PasswordValidatorInterface::class), + self::createStub(ConfigResolverInterface::class), + self::createStub(NameSchemaServiceInterface::class), $this->getTransactionHandlerMock(), new ContentCollector(), - $this->createMock(ValidatorInterface::class), + self::createStub(ValidatorInterface::class), $serviceSettings, ); @@ -343,7 +343,6 @@ protected function getSPIMockHandler($handler) { if (!isset($this->spiMockHandlers[$handler])) { $this->spiMockHandlers[$handler] = $this->getMockBuilder("Ibexa\\Contracts\\Core\\{$handler}") - ->setMethods([]) ->disableOriginalConstructor() ->setConstructorArgs([]) ->getMock(); @@ -420,7 +419,7 @@ protected function getRoleDomainMapperMock(array $methods = []): RoleDomainMappe if ($this->roleDomainMapperMock === null) { $mockBuilder = $this->getMockBuilder(RoleDomainMapper::class); if (!empty($methods)) { - $mockBuilder->onlyMethods($methods); + $mockBuilder->onlyMethods(array_values($methods)); } $this->roleDomainMapperMock = $mockBuilder ->disableOriginalConstructor() diff --git a/tests/lib/Repository/Service/Mock/BookmarkTest.php b/tests/lib/Repository/Service/Mock/BookmarkTest.php index 880dad3444..810b3dbeb3 100644 --- a/tests/lib/Repository/Service/Mock/BookmarkTest.php +++ b/tests/lib/Repository/Service/Mock/BookmarkTest.php @@ -20,8 +20,10 @@ use Ibexa\Core\Repository\Values\Content\Location; use Ibexa\Core\Repository\Values\User\UserReference; use Ibexa\Tests\Core\Repository\Service\Mock\Base as BaseServiceMockTest; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\MockObject\MockObject; +#[CoversClass(BookmarkService::class)] class BookmarkTest extends BaseServiceMockTest { public const BOOKMARK_ID = 2; @@ -50,10 +52,7 @@ protected function setUp(): void ->willReturn($permissionResolverMock); } - /** - * @covers \Ibexa\Contracts\Core\Repository\BookmarkService::createBookmark - */ - public function testCreateBookmark() + public function testCreateBookmark(): void { $location = $this->createLocation(self::LOCATION_ID); @@ -80,10 +79,7 @@ public function testCreateBookmark() $this->createBookmarkService()->createBookmark($location); } - /** - * @covers \Ibexa\Contracts\Core\Repository\BookmarkService::createBookmark - */ - public function testCreateBookmarkThrowsInvalidArgumentException() + public function testCreateBookmarkThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -104,10 +100,7 @@ public function testCreateBookmarkThrowsInvalidArgumentException() $this->createBookmarkService()->createBookmark($location); } - /** - * @covers \Ibexa\Contracts\Core\Repository\BookmarkService::createBookmark - */ - public function testCreateBookmarkWithRollback() + public function testCreateBookmarkWithRollback(): void { $this->expectException(\Exception::class); @@ -125,16 +118,13 @@ public function testCreateBookmarkWithRollback() $this->bookmarkHandler ->expects($this->once()) ->method('create') - ->willThrowException($this->createMock(Exception::class)); + ->willThrowException(self::createStub(Exception::class)); }); $this->createBookmarkService()->createBookmark($location); } - /** - * @covers \Ibexa\Contracts\Core\Repository\BookmarkService::deleteBookmark - */ - public function testDeleteBookmarkExisting() + public function testDeleteBookmarkExisting(): void { $location = $this->createLocation(self::LOCATION_ID); @@ -158,10 +148,7 @@ public function testDeleteBookmarkExisting() $this->createBookmarkService()->deleteBookmark($location); } - /** - * @covers \Ibexa\Contracts\Core\Repository\BookmarkService::deleteBookmark - */ - public function testDeleteBookmarkWithRollback() + public function testDeleteBookmarkWithRollback(): void { $this->expectException(\Exception::class); @@ -179,16 +166,13 @@ public function testDeleteBookmarkWithRollback() $this->bookmarkHandler ->expects($this->once()) ->method('delete') - ->willThrowException($this->createMock(Exception::class)); + ->willThrowException(self::createStub(Exception::class)); }); $this->createBookmarkService()->deleteBookmark($location); } - /** - * @covers \Ibexa\Contracts\Core\Repository\BookmarkService::deleteBookmark - */ - public function testDeleteBookmarkNonExisting() + public function testDeleteBookmarkNonExisting(): void { $this->expectException(InvalidArgumentException::class); @@ -209,10 +193,7 @@ public function testDeleteBookmarkNonExisting() $this->createBookmarkService()->deleteBookmark($location); } - /** - * @covers \Ibexa\Contracts\Core\Repository\BookmarkService::loadBookmarks - */ - public function testLoadBookmarks() + public function testLoadBookmarks(): void { $offset = 0; $limit = 25; @@ -246,10 +227,7 @@ public function testLoadBookmarks() self::assertEquals($expectedItems, $bookmarks->items); } - /** - * @covers \Ibexa\Contracts\Core\Repository\BookmarkService::isBookmarked - */ - public function testLocationShouldNotBeBookmarked() + public function testLocationShouldNotBeBookmarked(): void { $this->bookmarkHandler ->expects(self::once()) @@ -260,7 +238,7 @@ public function testLocationShouldNotBeBookmarked() self::assertFalse($this->createBookmarkService()->isBookmarked($this->createLocation(self::LOCATION_ID))); } - public function testLocationShouldBeBookmarked() + public function testLocationShouldBeBookmarked(): void { $this->bookmarkHandler ->expects(self::once()) @@ -333,7 +311,7 @@ private function createBookmarkService(?array $methods = null) return $this ->getMockBuilder(BookmarkService::class) ->setConstructorArgs([$this->getRepositoryMock(), $this->bookmarkHandler]) - ->setMethods($methods) + ->onlyMethods(array_values($methods ?? [])) ->getMock(); } } diff --git a/tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php b/tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php index 90b18f41e3..e824546af8 100644 --- a/tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php +++ b/tests/lib/Repository/Service/Mock/ContentDomainMapperTest.php @@ -27,12 +27,13 @@ use Ibexa\Core\Repository\Values\Content\VersionInfo; use Ibexa\Core\Repository\Values\ContentType\FieldDefinitionCollection; use Ibexa\Tests\Core\Repository\Service\Mock\Base as BaseServiceMockTest; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Group; use Psr\Log\LoggerInterface; use Symfony\Bridge\PhpUnit\ExpectDeprecationTrait; -/** - * @covers \Ibexa\Core\Repository\Mapper\ContentDomainMapper - */ +#[CoversClass(ContentDomainMapper::class)] final class ContentDomainMapperTest extends BaseServiceMockTest { use ExpectDeprecationTrait; @@ -48,10 +49,8 @@ final class ContentDomainMapperTest extends BaseServiceMockTest private const EXAMPLE_CREATOR_ID = 23; private const int EXAMPLE_VERSION_INFO_ID = 12; - /** - * @dataProvider providerForBuildVersionInfo - */ - public function testBuildVersionInfo(SPIVersionInfo $spiVersionInfo) + #[DataProvider('providerForBuildVersionInfo')] + public function testBuildVersionInfo(SPIVersionInfo $spiVersionInfo): void { $languageHandlerMock = $this->getLanguageHandlerMock(); $languageHandlerMock->expects(self::never())->method('load'); @@ -61,7 +60,7 @@ public function testBuildVersionInfo(SPIVersionInfo $spiVersionInfo) self::assertInstanceOf(APIVersionInfo::class, $versionInfo); } - public function testBuildLocationWithContentForRootLocation() + public function testBuildLocationWithContentForRootLocation(): void { $spiRootLocation = new Location([ 'id' => 1, @@ -116,7 +115,7 @@ public function testBuildLocationWithContentForRootLocation() self::assertEquals($expectedContent, $apiRootLocation->getContent()); } - public function testBuildLocationWithContentThrowsInvalidArgumentException() + public function testBuildLocationWithContentThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('Argument \'$content\' is invalid: Location 2 has missing Content'); @@ -126,7 +125,7 @@ public function testBuildLocationWithContentThrowsInvalidArgumentException() $this->getContentDomainMapper()->buildLocationWithContent($nonRootLocation, null); } - public function testBuildLocationWithContentIsAlignedWithBuildLocation() + public function testBuildLocationWithContentIsAlignedWithBuildLocation(): void { $spiRootLocation = new Location([ 'id' => 1, @@ -149,13 +148,12 @@ public function testBuildLocationWithContentIsAlignedWithBuildLocation() /** * @throws \Ibexa\Contracts\Core\Repository\Exceptions\Exception - * - * @group legacy */ + #[Group('legacy')] public function testBuildDomainFieldsDeprecatedBehavior(): void { $persistenceFields = [new PersistenceContentField()]; - $persistenceContentType = $this->createMock(PersistenceContentType::class); + $persistenceContentType = self::createStub(PersistenceContentType::class); $apiContentTypeMock = $this->createMock(ContentType::class); $apiContentTypeMock->method('getFieldDefinitions')->willReturn(new FieldDefinitionCollection()); $this @@ -175,7 +173,10 @@ public function testBuildDomainFieldsDeprecatedBehavior(): void $this->getContentDomainMapper()->buildDomainFields($persistenceFields, $persistenceContentType); } - public function providerForBuildVersionInfo() + /** + * @return array + */ + public static function providerForBuildVersionInfo(): array { $properties = [ 'id' => self::EXAMPLE_VERSION_INFO_ID, @@ -238,7 +239,10 @@ public function providerForBuildVersionInfo() ]; } - public function providerForBuildLocationDomainObjectsOnSearchResult() + /** + * @return array + */ + public static function providerForBuildLocationDomainObjectsOnSearchResult(): array { $properties = [ 'name' => self::EXAMPLE_NAME, @@ -314,21 +318,20 @@ public function providerForBuildLocationDomainObjectsOnSearchResult() } /** - * @dataProvider providerForBuildLocationDomainObjectsOnSearchResult - * * @param array $locationHits * @param array $contentIds * @param array $languageFilter * @param array $contentInfoList * @param int $missing */ + #[DataProvider('providerForBuildLocationDomainObjectsOnSearchResult')] public function testBuildLocationDomainObjectsOnSearchResult( array $locationHits, array $contentIds, array $languageFilter, array $contentInfoList, int $missing - ) { + ): void { $contentHandlerMock = $this->getContentHandlerMock(); $contentHandlerMock ->expects(self::once()) diff --git a/tests/lib/Repository/Service/Mock/ContentTest.php b/tests/lib/Repository/Service/Mock/ContentTest.php index a73c265069..3dc9f011d8 100644 --- a/tests/lib/Repository/Service/Mock/ContentTest.php +++ b/tests/lib/Repository/Service/Mock/ContentTest.php @@ -49,6 +49,7 @@ use Ibexa\Core\Repository\Collector\ContentCollector; use Ibexa\Core\Repository\ContentService; use Ibexa\Core\Repository\Helper\RelationProcessor; +use Ibexa\Core\Repository\Mapper\ContentMapper; use Ibexa\Core\Repository\Values\Content\Content; use Ibexa\Core\Repository\Values\Content\ContentCreateStruct; use Ibexa\Core\Repository\Values\Content\ContentUpdateStruct; @@ -59,11 +60,18 @@ use Ibexa\Core\Repository\Values\ContentType\FieldDefinitionCollection; use Ibexa\Core\Repository\Values\User\UserReference; use Ibexa\Tests\Core\Repository\Service\Mock\Base as BaseServiceMockTest; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\Depends; +use PHPUnit\Framework\Attributes\DependsExternal; +use PHPUnit\Framework\MockObject\MockObject; use Symfony\Component\Validator\Validator\ValidatorInterface; /** * Mock test case for Content service. */ +#[CoversClass(ContentService::class)] +#[CoversClass(ContentMapper::class)] class ContentTest extends BaseServiceMockTest { private const string EMPTY_FIELD_VALUE = 'empty'; @@ -78,8 +86,6 @@ class ContentTest extends BaseServiceMockTest /** * Test for the __construct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::__construct */ public function testConstructor(): void { @@ -112,17 +118,15 @@ public function testConstructor(): void $contentValidatorStrategy, $contentFilteringHandlerMock, new ContentCollector(), - $this->createMock(ValidatorInterface::class), + self::createStub(ValidatorInterface::class), $settings ); } /** * Test for the loadVersionInfo() method, of published version. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfoById */ - public function testLoadVersionInfoById() + public function testLoadVersionInfoById(): void { $contentServiceMock = $this->getPartlyMockedContentService(['loadContentInfo']); /** @var \PHPUnit\Framework\MockObject\MockObject $contentHandler */ @@ -167,12 +171,9 @@ public function testLoadVersionInfoById() /** * Test for the loadVersionInfo() method, of a draft. - * - * @depends testLoadVersionInfoById - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfoById */ - public function testLoadVersionInfoByIdAndVersionNumber() + #[Depends('testLoadVersionInfoById')] + public function testLoadVersionInfoByIdAndVersionNumber(): void { $permissionResolver = $this->getPermissionResolverMock(); $contentServiceMock = $this->getPartlyMockedContentService(['loadContentInfo']); @@ -216,10 +217,8 @@ public function testLoadVersionInfoByIdAndVersionNumber() /** * Test for the loadVersionInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfoById */ - public function testLoadVersionInfoByIdThrowsNotFoundException() + public function testLoadVersionInfoByIdThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -249,10 +248,8 @@ public function testLoadVersionInfoByIdThrowsNotFoundException() /** * Test for the loadVersionInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfoById */ - public function testLoadVersionInfoByIdThrowsUnauthorizedExceptionNonPublishedVersion() + public function testLoadVersionInfoByIdThrowsUnauthorizedExceptionNonPublishedVersion(): void { $this->expectException(UnauthorizedException::class); @@ -294,10 +291,8 @@ public function testLoadVersionInfoByIdThrowsUnauthorizedExceptionNonPublishedVe /** * Test for the loadVersionInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfoById */ - public function testLoadVersionInfoByIdPublishedVersion() + public function testLoadVersionInfoByIdPublishedVersion(): void { $contentServiceMock = $this->getPartlyMockedContentService(); /** @var \PHPUnit\Framework\MockObject\MockObject $contentHandler */ @@ -339,10 +334,8 @@ public function testLoadVersionInfoByIdPublishedVersion() /** * Test for the loadVersionInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfoById */ - public function testLoadVersionInfoByIdNonPublishedVersion() + public function testLoadVersionInfoByIdNonPublishedVersion(): void { $contentServiceMock = $this->getPartlyMockedContentService(); /** @var \PHPUnit\Framework\MockObject\MockObject $contentHandler */ @@ -384,18 +377,15 @@ public function testLoadVersionInfoByIdNonPublishedVersion() /** * Test for the loadVersionInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadVersionInfo - * - * @depends Ibexa\Tests\Core\Repository\Service\Mock\ContentTest::testLoadVersionInfoById - * @depends Ibexa\Tests\Core\Repository\Service\Mock\ContentTest::testLoadVersionInfoByIdThrowsNotFoundException - * @depends Ibexa\Tests\Core\Repository\Service\Mock\ContentTest::testLoadVersionInfoByIdThrowsUnauthorizedExceptionNonPublishedVersion - * @depends Ibexa\Tests\Core\Repository\Service\Mock\ContentTest::testLoadVersionInfoByIdPublishedVersion - * @depends Ibexa\Tests\Core\Repository\Service\Mock\ContentTest::testLoadVersionInfoByIdNonPublishedVersion */ - public function testLoadVersionInfo() + #[DependsExternal(self::class, 'testLoadVersionInfoById')] + #[DependsExternal(self::class, 'testLoadVersionInfoByIdThrowsNotFoundException')] + #[DependsExternal(self::class, 'testLoadVersionInfoByIdThrowsUnauthorizedExceptionNonPublishedVersion')] + #[DependsExternal(self::class, 'testLoadVersionInfoByIdPublishedVersion')] + #[DependsExternal(self::class, 'testLoadVersionInfoByIdNonPublishedVersion')] + public function testLoadVersionInfo(): void { - $expectedResult = $this->createMock(VersionInfo::class); + $expectedResult = self::createStub(VersionInfo::class); $contentServiceMock = $this->getPartlyMockedContentService( ['loadVersionInfoById'] @@ -419,7 +409,7 @@ public function testLoadVersionInfo() self::assertEquals($expectedResult, $result); } - public function testLoadContent() + public function testLoadContent(): void { $contentService = $this->getPartlyMockedContentService(['internalLoadContentById']); $content = $this->createMock(APIContent::class); @@ -450,11 +440,11 @@ public function testLoadContent() self::assertSame($content, $contentService->loadContent($contentId)); } - public function testLoadContentNonPublished() + public function testLoadContentNonPublished(): void { $contentService = $this->getPartlyMockedContentService(['internalLoadContentById']); $content = $this->createMock(APIContent::class); - $versionInfo = $this->createMock(APIVersionInfo::class); + $versionInfo = self::createStub(APIVersionInfo::class); $permissionResolver = $this->getPermissionResolverMock(); $content @@ -483,14 +473,14 @@ public function testLoadContentNonPublished() self::assertSame($content, $contentService->loadContent($contentId)); } - public function testLoadContentUnauthorized() + public function testLoadContentUnauthorized(): void { $this->expectException(UnauthorizedException::class); $permissionResolver = $this->getPermissionResolverMock(); $contentService = $this->getPartlyMockedContentService(['internalLoadContentById']); - $content = $this->createMock(APIContent::class); + $content = self::createStub(APIContent::class); $contentId = 123; $contentService ->expects(self::once()) @@ -507,7 +497,7 @@ public function testLoadContentUnauthorized() $contentService->loadContent($contentId); } - public function testLoadContentNotPublishedStatusUnauthorized() + public function testLoadContentNotPublishedStatusUnauthorized(): void { $permissionResolver = $this->getPermissionResolverMock(); $contentService = $this->getPartlyMockedContentService(['internalLoadContentById']); @@ -542,9 +532,7 @@ public function testLoadContentNotPublishedStatusUnauthorized() $contentService->loadContent($contentId); } - /** - * @dataProvider internalLoadContentProviderById - */ + #[DataProvider('internalLoadContentProviderById')] public function testInternalLoadContentById(int $id, ?array $languages, ?int $versionNo, bool $useAlwaysAvailable): void { if (!empty($languages) && $useAlwaysAvailable) { @@ -584,10 +572,8 @@ public function testInternalLoadContentById(int $id, ?array $languages, ?int $ve self::assertSame($expectedContent, $actualContent); } - /** - * @dataProvider internalLoadContentProviderByRemoteId - */ - public function testInternalLoadContentByRemoteId(string $remoteId, ?array $languages, ?int $versionNo, bool $useAlwaysAvailable) + #[DataProvider('internalLoadContentProviderByRemoteId')] + public function testInternalLoadContentByRemoteId(string $remoteId, ?array $languages, ?int $versionNo, bool $useAlwaysAvailable): void { $realId = 123; @@ -629,7 +615,7 @@ public function testInternalLoadContentByRemoteId(string $remoteId, ?array $lang self::assertSame($expectedContent, $actualContent); } - public function internalLoadContentProviderById(): array + public static function internalLoadContentProviderById(): array { return [ [123, null, null, false], @@ -642,7 +628,7 @@ public function internalLoadContentProviderById(): array ]; } - public function internalLoadContentProviderByRemoteId(): array + public static function internalLoadContentProviderByRemoteId(): array { return [ ['123', null, null, false], @@ -677,7 +663,7 @@ public function testInternalLoadContentByIdNotFound(): void ->with($id, $versionNo, $languages) ->will( self::throwException( - $this->createMock(APINotFoundException::class) + self::createStub(APINotFoundException::class) ) ); @@ -707,7 +693,7 @@ public function testInternalLoadContentByRemoteIdNotFound(): void ->method('load') ->with($id, $versionNo, $languages) ->willThrowException( - $this->createMock(APINotFoundException::class) + self::createStub(APINotFoundException::class) ); $contentService = $this->getPartlyMockedContentService(); @@ -716,12 +702,10 @@ public function testInternalLoadContentByRemoteIdNotFound(): void /** * Test for the loadContentByContentInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByContentInfo */ - public function testLoadContentByContentInfo() + public function testLoadContentByContentInfo(): void { - $versionInfo = $this->createMock(APIVersionInfo::class); + $versionInfo = self::createStub(APIVersionInfo::class); $content = $this->createMock(APIContent::class); $content->method('getVersionInfo') ->will(self::returnValue($versionInfo)); @@ -758,12 +742,10 @@ public function testLoadContentByContentInfo() /** * Test for the loadContentByVersionInfo() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::loadContentByVersionInfo */ - public function testLoadContentByVersionInfo() + public function testLoadContentByVersionInfo(): void { - $expectedResult = $this->createMock(Content::class); + $expectedResult = self::createStub(Content::class); $contentServiceMock = $this->getPartlyMockedContentService( ['loadContent'] @@ -796,10 +778,8 @@ public function testLoadContentByVersionInfo() /** * Test for the deleteContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteContent */ - public function testDeleteContentThrowsUnauthorizedException() + public function testDeleteContentThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -845,10 +825,8 @@ public function testDeleteContentThrowsUnauthorizedException() /** * Test for the deleteContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteContent */ - public function testDeleteContent() + public function testDeleteContent(): void { $repository = $this->getRepositoryMock(); $permissionResolver = $this->getPermissionResolverMock(); @@ -907,11 +885,15 @@ public function testDeleteContent() ->method('deleteContent') ->with(42); - foreach ($spiLocations as $index => $spiLocation) { - $urlAliasHandler->expects(self::at($index)) - ->method('locationDeleted') - ->with($spiLocation->id); - } + $locationDeletedMatcher = self::exactly(count($spiLocations)); + $urlAliasHandler->expects($locationDeletedMatcher) + ->method('locationDeleted') + ->willReturnCallback(static function ($locationId) use ($locationDeletedMatcher, $spiLocations): array { + $expectedLocation = $spiLocations[$locationDeletedMatcher->numberOfInvocations() - 1]; + self::assertSame($expectedLocation->id, $locationId); + + return []; + }); $repository->expects(self::once())->method('commit'); @@ -921,10 +903,8 @@ public function testDeleteContent() /** * Test for the deleteContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteContent */ - public function testDeleteContentWithRollback() + public function testDeleteContentWithRollback(): void { $this->expectException(\Exception::class); @@ -984,10 +964,8 @@ public function testDeleteContentWithRollback() /** * Test for the deleteVersion() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::deleteVersion */ - public function testDeleteVersionThrowsBadStateExceptionLastVersion() + public function testDeleteVersionThrowsBadStateExceptionLastVersion(): void { $this->expectException(BadStateException::class); @@ -1043,10 +1021,8 @@ public function testDeleteVersionThrowsBadStateExceptionLastVersion() /** * Test for the createContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent */ - public function testCreateContentThrowsUnauthorizedException() + public function testCreateContentThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -1106,11 +1082,10 @@ public function testCreateContentThrowsUnauthorizedException() /** * Test for the createContent() method. * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent * * @exceptionMessage Argument '$contentCreateStruct' is invalid: Another content with remoteId 'faraday' exists */ - public function testCreateContentThrowsInvalidArgumentExceptionDuplicateRemoteId() + public function testCreateContentThrowsInvalidArgumentExceptionDuplicateRemoteId(): void { $this->expectException(InvalidArgumentException::class); @@ -1119,7 +1094,7 @@ public function testCreateContentThrowsInvalidArgumentExceptionDuplicateRemoteId $permissionResolverMock ->expects(self::once()) ->method('getCurrentUserReference') - ->willReturn($this->createMock(UserReference::class)); + ->willReturn(self::createStub(UserReference::class)); $mockedService = $this->getPartlyMockedContentService(['loadContentByRemoteId']); $contentTypeServiceMock = $this->getContentTypeServiceMock(); @@ -1160,7 +1135,7 @@ public function testCreateContentThrowsInvalidArgumentExceptionDuplicateRemoteId $mockedService->expects(self::once()) ->method('loadContentByRemoteId') ->with($contentCreateStruct->remoteId) - ->will(self::returnValue($this->createMock(Content::class))); + ->will(self::returnValue(self::createStub(Content::class))); $mockedService->createContent( new ContentCreateStruct( @@ -1371,8 +1346,8 @@ static function (ValueStub $value): string { ->expects(self::exactly(count($fieldDefinitions) * count($languageCodes))) ->method('appendFieldRelations') ->with( - self::isType('array'), - self::isType('array'), + self::isArray(), + self::isArray(), self::isInstanceOf(SPIFieldType::class), self::isInstanceOf(Value::class), self::anything() @@ -1396,9 +1371,9 @@ static function (ValueStub $value): string { $relationProcessorMock->expects(self::any()) ->method('processFieldRelations') ->with( - self::isType('array'), + self::isArray(), self::equalTo(42), - self::isType('int'), + self::isInt(), self::equalTo($contentType), self::equalTo([]) ); @@ -1456,7 +1431,10 @@ static function (ValueStub $value): string { return $contentCreateStruct; } - public function providerForTestCreateContentNonRedundantFieldSet1() + /** + * @return array + */ + public static function providerForTestCreateContentNonRedundantFieldSet1(): array { $spiFields = [ new SPIField( @@ -1506,16 +1484,9 @@ public function providerForTestCreateContentNonRedundantFieldSet1() * Test for the createContent() method. * * Testing the simplest use case. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::cloneField - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getDefaultObjectStates - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent - * - * @dataProvider providerForTestCreateContentNonRedundantFieldSet1 */ - public function testCreateContentNonRedundantFieldSet1($mainLanguageCode, $structFields, $spiFields) + #[DataProvider('providerForTestCreateContentNonRedundantFieldSet1')] + public function testCreateContentNonRedundantFieldSet1($mainLanguageCode, $structFields, $spiFields): void { $fieldDefinitions = [ new FieldDefinition( @@ -1538,7 +1509,10 @@ public function testCreateContentNonRedundantFieldSet1($mainLanguageCode, $struc ); } - public function providerForTestCreateContentNonRedundantFieldSet2() + /** + * @return array + */ + public static function providerForTestCreateContentNonRedundantFieldSet2(): array { $spiFields = [ new SPIField( @@ -1611,16 +1585,9 @@ public function providerForTestCreateContentNonRedundantFieldSet2() * Test for the createContent() method. * * Testing multiple languages with multiple translatable fields with empty default value. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::cloneField - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getDefaultObjectStates - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent - * - * @dataProvider providerForTestCreateContentNonRedundantFieldSet2 */ - public function testCreateContentNonRedundantFieldSet2($mainLanguageCode, $structFields, $spiFields) + #[DataProvider('providerForTestCreateContentNonRedundantFieldSet2')] + public function testCreateContentNonRedundantFieldSet2($mainLanguageCode, $structFields, $spiFields): void { $fieldDefinitions = [ new FieldDefinition( @@ -1653,7 +1620,10 @@ public function testCreateContentNonRedundantFieldSet2($mainLanguageCode, $struc ); } - public function providerForTestCreateContentNonRedundantFieldSetComplex() + /** + * @return array + */ + public static function providerForTestCreateContentNonRedundantFieldSetComplex(): array { $spiFields0 = [ new SPIField( @@ -1827,16 +1797,9 @@ protected function fixturesForTestCreateContentNonRedundantFieldSetComplex() * Test for the createContent() method. * * Testing multiple languages with multiple translatable fields with empty default value. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::cloneField - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getDefaultObjectStates - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent - * - * @dataProvider providerForTestCreateContentNonRedundantFieldSetComplex */ - public function testCreateContentNonRedundantFieldSetComplex($mainLanguageCode, $structFields, $spiFields) + #[DataProvider('providerForTestCreateContentNonRedundantFieldSetComplex')] + public function testCreateContentNonRedundantFieldSetComplex($mainLanguageCode, $structFields, $spiFields): void { $fieldDefinitions = $this->fixturesForTestCreateContentNonRedundantFieldSetComplex(); @@ -1848,7 +1811,10 @@ public function testCreateContentNonRedundantFieldSetComplex($mainLanguageCode, ); } - public function providerForTestCreateContentWithInvalidLanguage() + /** + * @return array + */ + public static function providerForTestCreateContentWithInvalidLanguage(): array { return [ [ @@ -1880,13 +1846,9 @@ public function providerForTestCreateContentWithInvalidLanguage() /** * Test for the updateContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent - * - * @dataProvider providerForTestCreateContentWithInvalidLanguage */ - public function testCreateContentWithInvalidLanguage($mainLanguageCode, $structFields) + #[DataProvider('providerForTestCreateContentWithInvalidLanguage')] + public function testCreateContentWithInvalidLanguage($mainLanguageCode, $structFields): void { $this->expectException(APINotFoundException::class); $this->expectExceptionMessage('Could not find \'Language\' with identifier \'Klingon\''); @@ -1932,7 +1894,7 @@ public function testCreateContentWithInvalidLanguage($mainLanguageCode, $structF $languageHandlerMock->expects(self::any()) ->method('loadByLanguageCode') - ->with(self::isType('string')) + ->with(self::isString()) ->will( self::returnCallback( static function ($languageCode) { @@ -2057,7 +2019,10 @@ static function ($valueString) { $mockedService->createContent($contentCreateStruct, []); } - public function providerForTestCreateContentThrowsContentValidationExceptionFieldDefinition() + /** + * @return array + */ + public static function providerForTestCreateContentThrowsContentValidationExceptionFieldDefinition(): array { return [ [ @@ -2077,14 +2042,9 @@ public function providerForTestCreateContentThrowsContentValidationExceptionFiel /** * Test for the createContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent - * - * @dataProvider providerForTestCreateContentThrowsContentValidationExceptionFieldDefinition */ - public function testCreateContentThrowsContentValidationExceptionFieldDefinition($mainLanguageCode, $structFields) + #[DataProvider('providerForTestCreateContentThrowsContentValidationExceptionFieldDefinition')] + public function testCreateContentThrowsContentValidationExceptionFieldDefinition($mainLanguageCode, $structFields): void { $this->expectException(ContentValidationException::class); $this->expectExceptionMessage('Field definition \'identifier\' does not exist in the given content type'); @@ -2096,7 +2056,10 @@ public function testCreateContentThrowsContentValidationExceptionFieldDefinition ); } - public function providerForTestCreateContentThrowsContentValidationExceptionTranslation() + /** + * @return array + */ + public static function providerForTestCreateContentThrowsContentValidationExceptionTranslation(): array { return [ [ @@ -2116,14 +2079,9 @@ public function providerForTestCreateContentThrowsContentValidationExceptionTran /** * Test for the createContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent - * - * @dataProvider providerForTestCreateContentThrowsContentValidationExceptionTranslation */ - public function testCreateContentThrowsContentValidationExceptionTranslation($mainLanguageCode, $structFields) + #[DataProvider('providerForTestCreateContentThrowsContentValidationExceptionTranslation')] + public function testCreateContentThrowsContentValidationExceptionTranslation($mainLanguageCode, $structFields): void { $this->expectException(ContentValidationException::class); $this->expectExceptionMessage('You cannot set a value for the non-translatable Field definition \'identifier\' in language \'eng-US\''); @@ -2193,7 +2151,7 @@ private function loadByLanguageCodeMock(\PHPUnit\Framework\MockObject\MockObject { $languageHandlerMock->expects(self::any()) ->method('loadByLanguageCode') - ->with(self::isType('string')) + ->with(self::isString()) ->will( self::returnCallback( static function () { @@ -2275,7 +2233,10 @@ static function () use ($that, $contentCreateStruct): bool { return $contentCreateStruct; } - public function providerForTestCreateContentThrowsContentValidationExceptionRequiredField() + /** + * @return array + */ + public static function providerForTestCreateContentThrowsContentValidationExceptionRequiredField(): array { return [ [ @@ -2298,19 +2259,14 @@ public function providerForTestCreateContentThrowsContentValidationExceptionRequ /** * Test for the createContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent - * - * @dataProvider providerForTestCreateContentThrowsContentValidationExceptionRequiredField */ + #[DataProvider('providerForTestCreateContentThrowsContentValidationExceptionRequiredField')] public function testCreateContentRequiredField( $mainLanguageCode, $structFields, $identifier, $languageCode - ) { + ): void { $this->expectException(ContentFieldValidationException::class); $fieldDefinitions = [ @@ -2421,8 +2377,8 @@ static function () use ($that, $contentCreateStruct): bool { ->expects(self::any()) ->method('appendFieldRelations') ->with( - self::isType('array'), - self::isType('array'), + self::isArray(), + self::isArray(), self::isInstanceOf(SPIFieldType::class), self::isInstanceOf(Value::class), self::anything() @@ -2479,20 +2435,18 @@ static function (ValueStub $value) use ($emptyValue): bool { return [$contentCreateStruct, $allFieldErrors]; } - public function providerForTestCreateContentThrowsContentFieldValidationException() + /** + * @return array + */ + public static function providerForTestCreateContentThrowsContentFieldValidationException(): array { - return $this->providerForTestCreateContentNonRedundantFieldSetComplex(); + return self::providerForTestCreateContentNonRedundantFieldSetComplex(); } /** * Test for the createContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent - * - * @dataProvider providerForTestCreateContentThrowsContentFieldValidationException */ + #[DataProvider('providerForTestCreateContentThrowsContentFieldValidationException')] public function testCreateContentThrowsContentFieldValidationException($mainLanguageCode, $structFields): void { $this->expectException(ContentFieldValidationException::class); @@ -2516,7 +2470,7 @@ public function testCreateContentThrowsContentFieldValidationException($mainLang } } - private function acceptFieldTypeValueMock(\PHPUnit\Framework\MockObject\MockObject $fieldTypeMock): void + private function acceptFieldTypeValueMock(FieldType&MockObject $fieldTypeMock): void { $fieldTypeMock->expects(self::any()) ->method('acceptValue') @@ -2545,7 +2499,7 @@ private function getFieldTypeFieldTypeRegistryMock(\PHPUnit\Framework\MockObject ->will(self::returnValue($fieldTypeMock)); } - private function isEmptyValueFieldTypeMock(\PHPUnit\Framework\MockObject\MockObject $fieldTypeMock): void + private function isEmptyValueFieldTypeMock(FieldType&MockObject $fieldTypeMock): void { $emptyValue = new ValueStub(self::EMPTY_FIELD_VALUE); $fieldTypeMock->expects(self::any()) @@ -2580,13 +2534,8 @@ static function ($object) use ($that, $contentCreateStruct): string { /** * Test for the createContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::buildSPILocationCreateStructs - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent */ - public function testCreateContentWithLocations() + public function testCreateContentWithLocations(): void { $spiFields = [ new SPIField( @@ -2635,41 +2584,42 @@ public function testCreateContentWithLocations() $spiLocationCreateStruct = new SPILocation\CreateStruct(); $parentLocation = new Location(['contentInfo' => new ContentInfo(['sectionId' => 1])]); - $locationServiceMock->expects(self::at(0)) + $loadLocationMatcher = self::exactly(2); + $locationServiceMock->expects($loadLocationMatcher) ->method('loadLocation') - ->with(self::equalTo(321)) - ->will(self::returnValue($parentLocation)); + ->willReturnCallback(static function ($locationId) use ($loadLocationMatcher, $parentLocation): Location { + if ($loadLocationMatcher->numberOfInvocations() === 1) { + self::assertSame(321, $locationId); + } else { + self::assertSame(654, $locationId); + } - $locationServiceMock->expects(self::at(1)) - ->method('loadLocation') - ->with(self::equalTo(654)) - ->will(self::returnValue($parentLocation)); + return $parentLocation; + }); $repositoryMock->expects(self::atLeastOnce()) ->method('getLocationService') ->will(self::returnValue($locationServiceMock)); - $domainMapperMock->expects(self::at(1)) + $buildSPILocationCreateStructMatcher = self::exactly(2); + $domainMapperMock->expects($buildSPILocationCreateStructMatcher) ->method('buildSPILocationCreateStruct') - ->with( - self::equalTo($locationCreateStruct1), - self::equalTo($parentLocation), - self::equalTo(true), - self::equalTo(null), - self::equalTo(null), - self::equalTo(false) - )->will(self::returnValue($spiLocationCreateStruct)); + ->willReturnCallback(static function ($locationCreateStruct, $parentLocationArg, $mainLocation, $contentId, $contentVersionNo, bool $isContentHidden) use ($buildSPILocationCreateStructMatcher, $locationCreateStruct1, $locationCreateStruct2, $parentLocation, $spiLocationCreateStruct) { + self::assertSame($parentLocation, $parentLocationArg); + self::assertNull($contentId); + self::assertNull($contentVersionNo); + self::assertFalse($isContentHidden); + + if ($buildSPILocationCreateStructMatcher->numberOfInvocations() === 1) { + self::assertSame($locationCreateStruct1, $locationCreateStruct); + self::assertTrue($mainLocation); + } else { + self::assertSame($locationCreateStruct2, $locationCreateStruct); + self::assertFalse($mainLocation); + } - $domainMapperMock->expects(self::at(2)) - ->method('buildSPILocationCreateStruct') - ->with( - self::equalTo($locationCreateStruct2), - self::equalTo($parentLocation), - self::equalTo(false), - self::equalTo(null), - self::equalTo(null), - self::equalTo(false) - )->will(self::returnValue($spiLocationCreateStruct)); + return $spiLocationCreateStruct; + }); $spiContentCreateStruct = new SPIContentCreateStruct( [ @@ -2709,7 +2659,7 @@ public function testCreateContentWithLocations() self::isInstanceOf(SPIContent::class), self::isInstanceOf(APIContentType::class) ) - ->willReturn($this->createMock(APIContent::class)); + ->willReturn(self::createStub(APIContent::class)); $repositoryMock->expects(self::once())->method('commit'); @@ -2719,13 +2669,8 @@ public function testCreateContentWithLocations() /** * Test for the createContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::buildSPILocationCreateStructs - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent */ - public function testCreateContentWithLocationsDuplicateUnderParent() + public function testCreateContentWithLocationsDuplicateUnderParent(): void { $this->expectException(InvalidArgumentException::class); $this->expectExceptionMessage('You provided multiple LocationCreateStructs with the same parent Location \'321\''); @@ -2782,7 +2727,7 @@ public function testCreateContentWithLocationsDuplicateUnderParent() $languageHandlerMock->expects(self::any()) ->method('loadByLanguageCode') - ->with(self::isType('string')) + ->with(self::isString()) ->will( self::returnCallback( static function () { @@ -2888,13 +2833,8 @@ static function ($valueString) { /** * Test for the createContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getDefaultObjectStates - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent */ - public function testCreateContentObjectStates() + public function testCreateContentObjectStates(): void { $spiFields = [ new SPIField( @@ -2984,7 +2924,7 @@ public function testCreateContentObjectStates() self::isInstanceOf(SPIContent::class), self::isInstanceOf(APIContentType::class) ) - ->willReturn($this->createMock(APIContent::class)); + ->willReturn(self::createStub(APIContent::class)); $repositoryMock->expects(self::once())->method('commit'); @@ -2994,15 +2934,9 @@ public function testCreateContentObjectStates() /** * Test for the createContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForCreate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getDefaultObjectStates - * @covers \Ibexa\Contracts\Core\Repository\ContentService::createContent - * - * @dataProvider providerForTestCreateContentThrowsContentValidationExceptionTranslation */ - public function testCreateContentWithRollback() + #[DataProvider('providerForTestCreateContentThrowsContentValidationExceptionTranslation')] + public function testCreateContentWithRollback(): void { $this->expectException(\Exception::class); $this->expectExceptionMessage('Store failed'); @@ -3047,7 +2981,10 @@ public function testCreateContentWithRollback() $this->partlyMockedContentService->createContent($contentCreateStruct, []); } - public function providerForTestUpdateContentThrowsBadStateException() + /** + * @return array + */ + public static function providerForTestUpdateContentThrowsBadStateException(): array { return [ [VersionInfo::STATUS_PUBLISHED], @@ -3057,12 +2994,9 @@ public function providerForTestUpdateContentThrowsBadStateException() /** * Test for the updateContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent - * - * @dataProvider providerForTestUpdateContentThrowsBadStateException */ - public function testUpdateContentThrowsBadStateException($status) + #[DataProvider('providerForTestUpdateContentThrowsBadStateException')] + public function testUpdateContentThrowsBadStateException($status): void { $this->expectException(BadStateException::class); @@ -3109,10 +3043,8 @@ public function testUpdateContentThrowsBadStateException($status) /** * Test for the updateContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent */ - public function testUpdateContentThrowsUnauthorizedException() + public function testUpdateContentThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -3150,7 +3082,7 @@ public function testUpdateContentThrowsUnauthorizedException() self::equalTo('content'), self::equalTo('edit'), self::equalTo($content), - self::isType('array') + self::isArray() )->will(self::returnValue(false)); $mockedService->updateContent($versionInfo, $contentUpdateStruct); @@ -3363,7 +3295,7 @@ static function (Field $field) { $languageHandlerMock->expects(self::any()) ->method('loadByLanguageCode') - ->with(self::isType('string')) + ->with(self::isString()) ->will( self::returnCallback( static function () { @@ -3442,8 +3374,8 @@ static function (SPIValue $value) use ($emptyValue): bool { ->expects(self::exactly(count($fieldDefinitions) * count($languageCodes))) ->method('appendFieldRelations') ->with( - self::isType('array'), - self::isType('array'), + self::isArray(), + self::isArray(), self::isInstanceOf(SPIFieldType::class), self::isInstanceOf(Value::class), self::anything() @@ -3469,9 +3401,9 @@ static function (SPIValue $value) use ($emptyValue): bool { $relationProcessorMock->expects(self::any()) ->method('processFieldRelations') ->with( - self::isType('array'), + self::isArray(), self::equalTo(42), - self::isType('int'), + self::isInt(), self::equalTo($contentType), self::equalTo($existingRelations) ); @@ -3538,7 +3470,10 @@ static function (SPIValue $value) use ($emptyValue): bool { return [$content->versionInfo, $contentUpdateStruct]; } - public function providerForTestUpdateContentNonRedundantFieldSet1() + /** + * @return array + */ + public static function providerForTestUpdateContentNonRedundantFieldSet1(): array { $spiFields = [ new SPIField( @@ -3596,14 +3531,9 @@ public function providerForTestUpdateContentNonRedundantFieldSet1() * Test for the updateContent() method. * * Testing the simplest use case. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent - * - * @dataProvider providerForTestUpdateContentNonRedundantFieldSet1 */ - public function testUpdateContentNonRedundantFieldSet1($initialLanguageCode, $structFields, $spiFields) + #[DataProvider('providerForTestUpdateContentNonRedundantFieldSet1')] + public function testUpdateContentNonRedundantFieldSet1($initialLanguageCode, $structFields, $spiFields): void { $existingFields = [ new Field( @@ -3638,7 +3568,10 @@ public function testUpdateContentNonRedundantFieldSet1($initialLanguageCode, $st ); } - public function providerForTestUpdateContentNonRedundantFieldSet2() + /** + * @return array + */ + public static function providerForTestUpdateContentNonRedundantFieldSet2(): array { $spiFields0 = [ new SPIField( @@ -3813,14 +3746,9 @@ public function providerForTestUpdateContentNonRedundantFieldSet2() * Test for the updateContent() method. * * Testing with translatable field. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent - * - * @dataProvider providerForTestUpdateContentNonRedundantFieldSet2 */ - public function testUpdateContentNonRedundantFieldSet2($initialLanguageCode, $structFields, $spiFields) + #[DataProvider('providerForTestUpdateContentNonRedundantFieldSet2')] + public function testUpdateContentNonRedundantFieldSet2($initialLanguageCode, $structFields, $spiFields): void { $existingFields = [ new Field( @@ -3855,7 +3783,10 @@ public function testUpdateContentNonRedundantFieldSet2($initialLanguageCode, $st ); } - public function providerForTestUpdateContentNonRedundantFieldSet3() + /** + * @return array + */ + public static function providerForTestUpdateContentNonRedundantFieldSet3(): array { $spiFields0 = [ new SPIField( @@ -4081,14 +4012,9 @@ public function providerForTestUpdateContentNonRedundantFieldSet3() * Test for the updateContent() method. * * Testing with new language and untranslatable field. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent - * - * @dataProvider providerForTestUpdateContentNonRedundantFieldSet3 */ - public function testUpdateContentNonRedundantFieldSet3($initialLanguageCode, $structFields, $spiFields) + #[DataProvider('providerForTestUpdateContentNonRedundantFieldSet3')] + public function testUpdateContentNonRedundantFieldSet3($initialLanguageCode, $structFields, $spiFields): void { $existingFields = [ new Field( @@ -4141,7 +4067,10 @@ public function testUpdateContentNonRedundantFieldSet3($initialLanguageCode, $st ); } - public function providerForTestUpdateContentNonRedundantFieldSet4() + /** + * @return array + */ + public static function providerForTestUpdateContentNonRedundantFieldSet4(): array { $spiFields0 = [ new SPIField( @@ -4393,14 +4322,9 @@ public function providerForTestUpdateContentNonRedundantFieldSet4() * Test for the updateContent() method. * * Testing with empty values. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent - * - * @dataProvider providerForTestUpdateContentNonRedundantFieldSet4 */ - public function testUpdateContentNonRedundantFieldSet4($initialLanguageCode, $structFields, $spiFields) + #[DataProvider('providerForTestUpdateContentNonRedundantFieldSet4')] + public function testUpdateContentNonRedundantFieldSet4($initialLanguageCode, $structFields, $spiFields): void { $existingFields = [ new Field( @@ -4458,7 +4382,7 @@ public function testUpdateContentNonRedundantFieldSet4($initialLanguageCode, $st * * @todo add first field empty */ - public function providerForTestUpdateContentNonRedundantFieldSetComplex() + public static function providerForTestUpdateContentNonRedundantFieldSetComplex(): array { $spiFields0 = [ new SPIField( @@ -4780,14 +4704,9 @@ protected function fixturesForTestUpdateContentNonRedundantFieldSetComplex() * Test for the updateContent() method. * * Testing more complex cases. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent - * - * @dataProvider providerForTestUpdateContentNonRedundantFieldSetComplex */ - public function testUpdateContentNonRedundantFieldSetComplex($initialLanguageCode, $structFields, $spiFields) + #[DataProvider('providerForTestUpdateContentNonRedundantFieldSetComplex')] + public function testUpdateContentNonRedundantFieldSetComplex($initialLanguageCode, $structFields, $spiFields): void { list($existingFields, $fieldDefinitions) = $this->fixturesForTestUpdateContentNonRedundantFieldSetComplex(); @@ -4800,7 +4719,10 @@ public function testUpdateContentNonRedundantFieldSetComplex($initialLanguageCod ); } - public function providerForTestUpdateContentWithInvalidLanguage() + /** + * @return array + */ + public static function providerForTestUpdateContentWithInvalidLanguage(): array { return [ [ @@ -4809,7 +4731,12 @@ public function providerForTestUpdateContentWithInvalidLanguage() new Field( [ 'fieldDefIdentifier' => 'identifier', - 'value' => $this->createMock(Value::class), + 'value' => new class() extends Value { + public function __toString(): string + { + return ''; + } + }, 'languageCode' => 'Klingon', ] ), @@ -4821,7 +4748,12 @@ public function providerForTestUpdateContentWithInvalidLanguage() new Field( [ 'fieldDefIdentifier' => 'identifier', - 'value' => $this->createMock(Value::class), + 'value' => new class() extends Value { + public function __toString(): string + { + return ''; + } + }, 'languageCode' => 'eng-GB', ] ), @@ -4832,13 +4764,9 @@ public function providerForTestUpdateContentWithInvalidLanguage() /** * Test for the updateContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent - * - * @dataProvider providerForTestUpdateContentWithInvalidLanguage */ - public function testUpdateContentWithInvalidLanguage($initialLanguageCode, $structFields) + #[DataProvider('providerForTestUpdateContentWithInvalidLanguage')] + public function testUpdateContentWithInvalidLanguage($initialLanguageCode, $structFields): void { $this->expectException(APINotFoundException::class); $this->expectExceptionMessage('Could not find \'Language\' with identifier \'Klingon\''); @@ -4863,7 +4791,7 @@ public function testUpdateContentWithInvalidLanguage($initialLanguageCode, $stru ] ); - $fieldValueMock = $this->createMock(Value::class); + $fieldValueMock = self::createStub(Value::class); $content = new Content( [ @@ -4895,7 +4823,7 @@ public function testUpdateContentWithInvalidLanguage($initialLanguageCode, $stru $languageHandlerMock->expects(self::any()) ->method('loadByLanguageCode') - ->with(self::isType('string')) + ->with(self::isString()) ->will( self::returnCallback( static function ($languageCode) { @@ -4930,7 +4858,7 @@ static function ($languageCode) { self::equalTo('content'), self::equalTo('edit'), self::equalTo($content), - self::isType('array') + self::isArray() )->will(self::returnValue(true)); $contentUpdateStruct = new ContentUpdateStruct( @@ -4998,7 +4926,7 @@ static function ($value) { $languageHandlerMock->expects(self::any()) ->method('loadByLanguageCode') - ->with(self::isType('string')) + ->with(self::isString()) ->will( self::returnCallback( static function ($languageCode) { @@ -5033,7 +4961,7 @@ static function ($languageCode) { self::equalTo('content'), self::equalTo('edit'), self::equalTo($content), - self::isType('array') + self::isArray() )->will(self::returnValue(true)); /* @@ -5089,7 +5017,10 @@ private function prepareContentForTestCreateAndUpdateContent( ); } - public function providerForTestUpdateContentThrowsContentValidationExceptionFieldDefinition() + /** + * @return array + */ + public static function providerForTestUpdateContentThrowsContentValidationExceptionFieldDefinition(): array { return [ [ @@ -5109,14 +5040,9 @@ public function providerForTestUpdateContentThrowsContentValidationExceptionFiel /** * Test for the updateContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent - * - * @dataProvider providerForTestUpdateContentThrowsContentValidationExceptionFieldDefinition */ - public function testUpdateContentThrowsContentValidationExceptionFieldDefinition($initialLanguageCode, $structFields) + #[DataProvider('providerForTestUpdateContentThrowsContentValidationExceptionFieldDefinition')] + public function testUpdateContentThrowsContentValidationExceptionFieldDefinition($initialLanguageCode, $structFields): void { $this->expectException(ContentValidationException::class); $this->expectExceptionMessage('Field definition \'identifier\' does not exist in given content type'); @@ -5128,7 +5054,10 @@ public function testUpdateContentThrowsContentValidationExceptionFieldDefinition ); } - public function providerForTestUpdateContentThrowsContentValidationExceptionTranslation() + /** + * @return array + */ + public static function providerForTestUpdateContentThrowsContentValidationExceptionTranslation(): array { return [ [ @@ -5148,14 +5077,9 @@ public function providerForTestUpdateContentThrowsContentValidationExceptionTran /** * Test for the updateContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent - * - * @dataProvider providerForTestUpdateContentThrowsContentValidationExceptionTranslation */ - public function testUpdateContentThrowsContentValidationExceptionTranslation($initialLanguageCode, $structFields) + #[DataProvider('providerForTestUpdateContentThrowsContentValidationExceptionTranslation')] + public function testUpdateContentThrowsContentValidationExceptionTranslation($initialLanguageCode, $structFields): void { $this->expectException(ContentValidationException::class); $this->expectExceptionMessage('You cannot set a value for the non-translatable Field definition \'identifier\' in language \'eng-US\''); @@ -5228,7 +5152,7 @@ static function (Field $field) { self::equalTo('content'), self::equalTo('edit'), self::equalTo($content), - self::isType('array') + self::isArray() )->will(self::returnValue(true)); $this->acceptFieldTypeValueMock($fieldTypeMock); @@ -5256,7 +5180,10 @@ static function (Field $field) { return [$content->versionInfo, $contentUpdateStruct]; } - public function providerForTestUpdateContentRequiredField() + /** + * @return array + */ + public static function providerForTestUpdateContentRequiredField(): array { return [ [ @@ -5279,19 +5206,14 @@ public function providerForTestUpdateContentRequiredField() /** * Test for the updateContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent - * - * @dataProvider providerForTestUpdateContentRequiredField */ + #[DataProvider('providerForTestUpdateContentRequiredField')] public function testUpdateContentRequiredField( $initialLanguageCode, $structFields, $identifier, $languageCode - ) { + ): void { $this->expectException(ContentFieldValidationException::class); $existingFields = [ @@ -5436,7 +5358,7 @@ static function (FieldDefinition $fieldDefinition) use ($allFieldErrors, $struct return [$content->versionInfo, $contentUpdateStruct, $allFieldErrors]; } - public function providerForTestUpdateContentThrowsContentFieldValidationException(): array + public static function providerForTestUpdateContentThrowsContentFieldValidationException(): array { $newValue1engGBValidationError = new ValidationError('newValue1-eng-GB'); $newValue2ValidationError = new ValidationError('newValue2'); @@ -5493,7 +5415,7 @@ public function providerForTestUpdateContentThrowsContentFieldValidationExceptio ], ]; - $data = $this->providerForTestUpdateContentNonRedundantFieldSetComplex(); + $data = self::providerForTestUpdateContentNonRedundantFieldSetComplex(); $count = count($data); for ($i = 0; $i < $count; ++$i) { $data[$i][] = $allFieldErrors[$i]; @@ -5504,13 +5426,8 @@ public function providerForTestUpdateContentThrowsContentFieldValidationExceptio /** * Test for the updateContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent - * - * @dataProvider providerForTestUpdateContentThrowsContentFieldValidationException */ + #[DataProvider('providerForTestUpdateContentThrowsContentFieldValidationException')] public function testUpdateContentThrowsContentFieldValidationException( $initialLanguageCode, $structFields, @@ -5540,12 +5457,8 @@ public function testUpdateContentThrowsContentFieldValidationException( /** * Test for the updateContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getLanguageCodesForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::mapFieldsForUpdate - * @covers \Ibexa\Contracts\Core\Repository\ContentService::updateContent */ - public function testUpdateContentTransactionRollback() + public function testUpdateContentTransactionRollback(): void { $this->expectException(\Exception::class); $this->expectExceptionMessage('Store failed'); @@ -5605,10 +5518,8 @@ public function testUpdateContentTransactionRollback() /** * Test for the copyContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::copyContent */ - public function testCopyContentThrowsUnauthorizedException() + public function testCopyContentThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -5654,12 +5565,8 @@ public function testCopyContentThrowsUnauthorizedException() /** * Test for the copyContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::copyContent - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getDefaultObjectStates - * @covers \Ibexa\Contracts\Core\Repository\ContentService::internalPublishVersion */ - public function testCopyContent() + public function testCopyContent(): void { $repositoryMock = $this->getRepositoryMock(); $contentService = $this->getPartlyMockedContentService([ @@ -5732,13 +5639,26 @@ public function testCopyContent() $repositoryMock->expects(self::once())->method('commit'); $destinationLocationTarget = (new DestinationLocation($locationCreateStruct->parentLocationId, $contentInfoMock)); - $permissionResolverMock - ->method('canUser') - ->withConsecutive( - ['content', 'create', $contentInfoMock, [$location, $destinationLocationTarget]], - ['content', 'manage_locations', $contentInfoMock, [$location]], - ) - ->willReturnOnConsecutiveCalls(true, true); + $matcher = $this->exactly(2); + $permissionResolverMock->expects($matcher) + ->method('canUser')->willReturnCallback(function (...$parameters) use ($matcher, $contentInfoMock, $location, $destinationLocationTarget) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame('content', $parameters[0]); + $this->assertSame('create', $parameters[1]); + $this->assertSame($contentInfoMock, $parameters[2]); + $this->assertEquals([$location, $destinationLocationTarget], $parameters[3]); + + return true; + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame('content', $parameters[0]); + $this->assertSame('manage_locations', $parameters[1]); + $this->assertSame($contentInfoMock, $parameters[2]); + $this->assertSame([$location], $parameters[3]); + + return true; + } + }); $spiContentInfo = new SPIContentInfo(['id' => 42]); $spiVersionInfo = new SPIVersionInfo( @@ -5791,12 +5711,8 @@ public function testCopyContent() /** * Test for the copyContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::copyContent - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getDefaultObjectStates - * @covers \Ibexa\Contracts\Core\Repository\ContentService::internalPublishVersion */ - public function testCopyContentWithVersionInfo() + public function testCopyContentWithVersionInfo(): void { $repositoryMock = $this->getRepositoryMock(); $contentService = $this->getPartlyMockedContentService([ @@ -5864,13 +5780,26 @@ public function testCopyContentWithVersionInfo() $repositoryMock->expects(self::once())->method('commit'); $destinationLocationTarget = (new DestinationLocation($locationCreateStruct->parentLocationId, $contentInfoMock)); - $permissionResolverMock - ->method('canUser') - ->withConsecutive( - ['content', 'create', $contentInfoMock, [$location, $destinationLocationTarget]], - ['content', 'manage_locations', $contentInfoMock, [$location]], - ) - ->willReturnOnConsecutiveCalls(true, true); + $matcher = $this->exactly(2); + $permissionResolverMock->expects($matcher) + ->method('canUser')->willReturnCallback(function (...$parameters) use ($matcher, $contentInfoMock, $location, $destinationLocationTarget) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame('content', $parameters[0]); + $this->assertSame('create', $parameters[1]); + $this->assertSame($contentInfoMock, $parameters[2]); + $this->assertEquals([$location, $destinationLocationTarget], $parameters[3]); + + return true; + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame('content', $parameters[0]); + $this->assertSame('manage_locations', $parameters[1]); + $this->assertSame($contentInfoMock, $parameters[2]); + $this->assertSame([$location], $parameters[3]); + + return true; + } + }); $spiContentInfo = new SPIContentInfo(['id' => 42]); $spiVersionInfo = new SPIVersionInfo( @@ -5919,12 +5848,8 @@ public function testCopyContentWithVersionInfo() /** * Test for the copyContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\ContentService::copyContent - * @covers \Ibexa\Contracts\Core\Repository\ContentService::getDefaultObjectStates - * @covers \Ibexa\Contracts\Core\Repository\ContentService::internalPublishVersion */ - public function testCopyContentWithRollback() + public function testCopyContentWithRollback(): void { $this->expectException(\Exception::class); $this->expectExceptionMessage('Handler threw an exception'); @@ -5970,13 +5895,26 @@ public function testCopyContentWithRollback() $repositoryMock->expects(self::once())->method('rollback'); $destinationLocationTarget = (new DestinationLocation($locationCreateStruct->parentLocationId, $contentInfoMock)); - $permissionResolverMock - ->method('canUser') - ->withConsecutive( - ['content', 'create', $contentInfoMock, [$location, $destinationLocationTarget]], - ['content', 'manage_locations', $contentInfoMock, [$location]], - ) - ->willReturnOnConsecutiveCalls(true, true); + $matcher = $this->exactly(2); + $permissionResolverMock->expects($matcher) + ->method('canUser')->willReturnCallback(function (...$parameters) use ($matcher, $contentInfoMock, $location, $destinationLocationTarget) { + if ($matcher->numberOfInvocations() === 1) { + $this->assertSame('content', $parameters[0]); + $this->assertSame('create', $parameters[1]); + $this->assertSame($contentInfoMock, $parameters[2]); + $this->assertEquals([$location, $destinationLocationTarget], $parameters[3]); + + return true; + } + if ($matcher->numberOfInvocations() === 2) { + $this->assertSame('content', $parameters[0]); + $this->assertSame('manage_locations', $parameters[1]); + $this->assertSame($contentInfoMock, $parameters[2]); + $this->assertSame([$location], $parameters[3]); + + return true; + } + }); $contentHandlerMock->expects(self::once()) ->method('copy') @@ -6046,29 +5984,26 @@ protected function mockGetDefaultObjectStates() ->method('loadAllGroups') ->will(self::returnValue($objectStateGroups)); - $objectStateHandlerMock->expects(self::at(1)) + $loadObjectStatesMatcher = self::exactly(2); + $objectStateHandlerMock->expects($loadObjectStatesMatcher) ->method('loadObjectStates') - ->with(self::equalTo(10)) - ->will( - self::returnValue( - [ + ->willReturnCallback(static function ($groupId) use ($loadObjectStatesMatcher): array { + if ($loadObjectStatesMatcher->numberOfInvocations() === 1) { + self::assertSame(10, $groupId); + + return [ new SPIObjectState(['id' => 11, 'groupId' => 10]), new SPIObjectState(['id' => 12, 'groupId' => 10]), - ] - ) - ); + ]; + } - $objectStateHandlerMock->expects(self::at(2)) - ->method('loadObjectStates') - ->with(self::equalTo(20)) - ->will( - self::returnValue( - [ - new SPIObjectState(['id' => 21, 'groupId' => 20]), - new SPIObjectState(['id' => 22, 'groupId' => 20]), - ] - ) - ); + self::assertSame(20, $groupId); + + return [ + new SPIObjectState(['id' => 21, 'groupId' => 20]), + new SPIObjectState(['id' => 22, 'groupId' => 20]), + ]; + }); } protected function mockSetDefaultObjectStates() @@ -6080,15 +6015,17 @@ protected function mockSetDefaultObjectStates() new SPIObjectState(['id' => 11, 'groupId' => 10]), new SPIObjectState(['id' => 21, 'groupId' => 20]), ]; - foreach ($defaultObjectStates as $index => $objectState) { - $objectStateHandlerMock->expects(self::at($index + 3)) - ->method('setContentState') - ->with( - 42, - $objectState->groupId, - $objectState->id - ); - } + $setContentStateMatcher = self::exactly(count($defaultObjectStates)); + $objectStateHandlerMock->expects($setContentStateMatcher) + ->method('setContentState') + ->willReturnCallback(static function ($contentId, $groupId, $stateId) use ($setContentStateMatcher, $defaultObjectStates): bool { + $objectState = $defaultObjectStates[$setContentStateMatcher->numberOfInvocations() - 1]; + self::assertSame(42, $contentId); + self::assertSame($objectState->groupId, $groupId); + self::assertSame($objectState->id, $stateId); + + return true; + }); } /** @@ -6187,14 +6124,21 @@ protected function mockPublishUrlAliasesForContent(APIContent $content) $locationServiceMock = $this->getLocationServiceMock(); $location = $this->createMock(APILocation::class); - $location->expects(self::at(0)) - ->method('__get') - ->with('id') - ->will(self::returnValue(123)); - $location->expects(self::at(1)) + $locationGetMatcher = self::exactly(4); + $location->expects($locationGetMatcher) ->method('__get') - ->with('parentLocationId') - ->will(self::returnValue(456)); + ->willReturnCallback(static function ($property) use ($locationGetMatcher) { + $invocation = $locationGetMatcher->numberOfInvocations(); + if ($invocation === 1 || $invocation === 3) { + self::assertSame('id', $property); + + return 123; + } + + self::assertSame('parentLocationId', $property); + + return 456; + }); $urlAliasNames = ['eng-GB' => 'hello']; $nameSchemaServiceMock->expects(self::once()) @@ -6211,16 +6155,6 @@ protected function mockPublishUrlAliasesForContent(APIContent $content) ->method('publishUrlAliasForLocation') ->with(123, 456, 'hello', 'eng-GB', true, true); - $location->expects(self::at(2)) - ->method('__get') - ->with('id') - ->will(self::returnValue(123)); - - $location->expects(self::at(3)) - ->method('__get') - ->with('parentLocationId') - ->will(self::returnValue(456)); - $urlAliasHandlerMock->expects(self::once()) ->method('archiveUrlAliasesForDeletedTranslations') ->with(123, 456, ['eng-GB']); @@ -6302,8 +6236,7 @@ protected function getLocationServiceMock() protected function getPartlyMockedContentService(?array $methods = null, int $gracePeriodInSeconds = 0) { if (!isset($this->partlyMockedContentService)) { - $this->partlyMockedContentService = $this->getMockBuilder(ContentService::class) - ->setMethods($methods) + $builder = $this->getMockBuilder(ContentService::class) ->setConstructorArgs( [ $this->getRepositoryMock(), @@ -6317,13 +6250,29 @@ protected function getPartlyMockedContentService(?array $methods = null, int $gr $this->getContentValidatorStrategy(), $this->getContentFilteringHandlerMock(), new ContentCollector(), - $this->createMock(ValidatorInterface::class), + self::createStub(ValidatorInterface::class), [ 'grace_period_in_seconds' => $gracePeriodInSeconds, ], ] - ) - ->getMock(); + ); + + $methods ??= []; + if ($methods !== []) { + $reflection = new \ReflectionClass(ContentService::class); + $existingMethods = array_values(array_filter($methods, static fn (string $method): bool => $reflection->hasMethod($method))); + $nonExistingMethods = array_values(array_diff($methods, $existingMethods)); + if ($existingMethods !== []) { + $builder->onlyMethods($existingMethods); + } + if ($nonExistingMethods !== []) { + $builder->addMethods($nonExistingMethods); + } + } else { + $builder->onlyMethods([]); + } + + $this->partlyMockedContentService = $builder->getMock(); } return $this->partlyMockedContentService; diff --git a/tests/lib/Repository/Service/Mock/PermissionTest.php b/tests/lib/Repository/Service/Mock/PermissionTest.php index 268d378e1a..047d31a60b 100644 --- a/tests/lib/Repository/Service/Mock/PermissionTest.php +++ b/tests/lib/Repository/Service/Mock/PermissionTest.php @@ -21,6 +21,7 @@ use Ibexa\Core\Repository\Repository as CoreRepository; use Ibexa\Core\Repository\Values\User\UserReference; use Ibexa\Tests\Core\Repository\Service\Mock\Base as BaseServiceMockTest; +use PHPUnit\Framework\Attributes\DataProvider; /** * Mock test case for PermissionResolver. @@ -29,19 +30,22 @@ */ class PermissionTest extends BaseServiceMockTest { - public function providerForTestHasAccessReturnsTrue() + /** + * @return array + */ + public static function providerForTestHasAccessReturnsTrue(): array { return [ [ [ - 25 => $this->createRole( + 25 => self::createRole( [ ['dummy-module', 'dummy-function', 'dummy-limitation'], ['dummy-module2', 'dummy-function2', 'dummy-limitation2'], ], 25 ), - 26 => $this->createRole( + 26 => self::createRole( [ ['*', 'dummy-function', 'dummy-limitation'], ], @@ -63,7 +67,7 @@ public function providerForTestHasAccessReturnsTrue() ], [ [ - 27 => $this->createRole( + 27 => self::createRole( [ ['dummy-module', '*', 'dummy-limitation'], ], @@ -80,7 +84,7 @@ public function providerForTestHasAccessReturnsTrue() ], [ [ - 28 => $this->createRole( + 28 => self::createRole( [ ['dummy-module', 'dummy-function', '*'], ], @@ -100,10 +104,9 @@ public function providerForTestHasAccessReturnsTrue() /** * Test for the hasAccess() method. - * - * @dataProvider providerForTestHasAccessReturnsTrue */ - public function testHasAccessReturnsTrue(array $roles, array $roleAssignments) + #[DataProvider('providerForTestHasAccessReturnsTrue')] + public function testHasAccessReturnsTrue(array $roles, array $roleAssignments): void { /** @var $userHandlerMock \PHPUnit\Framework\MockObject\MockObject */ $userHandlerMock = $this->getPersistenceMock()->userHandler(); @@ -115,26 +118,23 @@ public function testHasAccessReturnsTrue(array $roles, array $roleAssignments) ->with(self::equalTo(10), self::equalTo(true)) ->will(self::returnValue($roleAssignments)); - foreach ($roleAssignments as $at => $roleAssignment) { - $userHandlerMock - ->expects(self::at($at + 1)) - ->method('loadRole') - ->with($roleAssignment->roleId) - ->will(self::returnValue($roles[$roleAssignment->roleId])); - } + $this->mockLoadRoleSequence($userHandlerMock, $roleAssignments, $roles); $result = $mockedService->hasAccess('dummy-module', 'dummy-function'); self::assertTrue($result); } - public function providerForTestHasAccessReturnsFalse() + /** + * @return array + */ + public static function providerForTestHasAccessReturnsFalse(): array { return [ [[], []], [ [ - 29 => $this->createRole( + 29 => self::createRole( [ ['dummy-module', 'dummy-function', 'dummy-limitation'], ], @@ -151,7 +151,7 @@ public function providerForTestHasAccessReturnsFalse() ], [ [ - 30 => $this->createRole( + 30 => self::createRole( [ ['dummy-module', '*', 'dummy-limitation'], ], @@ -171,10 +171,9 @@ public function providerForTestHasAccessReturnsFalse() /** * Test for the hasAccess() method. - * - * @dataProvider providerForTestHasAccessReturnsFalse */ - public function testHasAccessReturnsFalse(array $roles, array $roleAssignments) + #[DataProvider('providerForTestHasAccessReturnsFalse')] + public function testHasAccessReturnsFalse(array $roles, array $roleAssignments): void { /** @var $userHandlerMock \PHPUnit\Framework\MockObject\MockObject */ $userHandlerMock = $this->getPersistenceMock()->userHandler(); @@ -186,13 +185,7 @@ public function testHasAccessReturnsFalse(array $roles, array $roleAssignments) ->with(self::equalTo(10), self::equalTo(true)) ->will(self::returnValue($roleAssignments)); - foreach ($roleAssignments as $at => $roleAssignment) { - $userHandlerMock - ->expects(self::at($at + 1)) - ->method('loadRole') - ->with($roleAssignment->roleId) - ->will(self::returnValue($roles[$roleAssignment->roleId])); - } + $this->mockLoadRoleSequence($userHandlerMock, $roleAssignments, $roles); $result = $service->hasAccess('dummy-module2', 'dummy-function2'); @@ -202,7 +195,7 @@ public function testHasAccessReturnsFalse(array $roles, array $roleAssignments) /** * Test for the sudo() & hasAccess() method. */ - public function testHasAccessReturnsFalseButSudoSoTrue() + public function testHasAccessReturnsFalseButSudoSoTrue(): void { /** @var $userHandlerMock \PHPUnit\Framework\MockObject\MockObject */ $userHandlerMock = $this->getPersistenceMock()->userHandler(); @@ -230,12 +223,12 @@ static function (Repository $repo) { /** * @return array */ - public function providerForTestHasAccessReturnsPermissionSets() + public static function providerForTestHasAccessReturnsPermissionSets(): array { return [ [ [ - 31 => $this->createRole( + 31 => self::createRole( [ ['dummy-module', 'dummy-function', 'test-limitation'], ], @@ -252,13 +245,13 @@ public function providerForTestHasAccessReturnsPermissionSets() ], [ [ - 31 => $this->createRole( + 31 => self::createRole( [ ['dummy-module', 'dummy-function', 'test-limitation'], ], 31 ), - 32 => $this->createRole( + 32 => self::createRole( [ ['dummy-module', 'dummy-function', 'test-limitation2'], ], @@ -283,10 +276,9 @@ public function providerForTestHasAccessReturnsPermissionSets() /** * Test for the hasAccess() method. - * - * @dataProvider providerForTestHasAccessReturnsPermissionSets */ - public function testHasAccessReturnsPermissionSets(array $roles, array $roleAssignments) + #[DataProvider('providerForTestHasAccessReturnsPermissionSets')] + public function testHasAccessReturnsPermissionSets(array $roles, array $roleAssignments): void { /** @var $userHandlerMock \PHPUnit\Framework\MockObject\MockObject */ $userHandlerMock = $this->getPersistenceMock()->userHandler(); @@ -301,32 +293,21 @@ public function testHasAccessReturnsPermissionSets(array $roles, array $roleAssi $userHandlerMock ->expects(self::once()) ->method('loadRoleAssignmentsByGroupId') - ->with(self::isType('integer'), self::equalTo(true)) + ->with(self::isInt(), self::equalTo(true)) ->will(self::returnValue($roleAssignments)); - foreach ($roleAssignments as $at => $roleAssignment) { - $userHandlerMock - ->expects(self::at($at + 1)) - ->method('loadRole') - ->with($roleAssignment->roleId) - ->will(self::returnValue($roles[$roleAssignment->roleId])); - } + $this->mockLoadRoleSequence($userHandlerMock, $roleAssignments, $roles); $permissionSets = []; - $count = 0; + $expectedBuildDomainPolicyObjectCalls = []; /* @var $roleAssignments \Ibexa\Contracts\Core\Persistence\User\RoleAssignment[] */ foreach ($roleAssignments as $i => $roleAssignment) { $permissionSet = ['limitation' => null]; foreach ($roles[$roleAssignment->roleId]->policies as $k => $policy) { $policyName = 'policy-' . $i . '-' . $k; - $return = self::returnValue($policyName); $permissionSet['policies'][] = $policyName; - $roleDomainMapper - ->expects(self::at($count++)) - ->method('buildDomainPolicyObject') - ->with($policy) - ->will($return); + $expectedBuildDomainPolicyObjectCalls[] = [$policy, $policyName]; } if (!empty($permissionSet['policies'])) { @@ -334,6 +315,19 @@ public function testHasAccessReturnsPermissionSets(array $roles, array $roleAssi } } + if ($expectedBuildDomainPolicyObjectCalls !== []) { + $buildDomainPolicyObjectMatcher = self::exactly(count($expectedBuildDomainPolicyObjectCalls)); + $roleDomainMapper + ->expects($buildDomainPolicyObjectMatcher) + ->method('buildDomainPolicyObject') + ->willReturnCallback(static function ($policy) use ($buildDomainPolicyObjectMatcher, $expectedBuildDomainPolicyObjectCalls) { + [$expectedPolicy, $policyName] = $expectedBuildDomainPolicyObjectCalls[$buildDomainPolicyObjectMatcher->numberOfInvocations() - 1]; + self::assertSame($expectedPolicy, $policy); + + return $policyName; + }); + } + /* @var $repositoryMock \Ibexa\Core\Repository\Repository */ self::assertEquals( $permissionSets, @@ -344,12 +338,12 @@ public function testHasAccessReturnsPermissionSets(array $roles, array $roleAssi /** * @return array */ - public function providerForTestHasAccessReturnsLimitationNotFoundException() + public static function providerForTestHasAccessReturnsLimitationNotFoundException(): array { return [ [ [ - 31 => $this->createRole( + 31 => self::createRole( [ ['dummy-module', 'dummy-function', 'notfound'], ], @@ -366,13 +360,13 @@ public function providerForTestHasAccessReturnsLimitationNotFoundException() ], [ [ - 31 => $this->createRole( + 31 => self::createRole( [ ['dummy-module', 'dummy-function', 'test-limitation'], ], 31 ), - 32 => $this->createRole( + 32 => self::createRole( [ ['dummy-module', 'dummy-function', 'notfound'], ], @@ -397,10 +391,9 @@ public function providerForTestHasAccessReturnsLimitationNotFoundException() /** * Test for the hasAccess() method. - * - * @dataProvider providerForTestHasAccessReturnsLimitationNotFoundException */ - public function testHasAccessReturnsLimitationNotFoundException(array $roles, array $roleAssignments) + #[DataProvider('providerForTestHasAccessReturnsLimitationNotFoundException')] + public function testHasAccessReturnsLimitationNotFoundException(array $roles, array $roleAssignments): void { $this->expectException(LimitationNotFoundException::class); @@ -417,54 +410,57 @@ public function testHasAccessReturnsLimitationNotFoundException(array $roles, ar $userHandlerMock ->expects(self::once()) ->method('loadRoleAssignmentsByGroupId') - ->with(self::isType('integer'), self::equalTo(true)) + ->with(self::isInt(), self::equalTo(true)) ->will(self::returnValue($roleAssignments)); - foreach ($roleAssignments as $at => $roleAssignment) { - $userHandlerMock - ->expects(self::at($at + 1)) - ->method('loadRole') - ->with($roleAssignment->roleId) - ->will(self::returnValue($roles[$roleAssignment->roleId])); - } + $this->mockLoadRoleSequence($userHandlerMock, $roleAssignments, $roles); - $count = 0; + $expectedBuildDomainPolicyObjectCalls = []; /* @var $roleAssignments \Ibexa\Contracts\Core\Persistence\User\RoleAssignment[] */ foreach ($roleAssignments as $i => $roleAssignment) { $permissionSet = ['limitation' => null]; foreach ($roles[$roleAssignment->roleId]->policies as $k => $policy) { $policyName = 'policy-' . $i . '-' . $k; if ($policy->limitations === 'notfound') { - $return = self::throwException(new LimitationNotFoundException('notfound')); + $expectedBuildDomainPolicyObjectCalls[] = [$policy, null]; } else { - $return = self::returnValue($policyName); $permissionSet['policies'][] = $policyName; + $expectedBuildDomainPolicyObjectCalls[] = [$policy, $policyName]; } - $roleDomainMapper - ->expects(self::at($count++)) - ->method('buildDomainPolicyObject') - ->with($policy) - ->will($return); - if ($policy->limitations === 'notfound') { break 2; // no more execution after exception } } } + $buildDomainPolicyObjectMatcher = self::exactly(count($expectedBuildDomainPolicyObjectCalls)); + $roleDomainMapper + ->expects($buildDomainPolicyObjectMatcher) + ->method('buildDomainPolicyObject') + ->willReturnCallback(static function ($policy) use ($buildDomainPolicyObjectMatcher, $expectedBuildDomainPolicyObjectCalls) { + [$expectedPolicy, $policyName] = $expectedBuildDomainPolicyObjectCalls[$buildDomainPolicyObjectMatcher->numberOfInvocations() - 1]; + self::assertSame($expectedPolicy, $policy); + + if ($policyName === null) { + throw new LimitationNotFoundException('notfound'); + } + + return $policyName; + }); + $permissionResolverMock->hasAccess('dummy-module', 'dummy-function'); } /** * @return array */ - public function providerForTestHasAccessReturnsInvalidArgumentValueException() + public static function providerForTestHasAccessReturnsInvalidArgumentValueException(): array { return [ [ [ - 31 => $this->createRole( + 31 => self::createRole( [ ['test-module', 'test-function', '*'], ], @@ -481,13 +477,13 @@ public function providerForTestHasAccessReturnsInvalidArgumentValueException() ], [ [ - 31 => $this->createRole( + 31 => self::createRole( [ ['other-module', 'test-function', '*'], ], 31 ), - 32 => $this->createRole( + 32 => self::createRole( [ ['test-module', 'other-function', '*'], ], @@ -512,10 +508,9 @@ public function providerForTestHasAccessReturnsInvalidArgumentValueException() /** * Test for the hasAccess() method. - * - * @dataProvider providerForTestHasAccessReturnsInvalidArgumentValueException */ - public function testHasAccessReturnsInvalidArgumentValueException(array $roles, array $roleAssignments) + #[DataProvider('providerForTestHasAccessReturnsInvalidArgumentValueException')] + public function testHasAccessReturnsInvalidArgumentValueException(array $roles, array $roleAssignments): void { $this->expectException(InvalidArgumentValue::class); @@ -530,12 +525,15 @@ public function testHasAccessReturnsInvalidArgumentValueException(array $roles, } } - public function providerForTestHasAccessReturnsPermissionSetsWithRoleLimitation() + /** + * @return array + */ + public static function providerForTestHasAccessReturnsPermissionSetsWithRoleLimitation(): array { return [ [ [ - 32 => $this->createRole( + 32 => self::createRole( [ [ 'dummy-module', 'dummy-function', [ @@ -560,7 +558,7 @@ public function providerForTestHasAccessReturnsPermissionSetsWithRoleLimitation( ], [ [ - 33 => $this->createRole([['*', '*', '*']], 33), + 33 => self::createRole([['*', '*', '*']], 33), ], [ new RoleAssignment( @@ -577,10 +575,9 @@ public function providerForTestHasAccessReturnsPermissionSetsWithRoleLimitation( /** * Test for the hasAccess() method. - * - * @dataProvider providerForTestHasAccessReturnsPermissionSetsWithRoleLimitation */ - public function testHasAccessReturnsPermissionSetsWithRoleLimitation(array $roles, array $roleAssignments) + #[DataProvider('providerForTestHasAccessReturnsPermissionSetsWithRoleLimitation')] + public function testHasAccessReturnsPermissionSetsWithRoleLimitation(array $roles, array $roleAssignments): void { /** @var $userHandlerMock \PHPUnit\Framework\MockObject\MockObject */ $userHandlerMock = $this->getPersistenceMock()->userHandler(); @@ -597,40 +594,28 @@ public function testHasAccessReturnsPermissionSetsWithRoleLimitation(array $role $userHandlerMock ->expects(self::once()) ->method('loadRoleAssignmentsByGroupId') - ->with(self::isType('integer'), self::equalTo(true)) + ->with(self::isInt(), self::equalTo(true)) ->will(self::returnValue($roleAssignments)); - foreach ($roleAssignments as $at => $roleAssignment) { - $userHandlerMock - ->expects(self::at($at + 1)) - ->method('loadRole') - ->with($roleAssignment->roleId) - ->will(self::returnValue($roles[$roleAssignment->roleId])); - } + $this->mockLoadRoleSequence($userHandlerMock, $roleAssignments, $roles); $permissionSets = []; + $expectedBuildDomainPolicyObjectCalls = []; + $expectedBuildValueCalls = []; /** @var $roleAssignments \Ibexa\Contracts\Core\Persistence\User\RoleAssignment[] */ foreach ($roleAssignments as $i => $roleAssignment) { $permissionSet = []; foreach ($roles[$roleAssignment->roleId]->policies as $k => $policy) { $policyName = "policy-{$i}-{$k}"; $permissionSet['policies'][] = $policyName; - $roleDomainMapper - ->expects(self::at($k)) - ->method('buildDomainPolicyObject') - ->with($policy) - ->will(self::returnValue($policyName)); + $expectedBuildDomainPolicyObjectCalls[] = [$policy, $policyName]; } $limitation = $this->createMock(Limitation::class); $limitation->method('getIdentifier')->willReturn("limitation-{$i}"); $permissionSet['limitation'] = $limitation; - $limitationTypeMock - ->expects(self::at($i)) - ->method('buildValue') - ->with($roleAssignment->values) - ->will(self::returnValue($permissionSet['limitation'])); + $expectedBuildValueCalls[] = [$roleAssignment->values, $permissionSet['limitation']]; $limitationService ->expects(self::any()) ->method('getLimitationType') @@ -640,12 +625,67 @@ public function testHasAccessReturnsPermissionSetsWithRoleLimitation(array $role $permissionSets[] = $permissionSet; } + if ($expectedBuildDomainPolicyObjectCalls !== []) { + $buildDomainPolicyObjectMatcher = self::exactly(count($expectedBuildDomainPolicyObjectCalls)); + $roleDomainMapper + ->expects($buildDomainPolicyObjectMatcher) + ->method('buildDomainPolicyObject') + ->willReturnCallback(static function ($policy) use ($buildDomainPolicyObjectMatcher, $expectedBuildDomainPolicyObjectCalls) { + [$expectedPolicy, $policyName] = $expectedBuildDomainPolicyObjectCalls[$buildDomainPolicyObjectMatcher->numberOfInvocations() - 1]; + self::assertSame($expectedPolicy, $policy); + + return $policyName; + }); + } + + if ($expectedBuildValueCalls !== []) { + $buildValueMatcher = self::exactly(count($expectedBuildValueCalls)); + $limitationTypeMock + ->expects($buildValueMatcher) + ->method('buildValue') + ->willReturnCallback(static function ($values) use ($buildValueMatcher, $expectedBuildValueCalls) { + [$expectedValues, $limitation] = $expectedBuildValueCalls[$buildValueMatcher->numberOfInvocations() - 1]; + self::assertSame($expectedValues, $values); + + return $limitation; + }); + } + self::assertEquals( $permissionSets, $permissionResolverMock->hasAccess('dummy-module', 'dummy-function') ); } + /** + * Sets up the expectation that $userHandlerMock->loadRole() is called once per + * $roleAssignment, in order, each returning the matching entry from $roles. + * + * @param \PHPUnit\Framework\MockObject\MockObject $userHandlerMock + * @param \Ibexa\Contracts\Core\Persistence\User\RoleAssignment[] $roleAssignments + * @param \Ibexa\Contracts\Core\Persistence\User\Role[] $roles + */ + private function mockLoadRoleSequence($userHandlerMock, array $roleAssignments, array $roles): void + { + if ($roleAssignments === []) { + $userHandlerMock->expects(self::never())->method('loadRole'); + + return; + } + + $roleAssignmentList = array_values($roleAssignments); + $matcher = self::exactly(count($roleAssignmentList)); + $userHandlerMock + ->expects($matcher) + ->method('loadRole') + ->willReturnCallback(static function ($roleId, $status = Role::STATUS_DEFINED) use ($matcher, $roleAssignmentList, $roles) { + $roleAssignment = $roleAssignmentList[$matcher->numberOfInvocations() - 1]; + self::assertSame($roleAssignment->roleId, $roleId); + + return $roles[$roleAssignment->roleId]; + }); + } + /** * Returns Role stub. * @@ -654,7 +694,7 @@ public function testHasAccessReturnsPermissionSetsWithRoleLimitation(array $role * * @return \Ibexa\Contracts\Core\Persistence\User\Role */ - private function createRole(array $policiesData, $roleId = null) + private static function createRole(array $policiesData, $roleId = null) { $policies = []; foreach ($policiesData as $policyData) { @@ -675,7 +715,10 @@ private function createRole(array $policiesData, $roleId = null) ); } - public function providerForTestCanUserSimple() + /** + * @return array + */ + public static function providerForTestCanUserSimple(): array { return [ [true, true], @@ -688,10 +731,9 @@ public function providerForTestCanUserSimple() * Test for the canUser() method. * * Tests execution paths with permission sets equaling to boolean value or empty array. - * - * @dataProvider providerForTestCanUserSimple */ - public function testCanUserSimple($permissionSets, $result) + #[DataProvider('providerForTestCanUserSimple')] + public function testCanUserSimple($permissionSets, $result): void { $permissionResolverMock = $this->getPermissionResolverMock(['hasAccess']); @@ -715,7 +757,7 @@ public function testCanUserSimple($permissionSets, $result) * * Tests execution path with permission set defining no limitations. */ - public function testCanUserWithoutLimitations() + public function testCanUserWithoutLimitations(): void { $permissionResolverMock = $this->getPermissionResolverMock( [ @@ -725,9 +767,9 @@ public function testCanUserWithoutLimitations() ); $policyMock = $this->getMockBuilder(Policy::class) - ->setMethods(['getLimitations']) ->setConstructorArgs([]) ->disableOriginalConstructor() + ->addMethods(['getLimitations']) ->getMock(); $policyMock @@ -782,8 +824,8 @@ private function getPermissionSetsMock() ->will(self::returnValue('test-policy-limitation-identifier')); $policyMock = $this->getMockBuilder(Policy::class) - ->setMethods(['getLimitations']) ->setConstructorArgs([]) + ->addMethods(['getLimitations']) ->getMock(); $policyMock @@ -806,7 +848,7 @@ private function getPermissionSetsMock() * * @return array */ - public function providerForTestCanUserComplex() + public static function providerForTestCanUserComplex(): array { return [ [ @@ -886,13 +928,12 @@ public function providerForTestCanUserComplex() * Test for the canUser() method. * * Tests execution paths with permission sets containing limitations. - * - * @dataProvider providerForTestCanUserComplex */ - public function testCanUserComplex(array $roleLimitationEvaluations, array $policyLimitationEvaluations, $userCan) + #[DataProvider('providerForTestCanUserComplex')] + public function testCanUserComplex(array $roleLimitationEvaluations, array $policyLimitationEvaluations, $userCan): void { /** @var $valueObject \Ibexa\Contracts\Core\Repository\Values\ValueObject */ - $valueObject = $this->createMock(ValueObject::class); + $valueObject = self::createStub(ValueObject::class); $limitationServiceMock = $this->getLimitationServiceMock(); $permissionResolverMock = $this->getPermissionResolverMock( [ @@ -914,7 +955,7 @@ public function testCanUserComplex(array $roleLimitationEvaluations, array $poli ->method('getCurrentUserReference') ->will(self::returnValue(new UserReference(14))); - $invocation = 0; + $expectedGetLimitationTypeCalls = []; for ($i = 0; $i < count($permissionSets); ++$i) { $limitation = $this->createMock(Type::class); $limitation @@ -922,11 +963,7 @@ public function testCanUserComplex(array $roleLimitationEvaluations, array $poli ->method('evaluate') ->with($permissionSets[$i]['limitation'], $userRef, $valueObject, [$valueObject]) ->will(self::returnValue($roleLimitationEvaluations[$i])); - $limitationServiceMock - ->expects(self::at($invocation++)) - ->method('getLimitationType') - ->with('test-role-limitation-identifier') - ->will(self::returnValue($limitation)); + $expectedGetLimitationTypeCalls[] = ['test-role-limitation-identifier', $limitation]; if (!$roleLimitationEvaluations[$i]) { continue; @@ -944,11 +981,7 @@ public function testCanUserComplex(array $roleLimitationEvaluations, array $poli ->method('evaluate') ->with($limitations[$k], $userRef, $valueObject, [$valueObject]) ->will(self::returnValue($policyLimitationEvaluations[$i][$j][$k])); - $limitationServiceMock - ->expects(self::at($invocation++)) - ->method('getLimitationType') - ->with('test-policy-limitation-identifier') - ->will(self::returnValue($limitation)); + $expectedGetLimitationTypeCalls[] = ['test-policy-limitation-identifier', $limitation]; if (!$policyLimitationEvaluations[$i][$j][$k]) { $limitationsPass = false; @@ -963,6 +996,17 @@ public function testCanUserComplex(array $roleLimitationEvaluations, array $poli } } + $getLimitationTypeMatcher = self::exactly(count($expectedGetLimitationTypeCalls)); + $limitationServiceMock + ->expects($getLimitationTypeMatcher) + ->method('getLimitationType') + ->willReturnCallback(static function ($identifier) use ($getLimitationTypeMatcher, $expectedGetLimitationTypeCalls) { + [$expectedIdentifier, $limitation] = $expectedGetLimitationTypeCalls[$getLimitationTypeMatcher->numberOfInvocations() - 1]; + self::assertSame($expectedIdentifier, $identifier); + + return $limitation; + }); + self::assertEquals( $userCan, $permissionResolverMock->canUser( @@ -977,7 +1021,7 @@ public function testCanUserComplex(array $roleLimitationEvaluations, array $poli /** * Test for the setCurrentUserReference() and getCurrentUserReference() methods. */ - public function testSetAndGetCurrentUserReference() + public function testSetAndGetCurrentUserReference(): void { $permissionResolverMock = $this->getPermissionResolverMock(null); $userReferenceMock = $this->getUserReferenceMock(); @@ -998,7 +1042,7 @@ public function testSetAndGetCurrentUserReference() /** * Test for the getCurrentUserReference() method. */ - public function testGetCurrentUserReferenceReturnsAnonymousUser() + public function testGetCurrentUserReferenceReturnsAnonymousUser(): void { $permissionResolverMock = $this->getPermissionResolverMock(null); @@ -1019,9 +1063,14 @@ protected function getPermissionResolverMock($methods = []) ->with('anonymous_user_id') ->willReturn(10); - $this->permissionResolverMock = $this - ->getMockBuilder(PermissionResolver::class) - ->setMethods($methods) + $builder = $this + ->getMockBuilder(PermissionResolver::class); + if ($methods === null) { + $builder->onlyMethods([]); + } elseif ($methods !== []) { + $builder->onlyMethods($methods); + } + $this->permissionResolverMock = $builder ->setConstructorArgs( [ $this->getRoleDomainMapperMock(), diff --git a/tests/lib/Repository/Service/Mock/RelationProcessorTest.php b/tests/lib/Repository/Service/Mock/RelationProcessorTest.php index 274a03565c..ac48a61799 100644 --- a/tests/lib/Repository/Service/Mock/RelationProcessorTest.php +++ b/tests/lib/Repository/Service/Mock/RelationProcessorTest.php @@ -20,14 +20,17 @@ use Ibexa\Core\Repository\Values\Content\Relation as RelationValue; use Ibexa\Core\Repository\Values\ContentType\FieldDefinition; use Ibexa\Tests\Core\Repository\Service\Mock\Base as BaseServiceMockTest; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use Psr\Log\LoggerInterface; -/** - * @covers \Ibexa\Core\Repository\Helper\RelationProcessor - */ +#[CoversClass(RelationProcessor::class)] class RelationProcessorTest extends BaseServiceMockTest { - public function providerForTestAppendRelations() + /** + * @return array + */ + public static function providerForTestAppendRelations(): array { return [ [ @@ -161,35 +164,44 @@ public function providerForTestAppendRelations() /** * Test for the appendFieldRelations() method. - * - * @dataProvider providerForTestAppendRelations */ - public function testAppendFieldRelations(array $fieldRelations, array $expected) + #[DataProvider('providerForTestAppendRelations')] + public function testAppendFieldRelations(array $fieldRelations, array $expected): void { $locationHandler = $this->getPersistenceMock()->locationHandler(); $relationProcessor = $this->getPartlyMockedRelationProcessor(); $fieldValueMock = $this->getMockForAbstractClass(Value::class); $fieldTypeMock = $this->createMock(FieldType::class); - $locationCallCount = 0; $fieldTypeMock->expects(self::once()) ->method('getRelations') ->with(self::equalTo($fieldValueMock)) ->will(self::returnValue($fieldRelations)); + $expectedLocationIds = []; $this->assertLocationHandlerExpectation( - $locationHandler, $fieldRelations, RelationType::LINK->value, - $locationCallCount + $expectedLocationIds ); $this->assertLocationHandlerExpectation( - $locationHandler, $fieldRelations, RelationType::EMBED->value, - $locationCallCount + $expectedLocationIds ); + if ($expectedLocationIds !== []) { + $loadMatcher = self::exactly(count($expectedLocationIds)); + $locationHandler->expects($loadMatcher) + ->method('load') + ->willReturnCallback(static function ($locationId) use ($loadMatcher, $expectedLocationIds): Location { + $expectedLocationId = $expectedLocationIds[$loadMatcher->numberOfInvocations() - 1]; + self::assertSame($expectedLocationId, $locationId); + + return new Location(['contentId' => $expectedLocationId + 100]); + }); + } + $relations = []; $locationIdToContentIdMapping = []; @@ -207,22 +219,11 @@ public function testAppendFieldRelations(array $fieldRelations, array $expected) /** * Assert loading Locations to find Content id in {@link RelationProcessor::appendFieldRelations()} method. */ - protected function assertLocationHandlerExpectation($locationHandlerMock, $fieldRelations, $type, &$callCounter) + protected function assertLocationHandlerExpectation($fieldRelations, $type, array &$expectedLocationIds) { if (isset($fieldRelations[$type]['locationIds'])) { foreach ($fieldRelations[$type]['locationIds'] as $locationId) { - $locationHandlerMock->expects(self::at($callCounter)) - ->method('load') - ->with(self::equalTo($locationId)) - ->will( - self::returnValue( - new Location( - ['contentId' => $locationId + 100] - ) - ) - ); - - ++$callCounter; + $expectedLocationIds[] = $locationId; } } } @@ -230,7 +231,7 @@ protected function assertLocationHandlerExpectation($locationHandlerMock, $field /** * Test for the appendFieldRelations() method. */ - public function testAppendFieldRelationsLocationMappingWorks() + public function testAppendFieldRelationsLocationMappingWorks(): void { $locationHandler = $this->getPersistenceMock()->locationHandler(); $relationProcessor = $this->getPartlyMockedRelationProcessor(); @@ -290,7 +291,7 @@ public function testAppendFieldRelationsLocationMappingWorks() ); } - public function testAppendFieldRelationsLogsMissingLocations() + public function testAppendFieldRelationsLogsMissingLocations(): void { $fieldValueMock = $this->getMockForAbstractClass(Value::class); $fieldTypeMock = $this->createMock(FieldType::class); @@ -345,21 +346,26 @@ public function testAppendFieldRelationsLogsMissingLocations() /** * Test for the processFieldRelations() method. */ - public function testProcessFieldRelationsNoChanges() + public function testProcessFieldRelationsNoChanges(): void { $relationProcessor = $this->getPartlyMockedRelationProcessor(); $contentHandlerMock = $this->getPersistenceMockHandler('Content\\Handler'); $contentTypeMock = $this->createMock(ContentType::class); - $contentTypeMock->expects(self::at(0)) + $getFieldDefinitionMatcher = self::exactly(2); + $contentTypeMock->expects($getFieldDefinitionMatcher) ->method('getFieldDefinition') - ->with(self::equalTo('identifier42')) - ->will(self::returnValue(new FieldDefinition(['id' => 42]))); + ->willReturnCallback(static function ($identifier) use ($getFieldDefinitionMatcher): FieldDefinition { + if ($getFieldDefinitionMatcher->numberOfInvocations() === 1) { + self::assertSame('identifier42', $identifier); - $contentTypeMock->expects(self::at(1)) - ->method('getFieldDefinition') - ->with(self::equalTo('identifier43')) - ->will(self::returnValue(new FieldDefinition(['id' => 43]))); + return new FieldDefinition(['id' => 42]); + } + + self::assertSame('identifier43', $identifier); + + return new FieldDefinition(['id' => 43]); + }); $contentHandlerMock->expects(self::never())->method('addRelation'); $contentHandlerMock->expects(self::never())->method('removeRelation'); @@ -415,7 +421,7 @@ public function testProcessFieldRelationsNoChanges() /** * Test for the processFieldRelations() method. */ - public function testProcessFieldRelationsAddsRelations() + public function testProcessFieldRelationsAddsRelations(): void { $relationProcessor = $this->getPartlyMockedRelationProcessor(); $contentHandlerMock = $this->getPersistenceMockHandler('Content\\Handler'); @@ -455,61 +461,53 @@ public function testProcessFieldRelationsAddsRelations() $contentTypeMock->expects(self::never())->method('getFieldDefinition'); $contentHandlerMock->expects(self::never())->method('removeRelation'); - $contentHandlerMock->expects(self::at(0)) - ->method('addRelation') - ->with( - new CreateStruct( - [ - 'sourceContentId' => 24, - 'sourceContentVersionNo' => 2, - 'sourceFieldDefinitionId' => null, - 'destinationContentId' => 17, - 'type' => RelationType::EMBED->value, - ] - ) - ); - - $contentHandlerMock->expects(self::at(1)) - ->method('addRelation') - ->with( - new CreateStruct( - [ - 'sourceContentId' => 24, - 'sourceContentVersionNo' => 2, - 'sourceFieldDefinitionId' => null, - 'destinationContentId' => 17, - 'type' => RelationType::LINK->value, - ] - ) - ); - - $contentHandlerMock->expects(self::at(2)) - ->method('addRelation') - ->with( - new CreateStruct( - [ - 'sourceContentId' => 24, - 'sourceContentVersionNo' => 2, - 'sourceFieldDefinitionId' => 42, - 'destinationContentId' => 13, - 'type' => RelationType::FIELD->value, - ] - ) - ); - - $contentHandlerMock->expects(self::at(3)) + $expectedAddRelationCreateStructs = [ + new CreateStruct( + [ + 'sourceContentId' => 24, + 'sourceContentVersionNo' => 2, + 'sourceFieldDefinitionId' => null, + 'destinationContentId' => 17, + 'type' => RelationType::EMBED->value, + ] + ), + new CreateStruct( + [ + 'sourceContentId' => 24, + 'sourceContentVersionNo' => 2, + 'sourceFieldDefinitionId' => null, + 'destinationContentId' => 17, + 'type' => RelationType::LINK->value, + ] + ), + new CreateStruct( + [ + 'sourceContentId' => 24, + 'sourceContentVersionNo' => 2, + 'sourceFieldDefinitionId' => 42, + 'destinationContentId' => 13, + 'type' => RelationType::FIELD->value, + ] + ), + new CreateStruct( + [ + 'sourceContentId' => 24, + 'sourceContentVersionNo' => 2, + 'sourceFieldDefinitionId' => 44, + 'destinationContentId' => 18, + 'type' => RelationType::ASSET->value, + ] + ), + ]; + $addRelationMatcher = self::exactly(count($expectedAddRelationCreateStructs)); + $contentHandlerMock->expects($addRelationMatcher) ->method('addRelation') - ->with( - new CreateStruct( - [ - 'sourceContentId' => 24, - 'sourceContentVersionNo' => 2, - 'sourceFieldDefinitionId' => 44, - 'destinationContentId' => 18, - 'type' => RelationType::ASSET->value, - ] - ) - ); + ->willReturnCallback(static function ($createStruct) use ($addRelationMatcher, $expectedAddRelationCreateStructs): void { + self::assertEquals( + $expectedAddRelationCreateStructs[$addRelationMatcher->numberOfInvocations() - 1], + $createStruct + ); + }); $relationProcessor->processFieldRelations( $inputRelations, @@ -523,7 +521,7 @@ public function testProcessFieldRelationsAddsRelations() /** * Test for the processFieldRelations() method. */ - public function testProcessFieldRelationsRemovesRelations() + public function testProcessFieldRelationsRemovesRelations(): void { $relationProcessor = $this->getPartlyMockedRelationProcessor(); $contentHandlerMock = $this->getPersistenceMockHandler('Content\\Handler'); @@ -568,46 +566,36 @@ public function testProcessFieldRelationsRemovesRelations() $contentHandlerMock->expects(self::never())->method('addRelation'); - $contentTypeMock->expects(self::at(0)) + $getFieldDefinitionMatcher = self::exactly(2); + $contentTypeMock->expects($getFieldDefinitionMatcher) ->method('getFieldDefinition') - ->with(self::equalTo('identifier42')) - ->will(self::returnValue(new FieldDefinition(['id' => 42]))); + ->willReturnCallback(static function ($identifier) use ($getFieldDefinitionMatcher): FieldDefinition { + if ($getFieldDefinitionMatcher->numberOfInvocations() === 1) { + self::assertSame('identifier42', $identifier); - $contentTypeMock->expects(self::at(1)) - ->method('getFieldDefinition') - ->with(self::equalTo('identifier44')) - ->will(self::returnValue(new FieldDefinition(['id' => 44]))); + return new FieldDefinition(['id' => 42]); + } - $contentHandlerMock->expects(self::at(0)) - ->method('removeRelation') - ->with( - self::equalTo(7), - self::equalTo(RelationType::EMBED->value), - self::equalTo(16) - ); - - $contentHandlerMock->expects(self::at(1)) - ->method('removeRelation') - ->with( - self::equalTo(7), - self::equalTo(RelationType::LINK->value), - self::equalTo(16) - ); + self::assertSame('identifier44', $identifier); - $contentHandlerMock->expects(self::at(2)) - ->method('removeRelation') - ->with( - self::equalTo(4), - self::equalTo(RelationType::FIELD->value), - self::equalTo(13) - ); + return new FieldDefinition(['id' => 44]); + }); - $contentHandlerMock->expects(self::at(3)) + $expectedRemoveRelationCalls = [ + [7, RelationType::EMBED->value, 16], + [7, RelationType::LINK->value, 16], + [4, RelationType::FIELD->value, 13], + [9, RelationType::FIELD->value, 18], + ]; + $removeRelationMatcher = self::exactly(count($expectedRemoveRelationCalls)); + $contentHandlerMock->expects($removeRelationMatcher) ->method('removeRelation') - ->with( - self::equalTo(9), - self::equalTo(RelationType::FIELD->value) - ); + ->willReturnCallback(static function ($relationId, $type, $destinationContentId = null) use ($removeRelationMatcher, $expectedRemoveRelationCalls): void { + [$expectedRelationId, $expectedType, $expectedDestinationContentId] = $expectedRemoveRelationCalls[$removeRelationMatcher->numberOfInvocations() - 1]; + self::assertSame($expectedRelationId, $relationId); + self::assertSame($expectedType, $type); + self::assertSame($expectedDestinationContentId, $destinationContentId); + }); $relationProcessor->processFieldRelations( $inputRelations, @@ -621,7 +609,7 @@ public function testProcessFieldRelationsRemovesRelations() /** * Test for the processFieldRelations() method. */ - public function testProcessFieldRelationsWhenRelationFieldNoLongerExists() + public function testProcessFieldRelationsWhenRelationFieldNoLongerExists(): void { $existingRelations = [ $this->getStubbedRelation(2, RelationType::FIELD->value, 43, 17), @@ -629,17 +617,19 @@ public function testProcessFieldRelationsWhenRelationFieldNoLongerExists() ]; $contentTypeMock = $this->createMock(ContentType::class); + $getFieldDefinitionMatcher = self::exactly(2); $contentTypeMock - ->expects(self::at(0)) + ->expects($getFieldDefinitionMatcher) ->method('getFieldDefinition') - ->with(self::equalTo('identifier43')) - ->will(self::returnValue(null)); + ->willReturnCallback(static function ($identifier) use ($getFieldDefinitionMatcher): ?FieldDefinition { + if ($getFieldDefinitionMatcher->numberOfInvocations() === 1) { + self::assertSame('identifier43', $identifier); + } else { + self::assertSame('identifier44', $identifier); + } - $contentTypeMock - ->expects(self::at(1)) - ->method('getFieldDefinition') - ->with(self::equalTo('identifier44')) - ->will(self::returnValue(null)); + return null; + }); $relationProcessor = $this->getPartlyMockedRelationProcessor(); $relationProcessor->processFieldRelations([], 24, 2, $contentTypeMock, $existingRelations); @@ -671,12 +661,12 @@ protected function getStubbedRelation($id, $type, $fieldDefinitionId, $contentId protected function getPartlyMockedRelationProcessor(?array $methods = null) { return $this->getMockBuilder(RelationProcessor::class) - ->setMethods($methods) ->setConstructorArgs( [ $this->getPersistenceMock(), ] ) + ->onlyMethods(array_values($methods ?? [])) ->getMock(); } diff --git a/tests/lib/Repository/Service/Mock/RepositoryTest.php b/tests/lib/Repository/Service/Mock/RepositoryTest.php index f098ed8858..4627e51d68 100644 --- a/tests/lib/Repository/Service/Mock/RepositoryTest.php +++ b/tests/lib/Repository/Service/Mock/RepositoryTest.php @@ -7,19 +7,20 @@ namespace Ibexa\Tests\Core\Repository\Service\Mock; +use Ibexa\Core\Repository\Repository; use Ibexa\Tests\Core\Repository\Service\Mock\Base as BaseServiceMockTest; +use PHPUnit\Framework\Attributes\CoversClass; /** * Mock test case for Repository. */ +#[CoversClass(Repository::class)] class RepositoryTest extends BaseServiceMockTest { /** * Test for the beginTransaction() method. - * - * @covers \Ibexa\Contracts\Core\Repository\Repository::beginTransaction */ - public function testBeginTransaction() + public function testBeginTransaction(): void { $mockedRepository = $this->getRepository(); $transactionHandlerMock = $this->getTransactionHandlerMock(); @@ -35,10 +36,8 @@ public function testBeginTransaction() /** * Test for the commit() method. - * - * @covers \Ibexa\Contracts\Core\Repository\Repository::commit */ - public function testCommit() + public function testCommit(): void { $mockedRepository = $this->getRepository(); $transactionHandlerMock = $this->getTransactionHandlerMock(); @@ -54,10 +53,8 @@ public function testCommit() /** * Test for the commit() method. - * - * @covers \Ibexa\Contracts\Core\Repository\Repository::commit */ - public function testCommitThrowsRuntimeException() + public function testCommitThrowsRuntimeException(): void { $this->expectException(\RuntimeException::class); @@ -77,10 +74,8 @@ public function testCommitThrowsRuntimeException() /** * Test for the rollback() method. - * - * @covers \Ibexa\Contracts\Core\Repository\Repository::rollback */ - public function testRollback() + public function testRollback(): void { $mockedRepository = $this->getRepository(); $transactionHandlerMock = $this->getTransactionHandlerMock(); @@ -96,10 +91,8 @@ public function testRollback() /** * Test for the rollback() method. - * - * @covers \Ibexa\Contracts\Core\Repository\Repository::rollback */ - public function testRollbackThrowsRuntimeException() + public function testRollbackThrowsRuntimeException(): void { $this->expectException(\RuntimeException::class); diff --git a/tests/lib/Repository/Service/Mock/RoleTest.php b/tests/lib/Repository/Service/Mock/RoleTest.php index d3123bb412..d916a06b73 100644 --- a/tests/lib/Repository/Service/Mock/RoleTest.php +++ b/tests/lib/Repository/Service/Mock/RoleTest.php @@ -30,18 +30,16 @@ use Ibexa\Core\Repository\Permission\LimitationService; use Ibexa\Core\Repository\RoleService; use Ibexa\Tests\Core\Repository\Service\Mock\Base as BaseServiceMockTest; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Contracts\Core\Repository\RoleService - * @covers \Ibexa\Core\Repository\Permission\LimitationService::validateLimitations - * @covers \Ibexa\Core\Repository\Permission\LimitationService::validateLimitation - */ +#[CoversClass(RoleService::class)] +#[CoversClass(LimitationService::class)] class RoleTest extends BaseServiceMockTest { /** * Test for the createRole() method. */ - public function testCreateRoleThrowsLimitationValidationException() + public function testCreateRoleThrowsLimitationValidationException(): void { $this->expectException(LimitationValidationException::class); @@ -106,7 +104,7 @@ public function testCreateRoleThrowsLimitationValidationException() /** * Test for the addPolicy() method. */ - public function testAddPolicyThrowsLimitationValidationException() + public function testAddPolicyThrowsLimitationValidationException(): void { $this->expectException(LimitationValidationException::class); @@ -170,7 +168,7 @@ public function testAddPolicyThrowsLimitationValidationException() /** * Test for the updatePolicyByRoleDraft() method. */ - public function testUpdatePolicyThrowsLimitationValidationException() + public function testUpdatePolicyThrowsLimitationValidationException(): void { $this->expectException(LimitationValidationException::class); @@ -196,7 +194,7 @@ public function testUpdatePolicyThrowsLimitationValidationException() $roleServiceMock = $this->getPartlyMockedRoleService(['loadRole'], $settings); - $roleDraftMock = $this->createMock(RoleDraft::class); + $roleDraftMock = self::createStub(RoleDraft::class); $policyDraftMock = $this->createMock(PolicyDraft::class); $policyUpdateStructMock = $this->createMock(PolicyUpdateStruct::class); @@ -243,15 +241,15 @@ static function ($propertyName): ?string { /** * Test for the assignRoleToUser() method. */ - public function testAssignRoleToUserThrowsUnauthorizedException() + public function testAssignRoleToUserThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); $roleServiceMock = $this->getPartlyMockedRoleService(); /** @var \Ibexa\Contracts\Core\Repository\Values\User\Role $roleMock */ - $roleMock = $this->createMock(Role::class); + $roleMock = self::createStub(Role::class); /** @var \Ibexa\Contracts\Core\Repository\Values\User\User $userMock */ - $userMock = $this->createMock(User::class); + $userMock = self::createStub(User::class); $permissionResolverMock = $this->getPermissionResolverMock(); $permissionResolverMock->expects(self::once()) @@ -269,7 +267,7 @@ public function testAssignRoleToUserThrowsUnauthorizedException() /** * Test for the assignRoleToUser() method. */ - public function testAssignRoleToUserThrowsLimitationValidationException() + public function testAssignRoleToUserThrowsLimitationValidationException(): void { $this->expectException(LimitationValidationException::class); @@ -295,9 +293,9 @@ public function testAssignRoleToUserThrowsLimitationValidationException() $roleServiceMock = $this->getPartlyMockedRoleService(null, $settings); /** @var \Ibexa\Contracts\Core\Repository\Values\User\Role $roleMock */ - $roleMock = $this->createMock(Role::class); + $roleMock = self::createStub(Role::class); /** @var \Ibexa\Contracts\Core\Repository\Values\User\User $userMock */ - $userMock = $this->createMock(User::class); + $userMock = self::createStub(User::class); $permissionResolverMock = $this->getPermissionResolverMock(); $permissionResolverMock->expects(self::once()) @@ -316,15 +314,15 @@ public function testAssignRoleToUserThrowsLimitationValidationException() /** * Test for the assignRoleToUser() method. */ - public function testAssignRoleToUserThrowsBadStateException() + public function testAssignRoleToUserThrowsBadStateException(): void { $this->expectException(BadStateException::class); $roleServiceMock = $this->getPartlyMockedRoleService(); /** @var \Ibexa\Contracts\Core\Repository\Values\User\Role $roleMock */ - $roleMock = $this->createMock(Role::class); + $roleMock = self::createStub(Role::class); /** @var \Ibexa\Contracts\Core\Repository\Values\User\User $userMock */ - $userMock = $this->createMock(User::class); + $userMock = self::createStub(User::class); $limitationMock = $this->createMock(RoleLimitation::class); $limitationMock->expects(self::once()) @@ -348,7 +346,7 @@ public function testAssignRoleToUserThrowsBadStateException() /** * Test for the assignRoleToUser() method. */ - public function testAssignRoleToUser() + public function testAssignRoleToUser(): void { $limitationMock = $this->createMock(RoleLimitation::class); $limitationTypeMock = $this->createMock(SPIType::class); @@ -431,7 +429,7 @@ public function testAssignRoleToUser() /** * Test for the assignRoleToUser() method. */ - public function testAssignRoleToUserWithNullLimitation() + public function testAssignRoleToUserWithNullLimitation(): void { $repository = $this->getRepositoryMock(); $roleServiceMock = $this->getPartlyMockedRoleService(['checkAssignmentAndFilterLimitationValues']); @@ -493,7 +491,7 @@ public function testAssignRoleToUserWithNullLimitation() /** * Test for the assignRoleToUser() method. */ - public function testAssignRoleToUserWithRollback() + public function testAssignRoleToUserWithRollback(): void { $this->expectException(\Exception::class); @@ -557,16 +555,16 @@ public function testAssignRoleToUserWithRollback() /** * Test for the assignRoleToUserGroup() method. */ - public function testAssignRoleToUserGroupThrowsUnauthorizedException() + public function testAssignRoleToUserGroupThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); $repository = $this->getRepositoryMock(); $roleServiceMock = $this->getPartlyMockedRoleService(); /** @var \Ibexa\Contracts\Core\Repository\Values\User\Role $roleMock */ - $roleMock = $this->createMock(Role::class); + $roleMock = self::createStub(Role::class); /** @var \Ibexa\Contracts\Core\Repository\Values\User\UserGroup $userGroupMock */ - $userGroupMock = $this->createMock(UserGroup::class); + $userGroupMock = self::createStub(UserGroup::class); $permissionResolverMock = $this->getPermissionResolverMock(); $permissionResolverMock->expects(self::once()) @@ -584,7 +582,7 @@ public function testAssignRoleToUserGroupThrowsUnauthorizedException() /** * Test for the assignRoleToUserGroup() method. */ - public function testAssignRoleToUserGroupThrowsLimitationValidationException() + public function testAssignRoleToUserGroupThrowsLimitationValidationException(): void { $this->expectException(LimitationValidationException::class); @@ -611,9 +609,9 @@ public function testAssignRoleToUserGroupThrowsLimitationValidationException() $repository = $this->getRepositoryMock(); /** @var \Ibexa\Contracts\Core\Repository\Values\User\Role $roleMock */ - $roleMock = $this->createMock(Role::class); + $roleMock = self::createStub(Role::class); /** @var \Ibexa\Contracts\Core\Repository\Values\User\UserGroup $userGroupMock */ - $userGroupMock = $this->createMock(UserGroup::class); + $userGroupMock = self::createStub(UserGroup::class); $permissionResolverMock = $this->getPermissionResolverMock(); $permissionResolverMock->expects(self::once()) @@ -632,16 +630,16 @@ public function testAssignRoleToUserGroupThrowsLimitationValidationException() /** * Test for the assignRoleToUserGroup() method. */ - public function testAssignRoleGroupToUserThrowsBadStateException() + public function testAssignRoleGroupToUserThrowsBadStateException(): void { $this->expectException(BadStateException::class); $repository = $this->getRepositoryMock(); $roleServiceMock = $this->getPartlyMockedRoleService(); /** @var \Ibexa\Contracts\Core\Repository\Values\User\Role $roleMock */ - $roleMock = $this->createMock(Role::class); + $roleMock = self::createStub(Role::class); /** @var \Ibexa\Contracts\Core\Repository\Values\User\UserGroup $userGroupMock */ - $userGroupMock = $this->createMock(UserGroup::class); + $userGroupMock = self::createStub(UserGroup::class); $limitationMock = $this->createMock(RoleLimitation::class); $limitationMock->expects(self::once()) @@ -665,7 +663,7 @@ public function testAssignRoleGroupToUserThrowsBadStateException() /** * Test for the assignRoleToUserGroup() method. */ - public function testAssignRoleToUserGroup() + public function testAssignRoleToUserGroup(): void { $limitationMock = $this->createMock(RoleLimitation::class); $limitationTypeMock = $this->createMock(SPIType::class); @@ -752,7 +750,7 @@ public function testAssignRoleToUserGroup() /** * Test for the assignRoleToUserGroup() method. */ - public function testAssignRoleToUserGroupWithNullLimitation() + public function testAssignRoleToUserGroupWithNullLimitation(): void { $repository = $this->getRepositoryMock(); $roleServiceMock = $this->getPartlyMockedRoleService(['checkAssignmentAndFilterLimitationValues']); @@ -818,7 +816,7 @@ public function testAssignRoleToUserGroupWithNullLimitation() /** * Test for the assignRoleToUserGroup() method. */ - public function testAssignRoleToUserGroupWithRollback() + public function testAssignRoleToUserGroupWithRollback(): void { $this->expectException(\Exception::class); @@ -883,11 +881,11 @@ public function testAssignRoleToUserGroupWithRollback() $roleServiceMock->assignRoleToUserGroup($roleMock, $userGroupMock, null); } - public function testRemovePolicyByRoleDraftThrowsUnauthorizedException() + public function testRemovePolicyByRoleDraftThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); - $roleDraftMock = $this->createMock(RoleDraft::class); + $roleDraftMock = self::createStub(RoleDraft::class); $roleDomainMapper = $this->createMock(RoleDomainMapper::class); $roleDomainMapper ->method('buildDomainRoleObject') @@ -922,7 +920,7 @@ public function testRemovePolicyByRoleDraftThrowsUnauthorizedException() /** * Test for the removePolicyByRoleDraft() method. */ - public function testRemovePolicyByRoleDraftWithRollback() + public function testRemovePolicyByRoleDraftWithRollback(): void { $this->expectException(\Exception::class); $this->expectExceptionMessage('Handler threw an exception'); @@ -977,7 +975,7 @@ public function testRemovePolicyByRoleDraftWithRollback() $roleServiceMock->removePolicyByRoleDraft($roleDraftMock, $policyDraftMock); } - public function testRemovePolicyByRoleDraft() + public function testRemovePolicyByRoleDraft(): void { $repository = $this->getRepositoryMock(); $roleDraftMock = $this->createMock(RoleDraft::class); @@ -1061,13 +1059,11 @@ protected function getPartlyMockedRoleService( ); if ($roleDomainMapper === null) { $roleDomainMapper = $this->getMockBuilder(RoleDomainMapper::class) - ->setMethods([]) ->setConstructorArgs([$limitationService]) ->getMock(); } $this->partlyMockedRoleService = $this->getMockBuilder(RoleService::class) - ->setMethods($methods) ->setConstructorArgs( [ $this->getRepositoryMock(), @@ -1077,6 +1073,7 @@ protected function getPartlyMockedRoleService( $settings, ] ) + ->onlyMethods(array_values($methods ?? [])) ->getMock(); } diff --git a/tests/lib/Repository/Service/Mock/SearchTest.php b/tests/lib/Repository/Service/Mock/SearchTest.php index 51520b1b54..63417e7281 100644 --- a/tests/lib/Repository/Service/Mock/SearchTest.php +++ b/tests/lib/Repository/Service/Mock/SearchTest.php @@ -26,10 +26,13 @@ use Ibexa\Core\Search\Common\BackgroundIndexer; use Ibexa\Core\Search\Common\BackgroundIndexer\NullIndexer; use Ibexa\Tests\Core\Repository\Service\Mock\Base as BaseServiceMockTest; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; /** * Mock test case for Search service. */ +#[CoversClass(SearchService::class)] class SearchTest extends BaseServiceMockTest { protected $repositoryMock; @@ -40,10 +43,8 @@ class SearchTest extends BaseServiceMockTest /** * Test for the __construct() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::__construct */ - public function testConstructor() + public function testConstructor(): void { $repositoryMock = $this->getRepositoryMock(); /** @var \Ibexa\Contracts\Core\Search\Handler $searchHandlerMock */ @@ -62,7 +63,10 @@ public function testConstructor() ); } - public function providerForFindContentValidatesLocationCriteriaAndSortClauses() + /** + * @return array + */ + public static function providerForFindContentValidatesLocationCriteriaAndSortClauses(): array { return [ [ @@ -92,10 +96,8 @@ public function providerForFindContentValidatesLocationCriteriaAndSortClauses() ]; } - /** - * @dataProvider providerForFindContentValidatesLocationCriteriaAndSortClauses - */ - public function testFindContentValidatesLocationCriteriaAndSortClauses($query, $exceptionMessage) + #[DataProvider('providerForFindContentValidatesLocationCriteriaAndSortClauses')] + public function testFindContentValidatesLocationCriteriaAndSortClauses($query, $exceptionMessage): void { $this->expectException(InvalidArgumentException::class); @@ -123,7 +125,10 @@ public function testFindContentValidatesLocationCriteriaAndSortClauses($query, $ self::fail('Expected exception was not thrown'); } - public function providerForFindSingleValidatesLocationCriteria() + /** + * @return array + */ + public static function providerForFindSingleValidatesLocationCriteria(): array { return [ [ @@ -141,10 +146,8 @@ public function providerForFindSingleValidatesLocationCriteria() ]; } - /** - * @dataProvider providerForFindSingleValidatesLocationCriteria - */ - public function testFindSingleValidatesLocationCriteria($criterion, $exceptionMessage) + #[DataProvider('providerForFindSingleValidatesLocationCriteria')] + public function testFindSingleValidatesLocationCriteria($criterion, $exceptionMessage): void { $this->expectException(InvalidArgumentException::class); @@ -173,11 +176,8 @@ public function testFindSingleValidatesLocationCriteria($criterion, $exceptionMe /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::addPermissionsCriterion - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent */ - public function testFindContentThrowsHandlerException() + public function testFindContentThrowsHandlerException(): void { $this->expectException(\Exception::class); $this->expectExceptionMessage('Handler threw an exception'); @@ -213,10 +213,8 @@ public function testFindContentThrowsHandlerException() /** * Test for the findContent() method when search is out of sync with persistence. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent */ - public function testFindContentWhenDomainMapperThrowsException() + public function testFindContentWhenDomainMapperThrowsException(): void { $indexer = $this->createMock(BackgroundIndexer::class); $indexer->expects(self::once()) @@ -230,7 +228,8 @@ public function testFindContentWhenDomainMapperThrowsException() $mapper = $this->getContentDomainMapperMock(), $this->getPermissionCriterionResolverMock(), $indexer, - ])->setMethods(['internalFindContentInfo']) + ]) + ->onlyMethods(['internalFindContentInfo']) ->getMock(); $info = new SPIContentInfo(['id' => 33]); @@ -260,11 +259,8 @@ public function testFindContentWhenDomainMapperThrowsException() /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::addPermissionsCriterion - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent */ - public function testFindContentNoPermissionsFilter() + public function testFindContentNoPermissionsFilter(): void { /** @var \Ibexa\Contracts\Core\Search\Handler $searchHandlerMock */ $searchHandlerMock = $this->getSPIMockHandler('Search\\Handler'); @@ -325,11 +321,8 @@ public function testFindContentNoPermissionsFilter() /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::addPermissionsCriterion - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent */ - public function testFindContentWithPermission() + public function testFindContentWithPermission(): void { /** @var \Ibexa\Contracts\Core\Search\Handler $searchHandlerMock */ $searchHandlerMock = $this->getSPIMockHandler('Search\\Handler'); @@ -398,11 +391,8 @@ public function testFindContentWithPermission() /** * Test for the findContent() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::addPermissionsCriterion - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findContent */ - public function testFindContentWithNoPermission() + public function testFindContentWithNoPermission(): void { /** @var \Ibexa\Contracts\Core\Search\Handler $searchHandlerMock */ $searchHandlerMock = $this->getSPIMockHandler('Search\\Handler'); @@ -446,7 +436,7 @@ public function testFindContentWithNoPermission() /** * Test for the findContent() method. */ - public function testFindContentWithDefaultQueryValues() + public function testFindContentWithDefaultQueryValues(): void { /** @var \Ibexa\Contracts\Core\Search\Handler $searchHandlerMock */ $searchHandlerMock = $this->getSPIMockHandler('Search\\Handler'); @@ -513,11 +503,8 @@ public function testFindContentWithDefaultQueryValues() /** * Test for the findSingle() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::addPermissionsCriterion - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findSingle */ - public function testFindSingleThrowsNotFoundException() + public function testFindSingleThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -549,11 +536,8 @@ public function testFindSingleThrowsNotFoundException() /** * Test for the findSingle() method. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::addPermissionsCriterion - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findSingle */ - public function testFindSingleThrowsHandlerException() + public function testFindSingleThrowsHandlerException(): void { $this->expectException(\Exception::class); $this->expectExceptionMessage('Handler threw an exception'); @@ -648,7 +632,7 @@ public function testFindSingle(): void /** * Test for the findLocations() method. */ - public function testFindLocationsWithPermission() + public function testFindLocationsWithPermission(): void { $repositoryMock = $this->getRepositoryMock(); /** @var \Ibexa\Contracts\Core\Search\Handler $searchHandlerMock */ @@ -719,7 +703,7 @@ public function testFindLocationsWithPermission() /** * Test for the findLocations() method. */ - public function testFindLocationsWithNoPermissionsFilter() + public function testFindLocationsWithNoPermissionsFilter(): void { $repositoryMock = $this->getRepositoryMock(); /** @var \Ibexa\Contracts\Core\Search\Handler $searchHandlerMock */ @@ -785,10 +769,8 @@ public function testFindLocationsWithNoPermissionsFilter() /** * Test for the findLocations() method when search is out of sync with persistence. - * - * @covers \Ibexa\Contracts\Core\Repository\SearchService::findLocations */ - public function testFindLocationsBackgroundIndexerWhenDomainMapperThrowsException() + public function testFindLocationsBackgroundIndexerWhenDomainMapperThrowsException(): void { $indexer = $this->createMock(BackgroundIndexer::class); $indexer->expects(self::once()) @@ -802,7 +784,8 @@ public function testFindLocationsBackgroundIndexerWhenDomainMapperThrowsExceptio $mapper = $this->getContentDomainMapperMock(), $this->getPermissionCriterionResolverMock(), $indexer, - ])->setMethods(['addPermissionsCriterion']) + ]) + ->onlyMethods(['addPermissionsCriterion']) ->getMock(); $location = new SPILocation(['id' => 44]); @@ -814,7 +797,7 @@ public function testFindLocationsBackgroundIndexerWhenDomainMapperThrowsExceptio $result = new SearchResult(['searchHits' => [new SearchHit(['valueObject' => $location])], 'totalCount' => 2]); $searchHandler->expects(self::once()) ->method('findLocations') - ->with(self::isInstanceOf(LocationQuery::class), self::isType('array')) + ->with(self::isInstanceOf(LocationQuery::class), self::isArray()) ->willReturn($result); $mapper->expects(self::once()) @@ -838,7 +821,7 @@ public function testFindLocationsBackgroundIndexerWhenDomainMapperThrowsExceptio /** * Test for the findLocations() method. */ - public function testFindLocationsThrowsHandlerException() + public function testFindLocationsThrowsHandlerException(): void { $this->expectException(\Exception::class); $this->expectExceptionMessage('Handler threw an exception'); @@ -875,7 +858,7 @@ public function testFindLocationsThrowsHandlerException() /** * Test for the findLocations() method. */ - public function testFindLocationsWithDefaultQueryValues() + public function testFindLocationsWithDefaultQueryValues(): void { $repositoryMock = $this->getRepositoryMock(); /** @var \Ibexa\Contracts\Core\Search\Handler $searchHandlerMock */ diff --git a/tests/lib/Repository/Service/Mock/UrlAliasTest.php b/tests/lib/Repository/Service/Mock/UrlAliasTest.php index f0e751f2ab..a01414b7fd 100644 --- a/tests/lib/Repository/Service/Mock/UrlAliasTest.php +++ b/tests/lib/Repository/Service/Mock/UrlAliasTest.php @@ -22,11 +22,15 @@ use Ibexa\Core\Repository\URLAliasService; use Ibexa\Core\Repository\Values\Content\Location; use Ibexa\Tests\Core\Repository\Service\Mock\Base as BaseServiceMockTest; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; +use PHPUnit\Framework\Attributes\DependsExternal; use PHPUnit\Framework\MockObject\MockObject; /** * Mock test case for UrlAlias Service. */ +#[CoversClass(URLAliasService::class)] class UrlAliasTest extends BaseServiceMockTest { private const EXAMPLE_ID = 'eznode:42'; @@ -52,7 +56,7 @@ protected function setUp(): void /** * Test for the __construct() method. */ - public function testConstructor() + public function testConstructor(): void { $repositoryMock = $this->getRepositoryMock(); @@ -69,7 +73,7 @@ public function testConstructor() /** * Test for the load() method. */ - public function testLoad() + public function testLoad(): void { $mockedService = $this->getPartlyMockedURLAliasServiceService(['extractPath']); /** @var \PHPUnit\Framework\MockObject\MockObject $urlAliasHandlerMock */ @@ -112,7 +116,7 @@ public function testLoad() /** * Test for the load() method. */ - public function testLoadThrowsNotFoundException() + public function testLoadThrowsNotFoundException(): void { $mockedService = $this->getPartlyMockedURLAliasServiceService(['extractPath']); /** @var \PHPUnit\Framework\MockObject\MockObject $urlAliasHandlerMock */ @@ -170,7 +174,7 @@ protected function getSpiUrlAlias() /** * Test for the load() method. */ - public function testLoadThrowsNotFoundExceptionPath() + public function testLoadThrowsNotFoundExceptionPath(): void { $spiUrlAlias = $this->getSpiUrlAlias(); $urlAliasService = $this->getPartlyMockedURLAliasServiceService( @@ -192,7 +196,7 @@ public function testLoadThrowsNotFoundExceptionPath() /** * Test for the removeAliases() method. */ - public function testRemoveAliasesThrowsInvalidArgumentException() + public function testRemoveAliasesThrowsInvalidArgumentException(): void { $aliasList = [new URLAlias(['isCustom' => false])]; $mockedService = $this->getPartlyMockedURLAliasServiceService(); @@ -212,7 +216,7 @@ public function testRemoveAliasesThrowsInvalidArgumentException() /** * Test for the removeAliases() method. */ - public function testRemoveAliases() + public function testRemoveAliases(): void { $aliasList = [ new URLAlias([ @@ -262,7 +266,7 @@ public function testRemoveAliases() /** * Test for the removeAliases() method. */ - public function testRemoveAliasesWithRollback() + public function testRemoveAliasesWithRollback(): void { $aliasList = [ new URLAlias([ @@ -313,7 +317,10 @@ public function testRemoveAliasesWithRollback() $mockedService->removeAliases($aliasList); } - public function providerForTestListAutogeneratedLocationAliasesPath() + /** + * @return array + */ + public static function providerForTestListAutogeneratedLocationAliasesPath(): array { $pathElement1 = [ 'always-available' => true, @@ -712,10 +719,9 @@ public function providerForTestListAutogeneratedLocationAliasesPath() /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesPath */ - public function testListAutogeneratedLocationAliasesPath($spiUrlAliases, $prioritizedLanguageCodes, $paths) + #[DataProvider('providerForTestListAutogeneratedLocationAliasesPath')] + public function testListAutogeneratedLocationAliasesPath($spiUrlAliases, $prioritizedLanguageCodes, $paths): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, @@ -747,14 +753,13 @@ public function testListAutogeneratedLocationAliasesPath($spiUrlAliases, $priori /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesPath */ + #[DataProvider('providerForTestListAutogeneratedLocationAliasesPath')] public function testListAutogeneratedLocationAliasesPathCustomConfiguration( $spiUrlAliases, $prioritizedLanguageCodes, $paths - ) { + ): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, [] @@ -791,7 +796,7 @@ public function testListAutogeneratedLocationAliasesPathCustomConfiguration( /** * Test for the load() method. */ - public function testListLocationAliasesWithShowAllTranslations() + public function testListLocationAliasesWithShowAllTranslations(): void { $pathElement1 = [ 'always-available' => true, @@ -853,7 +858,7 @@ public function testListLocationAliasesWithShowAllTranslations() /** * Test for the load() method. */ - public function testListLocationAliasesWithShowAllTranslationsCustomConfiguration() + public function testListLocationAliasesWithShowAllTranslationsCustomConfiguration(): void { $pathElement1 = [ 'always-available' => true, @@ -919,7 +924,10 @@ public function testListLocationAliasesWithShowAllTranslationsCustomConfiguratio self::assertEquals('/jedan/dva/tri', $urlAliases[0]->path); } - public function providerForTestListAutogeneratedLocationAliasesEmpty() + /** + * @return array + */ + public static function providerForTestListAutogeneratedLocationAliasesEmpty(): array { $pathElement1 = [ 'always-available' => true, @@ -998,10 +1006,9 @@ public function providerForTestListAutogeneratedLocationAliasesEmpty() /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesEmpty */ - public function testListAutogeneratedLocationAliasesEmpty($spiUrlAliases, $prioritizedLanguageCodes) + #[DataProvider('providerForTestListAutogeneratedLocationAliasesEmpty')] + public function testListAutogeneratedLocationAliasesEmpty($spiUrlAliases, $prioritizedLanguageCodes): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, @@ -1018,13 +1025,12 @@ public function testListAutogeneratedLocationAliasesEmpty($spiUrlAliases, $prior /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesEmpty */ + #[DataProvider('providerForTestListAutogeneratedLocationAliasesEmpty')] public function testListAutogeneratedLocationAliasesEmptyCustomConfiguration( $spiUrlAliases, $prioritizedLanguageCodes - ) { + ): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, [] @@ -1044,7 +1050,10 @@ public function testListAutogeneratedLocationAliasesEmptyCustomConfiguration( self::assertEmpty($urlAliases); } - public function providerForTestListAutogeneratedLocationAliasesWithLanguageCodePath() + /** + * @return array + */ + public static function providerForTestListAutogeneratedLocationAliasesWithLanguageCodePath(): array { $pathElement1 = [ 'always-available' => true, @@ -1401,15 +1410,14 @@ public function providerForTestListAutogeneratedLocationAliasesWithLanguageCodeP /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesWithLanguageCodePath */ + #[DataProvider('providerForTestListAutogeneratedLocationAliasesWithLanguageCodePath')] public function testListAutogeneratedLocationAliasesWithLanguageCodePath( $spiUrlAliases, $languageCode, $prioritizedLanguageCodes, $paths - ) { + ): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, $prioritizedLanguageCodes @@ -1435,15 +1443,14 @@ public function testListAutogeneratedLocationAliasesWithLanguageCodePath( /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesWithLanguageCodePath */ + #[DataProvider('providerForTestListAutogeneratedLocationAliasesWithLanguageCodePath')] public function testListAutogeneratedLocationAliasesWithLanguageCodePathCustomConfiguration( $spiUrlAliases, $languageCode, $prioritizedLanguageCodes, $paths - ) { + ): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, [] @@ -1473,7 +1480,10 @@ public function testListAutogeneratedLocationAliasesWithLanguageCodePathCustomCo } } - public function providerForTestListAutogeneratedLocationAliasesWithLanguageCodeEmpty() + /** + * @return array + */ + public static function providerForTestListAutogeneratedLocationAliasesWithLanguageCodeEmpty(): array { $pathElement1 = [ 'always-available' => true, @@ -1664,14 +1674,13 @@ public function providerForTestListAutogeneratedLocationAliasesWithLanguageCodeE /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesWithLanguageCodeEmpty */ + #[DataProvider('providerForTestListAutogeneratedLocationAliasesWithLanguageCodeEmpty')] public function testListAutogeneratedLocationAliasesWithLanguageCodeEmpty( $spiUrlAliases, $languageCode, $prioritizedLanguageCodes - ) { + ): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, $prioritizedLanguageCodes @@ -1687,14 +1696,13 @@ public function testListAutogeneratedLocationAliasesWithLanguageCodeEmpty( /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesWithLanguageCodeEmpty */ + #[DataProvider('providerForTestListAutogeneratedLocationAliasesWithLanguageCodeEmpty')] public function testListAutogeneratedLocationAliasesWithLanguageCodeEmptyCustomConfiguration( $spiUrlAliases, $languageCode, $prioritizedLanguageCodes - ) { + ): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, [] @@ -1714,7 +1722,10 @@ public function testListAutogeneratedLocationAliasesWithLanguageCodeEmptyCustomC self::assertEmpty($urlAliases); } - public function providerForTestListAutogeneratedLocationAliasesMultipleLanguagesPath() + /** + * @return array + */ + public static function providerForTestListAutogeneratedLocationAliasesMultipleLanguagesPath(): array { $spiUrlAliases = [ new SPIUrlAlias( @@ -1781,10 +1792,9 @@ public function providerForTestListAutogeneratedLocationAliasesMultipleLanguages /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesMultipleLanguagesPath */ - public function testListAutogeneratedLocationAliasesMultipleLanguagesPath($spiUrlAliases, $prioritizedLanguageCodes, $paths) + #[DataProvider('providerForTestListAutogeneratedLocationAliasesMultipleLanguagesPath')] + public function testListAutogeneratedLocationAliasesMultipleLanguagesPath($spiUrlAliases, $prioritizedLanguageCodes, $paths): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, @@ -1811,14 +1821,13 @@ public function testListAutogeneratedLocationAliasesMultipleLanguagesPath($spiUr /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesMultipleLanguagesPath */ + #[DataProvider('providerForTestListAutogeneratedLocationAliasesMultipleLanguagesPath')] public function testListAutogeneratedLocationAliasesMultipleLanguagesPathCustomConfiguration( $spiUrlAliases, $prioritizedLanguageCodes, $paths - ) { + ): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, [] @@ -1848,7 +1857,10 @@ public function testListAutogeneratedLocationAliasesMultipleLanguagesPathCustomC } } - public function providerForTestListAutogeneratedLocationAliasesMultipleLanguagesEmpty() + /** + * @return array + */ + public static function providerForTestListAutogeneratedLocationAliasesMultipleLanguagesEmpty(): array { $spiUrlAliases = [ new SPIUrlAlias( @@ -1889,10 +1901,9 @@ public function providerForTestListAutogeneratedLocationAliasesMultipleLanguages /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesMultipleLanguagesEmpty */ - public function testListAutogeneratedLocationAliasesMultipleLanguagesEmpty($spiUrlAliases, $prioritizedLanguageCodes) + #[DataProvider('providerForTestListAutogeneratedLocationAliasesMultipleLanguagesEmpty')] + public function testListAutogeneratedLocationAliasesMultipleLanguagesEmpty($spiUrlAliases, $prioritizedLanguageCodes): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, @@ -1909,13 +1920,12 @@ public function testListAutogeneratedLocationAliasesMultipleLanguagesEmpty($spiU /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesMultipleLanguagesEmpty */ + #[DataProvider('providerForTestListAutogeneratedLocationAliasesMultipleLanguagesEmpty')] public function testListAutogeneratedLocationAliasesMultipleLanguagesEmptyCustomConfiguration( $spiUrlAliases, $prioritizedLanguageCodes - ) { + ): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, [] @@ -1934,7 +1944,10 @@ public function testListAutogeneratedLocationAliasesMultipleLanguagesEmptyCustom self::assertEmpty($urlAliases); } - public function providerForTestListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPath() + /** + * @return array + */ + public static function providerForTestListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPath(): array { $spiUrlAliases = [ new SPIUrlAlias( @@ -2005,15 +2018,14 @@ public function providerForTestListAutogeneratedLocationAliasesWithLanguageCodeM /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPath */ + #[DataProvider('providerForTestListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPath')] public function testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPath( $spiUrlAliases, $languageCode, $prioritizedLanguageCodes, $paths - ) { + ): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, $prioritizedLanguageCodes @@ -2038,15 +2050,14 @@ public function testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLang /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPath */ + #[DataProvider('providerForTestListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPath')] public function testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesPathCustomConfiguration( $spiUrlAliases, $languageCode, $prioritizedLanguageCodes, $paths - ) { + ): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, [] @@ -2075,7 +2086,10 @@ public function testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLang } } - public function providerForTestListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmpty() + /** + * @return array + */ + public static function providerForTestListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmpty(): array { $spiUrlAliases = [ new SPIUrlAlias( @@ -2128,14 +2142,13 @@ public function providerForTestListAutogeneratedLocationAliasesWithLanguageCodeM /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmpty */ + #[DataProvider('providerForTestListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmpty')] public function testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmpty( $spiUrlAliases, $languageCode, $prioritizedLanguageCodes - ) { + ): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, $prioritizedLanguageCodes @@ -2150,14 +2163,13 @@ public function testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLang /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmpty */ + #[DataProvider('providerForTestListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmpty')] public function testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLanguagesEmptyCustomConfiguration( $spiUrlAliases, $languageCode, $prioritizedLanguageCodes - ) { + ): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, [] @@ -2176,7 +2188,10 @@ public function testListAutogeneratedLocationAliasesWithLanguageCodeMultipleLang self::assertEmpty($urlAliases); } - public function providerForTestListAutogeneratedLocationAliasesAlwaysAvailablePath() + /** + * @return array + */ + public static function providerForTestListAutogeneratedLocationAliasesAlwaysAvailablePath(): array { $spiUrlAliases = [ new SPIUrlAlias( @@ -2249,14 +2264,13 @@ public function providerForTestListAutogeneratedLocationAliasesAlwaysAvailablePa /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesAlwaysAvailablePath */ + #[DataProvider('providerForTestListAutogeneratedLocationAliasesAlwaysAvailablePath')] public function testListAutogeneratedLocationAliasesAlwaysAvailablePath( $spiUrlAliases, $prioritizedLanguageCodes, $paths - ) { + ): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, $prioritizedLanguageCodes @@ -2281,14 +2295,13 @@ public function testListAutogeneratedLocationAliasesAlwaysAvailablePath( /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesAlwaysAvailablePath */ + #[DataProvider('providerForTestListAutogeneratedLocationAliasesAlwaysAvailablePath')] public function testListAutogeneratedLocationAliasesAlwaysAvailablePathCustomConfiguration( $spiUrlAliases, $prioritizedLanguageCodes, $paths - ) { + ): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, [] @@ -2317,7 +2330,10 @@ public function testListAutogeneratedLocationAliasesAlwaysAvailablePathCustomCon } } - public function providerForTestListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePath() + /** + * @return array + */ + public static function providerForTestListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePath(): array { $spiUrlAliases = [ new SPIUrlAlias( @@ -2371,15 +2387,14 @@ public function providerForTestListAutogeneratedLocationAliasesWithLanguageCodeA /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePath */ + #[DataProvider('providerForTestListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePath')] public function testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePath( $spiUrlAliases, $languageCode, $prioritizedLanguageCodes, $paths - ) { + ): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, $prioritizedLanguageCodes @@ -2404,15 +2419,14 @@ public function testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvaila /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePath */ + #[DataProvider('providerForTestListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePath')] public function testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailablePathCustomConfiguration( $spiUrlAliases, $languageCode, $prioritizedLanguageCodes, $paths - ) { + ): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, [] @@ -2441,7 +2455,10 @@ public function testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvaila } } - public function providerForTestListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmpty() + /** + * @return array + */ + public static function providerForTestListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmpty(): array { $spiUrlAliases = [ new SPIUrlAlias( @@ -2488,14 +2505,13 @@ public function providerForTestListAutogeneratedLocationAliasesWithLanguageCodeA /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmpty */ + #[DataProvider('providerForTestListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmpty')] public function testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmpty( $spiUrlAliases, $languageCode, $prioritizedLanguageCodes - ) { + ): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, $prioritizedLanguageCodes @@ -2510,14 +2526,13 @@ public function testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvaila /** * Test for the listLocationAliases() method. - * - * @dataProvider providerForTestListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmpty */ + #[DataProvider('providerForTestListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmpty')] public function testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvailableEmptyCustomConfiguration( $spiUrlAliases, $languageCode, $prioritizedLanguageCodes - ) { + ): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, [] @@ -2539,7 +2554,7 @@ public function testListAutogeneratedLocationAliasesWithLanguageCodeAlwaysAvaila /** * Test for the listGlobalAliases() method. */ - public function testListGlobalAliases() + public function testListGlobalAliases(): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, @@ -2589,7 +2604,7 @@ public function testListGlobalAliases() /** * Test for the listGlobalAliases() method. */ - public function testListGlobalAliasesEmpty() + public function testListGlobalAliasesEmpty(): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService(); @@ -2628,7 +2643,7 @@ public function testListGlobalAliasesEmpty() /** * Test for the listGlobalAliases() method. */ - public function testListGlobalAliasesWithParameters() + public function testListGlobalAliasesWithParameters(): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService(); @@ -2656,7 +2671,7 @@ public function testListGlobalAliasesWithParameters() /** * Test for the lookup() method. */ - public function testLookupThrowsNotFoundException() + public function testLookupThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -2675,7 +2690,10 @@ public function testLookupThrowsNotFoundException() $urlAliasService->lookup('url'); } - public function providerForTestLookupThrowsNotFoundExceptionPath() + /** + * @return array + */ + public static function providerForTestLookupThrowsNotFoundExceptionPath(): array { return [ // alias does not exist in requested language @@ -2691,10 +2709,9 @@ public function providerForTestLookupThrowsNotFoundExceptionPath() /** * Test for the lookup() method. - * - * @dataProvider providerForTestLookupThrowsNotFoundExceptionPath */ - public function testLookupThrowsNotFoundExceptionPathNotMatchedOrNotLoadable($url, $prioritizedLanguageList, $languageCode) + #[DataProvider('providerForTestLookupThrowsNotFoundExceptionPath')] + public function testLookupThrowsNotFoundExceptionPathNotMatchedOrNotLoadable($url, $prioritizedLanguageList, $languageCode): void { $this->expectException(NotFoundException::class); @@ -2734,7 +2751,10 @@ public function testLookupThrowsNotFoundExceptionPathNotMatchedOrNotLoadable($ur $urlAliasService->lookup($url, $languageCode); } - public function providerForTestLookup() + /** + * @return array + */ + public static function providerForTestLookup(): array { return [ // showAllTranslations setting is true @@ -2748,10 +2768,9 @@ public function providerForTestLookup() /** * Test for the lookup() method. - * - * @dataProvider providerForTestLookup */ - public function testLookup($prioritizedLanguageList, $showAllTranslations, $alwaysAvailable, $languageCode) + #[DataProvider('providerForTestLookup')] + public function testLookup($prioritizedLanguageList, $showAllTranslations, $alwaysAvailable, $languageCode): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, @@ -2801,7 +2820,10 @@ public function testLookup($prioritizedLanguageList, $showAllTranslations, $alwa ); } - public function providerForTestLookupWithSharedTranslation() + /** + * @return array + */ + public static function providerForTestLookupWithSharedTranslation(): array { return [ // showAllTranslations setting is true @@ -2824,15 +2846,14 @@ public function providerForTestLookupWithSharedTranslation() /** * Test for the lookup() method. - * - * @dataProvider providerForTestLookupWithSharedTranslation */ + #[DataProvider('providerForTestLookupWithSharedTranslation')] public function testLookupWithSharedTranslation( $prioritizedLanguageList, $showAllTranslations, $alwaysAvailable, $languageCode - ) { + ): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, $prioritizedLanguageList, @@ -2884,7 +2905,7 @@ public function testLookupWithSharedTranslation( /** * Test for the reverseLookup() method. */ - public function testReverseLookupCustomConfiguration() + public function testReverseLookupCustomConfiguration(): void { $this->expectException(NotFoundException::class); @@ -2910,7 +2931,7 @@ public function testReverseLookupCustomConfiguration() /** * Test for the reverseLookup() method. */ - public function testReverseLookupThrowsNotFoundException() + public function testReverseLookupThrowsNotFoundException(): void { $this->expectException(NotFoundException::class); @@ -2944,17 +2965,19 @@ public function testReverseLookupThrowsNotFoundException() $urlAliasService->reverseLookup($location, $languageCode); } - public function providerForTestReverseLookup() + /** + * @return array + */ + public static function providerForTestReverseLookup(): array { - return $this->providerForTestListAutogeneratedLocationAliasesPath(); + return self::providerForTestListAutogeneratedLocationAliasesPath(); } /** * Test for the reverseLookup() method. - * - * @dataProvider providerForTestReverseLookup */ - public function testReverseLookupPath($spiUrlAliases, $prioritizedLanguageCodes, $paths, $reverseLookupLanguageCode) + #[DataProvider('providerForTestReverseLookup')] + public function testReverseLookupPath($spiUrlAliases, $prioritizedLanguageCodes, $paths, $reverseLookupLanguageCode): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, @@ -2975,21 +2998,23 @@ public function testReverseLookupPath($spiUrlAliases, $prioritizedLanguageCodes, ); } - public function providerForTestReverseLookupAlwaysAvailablePath() + /** + * @return array + */ + public static function providerForTestReverseLookupAlwaysAvailablePath(): array { - return $this->providerForTestListAutogeneratedLocationAliasesAlwaysAvailablePath(); + return self::providerForTestListAutogeneratedLocationAliasesAlwaysAvailablePath(); } /** * Test for the reverseLookup() method. - * - * @dataProvider providerForTestReverseLookupAlwaysAvailablePath */ + #[DataProvider('providerForTestReverseLookupAlwaysAvailablePath')] public function testReverseLookupAlwaysAvailablePath( $spiUrlAliases, $prioritizedLanguageCodes, $paths - ) { + ): void { $urlAliasService = $this->getPartlyMockedURLAliasServiceService( null, $prioritizedLanguageCodes @@ -3008,7 +3033,7 @@ public function testReverseLookupAlwaysAvailablePath( /** * Test for the reverseLookup() method. */ - public function testReverseLookupWithShowAllTranslations() + public function testReverseLookupWithShowAllTranslations(): void { $spiUrlAlias = $this->getSpiUrlAlias(); $urlAliasService = $this->getPartlyMockedURLAliasServiceService( @@ -3027,7 +3052,7 @@ public function testReverseLookupWithShowAllTranslations() /** * Test for the createUrlAlias() method. */ - public function testCreateUrlAlias() + public function testCreateUrlAlias(): void { $location = $this->getLocationStub(); $this->permissionResolver @@ -3095,7 +3120,7 @@ public function testCreateUrlAlias() /** * Test for the createUrlAlias() method. */ - public function testCreateUrlAliasWithRollback() + public function testCreateUrlAliasWithRollback(): void { $this->expectException(\Exception::class); $this->expectExceptionMessage('Handler threw an exception'); @@ -3151,7 +3176,7 @@ public function testCreateUrlAliasWithRollback() /** * Test for the createUrlAlias() method. */ - public function testCreateUrlAliasThrowsInvalidArgumentException() + public function testCreateUrlAliasThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -3197,7 +3222,7 @@ public function testCreateUrlAliasThrowsInvalidArgumentException() /** * Test for the createGlobalUrlAlias() method. */ - public function testCreateGlobalUrlAlias() + public function testCreateGlobalUrlAlias(): void { $resource = 'module:content/search'; @@ -3266,7 +3291,7 @@ public function testCreateGlobalUrlAlias() /** * Test for the createGlobalUrlAlias() method. */ - public function testCreateGlobalUrlAliasWithRollback() + public function testCreateGlobalUrlAliasWithRollback(): void { $this->expectException(\Exception::class); $this->expectExceptionMessage('Handler threw an exception'); @@ -3321,7 +3346,7 @@ public function testCreateGlobalUrlAliasWithRollback() /** * Test for the createGlobalUrlAlias() method. */ - public function testCreateGlobalUrlAliasThrowsInvalidArgumentExceptionResource() + public function testCreateGlobalUrlAliasThrowsInvalidArgumentExceptionResource(): void { $this->expectException(InvalidArgumentException::class); @@ -3346,7 +3371,7 @@ public function testCreateGlobalUrlAliasThrowsInvalidArgumentExceptionResource() /** * Test for the createGlobalUrlAlias() method. */ - public function testCreateGlobalUrlAliasThrowsInvalidArgumentExceptionPath() + public function testCreateGlobalUrlAliasThrowsInvalidArgumentExceptionPath(): void { $this->expectException(InvalidArgumentException::class); @@ -3387,12 +3412,11 @@ public function testCreateGlobalUrlAliasThrowsInvalidArgumentExceptionPath() /** * Test for the createGlobalUrlAlias() method. - * - * @depends Ibexa\Tests\Core\Repository\Service\Mock\UrlAliasTest::testCreateUrlAlias - * @depends Ibexa\Tests\Core\Repository\Service\Mock\UrlAliasTest::testCreateUrlAliasWithRollback - * @depends Ibexa\Tests\Core\Repository\Service\Mock\UrlAliasTest::testCreateUrlAliasThrowsInvalidArgumentException */ - public function testCreateGlobalUrlAliasForLocation() + #[DependsExternal(self::class, 'testCreateUrlAlias')] + #[DependsExternal(self::class, 'testCreateUrlAliasWithRollback')] + #[DependsExternal(self::class, 'testCreateUrlAliasThrowsInvalidArgumentException')] + public function testCreateGlobalUrlAliasForLocation(): void { $repositoryMock = $this->getRepositoryMock(); $mockedService = $this->getPartlyMockedURLAliasServiceService(['createUrlAlias']); @@ -3504,7 +3528,6 @@ protected function getPartlyMockedURLAliasServiceService( ->willReturn($showAllTranslations); return $this->getMockBuilder(URLAliasService::class) - ->setMethods($methods) ->setConstructorArgs( [ $this->getRepositoryMock(), @@ -3514,15 +3537,14 @@ protected function getPartlyMockedURLAliasServiceService( $languageResolverMock, ] ) + ->onlyMethods(array_values($methods ?? [])) ->getMock(); } /** * Test for the createUrlAlias() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::createUrlAlias */ - public function testCreateUrlAliasThrowsUnauthorizedException() + public function testCreateUrlAliasThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -3547,10 +3569,8 @@ public function testCreateUrlAliasThrowsUnauthorizedException() /** * Test for the createGlobalUrlAlias() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::createGlobalUrlAlias */ - public function testCreateGlobalUrlAliasThrowsUnauthorizedException() + public function testCreateGlobalUrlAliasThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -3574,10 +3594,8 @@ public function testCreateGlobalUrlAliasThrowsUnauthorizedException() /** * Test for the removeAliases() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLAliasService::removeAliases */ - public function testRemoveAliasesThrowsUnauthorizedException() + public function testRemoveAliasesThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); diff --git a/tests/lib/Repository/Service/Mock/UrlTest.php b/tests/lib/Repository/Service/Mock/UrlTest.php index a36e809331..ddec18b28f 100644 --- a/tests/lib/Repository/Service/Mock/UrlTest.php +++ b/tests/lib/Repository/Service/Mock/UrlTest.php @@ -25,6 +25,7 @@ use Ibexa\Core\Base\Exceptions\UnauthorizedException; use Ibexa\Core\Repository\URLService; use Ibexa\Tests\Core\Repository\Service\Mock\Base as BaseServiceMockTest; +use PHPUnit\Framework\Attributes\DataProvider; class UrlTest extends BaseServiceMockTest { @@ -45,7 +46,7 @@ protected function setUp(): void $this->permissionResolver = $this->getPermissionResolverMock(); } - public function testFindUrlsUnauthorized() + public function testFindUrlsUnauthorized(): void { $this->configureUrlViewPermissionForHasAccess(false); @@ -53,7 +54,7 @@ public function testFindUrlsUnauthorized() $this->createUrlService()->findUrls(new URLQuery()); } - public function testFindUrlsNonNumericOffset() + public function testFindUrlsNonNumericOffset(): void { $this->expectException(InvalidArgumentValue::class); @@ -63,7 +64,7 @@ public function testFindUrlsNonNumericOffset() $this->createUrlService()->findUrls($query); } - public function testFindUrlsNonNumericLimit() + public function testFindUrlsNonNumericLimit(): void { $this->expectException(InvalidArgumentValue::class); @@ -73,7 +74,7 @@ public function testFindUrlsNonNumericLimit() $this->createUrlService()->findUrls($query); } - public function testFindUrls() + public function testFindUrls(): void { $url = $this->getApiUrl(); @@ -102,7 +103,7 @@ public function testFindUrls() self::assertEquals($expected, $this->createUrlService()->findUrls($query)); } - public function testUpdateUrlUnauthorized() + public function testUpdateUrlUnauthorized(): void { $this->expectException(UnauthorizedException::class); @@ -113,7 +114,7 @@ public function testUpdateUrlUnauthorized() $this->createUrlService()->updateUrl($url, new URLUpdateStruct()); } - public function testUpdateUrlNonUnique() + public function testUpdateUrlNonUnique(): void { $this->expectException(InvalidArgumentException::class); @@ -135,7 +136,7 @@ public function testUpdateUrlNonUnique() $urlService->updateUrl($url, $struct); } - public function testUpdateUrl() + public function testUpdateUrl(): void { $apiUrl = $this->getApiUrl(self::URL_ID, self::URL_IBEXA_CO); $apiStruct = new URLUpdateStruct([ @@ -194,7 +195,7 @@ public function testUpdateUrl() ]), $urlService->updateUrl($apiUrl, $apiStruct)); } - public function testUpdateUrlStatus() + public function testUpdateUrlStatus(): void { $apiUrl = $this->getApiUrl(self::URL_ID, self::URL_IBEXA_CO); $apiStruct = new URLUpdateStruct([ @@ -254,7 +255,7 @@ public function testUpdateUrlStatus() ]), $urlService->updateUrl($apiUrl, $apiStruct)); } - public function testLoadByIdUnauthorized() + public function testLoadByIdUnauthorized(): void { $this->expectException(UnauthorizedException::class); @@ -276,7 +277,7 @@ public function testLoadByIdUnauthorized() $this->createUrlService()->loadById(self::URL_ID); } - public function testLoadById() + public function testLoadById(): void { $url = new URL([ 'id' => self::URL_ID, @@ -295,7 +296,7 @@ public function testLoadById() self::assertEquals($url, $this->createUrlService()->loadById(self::URL_ID)); } - public function testLoadByUrlUnauthorized() + public function testLoadByUrlUnauthorized(): void { $this->expectException(UnauthorizedException::class); @@ -319,7 +320,7 @@ public function testLoadByUrlUnauthorized() $this->createUrlService()->loadByUrl(self::URL_IBEXA_CO); } - public function testLoadByUrl() + public function testLoadByUrl(): void { $url = self::URL_IBEXA_CO; @@ -340,10 +341,8 @@ public function testLoadByUrl() self::assertEquals($apiUrl, $this->createUrlService()->loadByUrl($url)); } - /** - * @dataProvider dateProviderForFindUsages - */ - public function testFindUsages($offset, $limit, ContentQuery $expectedQuery, array $usages) + #[DataProvider('dateProviderForFindUsages')] + public function testFindUsages($offset, $limit, ContentQuery $expectedQuery, array $usages): void { $url = $this->getApiUrl(self::URL_ID, self::URL_IBEXA_CO); @@ -388,7 +387,10 @@ public function testFindUsages($offset, $limit, ContentQuery $expectedQuery, arr } } - public function dateProviderForFindUsages() + /** + * @return array + */ + public static function dateProviderForFindUsages(): array { return [ [ @@ -419,7 +421,7 @@ public function dateProviderForFindUsages() ]; } - public function testCreateUpdateStruct() + public function testCreateUpdateStruct(): void { self::assertEquals(new URLUpdateStruct(), $this->createUrlService()->createUpdateStruct()); } @@ -461,11 +463,15 @@ protected function configureUrlUpdatePermission($object, $hasAccess = false) protected function configurePermissions(array $permissions) { + $matcher = self::exactly(count($permissions)); $this->permissionResolver - ->expects(self::exactly(count($permissions))) + ->expects($matcher) ->method('canUser') - ->withConsecutive(...$permissions) - ->willReturn(true); + ->willReturnCallback(function (...$parameters) use ($matcher, $permissions) { + $this->assertEquals($permissions[$matcher->numberOfInvocations() - 1], $parameters); + + return true; + }); } /** @@ -476,7 +482,7 @@ private function createUrlService(?array $methods = null) return $this ->getMockBuilder(URLService::class) ->setConstructorArgs([$this->getRepositoryMock(), $this->urlHandler, $this->permissionResolver]) - ->setMethods($methods) + ->onlyMethods(array_values($methods ?? [])) ->getMock(); } diff --git a/tests/lib/Repository/Service/Mock/UrlWildcardTest.php b/tests/lib/Repository/Service/Mock/UrlWildcardTest.php index 2019c47261..6d0b43f647 100644 --- a/tests/lib/Repository/Service/Mock/UrlWildcardTest.php +++ b/tests/lib/Repository/Service/Mock/UrlWildcardTest.php @@ -19,10 +19,13 @@ use Ibexa\Core\Base\Exceptions\NotFoundException as APINotFoundException; use Ibexa\Core\Repository\URLWildcardService; use Ibexa\Tests\Core\Repository\Service\Mock\Base as BaseServiceMockTest; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; /** * Mock Test case for UrlWildcard Service. */ +#[CoversClass(URLWildcardService::class)] class UrlWildcardTest extends BaseServiceMockTest { private const EXAMPLE_URL_WILDCARD_ID = 1; @@ -42,10 +45,8 @@ protected function setUp(): void /** * Test for the create() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::create */ - public function testCreateThrowsUnauthorizedException() + public function testCreateThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -69,10 +70,8 @@ public function testCreateThrowsUnauthorizedException() /** * Test for the create() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::create */ - public function testCreateThrowsInvalidArgumentException() + public function testCreateThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -100,7 +99,10 @@ public function testCreateThrowsInvalidArgumentException() $mockedService->create('/lorem/ipsum', 'opossum', true); } - public function providerForTestCreateThrowsContentValidationException() + /** + * @return array + */ + public static function providerForTestCreateThrowsContentValidationException(): array { return [ ['fruit', 'food/{1}', true], @@ -111,12 +113,9 @@ public function providerForTestCreateThrowsContentValidationException() /** * Test for the create() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::create - * - * @dataProvider providerForTestCreateThrowsContentValidationException */ - public function testCreateThrowsContentValidationException($sourceUrl, $destinationUrl, $forward) + #[DataProvider('providerForTestCreateThrowsContentValidationException')] + public function testCreateThrowsContentValidationException($sourceUrl, $destinationUrl, $forward): void { $this->expectException(ContentValidationException::class); @@ -144,7 +143,10 @@ public function testCreateThrowsContentValidationException($sourceUrl, $destinat $mockedService->create($sourceUrl, $destinationUrl, $forward); } - public function providerForTestCreate() + /** + * @return array + */ + public static function providerForTestCreate(): array { return [ ['fruit', 'food', true], @@ -159,12 +161,9 @@ public function providerForTestCreate() /** * Test for the create() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::create - * - * @dataProvider providerForTestCreate */ - public function testCreate($sourceUrl, $destinationUrl, $forward) + #[DataProvider('providerForTestCreate')] + public function testCreate($sourceUrl, $destinationUrl, $forward): void { $mockedService = $this->getPartlyMockedURLWildcardService(); @@ -230,10 +229,8 @@ public function testCreate($sourceUrl, $destinationUrl, $forward) /** * Test for the create() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::create */ - public function testCreateWithRollback() + public function testCreateWithRollback(): void { $this->expectException(\Exception::class); @@ -283,10 +280,8 @@ public function testCreateWithRollback() /** * Test for the remove() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::remove */ - public function testRemoveThrowsUnauthorizedException() + public function testRemoveThrowsUnauthorizedException(): void { $this->expectException(UnauthorizedException::class); @@ -316,10 +311,8 @@ public function testRemoveThrowsUnauthorizedException() /** * Test for the remove() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::remove */ - public function testRemove() + public function testRemove(): void { $wildcard = new URLWildcard(['id' => self::EXAMPLE_URL_WILDCARD_ID]); @@ -354,10 +347,8 @@ public function testRemove() /** * Test for the remove() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::remove */ - public function testRemoveWithRollback() + public function testRemoveWithRollback(): void { $this->expectException(\Exception::class); @@ -398,10 +389,8 @@ public function testRemoveWithRollback() /** * Test for the load() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::remove */ - public function testLoadThrowsException() + public function testLoadThrowsException(): void { $this->expectException(\Exception::class); @@ -424,10 +413,8 @@ public function testLoadThrowsException() /** * Test for the load() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::remove */ - public function testLoad() + public function testLoad(): void { $mockedService = $this->getPartlyMockedURLWildcardService(); @@ -467,10 +454,8 @@ public function testLoad() /** * Test for the loadAll() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::loadAll */ - public function testLoadAll() + public function testLoadAll(): void { $mockedService = $this->getPartlyMockedURLWildcardService(); @@ -490,10 +475,8 @@ public function testLoadAll() /** * Test for the loadAll() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::loadAll */ - public function testLoadAllWithLimitAndOffset() + public function testLoadAllWithLimitAndOffset(): void { $mockedService = $this->getPartlyMockedURLWildcardService(); @@ -539,7 +522,7 @@ public function testLoadAllWithLimitAndOffset() /** * @return array */ - public function providerForTestTranslateThrowsNotFoundException() + public static function providerForTestTranslateThrowsNotFoundException(): array { return [ [ @@ -579,12 +562,9 @@ public function providerForTestTranslateThrowsNotFoundException() /** * Test for the translate() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::translate - * - * @dataProvider providerForTestTranslateThrowsNotFoundException */ - public function testTranslateThrowsNotFoundException($createArray, $url) + #[DataProvider('providerForTestTranslateThrowsNotFoundException')] + public function testTranslateThrowsNotFoundException($createArray, $url): void { $this->expectException(NotFoundException::class); @@ -606,7 +586,7 @@ public function testTranslateThrowsNotFoundException($createArray, $url) /** * @return array */ - public function providerForTestTranslate() + public static function providerForTestTranslate(): array { return [ [ @@ -686,12 +666,9 @@ public function providerForTestTranslate() /** * Test for the translate() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::translate - * - * @dataProvider providerForTestTranslate */ - public function testTranslate($createArray, $url, $uri) + #[DataProvider('providerForTestTranslate')] + public function testTranslate($createArray, $url, $uri): void { $mockedService = $this->getPartlyMockedURLWildcardService(); @@ -723,10 +700,8 @@ public function testTranslate($createArray, $url, $uri) /** * Test for the translate() method. - * - * @covers \Ibexa\Contracts\Core\Repository\URLWildcardService::translate */ - public function testTranslateUsesLongestMatchingWildcard() + public function testTranslateUsesLongestMatchingWildcard(): void { $mockedService = $this->getPartlyMockedURLWildcardService(); @@ -767,7 +742,6 @@ public function testTranslateUsesLongestMatchingWildcard() protected function getPartlyMockedURLWildcardService(?array $methods = null) { return $this->getMockBuilder(URLWildcardService::class) - ->setMethods($methods) ->setConstructorArgs( [ $this->getRepositoryMock(), @@ -775,6 +749,7 @@ protected function getPartlyMockedURLWildcardService(?array $methods = null) $this->permissionResolver, ] ) + ->onlyMethods(array_values($methods ?? [])) ->getMock(); } } diff --git a/tests/lib/Repository/Service/Mock/UserPasswordValidatorTest.php b/tests/lib/Repository/Service/Mock/UserPasswordValidatorTest.php index ebee11608b..8b759c8404 100644 --- a/tests/lib/Repository/Service/Mock/UserPasswordValidatorTest.php +++ b/tests/lib/Repository/Service/Mock/UserPasswordValidatorTest.php @@ -11,23 +11,21 @@ use Ibexa\Core\FieldType\ValidationError; use Ibexa\Core\Repository\Validator\UserPasswordValidator; use Ibexa\Tests\Core\Search\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; -/** - * @covers \Ibexa\Core\Repository\Validator\UserPasswordValidator - */ +#[CoversClass(UserPasswordValidator::class)] class UserPasswordValidatorTest extends TestCase { - /** - * @dataProvider dateProviderForValidate - */ - public function testValidate(array $constraints, string $password, array $expectedErrors) + #[DataProvider('dateProviderForValidate')] + public function testValidate(array $constraints, string $password, array $expectedErrors): void { $validator = new UserPasswordValidator($constraints); self::assertEqualsCanonicalizing($expectedErrors, $validator->validate($password), ''); } - public function dateProviderForValidate(): array + public static function dateProviderForValidate(): array { return [ [ diff --git a/tests/lib/Repository/Service/Mock/UserPreferenceTest.php b/tests/lib/Repository/Service/Mock/UserPreferenceTest.php index 7d35327973..635130c451 100644 --- a/tests/lib/Repository/Service/Mock/UserPreferenceTest.php +++ b/tests/lib/Repository/Service/Mock/UserPreferenceTest.php @@ -18,7 +18,9 @@ use Ibexa\Core\Repository\UserPreferenceService; use Ibexa\Core\Repository\Values\User\UserReference; use Ibexa\Tests\Core\Repository\Service\Mock\Base as BaseServiceMockTest; +use PHPUnit\Framework\Attributes\CoversClass; +#[CoversClass(UserPreferenceService::class)] class UserPreferenceTest extends BaseServiceMockTest { public const CURRENT_USER_ID = 14; @@ -42,10 +44,7 @@ protected function setUp(): void ->willReturn($permissionResolverMock); } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserPreferenceService::setUserPreference() - */ - public function testSetUserPreference() + public function testSetUserPreference(): void { $apiUserPreferenceSetStruct = new APIUserPreferenceSetStruct([ 'name' => 'setting', @@ -68,10 +67,7 @@ public function testSetUserPreference() $this->createAPIUserPreferenceService()->setUserPreference([$apiUserPreferenceSetStruct]); } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserPreferenceService::setUserPreference - */ - public function testSetUserPreferenceThrowsInvalidArgumentException() + public function testSetUserPreferenceThrowsInvalidArgumentException(): void { $this->expectException(InvalidArgumentException::class); @@ -86,10 +82,7 @@ public function testSetUserPreferenceThrowsInvalidArgumentException() $this->createAPIUserPreferenceService()->setUserPreference([$apiUserPreferenceSetStruct]); } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserPreferenceService::setUserPreference - */ - public function testSetUserPreferenceWithRollback() + public function testSetUserPreferenceWithRollback(): void { $this->expectException(\Exception::class); @@ -102,16 +95,13 @@ public function testSetUserPreferenceWithRollback() $this->userSPIPreferenceHandler ->expects($this->once()) ->method('setUserPreference') - ->willThrowException($this->createMock(Exception::class)); + ->willThrowException(self::createStub(Exception::class)); }); $this->createAPIUserPreferenceService()->setUserPreference([$apiUserPreferenceSetStruct]); } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserPreferenceService::getUserPreference() - */ - public function testGetUserPreference() + public function testGetUserPreference(): void { $userPreferenceName = 'setting'; $userPreferenceValue = 'value'; @@ -134,10 +124,7 @@ public function testGetUserPreference() self::assertEquals($expected, $APIUserPreference); } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserPreferenceService::loadUserPreferences - */ - public function testLoadUserPreferences() + public function testLoadUserPreferences(): void { $offset = 0; $limit = 25; @@ -170,10 +157,7 @@ public function testLoadUserPreferences() self::assertEquals($expectedItems, $userPreferences->items); } - /** - * @covers \Ibexa\Contracts\Core\Repository\UserPreferenceService::getUserPreferenceCount() - */ - public function testGetUserPreferenceCount() + public function testGetUserPreferenceCount(): void { $expectedTotalCount = 10; @@ -196,7 +180,7 @@ private function createAPIUserPreferenceService(?array $methods = null) return $this ->getMockBuilder(UserPreferenceService::class) ->setConstructorArgs([$this->getRepositoryMock(), $this->userSPIPreferenceHandler]) - ->setMethods($methods) + ->onlyMethods(array_values($methods ?? [])) ->getMock(); } diff --git a/tests/lib/Repository/Service/Mock/UserTest.php b/tests/lib/Repository/Service/Mock/UserTest.php index 2a9e09c47a..549557e13d 100644 --- a/tests/lib/Repository/Service/Mock/UserTest.php +++ b/tests/lib/Repository/Service/Mock/UserTest.php @@ -22,10 +22,10 @@ use Ibexa\Core\Repository\User\PasswordValidatorInterface; use Ibexa\Core\Repository\UserService; use Ibexa\Tests\Core\Repository\Service\Mock\Base as BaseServiceMockTest; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\MockObject\MockObject; -/** - * @covers \Ibexa\Core\Repository\UserService - */ +#[CoversClass(UserService::class)] class UserTest extends BaseServiceMockTest { private const MOCKED_USER_ID = 42; @@ -60,7 +60,7 @@ public function testDeleteUserWithRollback(): void $repository = $this->getRepositoryMock(); $userService = $this->getPartlyMockedUserService(['loadUser']); $contentService = $this->createMock(APIContentService::class); - /* @var \Ibexa\Contracts\Core\Persistence\User\Handler&\PHPUnit\Framework\MockObject\MockObject $userHandler */ + /* @var PersistenceUserHandler&MockObject $userHandler */ $userHandler = $this->getPersistenceMock()->userHandler(); $user = $this->createMock(APIUser::class); @@ -91,36 +91,28 @@ public function testDeleteUserWithRollback(): void protected function getPartlyMockedUserService(?array $methods = null): APIUserService { return $this->getMockBuilder(UserService::class) - ->onlyMethods($methods) + ->onlyMethods(array_values($methods)) ->setConstructorArgs( [ $this->getRepositoryMock(), $this->getPermissionResolverMock(), $this->getPersistenceMock()->userHandler(), $this->getPersistenceMock()->locationHandler(), - $this->createMock(PasswordHashService::class), - $this->createMock(PasswordValidatorInterface::class), - $this->createMock(ConfigResolverInterface::class), + self::createStub(PasswordHashService::class), + self::createStub(PasswordValidatorInterface::class), + self::createStub(ConfigResolverInterface::class), ] ) ->getMock(); } - /** - * @param \Ibexa\Contracts\Core\Repository\Repository&\PHPUnit\Framework\MockObject\MockObject $repository - * @param \Ibexa\Contracts\Core\Repository\UserService&\PHPUnit\Framework\MockObject\MockObject $userService - * @param \Ibexa\Contracts\Core\Repository\ContentService&\PHPUnit\Framework\MockObject\MockObject $contentService - * @param \Ibexa\Contracts\Core\Repository\Values\User\User&\PHPUnit\Framework\MockObject\MockObject $user - * @param \Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo&\PHPUnit\Framework\MockObject\MockObject $contentInfo - * @param \Ibexa\Contracts\Core\Persistence\User\Handler&\PHPUnit\Framework\MockObject\MockObject $userHandler - */ private function mockDeleteUserFlow( - Repository $repository, - APIUserService $userService, - APIContentService $contentService, - User $user, - APIContentInfo $contentInfo, - PersistenceUserHandler $userHandler + Repository&MockObject $repository, + APIUserService&MockObject $userService, + APIContentService&MockObject $contentService, + User&MockObject $user, + APIContentInfo&MockObject $contentInfo, + PersistenceUserHandler&MockObject $userHandler ): void { $loadedUser = $this->createMock(APIUser::class); $versionInfo = $this->createMock(APIVersionInfo::class); diff --git a/tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php b/tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php index 672dd03a11..f8a56069ca 100644 --- a/tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php +++ b/tests/lib/Repository/SiteAccessAware/AbstractServiceTestCase.php @@ -9,6 +9,7 @@ use Closure; use Ibexa\Contracts\Core\Repository\LanguageResolver; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use ReflectionClass; use ReflectionMethod; @@ -31,6 +32,14 @@ abstract class AbstractServiceTestCase extends TestCase */ public const LANG_ARG = 0; + /** + * Sentinel method name yielded by {@see providerForLanguagesLookupMethods()} implementations + * that legitimately have no language-lookup methods to test; PHPUnit 11 treats an empty data + * provider as a hard error, so a single sentinel row is yielded instead and the two consuming + * test methods skip immediately when they see it. + */ + protected const string NO_DATA_METHOD = '__no_data__'; + /** @var \object|\PHPUnit\Framework\MockObject\MockObject */ protected $innerApiServiceMock; @@ -70,20 +79,20 @@ protected function tearDown(): void /** * @return array See signature on {@link testForPassTrough} for arguments and their type. */ - abstract public function providerForPassTroughMethods(); + abstract public static function providerForPassTroughMethods(); /** * Make sure these methods does nothing more then passing the arguments to inner service. * * Methods tested here are basically those without as languages argument. * - * @dataProvider providerForPassTroughMethods * * @param string $method * @param array $arguments * @param mixed $return */ - final public function testForPassTrough($method, array $arguments, $return = true) + #[DataProvider('providerForPassTroughMethods')] + final public function testForPassTrough($method, array $arguments, $return = true): void { if ($return) { $this->innerApiServiceMock @@ -109,7 +118,7 @@ final public function testForPassTrough($method, array $arguments, $return = tru * @return array See signature on {@link testForLanguagesLookup} for arguments and their type. * NOTE: languages / prioritizedLanguage, can be set to 0, it will be replaced by tests methods. */ - abstract public function providerForLanguagesLookupMethods(); + abstract public static function providerForLanguagesLookupMethods(); /** * Method to be able to customize the logic for setting expected language argument during {@see testForLanguagesLookup()}. @@ -143,10 +152,9 @@ protected function setLanguagesLookupArguments(array $arguments, $languageArgume } /** - * @dataProvider providerForLanguagesLookupMethods - * * @param array $arguments */ + #[DataProvider('providerForLanguagesLookupMethods')] final public function testForLanguagesLookup( string $method, array $arguments, @@ -154,7 +162,11 @@ final public function testForLanguagesLookup( int $languageArgumentIndex, ?callable $callback = null, ?int $alwaysAvailableArgumentIndex = null - ) { + ): void { + if ($method === self::NO_DATA_METHOD) { + self::markTestSkipped($arguments[0] ?? 'No language-lookup methods for this service.'); + } + $languages = ['eng-GB', 'eng-US']; $arguments = $this->setLanguagesLookupArguments($arguments, $languageArgumentIndex); @@ -211,10 +223,9 @@ protected function setLanguagesPassTroughArguments(array $arguments, $languageAr } /** - * @dataProvider providerForLanguagesLookupMethods - * * @param array $arguments */ + #[DataProvider('providerForLanguagesLookupMethods')] final public function testForLanguagesPassTrough( string $method, array $arguments, @@ -222,7 +233,11 @@ final public function testForLanguagesPassTrough( int $languageArgumentIndex, ?callable $callback = null, ?int $alwaysAvailableArgumentIndex = null - ) { + ): void { + if ($method === self::NO_DATA_METHOD) { + self::markTestSkipped($arguments[0] ?? 'No language-lookup methods for this service.'); + } + $languages = ['eng-GB', 'eng-US']; $arguments = $this->setLanguagesPassTroughArguments($arguments, $languageArgumentIndex, $languages); @@ -257,14 +272,27 @@ final public function testForLanguagesPassTrough( } } + /** + * @param iterable $data + * + * @return array + */ + private static function toArray(iterable $data): array + { + return is_array($data) ? $data : iterator_to_array($data); + } + /** * @todo replace with coverage testing (see EZP-31035) */ final public function testIfThereIsMissingTest(): void { $tested = array_merge( - array_column($this->providerForLanguagesLookupMethods(), 0), - array_column($this->providerForPassTroughMethods(), 0) + array_diff( + array_column(self::toArray($this->providerForLanguagesLookupMethods()), 0), + [self::NO_DATA_METHOD] + ), + array_column(self::toArray($this->providerForPassTroughMethods()), 0) ); $class = new ReflectionClass($this->getSiteAccessAwareServiceClassName()); diff --git a/tests/lib/Repository/SiteAccessAware/ContentServiceTest.php b/tests/lib/Repository/SiteAccessAware/ContentServiceTest.php index fb53e65a0e..f207ca146e 100644 --- a/tests/lib/Repository/SiteAccessAware/ContentServiceTest.php +++ b/tests/lib/Repository/SiteAccessAware/ContentServiceTest.php @@ -8,7 +8,6 @@ namespace Ibexa\Tests\Core\Repository\SiteAccessAware; use Ibexa\Contracts\Core\Repository\ContentService as APIService; -use Ibexa\Contracts\Core\Repository\Values\Content\Content; use Ibexa\Contracts\Core\Repository\Values\Content\ContentDraftList; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; use Ibexa\Contracts\Core\Repository\Values\Content\ContentList; @@ -16,12 +15,13 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Language; use Ibexa\Contracts\Core\Repository\Values\Content\LocationCreateStruct; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\ContentId; -use Ibexa\Contracts\Core\Repository\Values\Content\Relation; use Ibexa\Contracts\Core\Repository\Values\Content\RelationList; use Ibexa\Contracts\Core\Repository\Values\Filter\Filter; use Ibexa\Core\Repository\SiteAccessAware\ContentService; +use Ibexa\Core\Repository\Values\Content\Content as CoreContent; use Ibexa\Core\Repository\Values\Content\ContentCreateStruct; use Ibexa\Core\Repository\Values\Content\ContentUpdateStruct; +use Ibexa\Core\Repository\Values\Content\Relation as CoreRelation; use Ibexa\Core\Repository\Values\Content\VersionInfo; use Ibexa\Core\Repository\Values\ContentType\ContentType; use Ibexa\Core\Repository\Values\User\User; @@ -41,12 +41,12 @@ public function getSiteAccessAwareServiceClassName(): string return ContentService::class; } - public function providerForPassTroughMethods(): array + public static function providerForPassTroughMethods(): array { $contentInfo = new ContentInfo(); $versionInfo = new VersionInfo(); - $content = $this->createMock(Content::class); - $relation = $this->createMock(Relation::class); + $content = new CoreContent(); + $relation = new CoreRelation(); $relationList = new RelationList(); $contentCreateStruct = new ContentCreateStruct(); $contentUpdateStruct = new ContentUpdateStruct(); @@ -131,9 +131,9 @@ public function providerForPassTroughMethods(): array /** * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException */ - public function providerForLanguagesLookupMethods(): array + public static function providerForLanguagesLookupMethods(): array { - $content = $this->createMock(Content::class); + $content = new CoreContent(); $contentInfo = new ContentInfo(); $versionInfo = new VersionInfo(); diff --git a/tests/lib/Repository/SiteAccessAware/ContentTypeServiceTest.php b/tests/lib/Repository/SiteAccessAware/ContentTypeServiceTest.php index 8eb591567b..1b375e53ae 100644 --- a/tests/lib/Repository/SiteAccessAware/ContentTypeServiceTest.php +++ b/tests/lib/Repository/SiteAccessAware/ContentTypeServiceTest.php @@ -35,7 +35,7 @@ public function getSiteAccessAwareServiceClassName(): string return ContentTypeService::class; } - public function providerForPassTroughMethods() + public static function providerForPassTroughMethods(): array { $contentTypeGroupCreateStruct = new ContentTypeGroupCreateStruct(); $contentTypeGroupUpdateStruct = new ContentTypeGroupUpdateStruct(); @@ -107,7 +107,7 @@ public function providerForPassTroughMethods() ]; } - public function providerForLanguagesLookupMethods() + public static function providerForLanguagesLookupMethods(): array { $contentType = new ContentType(); $contentTypeGroup = new ContentTypeGroup(); diff --git a/tests/lib/Repository/SiteAccessAware/Language/LanguageResolverTest.php b/tests/lib/Repository/SiteAccessAware/Language/LanguageResolverTest.php index 9832182548..3abb3e154b 100644 --- a/tests/lib/Repository/SiteAccessAware/Language/LanguageResolverTest.php +++ b/tests/lib/Repository/SiteAccessAware/Language/LanguageResolverTest.php @@ -8,31 +8,31 @@ namespace Ibexa\Tests\Core\Repository\SiteAccessAware\Language; +use Ibexa\Core\Repository\SiteAccessAware\Language\AbstractLanguageResolver; use Ibexa\Core\Repository\SiteAccessAware\Language\LanguageResolver; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Repository\SiteAccessAware\Language\AbstractLanguageResolver - * @covers \Ibexa\Core\Repository\SiteAccessAware\Language\LanguageResolver - */ +#[CoversClass(AbstractLanguageResolver::class)] +#[CoversClass(LanguageResolver::class)] class LanguageResolverTest extends TestCase { /** - * @dataProvider getDataForTestGetPrioritizedLanguages - * * @param array $expectedPrioritizedLanguagesList * @param array $configLanguages * @param bool $defaultShowAllTranslations * @param array|null $forcedLanguages * @param string|null $contextLanguage */ + #[DataProvider('getDataForTestGetPrioritizedLanguages')] public function testGetPrioritizedLanguages( array $expectedPrioritizedLanguagesList, array $configLanguages, bool $defaultShowAllTranslations, ?array $forcedLanguages, ?string $contextLanguage - ) { + ): void { // note: "use always available" does not affect this test $defaultUseAlwaysAvailable = true; @@ -57,7 +57,7 @@ public function testGetPrioritizedLanguages( * * @return array */ - public function getDataForTestGetPrioritizedLanguages(): array + public static function getDataForTestGetPrioritizedLanguages(): array { return [ [ diff --git a/tests/lib/Repository/SiteAccessAware/LanguageServiceTest.php b/tests/lib/Repository/SiteAccessAware/LanguageServiceTest.php index b5ce70999a..658211a408 100644 --- a/tests/lib/Repository/SiteAccessAware/LanguageServiceTest.php +++ b/tests/lib/Repository/SiteAccessAware/LanguageServiceTest.php @@ -24,7 +24,7 @@ public function getSiteAccessAwareServiceClassName(): string return LanguageService::class; } - public function providerForPassTroughMethods() + public static function providerForPassTroughMethods(): array { $languageCreateStruct = new LanguageCreateStruct(); $language = new Language(); @@ -55,9 +55,12 @@ public function providerForPassTroughMethods() ]; } - public function providerForLanguagesLookupMethods() + /** + * @return iterable + */ + public static function providerForLanguagesLookupMethods(): iterable { // string $method, array $arguments, bool $return, int $languageArgumentIndex - return []; + yield [self::NO_DATA_METHOD, ['LanguageService has no language-lookup methods.'], null, 0]; } } diff --git a/tests/lib/Repository/SiteAccessAware/LocationServiceTest.php b/tests/lib/Repository/SiteAccessAware/LocationServiceTest.php index 4c8ccbb360..0409999203 100644 --- a/tests/lib/Repository/SiteAccessAware/LocationServiceTest.php +++ b/tests/lib/Repository/SiteAccessAware/LocationServiceTest.php @@ -30,7 +30,7 @@ public function getSiteAccessAwareServiceClassName(): string return LocationService::class; } - public function providerForPassTroughMethods(): array + public static function providerForPassTroughMethods(): array { $location = new Location(); $contentInfo = new ContentInfo(); @@ -68,7 +68,7 @@ public function providerForPassTroughMethods(): array ]; } - public function providerForLanguagesLookupMethods(): array + public static function providerForLanguagesLookupMethods(): array { $location = new Location(); $locationList = new LocationList(); diff --git a/tests/lib/Repository/SiteAccessAware/ObjectStateServiceTest.php b/tests/lib/Repository/SiteAccessAware/ObjectStateServiceTest.php index d564a08dee..be446ef321 100644 --- a/tests/lib/Repository/SiteAccessAware/ObjectStateServiceTest.php +++ b/tests/lib/Repository/SiteAccessAware/ObjectStateServiceTest.php @@ -29,7 +29,7 @@ public function getSiteAccessAwareServiceClassName(): string return ObjectStateService::class; } - public function providerForPassTroughMethods() + public static function providerForPassTroughMethods(): array { $objectStateGroupCreateStruct = new ObjectStateGroupCreateStruct(); $objectStateGroupUpdateStruct = new ObjectStateGroupUpdateStruct(); @@ -63,7 +63,7 @@ public function providerForPassTroughMethods() ]; } - public function providerForLanguagesLookupMethods() + public static function providerForLanguagesLookupMethods(): array { $objectStateGroup = new ObjectStateGroup(); $objectState = new ObjectState(); diff --git a/tests/lib/Repository/SiteAccessAware/SearchServiceTest.php b/tests/lib/Repository/SiteAccessAware/SearchServiceTest.php index 077985803a..6fff0c994c 100644 --- a/tests/lib/Repository/SiteAccessAware/SearchServiceTest.php +++ b/tests/lib/Repository/SiteAccessAware/SearchServiceTest.php @@ -26,7 +26,7 @@ public function getSiteAccessAwareServiceClassName(): string return SearchService::class; } - public function providerForPassTroughMethods() + public static function providerForPassTroughMethods(): array { // string $method, array $arguments, bool $return = true return [ @@ -35,7 +35,7 @@ public function providerForPassTroughMethods() ]; } - public function providerForLanguagesLookupMethods() + public static function providerForLanguagesLookupMethods(): array { $query = new Query(); $locationQuery = new LocationQuery(); diff --git a/tests/lib/Repository/SiteAccessAware/TrashServiceTest.php b/tests/lib/Repository/SiteAccessAware/TrashServiceTest.php index 1bba0c3595..1ac5baba8e 100644 --- a/tests/lib/Repository/SiteAccessAware/TrashServiceTest.php +++ b/tests/lib/Repository/SiteAccessAware/TrashServiceTest.php @@ -28,7 +28,7 @@ public function getSiteAccessAwareServiceClassName(): string return TrashService::class; } - public function providerForPassTroughMethods() + public static function providerForPassTroughMethods(): array { $location = new Location(); $newLocation = new Location(); @@ -49,9 +49,12 @@ public function providerForPassTroughMethods() ]; } - public function providerForLanguagesLookupMethods() + /** + * @return iterable + */ + public static function providerForLanguagesLookupMethods(): iterable { // string $method, array $arguments, bool $return, int $languageArgumentIndex - return []; + yield [self::NO_DATA_METHOD, ['TrashService has no language-lookup methods.'], null, 0]; } } diff --git a/tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php b/tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php index 62e31b8158..b89d9a229f 100644 --- a/tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php +++ b/tests/lib/Repository/SiteAccessAware/UrlAliasServiceTest.php @@ -24,7 +24,7 @@ public function getSiteAccessAwareServiceClassName(): string return URLAliasService::class; } - public function providerForPassTroughMethods() + public static function providerForPassTroughMethods(): array { $location = new Location(); $urlAlias = new URLAlias(); @@ -42,7 +42,7 @@ public function providerForPassTroughMethods() ]; } - public function providerForLanguagesLookupMethods() + public static function providerForLanguagesLookupMethods(): array { $location = new Location(); $urlAlias = new URLAlias(); diff --git a/tests/lib/Repository/SiteAccessAware/UserServiceTest.php b/tests/lib/Repository/SiteAccessAware/UserServiceTest.php index e273a4e954..ce9f0cf4e9 100644 --- a/tests/lib/Repository/SiteAccessAware/UserServiceTest.php +++ b/tests/lib/Repository/SiteAccessAware/UserServiceTest.php @@ -34,7 +34,7 @@ public function getSiteAccessAwareServiceClassName(): string return UserService::class; } - public function providerForPassTroughMethods() + public static function providerForPassTroughMethods(): array { $userGroupCreateStruct = new UserGroupCreateStruct(); $userGroupUpdateStruct = new UserGroupUpdateStruct(); @@ -46,7 +46,7 @@ public function providerForPassTroughMethods() $userTokenUpdateStruct = new UserTokenUpdateStruct(); $user = new User(); $userId = 14; - $contentType = $this->createMock(ContentType::class); + $contentType = new ContentType(); $passwordValidationContext = new PasswordValidationContext(); $passwordExpirationDate = (new DateTime())->add(new DateInterval('P30D')); @@ -84,7 +84,7 @@ public function providerForPassTroughMethods() ]; } - public function providerForLanguagesLookupMethods() + public static function providerForLanguagesLookupMethods(): array { $userGroup = new UserGroup(); $user = new User(); diff --git a/tests/lib/Repository/Strategy/Publication/ChainContentPublicationStrategyTest.php b/tests/lib/Repository/Strategy/Publication/ChainContentPublicationStrategyTest.php index 4fdbe1e1d3..2c45dc86b7 100644 --- a/tests/lib/Repository/Strategy/Publication/ChainContentPublicationStrategyTest.php +++ b/tests/lib/Repository/Strategy/Publication/ChainContentPublicationStrategyTest.php @@ -19,7 +19,7 @@ final class ChainContentPublicationStrategyTest extends TestCase { public function testPublishVersionExecutesFirstSupportingStrategy(): void { - $versionInfo = $this->createStub(VersionInfo::class); + $versionInfo = self::createStub(VersionInfo::class); $result = new ContentPublicationResult(null); $notSupportingStrategy = $this->createMock(ContentPublicationStrategyInterface::class); @@ -101,6 +101,6 @@ public function testPublishVersionThrowsLogicExceptionWhenNoStrategySupports(): $this->expectException(LogicException::class); $this->expectExceptionMessage('No content publication strategy supports the current publication.'); - $chain->publishVersion($this->createMock(VersionInfo::class)); + $chain->publishVersion(self::createStub(VersionInfo::class)); } } diff --git a/tests/lib/Repository/Strategy/Publication/SynchronousContentPublicationStrategyTest.php b/tests/lib/Repository/Strategy/Publication/SynchronousContentPublicationStrategyTest.php index 27bc27b868..a7d4a17ace 100644 --- a/tests/lib/Repository/Strategy/Publication/SynchronousContentPublicationStrategyTest.php +++ b/tests/lib/Repository/Strategy/Publication/SynchronousContentPublicationStrategyTest.php @@ -13,6 +13,7 @@ use Ibexa\Contracts\Core\Repository\Values\Content\Language; use Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo; use Ibexa\Core\Repository\Strategy\ContentPublication\SynchronousContentPublicationStrategy; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; final class SynchronousContentPublicationStrategyTest extends TestCase @@ -20,24 +21,23 @@ final class SynchronousContentPublicationStrategyTest extends TestCase public function testSupportsAlwaysReturnsTrue(): void { $strategy = new SynchronousContentPublicationStrategy( - $this->createStub(ContentService::class) + self::createStub(ContentService::class) ); self::assertTrue($strategy->supports()); } /** - * @dataProvider providerForTestPublishVersionDelegatesToContentService - * * @param list|null $translations * @param list $expectedTranslations */ + #[DataProvider('providerForTestPublishVersionDelegatesToContentService')] public function testPublishVersionDelegatesToContentService( ?array $translations, array $expectedTranslations ): void { - $versionInfo = $this->createStub(VersionInfo::class); - $content = $this->createStub(Content::class); + $versionInfo = self::createStub(VersionInfo::class); + $content = self::createStub(Content::class); $contentService = $this->createMock(ContentService::class); $contentService diff --git a/tests/lib/Repository/Values/Content/ContentInfoTest.php b/tests/lib/Repository/Values/Content/ContentInfoTest.php index bf8de1afbe..5174aff00c 100644 --- a/tests/lib/Repository/Values/Content/ContentInfoTest.php +++ b/tests/lib/Repository/Values/Content/ContentInfoTest.php @@ -10,11 +10,10 @@ use DateTimeImmutable; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo - */ +#[CoversClass(ContentInfo::class)] final class ContentInfoTest extends TestCase { public function testCreateObject(): void diff --git a/tests/lib/Repository/Values/Content/ContentTest.php b/tests/lib/Repository/Values/Content/ContentTest.php index f1bdd191d1..5c5de44d41 100644 --- a/tests/lib/Repository/Values/Content/ContentTest.php +++ b/tests/lib/Repository/Values/Content/ContentTest.php @@ -13,11 +13,10 @@ use Ibexa\Core\FieldType\TextLine\Value as TextLineValue; use Ibexa\Core\Repository\Values\Content\Content; use Ibexa\Core\Repository\Values\Content\VersionInfo; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Repository\Values\Content\Content - */ +#[CoversClass(Content::class)] final class ContentTest extends TestCase { /** @var \Ibexa\Contracts\Core\Repository\Values\Content\Field[] */ diff --git a/tests/lib/Repository/Values/Content/LanguageTest.php b/tests/lib/Repository/Values/Content/LanguageTest.php index 5132390dcc..759203ed58 100644 --- a/tests/lib/Repository/Values/Content/LanguageTest.php +++ b/tests/lib/Repository/Values/Content/LanguageTest.php @@ -11,11 +11,10 @@ use Ibexa\Contracts\Core\Repository\Exceptions\PropertyReadOnlyException; use Ibexa\Contracts\Core\Repository\Values\Content\Language; use Ibexa\Tests\Core\Repository\Values\ValueObjectTestTrait; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Contracts\Core\Repository\Values\Content\Language - */ +#[CoversClass(Language::class)] class LanguageTest extends TestCase { use ValueObjectTestTrait; @@ -23,7 +22,7 @@ class LanguageTest extends TestCase /** * Test retrieving missing property. */ - public function testMissingProperty() + public function testMissingProperty(): void { $this->expectException(PropertyNotFoundException::class); $this->expectExceptionMessage('Property \'notDefined\' not found on class'); @@ -37,7 +36,7 @@ public function testMissingProperty() /** * Test setting read only property. */ - public function testReadOnlyProperty() + public function testReadOnlyProperty(): void { $this->expectException(PropertyReadOnlyException::class); $this->expectExceptionMessage('Property \'id\' is readonly on class'); @@ -50,7 +49,7 @@ public function testReadOnlyProperty() /** * Test if property exists. */ - public function testIsPropertySet() + public function testIsPropertySet(): void { $language = new Language(); /** @phpstan-ignore property.notFound */ @@ -64,7 +63,7 @@ public function testIsPropertySet() /** * Test unsetting a property. */ - public function testUnsetProperty() + public function testUnsetProperty(): void { $this->expectException(PropertyReadOnlyException::class); $this->expectExceptionMessage('Property \'id\' is readonly on class'); diff --git a/tests/lib/Repository/Values/Content/LocationTest.php b/tests/lib/Repository/Values/Content/LocationTest.php index aeb9f3cf70..df5a1409cf 100644 --- a/tests/lib/Repository/Values/Content/LocationTest.php +++ b/tests/lib/Repository/Values/Content/LocationTest.php @@ -13,11 +13,11 @@ use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; use Ibexa\Core\Repository\Values\Content\Location; use Ibexa\Tests\Core\Repository\Values\ValueObjectTestTrait; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Repository\Values\Content\Location - */ +#[CoversClass(Location::class)] final class LocationTest extends TestCase { use ValueObjectTestTrait; @@ -73,10 +73,9 @@ public static function getDataForTestPathComputedPropertyGetter(): iterable } /** - * @dataProvider getDataForTestPathComputedPropertyGetter - * * @param string[] $expectedPathValue */ + #[DataProvider('getDataForTestPathComputedPropertyGetter')] public function testPathComputedPropertyGetter(Location $location, array $expectedPathValue): void { self::assertSame($expectedPathValue, $location->getPath()); @@ -97,8 +96,6 @@ public function testMissingProperty(): void /** * Test setting read only property. - * - * @covers \Ibexa\Core\Repository\Values\Content\Location::__set */ public function testReadOnlyProperty(): void { @@ -125,8 +122,6 @@ public function testIsPropertySet(): void /** * Test unsetting a property. - * - * @covers \Ibexa\Core\Repository\Values\Content\Location::__unset */ public function testUnsetProperty(): void { diff --git a/tests/lib/Repository/Values/Content/Query/Aggregation/Location/SubtreeTermAggregationTest.php b/tests/lib/Repository/Values/Content/Query/Aggregation/Location/SubtreeTermAggregationTest.php index 7aef2b0111..ee6c0e392e 100644 --- a/tests/lib/Repository/Values/Content/Query/Aggregation/Location/SubtreeTermAggregationTest.php +++ b/tests/lib/Repository/Values/Content/Query/Aggregation/Location/SubtreeTermAggregationTest.php @@ -32,7 +32,7 @@ public function testConstruct(): void public function testConstructThrowsInvalidArgumentExceptionOnInvalidPathString(): void { $this->expectException(InvalidArgumentException::class); - $this->expectErrorMessage("'/INVALID/PATH' value must follow the path string format, e.g. /1/2/"); + $this->expectExceptionMessage("'/INVALID/PATH' value must follow the path string format, e.g. /1/2/"); $aggregation = new SubtreeTermAggregation('foo', '/INVALID/PATH'); } diff --git a/tests/lib/Repository/Values/Content/Query/Aggregation/RangeTest.php b/tests/lib/Repository/Values/Content/Query/Aggregation/RangeTest.php index eef108e6ec..801d0129f0 100644 --- a/tests/lib/Repository/Values/Content/Query/Aggregation/RangeTest.php +++ b/tests/lib/Repository/Values/Content/Query/Aggregation/RangeTest.php @@ -10,15 +10,15 @@ use DateTimeImmutable; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Aggregation\Range; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; final class RangeTest extends TestCase { /** - * @dataProvider dataProviderForTestToString - * * @phpstan-param \Ibexa\Contracts\Core\Repository\Values\Content\Query\Aggregation\Range $range */ + #[DataProvider('dataProviderForTestToString')] public function testToString(Range $range, string $expected): void { self::assertEquals($expected, (string)$range); @@ -27,7 +27,7 @@ public function testToString(Range $range, string $expected): void /** * @return iterable, string}> */ - public function dataProviderForTestToString(): iterable + public static function dataProviderForTestToString(): iterable { yield 'empty' => [ new Range(null, null), @@ -78,11 +78,10 @@ public function testOfDateTime(): void } /** - * @dataProvider dataProviderForEqualsTo - * * @phpstan-param \Ibexa\Contracts\Core\Repository\Values\Content\Query\Aggregation\Range $rangeA * @phpstan-param \Ibexa\Contracts\Core\Repository\Values\Content\Query\Aggregation\Range $rangeB */ + #[DataProvider('dataProviderForEqualsTo')] public function testEqualsTo(Range $rangeA, Range $rangeB, bool $expectedResult): void { self::assertEquals($expectedResult, $rangeA->equalsTo($rangeB)); @@ -92,7 +91,7 @@ public function testEqualsTo(Range $rangeA, Range $rangeB, bool $expectedResult) /** * @return iterable, \Ibexa\Contracts\Core\Repository\Values\Content\Query\Aggregation\Range, bool}> */ - public function dataProviderForEqualsTo(): iterable + public static function dataProviderForEqualsTo(): iterable { yield 'int (true)' => [ Range::ofInt(1, 10), diff --git a/tests/lib/Repository/Values/Content/Query/Criterion/DateMetadataTest.php b/tests/lib/Repository/Values/Content/Query/Criterion/DateMetadataTest.php index ccf8f75215..5cada87bb1 100644 --- a/tests/lib/Repository/Values/Content/Query/Criterion/DateMetadataTest.php +++ b/tests/lib/Repository/Values/Content/Query/Criterion/DateMetadataTest.php @@ -8,13 +8,12 @@ namespace Ibexa\Tests\Core\Repository\Values\Content\Query\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\DateMetadata; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; final class DateMetadataTest extends TestCase { - /** - * @dataProvider provideValidConstructorArguments - */ + #[DataProvider('provideValidConstructorArguments')] public function testConstruction(string $target, string $operator, $value): void { $criterion = new DateMetadata($target, $operator, $value); diff --git a/tests/lib/Repository/Values/Content/SectionTest.php b/tests/lib/Repository/Values/Content/SectionTest.php index f9d1844392..3662264798 100644 --- a/tests/lib/Repository/Values/Content/SectionTest.php +++ b/tests/lib/Repository/Values/Content/SectionTest.php @@ -11,18 +11,18 @@ use Ibexa\Contracts\Core\Repository\Exceptions\PropertyReadOnlyException; use Ibexa\Contracts\Core\Repository\Values\Content\Section; use Ibexa\Tests\Core\Repository\Values\ValueObjectTestTrait; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; +#[CoversClass(Section::class)] class SectionTest extends TestCase { use ValueObjectTestTrait; /** * Test retrieving missing property. - * - * @covers \Ibexa\Contracts\Core\Repository\Values\Content\Section::__get */ - public function testMissingProperty() + public function testMissingProperty(): void { $this->expectException(PropertyNotFoundException::class); @@ -34,10 +34,8 @@ public function testMissingProperty() /** * Test setting read only property. - * - * @covers \Ibexa\Contracts\Core\Repository\Values\Content\Section::__set */ - public function testReadOnlyProperty() + public function testReadOnlyProperty(): void { $this->expectException(PropertyReadOnlyException::class); @@ -48,10 +46,8 @@ public function testReadOnlyProperty() /** * Test if property exists. - * - * @covers \Ibexa\Contracts\Core\Repository\Values\Content\Section::__isset */ - public function testIsPropertySet() + public function testIsPropertySet(): void { $section = new Section(); /** @phpstan-ignore property.notFound */ @@ -64,10 +60,8 @@ public function testIsPropertySet() /** * Test unsetting a property. - * - * @covers \Ibexa\Contracts\Core\Repository\Values\Content\Section::__unset */ - public function testUnsetProperty() + public function testUnsetProperty(): void { $this->expectException(PropertyReadOnlyException::class); diff --git a/tests/lib/Repository/Values/Content/TrashItemTest.php b/tests/lib/Repository/Values/Content/TrashItemTest.php index b375fac104..ea61687c9b 100644 --- a/tests/lib/Repository/Values/Content/TrashItemTest.php +++ b/tests/lib/Repository/Values/Content/TrashItemTest.php @@ -11,11 +11,10 @@ use Ibexa\Contracts\Core\Repository\Exceptions\PropertyReadOnlyException; use Ibexa\Core\Repository\Values\Content\TrashItem; use Ibexa\Tests\Core\Repository\Values\ValueObjectTestTrait; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Repository\Values\Content\TrashItem - */ +#[CoversClass(TrashItem::class)] class TrashItemTest extends TestCase { use ValueObjectTestTrait; @@ -23,7 +22,7 @@ class TrashItemTest extends TestCase /** * Test retrieving missing property. */ - public function testMissingProperty() + public function testMissingProperty(): void { $this->expectException(PropertyNotFoundException::class); @@ -36,7 +35,7 @@ public function testMissingProperty() /** * Test setting read only property. */ - public function testReadOnlyProperty() + public function testReadOnlyProperty(): void { $this->expectException(PropertyReadOnlyException::class); @@ -48,7 +47,7 @@ public function testReadOnlyProperty() /** * Test if property exists. */ - public function testIsPropertySet() + public function testIsPropertySet(): void { $trashItem = new TrashItem(); /** @phpstan-ignore property.notFound */ @@ -61,10 +60,8 @@ public function testIsPropertySet() /** * Test unsetting a property. - * - * @covers \Ibexa\Core\Repository\Values\Content\TrashItem::__unset */ - public function testUnsetProperty() + public function testUnsetProperty(): void { $this->expectException(PropertyReadOnlyException::class); diff --git a/tests/lib/Repository/Values/Content/VersionInfoTest.php b/tests/lib/Repository/Values/Content/VersionInfoTest.php index 517811353f..1fec3bb302 100644 --- a/tests/lib/Repository/Values/Content/VersionInfoTest.php +++ b/tests/lib/Repository/Values/Content/VersionInfoTest.php @@ -9,11 +9,10 @@ namespace Ibexa\Tests\Core\Repository\Values\Content; use Ibexa\Core\Repository\Values\Content\VersionInfo; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Repository\Values\Content\VersionInfo - */ +#[CoversClass(VersionInfo::class)] final class VersionInfoTest extends TestCase { public function testIsDraft(): void diff --git a/tests/lib/Repository/Values/ContentType/ContentTypeTest.php b/tests/lib/Repository/Values/ContentType/ContentTypeTest.php index 787d16842d..c3f1b0b725 100644 --- a/tests/lib/Repository/Values/ContentType/ContentTypeTest.php +++ b/tests/lib/Repository/Values/ContentType/ContentTypeTest.php @@ -12,11 +12,11 @@ use Ibexa\Contracts\Core\Repository\Values\ContentType\FieldDefinitionCollection as APIFieldDefinitionCollection; use Ibexa\Core\Repository\Values\ContentType\ContentType; use Ibexa\Core\Repository\Values\ContentType\ContentTypeDraft; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Repository\Values\ContentType\ContentType - */ +#[CoversClass(ContentType::class)] final class ContentTypeTest extends TestCase { private const string EXAMPLE_FIELD_DEFINITION_IDENTIFIER = 'example'; @@ -32,7 +32,7 @@ public function testStrictGetters(): void public function testGetFieldDefinition(): void { - $fieldDefinition = $this->createMock(FieldDefinition::class); + $fieldDefinition = self::createStub(FieldDefinition::class); $fieldDefinitionCollection = $this->createMock(APIFieldDefinitionCollection::class); @@ -96,7 +96,7 @@ public function testHasFieldDefinitionOfType(): void public function testGetFieldDefinitionsOfType(): void { - $expectedFieldDefinitionCollection = $this->createMock(APIFieldDefinitionCollection::class); + $expectedFieldDefinitionCollection = self::createStub(APIFieldDefinitionCollection::class); $fieldDefinitionCollection = $this->createMock(APIFieldDefinitionCollection::class); $fieldDefinitionCollection @@ -117,7 +117,7 @@ public function testGetFieldDefinitionsOfType(): void public function testGetFirstFieldDefinitionOfType(): void { - $expectedFieldDefinition = $this->createMock(FieldDefinition::class); + $expectedFieldDefinition = self::createStub(FieldDefinition::class); $filteredFieldDefinitionCollection = $this->createMock(APIFieldDefinitionCollection::class); $filteredFieldDefinitionCollection @@ -141,9 +141,7 @@ public function testGetFirstFieldDefinitionOfType(): void ); } - /** - * @dataProvider provideForDeprecatedPropertyAccessMatchesMethodCallResult - */ + #[DataProvider('provideForDeprecatedPropertyAccessMatchesMethodCallResult')] public function testDeprecatedPropertyAccessMatchesMethodCallResult(bool $isContainer): void { $contentTypeDraft = new ContentTypeDraft([ @@ -162,7 +160,7 @@ public function testDeprecatedPropertyAccessMatchesMethodCallResult(bool $isCont /** * @return iterable */ - public function provideForDeprecatedPropertyAccessMatchesMethodCallResult(): iterable + public static function provideForDeprecatedPropertyAccessMatchesMethodCallResult(): iterable { yield 'content type draft is a container' => [true]; yield 'content type draft is not a container' => [false]; diff --git a/tests/lib/Repository/Values/ContentType/FieldDefinitionCollectionTest.php b/tests/lib/Repository/Values/ContentType/FieldDefinitionCollectionTest.php index a4a02f449d..bc0c1bc8dd 100644 --- a/tests/lib/Repository/Values/ContentType/FieldDefinitionCollectionTest.php +++ b/tests/lib/Repository/Values/ContentType/FieldDefinitionCollectionTest.php @@ -13,11 +13,10 @@ use Ibexa\Contracts\Core\Repository\Values\ContentType\FieldDefinition as APIFieldDefinition; use Ibexa\Core\Repository\Values\ContentType\FieldDefinition; use Ibexa\Core\Repository\Values\ContentType\FieldDefinitionCollection; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Repository\Values\ContentType\FieldDefinitionCollection - */ +#[CoversClass(FieldDefinitionCollection::class)] final class FieldDefinitionCollectionTest extends TestCase { public function testGet(): void diff --git a/tests/lib/Repository/Values/ContentType/FieldDefinitionTest.php b/tests/lib/Repository/Values/ContentType/FieldDefinitionTest.php index 6634f3bdfa..f297cf6703 100644 --- a/tests/lib/Repository/Values/ContentType/FieldDefinitionTest.php +++ b/tests/lib/Repository/Values/ContentType/FieldDefinitionTest.php @@ -10,16 +10,15 @@ use Ibexa\Core\FieldType\Value as BaseFieldValue; use Ibexa\Core\Repository\Values\ContentType\FieldDefinition; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Repository\Values\ContentType\FieldDefinition - */ +#[CoversClass(FieldDefinition::class)] final class FieldDefinitionTest extends TestCase { public function testStrictGetters(): void { - $defaultValueMock = $this->createMock(BaseFieldValue::class); + $defaultValueMock = self::createStub(BaseFieldValue::class); $fieldDefinition = new FieldDefinition( [ 'id' => 123, diff --git a/tests/lib/Repository/Values/Filter/FilterTest.php b/tests/lib/Repository/Values/Filter/FilterTest.php index a6d29af580..468d329a43 100644 --- a/tests/lib/Repository/Values/Filter/FilterTest.php +++ b/tests/lib/Repository/Values/Filter/FilterTest.php @@ -17,12 +17,12 @@ use Ibexa\Contracts\Core\Repository\Values\Filter\FilteringCriterion; use Ibexa\Contracts\Core\Repository\Values\URL\Query\SortClause as URLQuerySortClause; use function md5; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use function sprintf; -/** - * @covers \Ibexa\Contracts\Core\Repository\Values\Filter\Filter - */ +#[CoversClass(Filter::class)] final class FilterTest extends TestCase { /** @@ -43,10 +43,9 @@ public function testConstructor(): void } /** - * @dataProvider getInvalidSortClausesData - * * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException */ + #[DataProvider('getInvalidSortClausesData')] public function testConstructorThrowsBadStateException( array $sortClauses, string $expectedExceptionMessage @@ -57,7 +56,7 @@ public function testConstructorThrowsBadStateException( return new Filter(new Criterion\ParentLocationId(3), $sortClauses); } - public function getInvalidSortClausesData(): iterable + public static function getInvalidSortClausesData(): iterable { yield [ [ @@ -183,10 +182,9 @@ public function testWithSortClause(): Filter } /** - * @dataProvider getComplexFilterTestData - * * @param \Ibexa\Contracts\Core\Repository\Values\Content\Query\SortClause[] $expectedSortClauses */ + #[DataProvider('getComplexFilterTestData')] public function testBuildingComplexFilter( Filter $filter, ?Query\CriterionInterface $expectedCriterion, @@ -204,7 +202,7 @@ public function testBuildingComplexFilter( * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException * @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException */ - public function getComplexFilterTestData(): iterable + public static function getComplexFilterTestData(): iterable { $parent1Criterion = new Criterion\ParentLocationId(1); $engGBCriterion = new Criterion\LanguageCode('eng-GB'); @@ -334,9 +332,7 @@ public function getComplexFilterTestData(): iterable ]; } - /** - * @dataProvider getFiltersWithInvalidSliceData - */ + #[DataProvider('getFiltersWithInvalidSliceData')] public function testSliceByThrowsInvalidArgumentException( int $limit, int $offset, @@ -350,7 +346,7 @@ public function testSliceByThrowsInvalidArgumentException( $filter->sliceBy($limit, $offset); } - public function getFiltersWithInvalidSliceData(): iterable + public static function getFiltersWithInvalidSliceData(): iterable { yield [-1, 0, 'Argument \'$limit\' is invalid: Filtering slice limit needs to be >=0, got -1']; yield [0, -1, 'Argument \'$offset\' is invalid: Filtering slice offset needs to be >=0, got -1']; @@ -364,9 +360,7 @@ public function getFiltersWithInvalidSliceData(): iterable ]; } - /** - * @dataProvider getFilters - */ + #[DataProvider('getFilters')] public function testReset(Filter $filter): void { $filter->reset(); @@ -376,9 +370,7 @@ public function testReset(Filter $filter): void self::assertSame(0, $filter->getLimit()); } - /** - * @dataProvider getFilters - */ + #[DataProvider('getFilters')] public function testClone(Filter $filter): void { $clonedFilter = clone $filter; @@ -397,7 +389,7 @@ public function testClone(Filter $filter): void /** * @throws \Ibexa\Contracts\Core\Repository\Exceptions\BadStateException */ - public function getFilters(): iterable + public static function getFilters(): iterable { $criterion = new Criterion\LogicalAnd( [ diff --git a/tests/lib/Repository/Values/MultiLanguageTestTrait.php b/tests/lib/Repository/Values/MultiLanguageTestTrait.php index 24495987c7..b008679e88 100644 --- a/tests/lib/Repository/Values/MultiLanguageTestTrait.php +++ b/tests/lib/Repository/Values/MultiLanguageTestTrait.php @@ -9,6 +9,7 @@ use Ibexa\Contracts\Core\Repository\Values\MultiLanguageDescription; use Ibexa\Contracts\Core\Repository\Values\MultiLanguageName; +use PHPUnit\Framework\Attributes\Depends; use ReflectionClass; /** @@ -19,11 +20,10 @@ trait MultiLanguageTestTrait { /** - * @depends testNewClassWithMultiLanguageProperties - * * @param \Ibexa\Contracts\Core\Repository\Values\MultiLanguageName $object tested ValueObject */ - public function testGetMultiLanguagePrioritizedName($object) + #[Depends('testNewClassWithMultiLanguageProperties')] + public function testGetMultiLanguagePrioritizedName($object): void { if (!$object instanceof MultiLanguageName) { self::markTestSkipped( @@ -38,11 +38,10 @@ public function testGetMultiLanguagePrioritizedName($object) } /** - * @depends testNewClassWithMultiLanguageProperties - * * @param \Ibexa\Contracts\Core\Repository\Values\MultiLanguageName $object tested ValueObject */ - public function testGetMultiLanguageDefaultName($object) + #[Depends('testNewClassWithMultiLanguageProperties')] + public function testGetMultiLanguageDefaultName($object): void { if (!$object instanceof MultiLanguageName) { self::markTestSkipped( @@ -68,11 +67,10 @@ public function testGetMultiLanguageDefaultName($object) } /** - * @depends testNewClassWithMultiLanguageProperties - * * @param \Ibexa\Contracts\Core\Repository\Values\MultiLanguageDescription $object tested ValueObject */ - public function testGetMultiLanguagePrioritizedDescription($object) + #[Depends('testNewClassWithMultiLanguageProperties')] + public function testGetMultiLanguagePrioritizedDescription($object): void { if (!$object instanceof MultiLanguageDescription) { self::markTestSkipped( @@ -87,11 +85,10 @@ public function testGetMultiLanguagePrioritizedDescription($object) } /** - * @depends testNewClassWithMultiLanguageProperties - * * @param \Ibexa\Contracts\Core\Repository\Values\MultiLanguageDescription $object tested ValueObject */ - public function testGetMultiLanguageDefaultDescription($object) + #[Depends('testNewClassWithMultiLanguageProperties')] + public function testGetMultiLanguageDefaultDescription($object): void { if (!$object instanceof MultiLanguageDescription) { self::markTestSkipped( diff --git a/tests/lib/Repository/Values/ObjectState/ObjectStateGroupTest.php b/tests/lib/Repository/Values/ObjectState/ObjectStateGroupTest.php index a5b2b81145..edc72682a9 100644 --- a/tests/lib/Repository/Values/ObjectState/ObjectStateGroupTest.php +++ b/tests/lib/Repository/Values/ObjectState/ObjectStateGroupTest.php @@ -12,11 +12,10 @@ use Ibexa\Core\Repository\Values\ObjectState\ObjectStateGroup; use Ibexa\Tests\Core\Repository\Values\MultiLanguageTestTrait; use Ibexa\Tests\Core\Repository\Values\ValueObjectTestTrait; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Repository\Values\ObjectState\ObjectStateGroup - */ +#[CoversClass(ObjectStateGroup::class)] class ObjectStateGroupTest extends TestCase { use ValueObjectTestTrait; @@ -25,7 +24,7 @@ class ObjectStateGroupTest extends TestCase /** * Test a new class and default values on properties. */ - public function testNewClass() + public function testNewClass(): void { $objectStateGroup = new ObjectStateGroup(); @@ -74,10 +73,8 @@ public function testNewClassWithMultiLanguageProperties() /** * Test retrieving missing property. - * - * @covers \Ibexa\Core\Repository\Values\ObjectState\ObjectStateGroup::__get */ - public function testMissingProperty() + public function testMissingProperty(): void { $this->expectException(PropertyNotFoundException::class); @@ -89,10 +86,8 @@ public function testMissingProperty() /** * Test setting read only property. - * - * @covers \Ibexa\Core\Repository\Values\ObjectState\ObjectStateGroup::__set */ - public function testReadOnlyProperty() + public function testReadOnlyProperty(): void { $this->expectException(PropertyReadOnlyException::class); @@ -104,7 +99,7 @@ public function testReadOnlyProperty() /** * Test if property exists. */ - public function testIsPropertySet() + public function testIsPropertySet(): void { $objectStateGroup = new ObjectStateGroup(); /** @phpstan-ignore property.notFound */ @@ -117,10 +112,8 @@ public function testIsPropertySet() /** * Test unsetting a property. - * - * @covers \Ibexa\Core\Repository\Values\ObjectState\ObjectStateGroup::__unset */ - public function testUnsetProperty() + public function testUnsetProperty(): void { $this->expectException(PropertyReadOnlyException::class); diff --git a/tests/lib/Repository/Values/ObjectState/ObjectStateTest.php b/tests/lib/Repository/Values/ObjectState/ObjectStateTest.php index 3dd7a34063..7e64cea6c3 100644 --- a/tests/lib/Repository/Values/ObjectState/ObjectStateTest.php +++ b/tests/lib/Repository/Values/ObjectState/ObjectStateTest.php @@ -9,14 +9,17 @@ use Ibexa\Contracts\Core\Repository\Exceptions\PropertyNotFoundException; use Ibexa\Contracts\Core\Repository\Exceptions\PropertyReadOnlyException; +use Ibexa\Contracts\Core\Repository\Values\ObjectState\ObjectStateGroup as CoveredObjectStateGroup; use Ibexa\Core\Repository\Values\ObjectState\ObjectState; +use Ibexa\Core\Repository\Values\ObjectState\ObjectStateGroup; use Ibexa\Tests\Core\Repository\Values\MultiLanguageTestTrait; use Ibexa\Tests\Core\Repository\Values\ValueObjectTestTrait; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Repository\Values\ObjectState\ObjectState - */ +#[CoversClass(ObjectState::class)] +#[CoversClass(ObjectStateGroup::class)] +#[CoversClass(CoveredObjectStateGroup::class)] class ObjectStateTest extends TestCase { use ValueObjectTestTrait; @@ -25,7 +28,7 @@ class ObjectStateTest extends TestCase /** * Test a new class and default values on properties. */ - public function testNewClass() + public function testNewClass(): void { $objectState = new ObjectState(); @@ -75,11 +78,8 @@ public function testNewClassWithMultiLanguageProperties() /** * Test retrieving missing property. - * - * @covers \Ibexa\Core\Repository\Values\ObjectState\ObjectState::__get - * @covers \Ibexa\Core\Repository\Values\ObjectState\ObjectStateGroup::__get */ - public function testMissingProperty() + public function testMissingProperty(): void { $this->expectException(PropertyNotFoundException::class); @@ -91,11 +91,8 @@ public function testMissingProperty() /** * Test setting read only property. - * - * @covers \Ibexa\Core\Repository\Values\ObjectState\ObjectState::__set - * @covers \Ibexa\Core\Repository\Values\ObjectState\ObjectStateGroup::__set */ - public function testReadOnlyProperty() + public function testReadOnlyProperty(): void { $this->expectException(PropertyReadOnlyException::class); @@ -107,7 +104,7 @@ public function testReadOnlyProperty() /** * Test if property exists. */ - public function testIsPropertySet() + public function testIsPropertySet(): void { $objectState = new ObjectState(); /** @phpstan-ignore property.notFound */ @@ -120,11 +117,8 @@ public function testIsPropertySet() /** * Test unsetting a property. - * - * @covers \Ibexa\Core\Repository\Values\ObjectState\ObjectState::__unset - * @covers \Ibexa\Contracts\Core\Repository\Values\ObjectState\ObjectStateGroup::__unset */ - public function testUnsetProperty() + public function testUnsetProperty(): void { $this->expectException(PropertyReadOnlyException::class); diff --git a/tests/lib/Repository/Values/Translation/MessageTest.php b/tests/lib/Repository/Values/Translation/MessageTest.php index cfd2b52f09..fb1c7da832 100644 --- a/tests/lib/Repository/Values/Translation/MessageTest.php +++ b/tests/lib/Repository/Values/Translation/MessageTest.php @@ -9,18 +9,17 @@ namespace Ibexa\Tests\Core\Repository\Values\Translation; use Ibexa\Contracts\Core\Repository\Values\Translation\Message; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Contracts\Core\Repository\Values\Translation\Message - */ +#[CoversClass(Message::class)] final class MessageTest extends TestCase { /** - * @dataProvider getDataForTestMessage - * * @param array $values */ + #[DataProvider('getDataForTestMessage')] public function testStringable( string $message, array $values, @@ -30,10 +29,9 @@ public function testStringable( } /** - * @dataProvider getDataForTestMessage - * * @param array $values */ + #[DataProvider('getDataForTestMessage')] public function testGetters(string $message, array $values): void { $translation = new Message($message, $values); diff --git a/tests/lib/Repository/Values/Translation/PluralTest.php b/tests/lib/Repository/Values/Translation/PluralTest.php index 26acfd14f3..0984936fb7 100644 --- a/tests/lib/Repository/Values/Translation/PluralTest.php +++ b/tests/lib/Repository/Values/Translation/PluralTest.php @@ -9,18 +9,17 @@ namespace Ibexa\Tests\Core\Repository\Values\Translation; use Ibexa\Contracts\Core\Repository\Values\Translation\Plural; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Contracts\Core\Repository\Values\Translation\Plural - */ +#[CoversClass(Plural::class)] final class PluralTest extends TestCase { /** - * @dataProvider getDataForTestPlural - * * @param array $values */ + #[DataProvider('getDataForTestPlural')] public function testStringable( string $singular, string $plural, @@ -31,10 +30,9 @@ public function testStringable( } /** - * @dataProvider getDataForTestPlural - * * @param array $values */ + #[DataProvider('getDataForTestPlural')] public function testGetters( string $singular, string $plural, diff --git a/tests/lib/Repository/Values/User/PolicyTest.php b/tests/lib/Repository/Values/User/PolicyTest.php index 3a0ff9bbca..867927856b 100644 --- a/tests/lib/Repository/Values/User/PolicyTest.php +++ b/tests/lib/Repository/Values/User/PolicyTest.php @@ -11,18 +11,18 @@ use Ibexa\Contracts\Core\Repository\Exceptions\PropertyReadOnlyException; use Ibexa\Core\Repository\Values\User\Policy; use Ibexa\Tests\Core\Repository\Values\ValueObjectTestTrait; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; +#[CoversClass(Policy::class)] class PolicyTest extends TestCase { use ValueObjectTestTrait; /** * Test a new class and default values on properties. - * - * @covers \Ibexa\Core\Repository\Values\User\Policy::__construct */ - public function testNewClass() + public function testNewClass(): void { $this->assertPropertiesCorrect( [ @@ -38,10 +38,8 @@ public function testNewClass() /** * Test retrieving missing property. - * - * @covers \Ibexa\Core\Repository\Values\User\Policy::__get */ - public function testMissingProperty() + public function testMissingProperty(): void { $this->expectException(PropertyNotFoundException::class); @@ -53,10 +51,8 @@ public function testMissingProperty() /** * Test setting read only property. - * - * @covers \Ibexa\Core\Repository\Values\User\Policy::__set */ - public function testReadOnlyProperty() + public function testReadOnlyProperty(): void { $this->expectException(PropertyReadOnlyException::class); @@ -67,10 +63,8 @@ public function testReadOnlyProperty() /** * Test if property exists. - * - * @covers \Ibexa\Core\Repository\Values\User\Policy::__isset */ - public function testIsPropertySet() + public function testIsPropertySet(): void { $policy = new Policy(); /** @phpstan-ignore property.notFound */ @@ -83,10 +77,8 @@ public function testIsPropertySet() /** * Test unsetting a property. - * - * @covers \Ibexa\Core\Repository\Values\User\Policy::__unset */ - public function testUnsetProperty() + public function testUnsetProperty(): void { $this->expectException(PropertyReadOnlyException::class); diff --git a/tests/lib/Repository/Values/User/RoleTest.php b/tests/lib/Repository/Values/User/RoleTest.php index c62122c8de..c06a740a2f 100644 --- a/tests/lib/Repository/Values/User/RoleTest.php +++ b/tests/lib/Repository/Values/User/RoleTest.php @@ -11,11 +11,10 @@ use Ibexa\Contracts\Core\Repository\Exceptions\PropertyReadOnlyException; use Ibexa\Core\Repository\Values\User\Role; use Ibexa\Tests\Core\Repository\Values\ValueObjectTestTrait; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Repository\Values\User\Role - */ +#[CoversClass(Role::class)] class RoleTest extends TestCase { use ValueObjectTestTrait; @@ -37,8 +36,6 @@ public function testNewClass(): void /** * Test retrieving missing property. - * - * @covers \Ibexa\Core\Repository\Values\User\Role::__get */ public function testMissingProperty(): void { @@ -52,8 +49,6 @@ public function testMissingProperty(): void /** * Test setting read only property. - * - * @covers \Ibexa\Core\Repository\Values\User\Role::__set */ public function testReadOnlyProperty(): void { @@ -77,8 +72,6 @@ public function testIsPropertySet(): void /** * Test unsetting a property. - * - * @covers \Ibexa\Core\Repository\Values\User\Role::__unset */ public function testUnsetProperty(): void { diff --git a/tests/lib/Repository/Values/User/UserGroupTest.php b/tests/lib/Repository/Values/User/UserGroupTest.php index 59bb0ace42..8ea724a309 100644 --- a/tests/lib/Repository/Values/User/UserGroupTest.php +++ b/tests/lib/Repository/Values/User/UserGroupTest.php @@ -13,16 +13,15 @@ use Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo; use Ibexa\Core\Repository\Values\User\UserGroup; use Ibexa\Tests\Core\Repository\Values\ValueObjectTestTrait; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Repository\Values\User\UserGroup - */ +#[CoversClass(UserGroup::class)] class UserGroupTest extends TestCase { use ValueObjectTestTrait; - public function testNewClass() + public function testNewClass(): void { $group = new UserGroup(); self::assertNull($group->parentId); @@ -38,7 +37,7 @@ public function testNewClass() /** * Test getName method. */ - public function testGetName() + public function testGetName(): void { $name = 'Translated name'; $contentMock = $this->createMock(Content::class); @@ -60,7 +59,7 @@ public function testGetName() /** * Test retrieving missing property. */ - public function testMissingProperty() + public function testMissingProperty(): void { $this->expectException(PropertyNotFoundException::class); @@ -70,7 +69,7 @@ public function testMissingProperty() self::fail('Succeeded getting non existing property'); } - public function testObjectProperties() + public function testObjectProperties(): void { $object = new UserGroup(); $properties = $object->attributes(); @@ -95,7 +94,7 @@ public function testObjectProperties() /** * Test setting read only property. */ - public function testReadOnlyProperty() + public function testReadOnlyProperty(): void { $this->expectException(PropertyReadOnlyException::class); @@ -107,7 +106,7 @@ public function testReadOnlyProperty() /** * Test if property exists. */ - public function testIsPropertySet() + public function testIsPropertySet(): void { $userGroup = new UserGroup(); /** @phpstan-ignore property.notFound */ @@ -121,7 +120,7 @@ public function testIsPropertySet() /** * Test unsetting a property. */ - public function testUnsetProperty() + public function testUnsetProperty(): void { $this->expectException(PropertyReadOnlyException::class); diff --git a/tests/lib/Repository/Values/User/UserTest.php b/tests/lib/Repository/Values/User/UserTest.php index e6f0bac126..d768fc2e8c 100644 --- a/tests/lib/Repository/Values/User/UserTest.php +++ b/tests/lib/Repository/Values/User/UserTest.php @@ -13,11 +13,10 @@ use Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo; use Ibexa\Core\Repository\Values\User\User; use Ibexa\Tests\Core\Repository\Values\ValueObjectTestTrait; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Repository\Values\User\User - */ +#[CoversClass(User::class)] final class UserTest extends TestCase { use ValueObjectTestTrait; diff --git a/tests/lib/Search/Common/FieldValueMapper/AggregateTest.php b/tests/lib/Search/Common/FieldValueMapper/AggregateTest.php index ee34111799..208576637e 100644 --- a/tests/lib/Search/Common/FieldValueMapper/AggregateTest.php +++ b/tests/lib/Search/Common/FieldValueMapper/AggregateTest.php @@ -14,11 +14,10 @@ use Ibexa\Contracts\Core\Search\FieldType\FloatField; use Ibexa\Core\Search\Common\FieldValueMapper\Aggregate; use Ibexa\Core\Search\Common\FieldValueMapper\BooleanMapper; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Search\Common\FieldValueMapper\Aggregate - */ +#[CoversClass(Aggregate::class)] final class AggregateTest extends TestCase { private const MAPPED_VALUE = true; @@ -71,7 +70,7 @@ public function testMapThrowsNotImplementedException(): void $booleanMapperMock = $this->createMock(BooleanMapper::class); $this->aggregateMapper->addMapper($booleanMapperMock); - $floatFieldMock = $this->createMock(FloatField::class); + $floatFieldMock = self::createStub(FloatField::class); $searchFieldMock = $this->createMock(Field::class); $searchFieldMock ->method('getType') diff --git a/tests/lib/Search/Common/FieldValueMapper/RemoteIdentifierMapperTest.php b/tests/lib/Search/Common/FieldValueMapper/RemoteIdentifierMapperTest.php index b90fe383e5..d2e11fcfed 100644 --- a/tests/lib/Search/Common/FieldValueMapper/RemoteIdentifierMapperTest.php +++ b/tests/lib/Search/Common/FieldValueMapper/RemoteIdentifierMapperTest.php @@ -15,11 +15,11 @@ use Ibexa\Contracts\Core\Search\FieldType\StringField; use Ibexa\Core\Search\Common\FieldValueMapper\RemoteIdentifierMapper; use Ibexa\Tests\Core\Search\TestCase; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use Psr\Log\LoggerInterface; -/** - * @covers \Ibexa\Core\Search\Common\FieldValueMapper\RemoteIdentifierMapper - */ +#[CoversClass(RemoteIdentifierMapper::class)] final class RemoteIdentifierMapperTest extends TestCase { /** @var \Ibexa\Core\Search\Common\FieldValueMapper\RemoteIdentifierMapper */ @@ -28,19 +28,17 @@ final class RemoteIdentifierMapperTest extends TestCase protected function setUp(): void { $this->mapper = new RemoteIdentifierMapper( - $this->createMock(LoggerInterface::class) + self::createStub(LoggerInterface::class) ); } - /** - * @dataProvider getDataForTestCanMap - */ + #[DataProvider('getDataForTestCanMap')] public function testCanMap(Field $field, bool $canMap): void { self::assertSame($canMap, $this->mapper->canMap($field)); } - public function getDataForTestCanMap(): iterable + public static function getDataForTestCanMap(): iterable { yield 'can map' => [ new Field('id', 1, new RemoteIdentifierField()), @@ -63,15 +61,13 @@ public function getDataForTestCanMap(): iterable ]; } - /** - * @dataProvider getDataForTestMap - */ + #[DataProvider('getDataForTestMap')] public function testMap(Field $field, string $expectedMappedValue): void { self::assertSame($expectedMappedValue, $this->mapper->map($field)); } - public function getDataForTestMap(): iterable + public static function getDataForTestMap(): iterable { yield 'numeric id' => [ new Field('id', 1, new IdentifierField()), diff --git a/tests/lib/Search/Common/FieldValueMapper/StringMapperTest.php b/tests/lib/Search/Common/FieldValueMapper/StringMapperTest.php index eddd165ddc..b74889f45a 100644 --- a/tests/lib/Search/Common/FieldValueMapper/StringMapperTest.php +++ b/tests/lib/Search/Common/FieldValueMapper/StringMapperTest.php @@ -11,11 +11,10 @@ use Ibexa\Contracts\Core\Search\Field; use Ibexa\Contracts\Core\Search\FieldType\StringField; use Ibexa\Core\Search\Common\FieldValueMapper\StringMapper; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Search\Common\FieldValueMapper\StringMapper - */ +#[CoversClass(StringMapper::class)] final class StringMapperTest extends TestCase { private StringMapper $mapper; diff --git a/tests/lib/Search/Embedding/EmbeddingProviderRegistryTest.php b/tests/lib/Search/Embedding/EmbeddingProviderRegistryTest.php index 5c46f95625..2fe9b233a4 100644 --- a/tests/lib/Search/Embedding/EmbeddingProviderRegistryTest.php +++ b/tests/lib/Search/Embedding/EmbeddingProviderRegistryTest.php @@ -18,7 +18,7 @@ final class EmbeddingProviderRegistryTest extends TestCase public function testHasEmbeddingProvider(): void { $registry = new EmbeddingProviderRegistry([ - 'existing' => $this->createMock(EmbeddingProviderInterface::class), + 'existing' => self::createStub(EmbeddingProviderInterface::class), ]); self::assertTrue($registry->hasEmbeddingProvider('existing')); @@ -27,7 +27,7 @@ public function testHasEmbeddingProvider(): void public function testGetEmbeddingProvider(): void { - $expectedEmbeddingProvider = $this->createMock(EmbeddingProviderInterface::class); + $expectedEmbeddingProvider = self::createStub(EmbeddingProviderInterface::class); $registry = new EmbeddingProviderRegistry([ 'example' => $expectedEmbeddingProvider, @@ -50,8 +50,8 @@ public function testGetEmbeddingProviderThrowsInvalidArgumentException(): void public function testGetEmbeddingProviders(): void { - $embeddingProviderA = $this->createMock(EmbeddingProviderInterface::class); - $embeddingProviderB = $this->createMock(EmbeddingProviderInterface::class); + $embeddingProviderA = self::createStub(EmbeddingProviderInterface::class); + $embeddingProviderB = self::createStub(EmbeddingProviderInterface::class); $registry = new EmbeddingProviderRegistry([ 'existingA' => $embeddingProviderA, diff --git a/tests/lib/Search/Embedding/EmbeddingProviderResolverTest.php b/tests/lib/Search/Embedding/EmbeddingProviderResolverTest.php index 174c036ea9..042deee5b9 100644 --- a/tests/lib/Search/Embedding/EmbeddingProviderResolverTest.php +++ b/tests/lib/Search/Embedding/EmbeddingProviderResolverTest.php @@ -38,7 +38,7 @@ protected function setUp(): void public function testResolveReturnsProviderWhenAvailable(): void { $embeddingProviderIdentifier = 'ibexa_openai'; - $mockProvider = $this->createMock(EmbeddingProviderInterface::class); + $mockProvider = self::createStub(EmbeddingProviderInterface::class); $this->configuration ->method('getDefaultProvider') @@ -84,7 +84,7 @@ public function testResolveByModelIdentifierReturnsProviderConfiguredForModel(): { $modelIdentifier = 'gemini_embedding_001_1536'; $embeddingProviderIdentifier = 'ibexa_gemini'; - $mockProvider = $this->createMock(EmbeddingProviderInterface::class); + $mockProvider = self::createStub(EmbeddingProviderInterface::class); $this->configuration ->expects(self::once()) diff --git a/tests/lib/Search/FieldNameResolverTest.php b/tests/lib/Search/FieldNameResolverTest.php index 04482068d6..48fd3d135d 100644 --- a/tests/lib/Search/FieldNameResolverTest.php +++ b/tests/lib/Search/FieldNameResolverTest.php @@ -17,13 +17,12 @@ use Ibexa\Core\Search\Common\FieldNameGenerator; use Ibexa\Core\Search\Common\FieldNameResolver; use Ibexa\Core\Search\Common\FieldRegistry; +use PHPUnit\Framework\Attributes\CoversClass; -/** - * @covers \Ibexa\Core\Search\Common\FieldNameResolver - */ +#[CoversClass(FieldNameResolver::class)] class FieldNameResolverTest extends TestCase { - public function testGetFieldNamesReturnsEmptyArray() + public function testGetFieldNamesReturnsEmptyArray(): void { $mockedFieldNameResolver = $this->getMockedFieldNameResolver(['getSearchableFieldMap', 'getIndexFieldName']); $criterionMock = $this->getCriterionMock(); @@ -61,7 +60,7 @@ public function testGetFieldNamesReturnsEmptyArray() self::assertEmpty($fieldNames); } - public function testGetFieldNames() + public function testGetFieldNames(): void { $mockedFieldNameResolver = $this->getMockedFieldNameResolver(['getSearchableFieldMap', 'getIndexFieldName']); $criterionMock = $this->getCriterionMock(); @@ -92,33 +91,27 @@ public function testGetFieldNames() ) ); + $getIndexFieldNameMatcher = self::exactly(2); $mockedFieldNameResolver - ->expects(self::at(1)) + ->expects($getIndexFieldNameMatcher) ->method('getIndexFieldName') - ->with( - self::isInstanceOf( - APICriterion::class - ), - 'content_type_identifier_1', - 'field_definition_identifier_1', - 'field_type_identifier_1', - null - ) - ->will(self::returnValue(['index_field_name_1' => null])); + ->willReturnCallback(static function ($criterion, $contentTypeIdentifier, $fieldDefinitionIdentifier, $fieldTypeIdentifier, $fieldName) use ($getIndexFieldNameMatcher) { + self::assertInstanceOf(APICriterion::class, $criterion); + self::assertSame('field_definition_identifier_1', $fieldDefinitionIdentifier); + self::assertNull($fieldName); - $mockedFieldNameResolver - ->expects(self::at(2)) - ->method('getIndexFieldName') - ->with( - self::isInstanceOf( - APICriterion::class - ), - 'content_type_identifier_2', - 'field_definition_identifier_1', - 'field_type_identifier_2', - null - ) - ->will(self::returnValue(['index_field_name_2' => null])); + if ($getIndexFieldNameMatcher->numberOfInvocations() === 1) { + self::assertSame('content_type_identifier_1', $contentTypeIdentifier); + self::assertSame('field_type_identifier_1', $fieldTypeIdentifier); + + return ['index_field_name_1' => null]; + } + + self::assertSame('content_type_identifier_2', $contentTypeIdentifier); + self::assertSame('field_type_identifier_2', $fieldTypeIdentifier); + + return ['index_field_name_2' => null]; + }); $fieldNames = $mockedFieldNameResolver->getFieldTypes( $criterionMock, @@ -135,7 +128,7 @@ public function testGetFieldNames() ); } - public function testGetFieldNamesWithNamedField() + public function testGetFieldNamesWithNamedField(): void { $mockedFieldNameResolver = $this->getMockedFieldNameResolver(['getSearchableFieldMap', 'getIndexFieldName']); $criterionMock = $this->getCriterionMock(); @@ -166,33 +159,27 @@ public function testGetFieldNamesWithNamedField() ) ); + $getIndexFieldNameMatcher = self::exactly(2); $mockedFieldNameResolver - ->expects(self::at(1)) + ->expects($getIndexFieldNameMatcher) ->method('getIndexFieldName') - ->with( - self::isInstanceOf( - APICriterion::class - ), - 'content_type_identifier_1', - 'field_definition_identifier_1', - 'field_type_identifier_1', - 'field_name' - ) - ->will(self::returnValue(['index_field_name_1' => null])); + ->willReturnCallback(static function ($criterion, $contentTypeIdentifier, $fieldDefinitionIdentifier, $fieldTypeIdentifier, $fieldName) use ($getIndexFieldNameMatcher) { + self::assertInstanceOf(APICriterion::class, $criterion); + self::assertSame('field_definition_identifier_1', $fieldDefinitionIdentifier); + self::assertSame('field_name', $fieldName); - $mockedFieldNameResolver - ->expects(self::at(2)) - ->method('getIndexFieldName') - ->with( - self::isInstanceOf( - APICriterion::class - ), - 'content_type_identifier_2', - 'field_definition_identifier_1', - 'field_type_identifier_2', - 'field_name' - ) - ->will(self::returnValue(['index_field_name_2' => null])); + if ($getIndexFieldNameMatcher->numberOfInvocations() === 1) { + self::assertSame('content_type_identifier_1', $contentTypeIdentifier); + self::assertSame('field_type_identifier_1', $fieldTypeIdentifier); + + return ['index_field_name_1' => null]; + } + + self::assertSame('content_type_identifier_2', $contentTypeIdentifier); + self::assertSame('field_type_identifier_2', $fieldTypeIdentifier); + + return ['index_field_name_2' => null]; + }); $fieldNames = $mockedFieldNameResolver->getFieldTypes( $criterionMock, @@ -211,7 +198,7 @@ public function testGetFieldNamesWithNamedField() ); } - public function testGetFieldNamesWithTypedField() + public function testGetFieldNamesWithTypedField(): void { $mockedFieldNameResolver = $this->getMockedFieldNameResolver(['getSearchableFieldMap', 'getIndexFieldName']); $criterionMock = $this->getCriterionMock(); @@ -243,7 +230,7 @@ public function testGetFieldNamesWithTypedField() ); $mockedFieldNameResolver - ->expects(self::at(1)) + ->expects(self::once()) ->method('getIndexFieldName') ->with( self::isInstanceOf( @@ -272,7 +259,7 @@ public function testGetFieldNamesWithTypedField() ); } - public function testGetFieldNamesWithTypedAndNamedField() + public function testGetFieldNamesWithTypedAndNamedField(): void { $mockedFieldNameResolver = $this->getMockedFieldNameResolver(['getSearchableFieldMap', 'getIndexFieldName']); $criterionMock = $this->getCriterionMock(); @@ -304,7 +291,7 @@ public function testGetFieldNamesWithTypedAndNamedField() ); $mockedFieldNameResolver - ->expects(self::at(1)) + ->expects(self::once()) ->method('getIndexFieldName') ->with( self::isInstanceOf( @@ -333,7 +320,7 @@ public function testGetFieldNamesWithTypedAndNamedField() ); } - public function testGetSortFieldName() + public function testGetSortFieldName(): void { $mockedFieldNameResolver = $this->getMockedFieldNameResolver(['getSearchableFieldMap', 'getIndexFieldName']); $sortClauseMock = $this->getSortClauseMock(); @@ -378,7 +365,7 @@ public function testGetSortFieldName() self::assertEquals('index_field_name', $fieldName); } - public function testGetSortFieldNameReturnsNull() + public function testGetSortFieldNameReturnsNull(): void { $mockedFieldNameResolver = $this->getMockedFieldNameResolver(['getSearchableFieldMap', 'getIndexFieldName']); $sortClauseMock = $this->getSortClauseMock(); @@ -409,7 +396,7 @@ public function testGetSortFieldNameReturnsNull() self::assertNull($fieldName); } - public function testGetIndexFieldNameCustomField() + public function testGetIndexFieldNameCustomField(): void { $mockedFieldNameResolver = $this->getMockedFieldNameResolver(['getSearchableFieldMap']); @@ -437,7 +424,7 @@ public function testGetIndexFieldNameCustomField() self::assertEquals('custom_field_name', key($customFieldName)); } - public function testGetIndexFieldNameNamedField() + public function testGetIndexFieldNameNamedField(): void { $mockedFieldNameResolver = $this->getMockedFieldNameResolver(['getSearchableFieldMap']); $indexFieldType = $this->getIndexFieldTypeMock(); @@ -499,7 +486,7 @@ public function testGetIndexFieldNameNamedField() self::assertEquals('generated_typed_field_name', key($fieldName)); } - public function testGetIndexFieldNameDefaultMatchField() + public function testGetIndexFieldNameDefaultMatchField(): void { $mockedFieldNameResolver = $this->getMockedFieldNameResolver(['getSearchableFieldMap']); $indexFieldType = $this->getIndexFieldTypeMock(); @@ -566,7 +553,7 @@ public function testGetIndexFieldNameDefaultMatchField() self::assertEquals('generated_typed_field_name', key($fieldName)); } - public function testGetIndexFieldNameDefaultSortField() + public function testGetIndexFieldNameDefaultSortField(): void { $mockedFieldNameResolver = $this->getMockedFieldNameResolver(['getSearchableFieldMap']); $indexFieldType = $this->getIndexFieldTypeMock(); @@ -633,7 +620,7 @@ public function testGetIndexFieldNameDefaultSortField() self::assertEquals('generated_typed_field_name', key($fieldName)); } - public function testGetIndexFieldNameDefaultMatchFieldThrowsRuntimeException() + public function testGetIndexFieldNameDefaultMatchFieldThrowsRuntimeException(): void { $this->expectException(\RuntimeException::class); @@ -677,7 +664,7 @@ public function testGetIndexFieldNameDefaultMatchFieldThrowsRuntimeException() ); } - public function testGetIndexFieldNameDefaultSortFieldThrowsRuntimeException() + public function testGetIndexFieldNameDefaultSortFieldThrowsRuntimeException(): void { $this->expectException(\RuntimeException::class); @@ -721,7 +708,7 @@ public function testGetIndexFieldNameDefaultSortFieldThrowsRuntimeException() ); } - public function testGetIndexFieldNameNamedFieldThrowsRuntimeException() + public function testGetIndexFieldNameNamedFieldThrowsRuntimeException(): void { $this->expectException(\RuntimeException::class); @@ -769,7 +756,7 @@ public function testGetIndexFieldNameNamedFieldThrowsRuntimeException() */ protected function getMockedFieldNameResolver(array $methods = []) { - $fieldNameResolver = $this + $builder = $this ->getMockBuilder(FieldNameResolver::class) ->setConstructorArgs( [ @@ -777,9 +764,11 @@ protected function getMockedFieldNameResolver(array $methods = []) $this->getContentTypeHandlerMock(), $this->getFieldNameGeneratorMock(), ] - ) - ->setMethods($methods) - ->getMock(); + ); + if ($methods !== []) { + $builder->onlyMethods(array_values($methods)); + } + $fieldNameResolver = $builder->getMock(); return $fieldNameResolver; } diff --git a/tests/lib/Search/Indexer/ContentIdBatchListTest.php b/tests/lib/Search/Indexer/ContentIdBatchListTest.php index 1a4a2d6887..425f3f4390 100644 --- a/tests/lib/Search/Indexer/ContentIdBatchListTest.php +++ b/tests/lib/Search/Indexer/ContentIdBatchListTest.php @@ -12,21 +12,21 @@ use Generator; use Ibexa\Core\Search\Indexer\ContentIdBatchList; use IteratorAggregate; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Traversable; -/** - * @covers \Ibexa\Core\Search\Indexer\ContentIdBatchList - */ +#[CoversClass(ContentIdBatchList::class)] final class ContentIdBatchListTest extends TestCase { /** * @return iterable>, int, array>}> */ - public function getDataForTestGetIterator(): iterable + public static function getDataForTestGetIterator(): iterable { yield 'generator' => [ - $this->buildGenerator(), + self::buildGenerator(), 5, [ [1, 2, 3], @@ -49,7 +49,7 @@ public function getDataForTestGetIterator(): iterable ]; yield 'Traversable object' => [ - $this->buildTraversableObject(), + self::buildTraversableObject(), 5, [ [1, 2, 3, 4], @@ -58,18 +58,17 @@ public function getDataForTestGetIterator(): iterable ]; yield 'empty generator' => [ - $this->buildEmptyGenerator(), + self::buildEmptyGenerator(), 0, [], ]; } /** - * @dataProvider getDataForTestGetIterator - * * @param iterable> $list * @param array> $expectedBatches */ + #[DataProvider('getDataForTestGetIterator')] public function testGetIterator(iterable $list, int $totalCount, array $expectedBatches): void { $contentIdBatchList = new ContentIdBatchList($list, $totalCount); @@ -86,13 +85,13 @@ public function testGetCount(): void self::assertSame(3, $contentIdBatchList->getCount()); } - private function buildGenerator(): Generator + private static function buildGenerator(): Generator { yield [1, 2, 3]; yield [4, 5]; } - private function buildEmptyGenerator(): \Generator + private static function buildEmptyGenerator(): \Generator { yield from []; } @@ -100,7 +99,7 @@ private function buildEmptyGenerator(): \Generator /** * @return \Traversable> */ - private function buildTraversableObject(): Traversable + private static function buildTraversableObject(): Traversable { return new class() implements IteratorAggregate { /** diff --git a/tests/lib/Search/Legacy/Content/AbstractTestCase.php b/tests/lib/Search/Legacy/Content/AbstractTestCase.php index ca15b7023e..378b877427 100644 --- a/tests/lib/Search/Legacy/Content/AbstractTestCase.php +++ b/tests/lib/Search/Legacy/Content/AbstractTestCase.php @@ -98,11 +98,11 @@ protected function getContentTypeHandler(): SPIContentTypeHandler new ContentTypeMapper( $this->getConverterRegistry(), $this->getLanguageMaskGenerator(), - $this->createMock(StorageDispatcherInterface::class), + self::createStub(StorageDispatcherInterface::class), $this->getFieldTypeAliasResolver(), ), - $this->createMock(ContentTypeUpdateHandler::class), - $this->createMock(StorageDispatcherInterface::class), + self::createStub(ContentTypeUpdateHandler::class), + self::createStub(StorageDispatcherInterface::class), $this->getFieldTypeAliasResolver(), ); } @@ -137,8 +137,8 @@ protected function getEventDispatcher(): EventDispatcherInterface $eventDispatcher->addSubscriber( new ResolveVirtualFieldSubscriber( $this->getConverterRegistry(), - $this->createMock(StorageRegistry::class), - $this->createMock(Gateway::class) + self::createStub(StorageRegistry::class), + self::createStub(Gateway::class) ) ); diff --git a/tests/lib/Search/Legacy/Content/Common/Gateway/SortClauseHandler/Random/RandomSortClauseHandlerPlatformSupportTest.php b/tests/lib/Search/Legacy/Content/Common/Gateway/SortClauseHandler/Random/RandomSortClauseHandlerPlatformSupportTest.php index 31102256ca..29f122858d 100644 --- a/tests/lib/Search/Legacy/Content/Common/Gateway/SortClauseHandler/Random/RandomSortClauseHandlerPlatformSupportTest.php +++ b/tests/lib/Search/Legacy/Content/Common/Gateway/SortClauseHandler/Random/RandomSortClauseHandlerPlatformSupportTest.php @@ -21,20 +21,19 @@ use Ibexa\Core\Search\Legacy\Content\Common\Gateway\SortClauseHandler\Random\MySqlRandom; use Ibexa\Core\Search\Legacy\Content\Common\Gateway\SortClauseHandler\Random\PgSqlRandom; use Ibexa\Core\Search\Legacy\Content\Common\Gateway\SortClauseHandler\Random\SqlLiteRandom; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Search\Legacy\Content\Common\Gateway\SortClauseHandler\Random\MySqlRandom - * @covers \Ibexa\Core\Search\Legacy\Content\Common\Gateway\SortClauseHandler\Random\PgSqlRandom - * @covers \Ibexa\Core\Search\Legacy\Content\Common\Gateway\SortClauseHandler\Random\SqlLiteRandom - */ +#[CoversClass(MySqlRandom::class)] +#[CoversClass(PgSqlRandom::class)] +#[CoversClass(SqlLiteRandom::class)] final class RandomSortClauseHandlerPlatformSupportTest extends TestCase { /** - * @dataProvider providePlatformSupport - * * @phpstan-param class-string<\Ibexa\Core\Search\Legacy\Content\Common\Gateway\SortClauseHandler\AbstractRandom> $handlerClass */ + #[DataProvider('providePlatformSupport')] public function testSupportsPlatform( string $handlerClass, AbstractPlatform $platform, @@ -49,7 +48,7 @@ public function testSupportsPlatform( /** * @return iterable, AbstractPlatform, bool}> */ - public function providePlatformSupport(): iterable + public static function providePlatformSupport(): iterable { yield 'MySQL' => [MySqlRandom::class, new MySQLPlatform(), true]; yield 'MySQL 8.0' => [MySqlRandom::class, new MySQL80Platform(), true]; @@ -71,7 +70,7 @@ public function providePlatformSupport(): iterable */ private function createHandler(string $handlerClass, AbstractPlatform $platform): AbstractRandom { - $connection = $this->createStub(Connection::class); + $connection = self::createStub(Connection::class); $connection ->method('getDatabasePlatform') ->willReturn($platform); diff --git a/tests/lib/Search/Legacy/Content/HandlerContentSortTest.php b/tests/lib/Search/Legacy/Content/HandlerContentSortTest.php index bdea90b99a..65898f883e 100644 --- a/tests/lib/Search/Legacy/Content/HandlerContentSortTest.php +++ b/tests/lib/Search/Legacy/Content/HandlerContentSortTest.php @@ -77,7 +77,7 @@ protected function getContentSearchHandler(array $fullTextSearchConfiguration = ), $this->getLanguageHandler() ), - $this->createMock(LocationGateway::class), + self::createStub(LocationGateway::class), new Content\WordIndexer\Gateway\DoctrineDatabase( $this->getDatabaseConnection(), $this->getContentTypeHandler(), @@ -87,7 +87,7 @@ protected function getContentSearchHandler(array $fullTextSearchConfiguration = $this->getFullTextSearchConfiguration() ), $this->getContentMapperMock(), - $this->createMock(LocationMapper::class), + self::createStub(LocationMapper::class), $this->getLanguageHandler(), $this->getFullTextMapper($this->getContentTypeHandler()) ); @@ -110,11 +110,11 @@ protected function getContentMapperMock() $this->getFieldTypeAliasResolver(), ] ) - ->setMethods(['extractContentInfoFromRows']) + ->onlyMethods(['extractContentInfoFromRows']) ->getMock(); $mapperMock->expects(self::any()) ->method('extractContentInfoFromRows') - ->with(self::isType('array')) + ->with(self::isArray()) ->will( self::returnCallback( static function ($rows): array { @@ -145,7 +145,6 @@ protected function getFieldRegistry() if (!isset($this->fieldRegistry)) { $this->fieldRegistry = $this->getMockBuilder(ConverterRegistry::class) ->setConstructorArgs([]) - ->setMethods([]) ->getMock(); } @@ -161,11 +160,11 @@ protected function getContentFieldHandlerMock() { return $this->getMockBuilder(FieldHandler::class) ->disableOriginalConstructor() - ->setMethods(['loadExternalFieldData']) + ->onlyMethods(['loadExternalFieldData']) ->getMock(); } - public function testNoSorting() + public function testNoSorting(): void { $locator = $this->getContentSearchHandler(); @@ -192,7 +191,7 @@ static function ($hit) { ); } - public function testSortDateModified() + public function testSortDateModified(): void { $locator = $this->getContentSearchHandler(); @@ -220,7 +219,7 @@ static function ($hit) { ); } - public function testSortDatePublished() + public function testSortDatePublished(): void { $locator = $this->getContentSearchHandler(); @@ -248,7 +247,7 @@ static function ($hit) { ); } - public function testSortSectionIdentifier() + public function testSortSectionIdentifier(): void { $locator = $this->getContentSearchHandler(); @@ -293,7 +292,7 @@ static function ($hit) { } } - public function testSortSectionName() + public function testSortSectionName(): void { $locator = $this->getContentSearchHandler(); @@ -346,7 +345,7 @@ static function ($hit) { } } - public function testSortContentName() + public function testSortContentName(): void { $locator = $this->getContentSearchHandler(); @@ -374,7 +373,7 @@ static function ($hit) { ); } - public function testSortFieldText() + public function testSortFieldText(): void { $locator = $this->getContentSearchHandler(); @@ -443,7 +442,7 @@ static function ($hit) { } } - public function testSortFieldNumeric() + public function testSortFieldNumeric(): void { self::markTestSkipped(); $locator = $this->getContentSearchHandler(); diff --git a/tests/lib/Search/Legacy/Content/HandlerContentTest.php b/tests/lib/Search/Legacy/Content/HandlerContentTest.php index 3eab281e10..d39a2f2491 100644 --- a/tests/lib/Search/Legacy/Content/HandlerContentTest.php +++ b/tests/lib/Search/Legacy/Content/HandlerContentTest.php @@ -199,7 +199,7 @@ protected function getContentSearchHandler(array $fullTextSearchConfiguration = ), $this->getLanguageHandler() ), - $this->createMock(LocationGateway::class), + self::createStub(LocationGateway::class), new Content\WordIndexer\Gateway\DoctrineDatabase( $this->getDatabaseConnection(), $this->getContentTypeHandler(), @@ -209,7 +209,7 @@ protected function getContentSearchHandler(array $fullTextSearchConfiguration = $this->getFullTextSearchConfiguration() ), $this->getContentMapperMock(), - $this->createMock(LocationMapper::class), + self::createStub(LocationMapper::class), $this->getLanguageHandler(), $this->getFullTextMapper($this->getContentTypeHandler()) ); @@ -232,11 +232,11 @@ protected function getContentMapperMock() $this->getFieldTypeAliasResolver(), ] ) - ->setMethods(['extractContentInfoFromRows']) + ->onlyMethods(['extractContentInfoFromRows']) ->getMock(); $mapperMock->expects(self::any()) ->method('extractContentInfoFromRows') - ->with(self::isType('array')) + ->with(self::isArray()) ->will( self::returnCallback( static function ($rows): array { @@ -266,14 +266,14 @@ protected function getContentFieldHandlerMock() { return $this->getMockBuilder(FieldHandler::class) ->disableOriginalConstructor() - ->setMethods(['loadExternalFieldData']) + ->onlyMethods(['loadExternalFieldData']) ->getMock(); } /** * Bug #80. */ - public function testFindWithoutOffsetLimit() + public function testFindWithoutOffsetLimit(): void { $locator = $this->getContentSearchHandler(); @@ -294,7 +294,7 @@ public function testFindWithoutOffsetLimit() /** * Bug #81, bug #82. */ - public function testFindWithZeroLimit() + public function testFindWithZeroLimit(): void { $locator = $this->getContentSearchHandler(); @@ -321,7 +321,7 @@ public function testFindWithZeroLimit() /** * Issue with offsetting to the nonexistent results produces \ezcQueryInvalidParameterException exception. */ - public function testFindWithOffsetToNonexistent() + public function testFindWithOffsetToNonexistent(): void { $locator = $this->getContentSearchHandler(); @@ -345,7 +345,7 @@ public function testFindWithOffsetToNonexistent() ); } - public function testFindSingle() + public function testFindSingle(): void { $locator = $this->getContentSearchHandler(); @@ -354,7 +354,7 @@ public function testFindSingle() self::assertEquals(10, $contentInfo->id); } - public function testFindSingleWithNonSearchableField() + public function testFindSingleWithNonSearchableField(): void { $this->expectException(InvalidArgumentException::class); @@ -368,7 +368,7 @@ public function testFindSingleWithNonSearchableField() ); } - public function testFindContentWithNonSearchableField() + public function testFindContentWithNonSearchableField(): void { $this->expectException(InvalidArgumentException::class); @@ -387,7 +387,7 @@ public function testFindContentWithNonSearchableField() ); } - public function testFindSingleTooMany() + public function testFindSingleTooMany(): void { $this->expectException(InvalidArgumentException::class); @@ -395,7 +395,7 @@ public function testFindSingleTooMany() $locator->findSingle(new Criterion\ContentId([4, 10, 12, 23])); } - public function testFindSingleZero() + public function testFindSingleZero(): void { $this->expectException(NotFoundException::class); @@ -403,7 +403,7 @@ public function testFindSingleZero() $locator->findSingle(new Criterion\ContentId(0)); } - public function testContentIdFilter() + public function testContentIdFilter(): void { $this->assertSearchResults( [4, 10], @@ -420,7 +420,7 @@ public function testContentIdFilter() ); } - public function testContentIdFilterCount() + public function testContentIdFilterCount(): void { $locator = $this->getContentSearchHandler(); @@ -438,7 +438,7 @@ public function testContentIdFilterCount() self::assertSame(2, $result->totalCount); } - public function testContentAndCombinatorFilter() + public function testContentAndCombinatorFilter(): void { $this->assertSearchResults( [4], @@ -462,7 +462,7 @@ public function testContentAndCombinatorFilter() ); } - public function testContentOrCombinatorFilter() + public function testContentOrCombinatorFilter(): void { $locator = $this->getContentSearchHandler(); @@ -498,7 +498,7 @@ public function testContentOrCombinatorFilter() } } - public function testContentNotCombinatorFilter() + public function testContentNotCombinatorFilter(): void { $this->assertSearchResults( [4], @@ -524,7 +524,7 @@ public function testContentNotCombinatorFilter() ); } - public function testContentSubtreeFilterIn() + public function testContentSubtreeFilterIn(): void { $this->assertSearchResults( [67, 68, 69, 70, 71, 72, 73, 74], @@ -541,7 +541,7 @@ public function testContentSubtreeFilterIn() ); } - public function testContentSubtreeFilterEq() + public function testContentSubtreeFilterEq(): void { $this->assertSearchResults( [67, 68, 69, 70, 71, 72, 73, 74], @@ -556,7 +556,7 @@ public function testContentSubtreeFilterEq() ); } - public function testContentTypeIdFilter() + public function testContentTypeIdFilter(): void { $this->assertSearchResults( [10, 14, 226], @@ -571,7 +571,7 @@ public function testContentTypeIdFilter() ); } - public function testContentTypeIdentifierFilter() + public function testContentTypeIdentifierFilter(): void { $this->assertSearchResults( [41, 45, 49, 50, 51], @@ -587,7 +587,7 @@ public function testContentTypeIdentifierFilter() ); } - public function testContentTypeGroupFilter() + public function testContentTypeGroupFilter(): void { $this->assertSearchResults( [4, 10, 11, 12, 13, 14, 42, 225, 226], @@ -602,7 +602,7 @@ public function testContentTypeGroupFilter() ); } - public function testDateMetadataFilterModifiedGreater() + public function testDateMetadataFilterModifiedGreater(): void { $this->assertSearchResults( [11, 225, 226], @@ -621,7 +621,7 @@ public function testDateMetadataFilterModifiedGreater() ); } - public function testDateMetadataFilterModifiedGreaterOrEqual() + public function testDateMetadataFilterModifiedGreaterOrEqual(): void { $this->assertSearchResults( [11, 14, 225, 226], @@ -640,7 +640,7 @@ public function testDateMetadataFilterModifiedGreaterOrEqual() ); } - public function testDateMetadataFilterModifiedIn() + public function testDateMetadataFilterModifiedIn(): void { $this->assertSearchResults( [11, 14, 225, 226], @@ -659,7 +659,7 @@ public function testDateMetadataFilterModifiedIn() ); } - public function testDateMetadataFilterModifiedBetween() + public function testDateMetadataFilterModifiedBetween(): void { $this->assertSearchResults( [11, 14, 225, 226], @@ -678,7 +678,7 @@ public function testDateMetadataFilterModifiedBetween() ); } - public function testDateMetadataFilterCreatedBetween() + public function testDateMetadataFilterCreatedBetween(): void { $this->assertSearchResults( [66, 131, 225], @@ -697,7 +697,7 @@ public function testDateMetadataFilterCreatedBetween() ); } - public function testLocationIdFilter() + public function testLocationIdFilter(): void { $this->assertSearchResults( [4, 65], @@ -712,7 +712,7 @@ public function testLocationIdFilter() ); } - public function testParentLocationIdFilter() + public function testParentLocationIdFilter(): void { $this->assertSearchResults( [4, 41, 45, 56, 65], @@ -727,7 +727,7 @@ public function testParentLocationIdFilter() ); } - public function testRemoteIdFilter() + public function testRemoteIdFilter(): void { $this->assertSearchResults( [4, 10], @@ -744,7 +744,7 @@ public function testRemoteIdFilter() ); } - public function testLocationRemoteIdFilter() + public function testLocationRemoteIdFilter(): void { $this->assertSearchResults( [4, 65], @@ -761,7 +761,7 @@ public function testLocationRemoteIdFilter() ); } - public function testSectionFilter() + public function testSectionFilter(): void { $this->assertSearchResults( [4, 10, 11, 12, 13, 14, 42, 226], @@ -776,7 +776,7 @@ public function testSectionFilter() ); } - public function testStatusFilter() + public function testStatusFilter(): void { $this->assertSearchResults( [4, 10, 11, 12, 13, 14, 41, 42, 45, 49], @@ -802,7 +802,7 @@ public function testStatusFilter() ); } - public function testFieldFilter() + public function testFieldFilter(): void { $this->assertSearchResults( [11], @@ -821,7 +821,7 @@ public function testFieldFilter() ); } - public function testFieldFilterIn() + public function testFieldFilterIn(): void { $this->assertSearchResults( [11, 42], @@ -840,7 +840,7 @@ public function testFieldFilterIn() ); } - public function testFieldFilterContainsPartial() + public function testFieldFilterContainsPartial(): void { $this->assertSearchResults( [42], @@ -859,7 +859,7 @@ public function testFieldFilterContainsPartial() ); } - public function testFieldFilterContainsSimple() + public function testFieldFilterContainsSimple(): void { $this->assertSearchResults( [77], @@ -878,7 +878,7 @@ public function testFieldFilterContainsSimple() ); } - public function testFieldFilterContainsSimpleNoMatch() + public function testFieldFilterContainsSimpleNoMatch(): void { $this->assertSearchResults( [], @@ -897,7 +897,7 @@ public function testFieldFilterContainsSimpleNoMatch() ); } - public function testFieldFilterBetween() + public function testFieldFilterBetween(): void { $this->assertSearchResults( [186, 187], @@ -916,7 +916,7 @@ public function testFieldFilterBetween() ); } - public function testFieldFilterOr() + public function testFieldFilterOr(): void { $this->assertSearchResults( [11, 186, 187], @@ -944,7 +944,7 @@ public function testFieldFilterOr() ); } - public function testFullTextFilter() + public function testFullTextFilter(): void { $this->assertSearchResults( [191], @@ -959,7 +959,7 @@ public function testFullTextFilter() ); } - public function testFullTextWildcardFilter() + public function testFullTextWildcardFilter(): void { $this->assertSearchResults( [191], @@ -974,7 +974,7 @@ public function testFullTextWildcardFilter() ); } - public function testFullTextDisabledWildcardFilter() + public function testFullTextDisabledWildcardFilter(): void { $this->assertSearchResults( [], @@ -991,7 +991,7 @@ public function testFullTextDisabledWildcardFilter() ); } - public function testFullTextFilterStopwordRemoval() + public function testFullTextFilterStopwordRemoval(): void { $handler = $this->getContentSearchHandler( [ @@ -1012,7 +1012,7 @@ public function testFullTextFilterStopwordRemoval() ); } - public function testFullTextFilterNoStopwordRemoval() + public function testFullTextFilterNoStopwordRemoval(): void { $handler = $this->getContentSearchHandler( [ @@ -1042,7 +1042,7 @@ static function ($hit) { ); } - public function testFullTextFilterInvalidStopwordThreshold() + public function testFullTextFilterInvalidStopwordThreshold(): void { $this->expectException(InvalidArgumentException::class); @@ -1053,7 +1053,7 @@ public function testFullTextFilterInvalidStopwordThreshold() ); } - public function testObjectStateIdFilter() + public function testObjectStateIdFilter(): void { $this->assertSearchResults( [4, 10, 11, 12, 13, 14, 41, 42, 45, 49], @@ -1069,7 +1069,7 @@ public function testObjectStateIdFilter() ); } - public function testObjectStateIdFilterIn() + public function testObjectStateIdFilterIn(): void { $this->assertSearchResults( [4, 10, 11, 12, 13, 14, 41, 42, 45, 49], @@ -1085,7 +1085,7 @@ public function testObjectStateIdFilterIn() ); } - public function testLanguageCodeFilter() + public function testLanguageCodeFilter(): void { $this->assertSearchResults( [4, 10, 11, 12, 13, 14, 41, 42, 45, 49], @@ -1101,7 +1101,7 @@ public function testLanguageCodeFilter() ); } - public function testLanguageCodeFilterIn() + public function testLanguageCodeFilterIn(): void { $this->assertSearchResults( [4, 10, 11, 12, 13, 14, 41, 42, 45, 49], @@ -1117,7 +1117,7 @@ public function testLanguageCodeFilterIn() ); } - public function testLanguageCodeFilterWithAlwaysAvailable() + public function testLanguageCodeFilterWithAlwaysAvailable(): void { $this->assertSearchResults( [4, 10, 11, 12, 13, 14, 41, 42, 45, 49, 50, 51, 56, 57, 65, 68, 70, 74, 76, 80], @@ -1133,7 +1133,7 @@ public function testLanguageCodeFilterWithAlwaysAvailable() ); } - public function testVisibilityFilter() + public function testVisibilityFilter(): void { $this->assertSearchResults( [4, 10, 11, 12, 13, 14, 41, 42, 45, 49], @@ -1151,7 +1151,7 @@ public function testVisibilityFilter() ); } - public function testUserMetadataFilterOwnerWrongUserId() + public function testUserMetadataFilterOwnerWrongUserId(): void { $this->assertSearchResults( [], @@ -1169,7 +1169,7 @@ public function testUserMetadataFilterOwnerWrongUserId() ); } - public function testUserMetadataFilterOwnerAdministrator() + public function testUserMetadataFilterOwnerAdministrator(): void { $this->assertSearchResults( [4, 10, 11, 12, 13, 14, 41, 42, 45, 49], @@ -1189,7 +1189,7 @@ public function testUserMetadataFilterOwnerAdministrator() ); } - public function testUserMetadataFilterOwnerEqAMember() + public function testUserMetadataFilterOwnerEqAMember(): void { $this->assertSearchResults( [223], @@ -1207,7 +1207,7 @@ public function testUserMetadataFilterOwnerEqAMember() ); } - public function testUserMetadataFilterOwnerInAMember() + public function testUserMetadataFilterOwnerInAMember(): void { $this->assertSearchResults( [223], @@ -1225,7 +1225,7 @@ public function testUserMetadataFilterOwnerInAMember() ); } - public function testUserMetadataFilterCreatorEqAMember() + public function testUserMetadataFilterCreatorEqAMember(): void { $this->assertSearchResults( [223], @@ -1243,7 +1243,7 @@ public function testUserMetadataFilterCreatorEqAMember() ); } - public function testUserMetadataFilterCreatorInAMember() + public function testUserMetadataFilterCreatorInAMember(): void { $this->assertSearchResults( [223], @@ -1261,7 +1261,7 @@ public function testUserMetadataFilterCreatorInAMember() ); } - public function testUserMetadataFilterEqGroupMember() + public function testUserMetadataFilterEqGroupMember(): void { $this->assertSearchResults( [223], @@ -1279,7 +1279,7 @@ public function testUserMetadataFilterEqGroupMember() ); } - public function testUserMetadataFilterInGroupMember() + public function testUserMetadataFilterInGroupMember(): void { $this->assertSearchResults( [223], @@ -1297,7 +1297,7 @@ public function testUserMetadataFilterInGroupMember() ); } - public function testUserMetadataFilterEqGroupMemberNoMatch() + public function testUserMetadataFilterEqGroupMemberNoMatch(): void { $this->assertSearchResults( [], @@ -1315,7 +1315,7 @@ public function testUserMetadataFilterEqGroupMemberNoMatch() ); } - public function testUserMetadataFilterInGroupMemberNoMatch() + public function testUserMetadataFilterInGroupMemberNoMatch(): void { $this->assertSearchResults( [], @@ -1333,7 +1333,7 @@ public function testUserMetadataFilterInGroupMemberNoMatch() ); } - public function testFieldRelationFilterContainsSingle() + public function testFieldRelationFilterContainsSingle(): void { $this->assertSearchResults( [67], @@ -1351,7 +1351,7 @@ public function testFieldRelationFilterContainsSingle() ); } - public function testFieldRelationFilterContainsSingleNoMatch() + public function testFieldRelationFilterContainsSingleNoMatch(): void { $this->assertSearchResults( [], @@ -1369,7 +1369,7 @@ public function testFieldRelationFilterContainsSingleNoMatch() ); } - public function testFieldRelationFilterContainsArray() + public function testFieldRelationFilterContainsArray(): void { $this->assertSearchResults( [67], @@ -1387,7 +1387,7 @@ public function testFieldRelationFilterContainsArray() ); } - public function testFieldRelationFilterContainsArrayNotMatch() + public function testFieldRelationFilterContainsArrayNotMatch(): void { $this->assertSearchResults( [], @@ -1405,7 +1405,7 @@ public function testFieldRelationFilterContainsArrayNotMatch() ); } - public function testFieldRelationFilterInArray() + public function testFieldRelationFilterInArray(): void { $this->assertSearchResults( [67, 75], @@ -1423,7 +1423,7 @@ public function testFieldRelationFilterInArray() ); } - public function testFieldRelationFilterInArrayNotMatch() + public function testFieldRelationFilterInArrayNotMatch(): void { $this->assertSearchResults( [], diff --git a/tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php b/tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php index fe4d39381f..bae10da0b7 100644 --- a/tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php +++ b/tests/lib/Search/Legacy/Content/HandlerLocationSortTest.php @@ -53,7 +53,7 @@ protected function getContentSearchHandler() $joinedTablesTracker = new JoinedTablesTracker(); return new Content\Handler( - $this->createMock(ContentGateway::class), + self::createStub(ContentGateway::class), new Content\Location\Gateway\DoctrineDatabase( $connection, new CriteriaConverter( @@ -101,7 +101,7 @@ protected function getContentSearchHandler() $this->getLanguageMaskGenerator(), $this->getFullTextSearchConfiguration() ), - $this->createMock(ContentMapper::class), + self::createStub(ContentMapper::class), $this->getLocationMapperMock(), $this->getLanguageHandler(), $this->getFullTextMapper($this->getContentTypeHandler()) @@ -116,12 +116,12 @@ protected function getContentSearchHandler() protected function getLocationMapperMock() { $mapperMock = $this->getMockBuilder(LocationMapper::class) - ->setMethods(['createLocationsFromRows']) + ->onlyMethods(['createLocationsFromRows']) ->getMock(); $mapperMock ->expects(self::any()) ->method('createLocationsFromRows') - ->with(self::isType('array')) + ->with(self::isArray()) ->will( self::returnCallback( static function ($rows): array { @@ -142,7 +142,7 @@ static function ($rows): array { return $mapperMock; } - public function testNoSorting() + public function testNoSorting(): void { $handler = $this->getContentSearchHandler(); @@ -164,7 +164,7 @@ public function testNoSorting() ); } - public function testSortLocationPath() + public function testSortLocationPath(): void { $handler = $this->getContentSearchHandler(); @@ -185,7 +185,7 @@ public function testSortLocationPath() ); } - public function testSortLocationDepth() + public function testSortLocationDepth(): void { $handler = $this->getContentSearchHandler(); @@ -206,7 +206,7 @@ public function testSortLocationDepth() ); } - public function testSortLocationDepthAndPath() + public function testSortLocationDepthAndPath(): void { $handler = $this->getContentSearchHandler(); @@ -230,7 +230,7 @@ public function testSortLocationDepthAndPath() ); } - public function testSortLocationPriority() + public function testSortLocationPriority(): void { $handler = $this->getContentSearchHandler(); @@ -253,7 +253,7 @@ public function testSortLocationPriority() ); } - public function testSortDateModified() + public function testSortDateModified(): void { $handler = $this->getContentSearchHandler(); @@ -276,7 +276,7 @@ public function testSortDateModified() ); } - public function testSortDatePublished() + public function testSortDatePublished(): void { $handler = $this->getContentSearchHandler(); @@ -299,7 +299,7 @@ public function testSortDatePublished() ); } - public function testSortSectionIdentifier() + public function testSortSectionIdentifier(): void { $handler = $this->getContentSearchHandler(); @@ -341,7 +341,7 @@ public function testSortSectionIdentifier() } } - public function testSortContentName() + public function testSortContentName(): void { $handler = $this->getContentSearchHandler(); @@ -364,7 +364,7 @@ public function testSortContentName() ); } - public function testSortContentId() + public function testSortContentId(): void { $handler = $this->getContentSearchHandler(); @@ -387,7 +387,7 @@ public function testSortContentId() ); } - public function testSortLocationId() + public function testSortLocationId(): void { $handler = $this->getContentSearchHandler(); @@ -410,7 +410,7 @@ public function testSortLocationId() ); } - public function testSortLocationVisibilityAscending() + public function testSortLocationVisibilityAscending(): void { $handler = $this->getContentSearchHandler(); @@ -433,7 +433,7 @@ public function testSortLocationVisibilityAscending() ); } - public function testSortLocationVisibilityDescending() + public function testSortLocationVisibilityDescending(): void { $handler = $this->getContentSearchHandler(); @@ -456,7 +456,7 @@ public function testSortLocationVisibilityDescending() ); } - public function testSortSectionName() + public function testSortSectionName(): void { $handler = $this->getContentSearchHandler(); @@ -509,7 +509,7 @@ static function ($hit) { } } - public function testSortFieldText() + public function testSortFieldText(): void { $handler = $this->getContentSearchHandler(); @@ -578,7 +578,7 @@ static function ($hit) { } } - public function testSortFieldNumeric() + public function testSortFieldNumeric(): void { self::markTestSkipped(); $handler = $this->getContentSearchHandler(); @@ -612,7 +612,7 @@ static function ($hit) { ); } - public function testSortIsMainLocationAscending() + public function testSortIsMainLocationAscending(): void { $handler = $this->getContentSearchHandler(); @@ -635,7 +635,7 @@ public function testSortIsMainLocationAscending() ); } - public function testSortIsMainLocationDescending() + public function testSortIsMainLocationDescending(): void { $handler = $this->getContentSearchHandler(); diff --git a/tests/lib/Search/Legacy/Content/HandlerLocationTest.php b/tests/lib/Search/Legacy/Content/HandlerLocationTest.php index 92d36ab6ce..38e3dd9188 100644 --- a/tests/lib/Search/Legacy/Content/HandlerLocationTest.php +++ b/tests/lib/Search/Legacy/Content/HandlerLocationTest.php @@ -72,7 +72,7 @@ protected function getContentSearchHandler(array $fullTextSearchConfiguration = ); return new Content\Handler( - $this->createMock(ContentGateway::class), + self::createStub(ContentGateway::class), new Content\Location\Gateway\DoctrineDatabase( $connection, new CriteriaConverter( @@ -169,7 +169,7 @@ protected function getContentSearchHandler(array $fullTextSearchConfiguration = $this->getLanguageMaskGenerator(), $this->getFullTextSearchConfiguration() ), - $this->createMock(ContentMapper::class), + self::createStub(ContentMapper::class), $this->getLocationMapperMock(), $this->getLanguageHandler(), $this->getFullTextMapper($this->getContentTypeHandler()) @@ -184,12 +184,12 @@ protected function getContentSearchHandler(array $fullTextSearchConfiguration = protected function getLocationMapperMock() { $mapperMock = $this->getMockBuilder(LocationMapper::class) - ->setMethods(['createLocationsFromRows']) + ->onlyMethods(['createLocationsFromRows']) ->getMock(); $mapperMock ->expects(self::any()) ->method('createLocationsFromRows') - ->with(self::isType('array')) + ->with(self::isArray()) ->will( self::returnCallback( static function ($rows): array { @@ -210,7 +210,7 @@ static function ($rows): array { return $mapperMock; } - public function testFindWithoutOffsetLimit() + public function testFindWithoutOffsetLimit(): void { $handler = $this->getContentSearchHandler(); @@ -226,7 +226,7 @@ public function testFindWithoutOffsetLimit() self::assertCount(1, $searchResult->searchHits); } - public function testFindWithZeroLimit() + public function testFindWithZeroLimit(): void { $handler = $this->getContentSearchHandler(); @@ -247,7 +247,7 @@ public function testFindWithZeroLimit() /** * Issue with offsetting to the nonexistent results produces \ezcQueryInvalidParameterException exception. */ - public function testFindWithOffsetToNonexistent() + public function testFindWithOffsetToNonexistent(): void { $handler = $this->getContentSearchHandler(); @@ -265,7 +265,7 @@ public function testFindWithOffsetToNonexistent() self::assertEquals([], $searchResult->searchHits); } - public function testLocationIdFilter() + public function testLocationIdFilter(): void { $this->assertSearchResults( [12, 13], @@ -282,7 +282,7 @@ public function testLocationIdFilter() ); } - public function testParentLocationIdFilter() + public function testParentLocationIdFilter(): void { $this->assertSearchResults( [12, 13, 14, 44, 227], @@ -297,7 +297,7 @@ public function testParentLocationIdFilter() ); } - public function testLocationIdAndCombinatorFilter() + public function testLocationIdAndCombinatorFilter(): void { $this->assertSearchResults( [13], @@ -321,7 +321,7 @@ public function testLocationIdAndCombinatorFilter() ); } - public function testLocationIdParentLocationIdAndCombinatorFilter() + public function testLocationIdParentLocationIdAndCombinatorFilter(): void { $this->assertSearchResults( [44, 160], @@ -345,7 +345,7 @@ public function testLocationIdParentLocationIdAndCombinatorFilter() ); } - public function testContentDepthFilterEq() + public function testContentDepthFilterEq(): void { $this->assertSearchResults( [2, 5, 43, 48, 58], @@ -360,7 +360,7 @@ public function testContentDepthFilterEq() ); } - public function testContentDepthFilterIn() + public function testContentDepthFilterIn(): void { $this->assertSearchResults( [2, 5, 12, 13, 14, 43, 44, 48, 51, 52, 53, 54, 56, 58, 59, 69, 77, 86, 96, 107, 153, 156, 167, 190, 227], @@ -375,7 +375,7 @@ public function testContentDepthFilterIn() ); } - public function testContentDepthFilterBetween() + public function testContentDepthFilterBetween(): void { $this->assertSearchResults( [2, 5, 43, 48, 58], @@ -389,7 +389,7 @@ public function testContentDepthFilterBetween() ); } - public function testContentDepthFilterGreaterThan() + public function testContentDepthFilterGreaterThan(): void { $this->assertSearchResults( [99, 102, 135, 136, 137, 139, 140, 142, 143, 144, 145, 148, 151, 174, 175, 177, 194, 196, 197, 198, 199, 200, 201, 202, 203, 205, 206, 207, 208, 209, 210, 211, 212, 214, 215], @@ -404,7 +404,7 @@ public function testContentDepthFilterGreaterThan() ); } - public function testContentDepthFilterGreaterThanOrEqual() + public function testContentDepthFilterGreaterThanOrEqual(): void { $this->assertSearchResults( [99, 102, 135, 136, 137, 139, 140, 142, 143, 144, 145, 148, 151, 174, 175, 177, 194, 196, 197, 198, 199, 200, 201, 202, 203, 205, 206, 207, 208, 209, 210, 211, 212, 214, 215], @@ -419,7 +419,7 @@ public function testContentDepthFilterGreaterThanOrEqual() ); } - public function testContentDepthFilterLessThan() + public function testContentDepthFilterLessThan(): void { $this->assertSearchResults( [2, 5, 43, 48, 58], @@ -434,7 +434,7 @@ public function testContentDepthFilterLessThan() ); } - public function testContentDepthFilterLessThanOrEqual() + public function testContentDepthFilterLessThanOrEqual(): void { $this->assertSearchResults( [2, 5, 12, 13, 14, 43, 44, 48, 51, 52, 53, 54, 56, 58, 59, 69, 77, 86, 96, 107, 153, 156, 167, 190, 227], @@ -449,7 +449,7 @@ public function testContentDepthFilterLessThanOrEqual() ); } - public function testLocationPriorityFilter() + public function testLocationPriorityFilter(): void { $this->assertSearchResults( [156, 167, 190], @@ -467,7 +467,7 @@ public function testLocationPriorityFilter() ); } - public function testLocationRemoteIdFilter() + public function testLocationRemoteIdFilter(): void { $this->assertSearchResults( [2, 5], @@ -484,7 +484,7 @@ public function testLocationRemoteIdFilter() ); } - public function testVisibilityFilterVisible() + public function testVisibilityFilterVisible(): void { $this->assertSearchResults( [2, 5, 12, 13, 14], @@ -502,7 +502,7 @@ public function testVisibilityFilterVisible() ); } - public function testVisibilityFilterHidden() + public function testVisibilityFilterHidden(): void { $this->assertSearchResults( [228], @@ -518,7 +518,7 @@ public function testVisibilityFilterHidden() ); } - public function testLocationNotCombinatorFilter() + public function testLocationNotCombinatorFilter(): void { $this->assertSearchResults( [2, 5], @@ -544,7 +544,7 @@ public function testLocationNotCombinatorFilter() ); } - public function testLocationOrCombinatorFilter() + public function testLocationOrCombinatorFilter(): void { $this->assertSearchResults( [2, 5, 12, 13, 14], @@ -568,7 +568,7 @@ public function testLocationOrCombinatorFilter() ); } - public function testContentIdFilterEquals() + public function testContentIdFilterEquals(): void { $this->assertSearchResults( [225], @@ -582,7 +582,7 @@ public function testContentIdFilterEquals() ); } - public function testContentIdFilterIn() + public function testContentIdFilterIn(): void { $this->assertSearchResults( [225, 226, 227], @@ -598,7 +598,7 @@ public function testContentIdFilterIn() ); } - public function testContentTypeGroupFilter() + public function testContentTypeGroupFilter(): void { $this->assertSearchResults( [5, 12, 13, 14, 15, 44, 45, 227, 228], @@ -613,7 +613,7 @@ public function testContentTypeGroupFilter() ); } - public function testContentTypeIdFilter() + public function testContentTypeIdFilter(): void { $this->assertSearchResults( [15, 45, 228], @@ -628,7 +628,7 @@ public function testContentTypeIdFilter() ); } - public function testContentTypeIdentifierFilter() + public function testContentTypeIdentifierFilter(): void { $this->assertSearchResults( [43, 48, 51, 52, 53], @@ -644,7 +644,7 @@ public function testContentTypeIdentifierFilter() ); } - public function testObjectStateIdFilter() + public function testObjectStateIdFilter(): void { $this->assertSearchResults( [5, 12, 13, 14, 15, 43, 44, 45, 48, 51], @@ -660,7 +660,7 @@ public function testObjectStateIdFilter() ); } - public function testObjectStateIdFilterIn() + public function testObjectStateIdFilterIn(): void { $this->assertSearchResults( [2, 5, 12, 13, 14, 15, 43, 44, 45, 48], @@ -676,7 +676,7 @@ public function testObjectStateIdFilterIn() ); } - public function testRemoteIdFilter() + public function testRemoteIdFilter(): void { $this->assertSearchResults( [5, 45], @@ -693,7 +693,7 @@ public function testRemoteIdFilter() ); } - public function testSectionFilter() + public function testSectionFilter(): void { $this->assertSearchResults( [5, 12, 13, 14, 15, 44, 45, 228], @@ -708,7 +708,7 @@ public function testSectionFilter() ); } - public function testDateMetadataFilterModifiedGreater() + public function testDateMetadataFilterModifiedGreater(): void { $this->assertSearchResults( [12, 227, 228], @@ -727,7 +727,7 @@ public function testDateMetadataFilterModifiedGreater() ); } - public function testDateMetadataFilterModifiedGreaterOrEqual() + public function testDateMetadataFilterModifiedGreaterOrEqual(): void { $this->assertSearchResults( [12, 15, 227, 228], @@ -746,7 +746,7 @@ public function testDateMetadataFilterModifiedGreaterOrEqual() ); } - public function testDateMetadataFilterModifiedIn() + public function testDateMetadataFilterModifiedIn(): void { $this->assertSearchResults( [12, 15, 227, 228], @@ -765,7 +765,7 @@ public function testDateMetadataFilterModifiedIn() ); } - public function testDateMetadataFilterModifiedBetween() + public function testDateMetadataFilterModifiedBetween(): void { $this->assertSearchResults( [12, 15, 227, 228], @@ -784,7 +784,7 @@ public function testDateMetadataFilterModifiedBetween() ); } - public function testDateMetadataFilterCreatedBetween() + public function testDateMetadataFilterCreatedBetween(): void { $this->assertSearchResults( [68, 133, 227], @@ -803,7 +803,7 @@ public function testDateMetadataFilterCreatedBetween() ); } - public function testUserMetadataFilterOwnerWrongUserId() + public function testUserMetadataFilterOwnerWrongUserId(): void { $this->assertSearchResults( [], @@ -821,7 +821,7 @@ public function testUserMetadataFilterOwnerWrongUserId() ); } - public function testUserMetadataFilterOwnerAdministrator() + public function testUserMetadataFilterOwnerAdministrator(): void { $this->assertSearchResults( [2, 5, 12, 13, 14, 15, 43, 44, 45, 48], @@ -841,7 +841,7 @@ public function testUserMetadataFilterOwnerAdministrator() ); } - public function testUserMetadataFilterOwnerEqAMember() + public function testUserMetadataFilterOwnerEqAMember(): void { $this->assertSearchResults( [225], @@ -859,7 +859,7 @@ public function testUserMetadataFilterOwnerEqAMember() ); } - public function testUserMetadataFilterOwnerInAMember() + public function testUserMetadataFilterOwnerInAMember(): void { $this->assertSearchResults( [225], @@ -877,7 +877,7 @@ public function testUserMetadataFilterOwnerInAMember() ); } - public function testUserMetadataFilterCreatorEqAMember() + public function testUserMetadataFilterCreatorEqAMember(): void { $this->assertSearchResults( [225], @@ -895,7 +895,7 @@ public function testUserMetadataFilterCreatorEqAMember() ); } - public function testUserMetadataFilterCreatorInAMember() + public function testUserMetadataFilterCreatorInAMember(): void { $this->assertSearchResults( [225], @@ -913,7 +913,7 @@ public function testUserMetadataFilterCreatorInAMember() ); } - public function testUserMetadataFilterEqGroupMember() + public function testUserMetadataFilterEqGroupMember(): void { $this->assertSearchResults( [225], @@ -931,7 +931,7 @@ public function testUserMetadataFilterEqGroupMember() ); } - public function testUserMetadataFilterInGroupMember() + public function testUserMetadataFilterInGroupMember(): void { $this->assertSearchResults( [225], @@ -949,7 +949,7 @@ public function testUserMetadataFilterInGroupMember() ); } - public function testUserMetadataFilterEqGroupMemberNoMatch() + public function testUserMetadataFilterEqGroupMemberNoMatch(): void { $this->assertSearchResults( [], @@ -967,7 +967,7 @@ public function testUserMetadataFilterEqGroupMemberNoMatch() ); } - public function testUserMetadataFilterInGroupMemberNoMatch() + public function testUserMetadataFilterInGroupMemberNoMatch(): void { $this->assertSearchResults( [], @@ -985,7 +985,7 @@ public function testUserMetadataFilterInGroupMemberNoMatch() ); } - public function testLanguageCodeFilter() + public function testLanguageCodeFilter(): void { $this->assertSearchResults( [2, 5, 12, 13, 14, 15, 43, 44, 45, 48], @@ -1001,7 +1001,7 @@ public function testLanguageCodeFilter() ); } - public function testLanguageCodeFilterIn() + public function testLanguageCodeFilterIn(): void { $this->assertSearchResults( [2, 5, 12, 13, 14, 15, 43, 44, 45, 48], @@ -1017,7 +1017,7 @@ public function testLanguageCodeFilterIn() ); } - public function testLanguageCodeFilterWithAlwaysAvailable() + public function testLanguageCodeFilterWithAlwaysAvailable(): void { $this->assertSearchResults( [2, 5, 12, 13, 14, 15, 43, 44, 45, 48, 51, 52, 53, 58, 59, 70, 72, 76, 78, 82], @@ -1033,7 +1033,7 @@ public function testLanguageCodeFilterWithAlwaysAvailable() ); } - public function testMatchAllFilter() + public function testMatchAllFilter(): void { $result = $this->getContentSearchHandler()->findLocations( new LocationQuery( @@ -1053,7 +1053,7 @@ public function testMatchAllFilter() ); } - public function testFullTextFilter() + public function testFullTextFilter(): void { $this->assertSearchResults( [193], @@ -1068,7 +1068,7 @@ public function testFullTextFilter() ); } - public function testFullTextWildcardFilter() + public function testFullTextWildcardFilter(): void { $this->assertSearchResults( [193], @@ -1083,7 +1083,7 @@ public function testFullTextWildcardFilter() ); } - public function testFullTextDisabledWildcardFilter() + public function testFullTextDisabledWildcardFilter(): void { $this->assertSearchResults( [], @@ -1098,7 +1098,7 @@ public function testFullTextDisabledWildcardFilter() ); } - public function testFullTextFilterStopwordRemoval() + public function testFullTextFilterStopwordRemoval(): void { $handler = $this->getContentSearchHandler( [ @@ -1118,7 +1118,7 @@ public function testFullTextFilterStopwordRemoval() ); } - public function testFullTextFilterNoStopwordRemoval() + public function testFullTextFilterNoStopwordRemoval(): void { $handler = $this->getContentSearchHandler( [ @@ -1150,7 +1150,7 @@ static function ($hit) { ); } - public function testFullTextFilterInvalidStopwordThreshold() + public function testFullTextFilterInvalidStopwordThreshold(): void { $this->expectException(InvalidArgumentException::class); @@ -1161,7 +1161,7 @@ public function testFullTextFilterInvalidStopwordThreshold() ); } - public function testFieldRelationFilterContainsSingle() + public function testFieldRelationFilterContainsSingle(): void { $this->assertSearchResults( [69], @@ -1179,7 +1179,7 @@ public function testFieldRelationFilterContainsSingle() ); } - public function testFieldRelationFilterContainsSingleNoMatch() + public function testFieldRelationFilterContainsSingleNoMatch(): void { $this->assertSearchResults( [], @@ -1197,7 +1197,7 @@ public function testFieldRelationFilterContainsSingleNoMatch() ); } - public function testFieldRelationFilterContainsArray() + public function testFieldRelationFilterContainsArray(): void { $this->assertSearchResults( [69], @@ -1215,7 +1215,7 @@ public function testFieldRelationFilterContainsArray() ); } - public function testFieldRelationFilterContainsArrayNotMatch() + public function testFieldRelationFilterContainsArrayNotMatch(): void { $this->assertSearchResults( [], @@ -1233,7 +1233,7 @@ public function testFieldRelationFilterContainsArrayNotMatch() ); } - public function testFieldRelationFilterInArray() + public function testFieldRelationFilterInArray(): void { $this->assertSearchResults( [69, 77], @@ -1251,7 +1251,7 @@ public function testFieldRelationFilterInArray() ); } - public function testFieldRelationFilterInArrayNotMatch() + public function testFieldRelationFilterInArrayNotMatch(): void { $this->assertSearchResults( [], @@ -1269,7 +1269,7 @@ public function testFieldRelationFilterInArrayNotMatch() ); } - public function testFieldFilter() + public function testFieldFilter(): void { $this->assertSearchResults( [12], @@ -1288,7 +1288,7 @@ public function testFieldFilter() ); } - public function testFieldFilterIn() + public function testFieldFilterIn(): void { $this->assertSearchResults( [12, 44], @@ -1307,7 +1307,7 @@ public function testFieldFilterIn() ); } - public function testFieldFilterContainsPartial() + public function testFieldFilterContainsPartial(): void { $this->assertSearchResults( [44], @@ -1326,7 +1326,7 @@ public function testFieldFilterContainsPartial() ); } - public function testFieldFilterContainsSimple() + public function testFieldFilterContainsSimple(): void { $this->assertSearchResults( [79], @@ -1345,7 +1345,7 @@ public function testFieldFilterContainsSimple() ); } - public function testFieldFilterContainsSimpleNoMatch() + public function testFieldFilterContainsSimpleNoMatch(): void { $this->assertSearchResults( [], @@ -1364,7 +1364,7 @@ public function testFieldFilterContainsSimpleNoMatch() ); } - public function testFieldFilterBetween() + public function testFieldFilterBetween(): void { $this->assertSearchResults( [188, 189], @@ -1383,7 +1383,7 @@ public function testFieldFilterBetween() ); } - public function testFieldFilterOr() + public function testFieldFilterOr(): void { $this->assertSearchResults( [12, 188, 189], @@ -1411,7 +1411,7 @@ public function testFieldFilterOr() ); } - public function testIsMainLocationFilter() + public function testIsMainLocationFilter(): void { $this->assertSearchResults( [225], @@ -1433,7 +1433,7 @@ public function testIsMainLocationFilter() ); } - public function testIsNotMainLocationFilter() + public function testIsNotMainLocationFilter(): void { $this->assertSearchResults( [510], diff --git a/tests/lib/Specification/Content/ContentContainerSpecificationTest.php b/tests/lib/Specification/Content/ContentContainerSpecificationTest.php index 0aff756d04..8b9f8d5098 100644 --- a/tests/lib/Specification/Content/ContentContainerSpecificationTest.php +++ b/tests/lib/Specification/Content/ContentContainerSpecificationTest.php @@ -12,11 +12,11 @@ use Ibexa\Contracts\Core\Repository\Values\ContentType\ContentType; use Ibexa\Contracts\Core\Specification\Content\ContentContainerSpecification; use Ibexa\Contracts\Core\Specification\Content\ContentSpecification; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Contracts\Core\Specification\Content\ContentContainerSpecification - */ +#[CoversClass(ContentContainerSpecification::class)] final class ContentContainerSpecificationTest extends TestCase { public function testConstructor(): void @@ -26,9 +26,7 @@ public function testConstructor(): void self::assertInstanceOf(ContentSpecification::class, $contentTypeSpecification); } - /** - * @dataProvider providerForIsSatisfiedBy - */ + #[DataProvider('providerForIsSatisfiedBy')] public function testIsSatisfiedBy( bool $isContainer, bool $shouldBeSatisfied @@ -52,7 +50,7 @@ public function testIsSatisfiedBy( ); } - public function providerForIsSatisfiedBy(): array + public static function providerForIsSatisfiedBy(): array { return [ [true, true], diff --git a/tests/lib/Specification/Content/ContentTypeSpecificationTest.php b/tests/lib/Specification/Content/ContentTypeSpecificationTest.php index 49b8f534d1..a081c4266d 100644 --- a/tests/lib/Specification/Content/ContentTypeSpecificationTest.php +++ b/tests/lib/Specification/Content/ContentTypeSpecificationTest.php @@ -12,11 +12,11 @@ use Ibexa\Contracts\Core\Repository\Values\ContentType\ContentType; use Ibexa\Contracts\Core\Specification\Content\ContentSpecification; use Ibexa\Contracts\Core\Specification\Content\ContentTypeSpecification; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Contracts\Core\Specification\Content\ContentTypeSpecification - */ +#[CoversClass(ContentTypeSpecification::class)] final class ContentTypeSpecificationTest extends TestCase { private const EXISTING_CONTENT_TYPE_IDENTIFIER = 'article'; @@ -40,9 +40,7 @@ public function testConstructorWithNotExistingContentTypeIdentifier(): void self::assertInstanceOf(ContentSpecification::class, $contentTypeSpecification); } - /** - * @dataProvider providerForIsSatisfiedBy - */ + #[DataProvider('providerForIsSatisfiedBy')] public function testIsSatisfiedBy( string $contentTypeSpecificationIdentifier, string $contentTypeIdentifier, @@ -69,7 +67,7 @@ public function testIsSatisfiedBy( ); } - public function providerForIsSatisfiedBy(): array + public static function providerForIsSatisfiedBy(): array { return [ [self::EXISTING_CONTENT_TYPE_IDENTIFIER, self::EXISTING_CONTENT_TYPE_IDENTIFIER, true], diff --git a/tests/lib/Token/RandomBytesGeneratorTest.php b/tests/lib/Token/RandomBytesGeneratorTest.php index 138485510e..6cf6f05c34 100644 --- a/tests/lib/Token/RandomBytesGeneratorTest.php +++ b/tests/lib/Token/RandomBytesGeneratorTest.php @@ -10,11 +10,11 @@ use Ibexa\Contracts\Core\Token\TokenGeneratorInterface; use Ibexa\Core\Token\RandomBytesGenerator; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Token\RandomBytesGenerator - */ +#[CoversClass(RandomBytesGenerator::class)] final class RandomBytesGeneratorTest extends TestCase { private TokenGeneratorInterface $tokenGenerator; @@ -25,10 +25,9 @@ protected function setUp(): void } /** - * @dataProvider provideDataForTestGenerateToken - * * @throws \Exception */ + #[DataProvider('provideDataForTestGenerateToken')] public function testGenerateToken(int $expectedTokenLength): void { $generatedToken = $this->tokenGenerator->generateToken($expectedTokenLength); @@ -50,7 +49,7 @@ public function testGenerateToken(int $expectedTokenLength): void * int * }> */ - public function provideDataForTestGenerateToken(): iterable + public static function provideDataForTestGenerateToken(): iterable { yield [ 20, diff --git a/tests/lib/Token/WebSafeGeneratorTest.php b/tests/lib/Token/WebSafeGeneratorTest.php index e3ed9daafb..e02973f20f 100644 --- a/tests/lib/Token/WebSafeGeneratorTest.php +++ b/tests/lib/Token/WebSafeGeneratorTest.php @@ -10,11 +10,11 @@ use Ibexa\Contracts\Core\Token\TokenGeneratorInterface; use Ibexa\Core\Token\WebSafeGenerator; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; -/** - * @covers \Ibexa\Core\Token\WebSafeGenerator - */ +#[CoversClass(WebSafeGenerator::class)] final class WebSafeGeneratorTest extends TestCase { private TokenGeneratorInterface $tokenGenerator; @@ -29,10 +29,9 @@ protected function setUp(): void } /** - * @dataProvider provideDataForTestGenerateToken - * * @throws \Exception */ + #[DataProvider('provideDataForTestGenerateToken')] public function testGenerateToken( int $expectedTokenLength, string $mockGeneratorOutputToken, @@ -63,7 +62,7 @@ public function testGenerateToken( * string * }> */ - public function provideDataForTestGenerateToken(): iterable + public static function provideDataForTestGenerateToken(): iterable { yield [ 20, diff --git a/tests/lib/Validation/Constraint/UniqueIdentifierTest.php b/tests/lib/Validation/Constraint/UniqueIdentifierTest.php index 5346c60bfe..7e5db506b3 100644 --- a/tests/lib/Validation/Constraint/UniqueIdentifierTest.php +++ b/tests/lib/Validation/Constraint/UniqueIdentifierTest.php @@ -9,12 +9,11 @@ namespace Ibexa\Tests\Core\Validation\Constraint; use Ibexa\Contracts\Core\Validation\Constraint\UniqueIdentifier; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; use Symfony\Component\Validator\Attribute\HasNamedArguments; -/** - * @covers \Ibexa\Contracts\Core\Validation\Constraint\UniqueIdentifier - */ +#[CoversClass(UniqueIdentifier::class)] final class UniqueIdentifierTest extends TestCase { public function testNamedArguments(): void diff --git a/tests/lib/Validation/StructValidatorTest.php b/tests/lib/Validation/StructValidatorTest.php index 8a81ab5e6f..2bdd370394 100644 --- a/tests/lib/Validation/StructValidatorTest.php +++ b/tests/lib/Validation/StructValidatorTest.php @@ -10,6 +10,7 @@ use Ibexa\Contracts\Core\Validation\StructValidator; use Ibexa\Contracts\Core\Validation\ValidationFailedException; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; use stdClass; use Symfony\Component\Validator\ConstraintViolation; @@ -18,9 +19,7 @@ use Symfony\Component\Validator\ConstraintViolationListInterface; use Symfony\Component\Validator\Validator\ValidatorInterface; -/** - * @covers \Ibexa\Contracts\Core\Validation\StructValidator - */ +#[CoversClass(StructValidator::class)] final class StructValidatorTest extends TestCase { /** @var \Symfony\Component\Validator\Validator\ValidatorInterface&\PHPUnit\Framework\MockObject\MockObject) */ diff --git a/tests/lib/Validation/StructWrapperValidatorTest.php b/tests/lib/Validation/StructWrapperValidatorTest.php index 154d8c827b..1b27fe3299 100644 --- a/tests/lib/Validation/StructWrapperValidatorTest.php +++ b/tests/lib/Validation/StructWrapperValidatorTest.php @@ -10,6 +10,7 @@ use Ibexa\Contracts\Core\Validation\StructWrapperValidator; use Ibexa\Contracts\Core\Validation\ValidationStructWrapperInterface; +use PHPUnit\Framework\Attributes\CoversClass; use PHPUnit\Framework\TestCase; use stdClass; use Symfony\Component\Validator\ConstraintViolation; @@ -18,9 +19,7 @@ use Symfony\Component\Validator\ConstraintViolationListInterface; use Symfony\Component\Validator\Validator\ValidatorInterface; -/** - * @covers \Ibexa\Contracts\Core\Validation\StructWrapperValidator - */ +#[CoversClass(StructWrapperValidator::class)] final class StructWrapperValidatorTest extends TestCase { /** @var \Symfony\Component\Validator\Validator\ValidatorInterface&\PHPUnit\Framework\MockObject\MockObject */